> i just converted a server over to centos 4 and the rsync daemon is dying > with a segv. i've checked the redhat bugzilla and googled around some and > don't see anything obvious. > > the client connects and authenticates, and the server starts sending some > data but then dies after about 8k. strace'ing hasn't shown anything > obvious other than the segv. another user was able to confirm similar problems and i finally started digging around with gdb and friends. what i have determined is that this is probably a bug in libc, with some help from rsync. the problem seems to be that rsync is chroot'ing and trying to map uids to names for the -o option (to preserve ownership). this only occurs if files are owned by someone other than root and the remote user has requested -o. in my particular case, i normally use nis and rsync is reading that from nsswitch.conf before chrooting. when it tries to map uids, it tries valiantly to find libnss_nis.so in the chroot area and fails and that seems to cause a segfault. if rsync chroot'ed earlier, this might not happen, or if i wasn't using nis it might not happen. i haven't been able to test the latter. what i was able to do was chown everything to root since then rsync short circuits the getpwuid and doesn't crash. this is fine for now. i'll be contacting the rsync maintainer to see if he has any input.