Currently I only have one machine backing up to another. I am backing up to a filesystem that is mounted as nosuid. The syncing process works perfectly except it fails on files that are suid. Example proc/ root/ tmp/ mknod tmp/mysql.sock : Invalid argument mknod tmp/orbit-daud/orb-12573780511489051058 : Invalid argument mknod tmp/orbit-daud/orb-139425434385535813 : Invalid argument mknod var/pwcheck/pwcheck : Invalid argument var/run/ mknod var/run/log : Invalid argument mknod var/run/ndc : Invalid argument mknod var/run/printer : Invalid argument srw-rw-rw- 1 root wheel 0 Jan 23 11:52 log srw------- 1 root wheel 0 Jan 23 11:53 ndc srwxrwx--- 1 root wheel 0 Jan 23 11:53 printer I would figure that copying the file and setting the file typr would be different. Is this the rsyncd that is seeing the file system set nosuid or has anyone else run into this sort of problem? I would really rather not have suid files allowed on the backup filesystem. Regards, Steve -- Systems Administrator | D i m e n s i o n a l C o m m u n i c a t i o n s | support@dim.com | DSL/V90/K56flex/V34/ISDN/Frame/T1/T3 starts @$25/mo | 303.285.INET voice | http://www.dimensional.com/ info@dimensional.com | 888.3.DIMCOM tollfree | fast reliable internet access for home and business | 303.609.9373 emergency | Denver * Boulder * Longmont * Bailey * CO Springs |
Excuse my poor question/phrasing I am in alot of pain and on alot of fun drugs. hosta = backup machine hostb = rsync client hosta has a filesytem labelled /backup. It is mounted as rw,nosuid hostb is sucessfully backing up all files except ones currently suid. I would gather that it would copy the file over just ignore the +s bit in the file... I hope this is more clear. Steve On Thu, Jan 24, 2002 at 10:27:07AM -0700, Steve wrote:> Currently I only have one machine backing up to another. I am > backing up to a filesystem that is mounted as nosuid. The syncing process > works perfectly except it fails on files that are suid. > > Example > > proc/ > root/ > tmp/ > mknod tmp/mysql.sock : Invalid argument > mknod tmp/orbit-daud/orb-12573780511489051058 : Invalid argument > mknod tmp/orbit-daud/orb-139425434385535813 : Invalid argument > > > mknod var/pwcheck/pwcheck : Invalid argument > var/run/ > mknod var/run/log : Invalid argument > mknod var/run/ndc : Invalid argument > mknod var/run/printer : Invalid argument > > > srw-rw-rw- 1 root wheel 0 Jan 23 11:52 log > srw------- 1 root wheel 0 Jan 23 11:53 ndc > srwxrwx--- 1 root wheel 0 Jan 23 11:53 printer > > > I would figure that copying the file and setting the file typr would be > different. Is this the rsyncd that is seeing the file system set nosuid > or has anyone else run into this sort of problem? I would really rather > not have suid files allowed on the backup filesystem. > > Regards, > Steve > > -- > Systems Administrator | D i m e n s i o n a l C o m m u n i c a t i o n s | > support@dim.com | DSL/V90/K56flex/V34/ISDN/Frame/T1/T3 starts @$25/mo | > 303.285.INET voice | http://www.dimensional.com/ info@dimensional.com | > 888.3.DIMCOM tollfree | fast reliable internet access for home and business | > 303.609.9373 emergency | Denver * Boulder * Longmont * Bailey * CO Springs | >-- Systems Administrator | D i m e n s i o n a l C o m m u n i c a t i o n s | support@dim.com | DSL/V90/K56flex/V34/ISDN/Frame/T1/T3 starts @$25/mo | 303.285.INET voice | http://www.dimensional.com/ info@dimensional.com | 888.3.DIMCOM tollfree | fast reliable internet access for home and business | 303.609.9373 emergency | Denver * Boulder * Longmont * Bailey * CO Springs |
rsync tries to make the files the same. If you include mode, that's that. Perhaps you could modify generator.c for your own copy, to mask off the suid and sgid bits, so the list would make them all look non-suid, source and dest, and thus not try to set them, and not care that they're not set. I'm not sure it's generator.c, but i'm sure you can find it. Tim Conway tim.conway@philips.com 303.682.4917 Philips Semiconductor - Longmont TC 1880 Industrial Circle, Suite D Longmont, CO 80501 Available via SameTime Connect within Philips, n9hmg on AIM perl -e 'print pack(nnnnnnnnnnnn, 19061,29556,8289,28271,29800,25970,8304,25970,27680,26721,25451,25970), ".\n" ' "There are some who call me.... Tim?" Steve <stephen@dim.com> Sent by: rsync-admin@lists.samba.org 01/24/2002 10:27 AM To: rsync@lists.samba.org cc: (bcc: Tim Conway/LMT/SC/PHILIPS) Subject: suid files and bsd Classification: Currently I only have one machine backing up to another. I am backing up to a filesystem that is mounted as nosuid. The syncing process works perfectly except it fails on files that are suid. Example proc/ root/ tmp/ mknod tmp/mysql.sock : Invalid argument mknod tmp/orbit-daud/orb-12573780511489051058 : Invalid argument mknod tmp/orbit-daud/orb-139425434385535813 : Invalid argument mknod var/pwcheck/pwcheck : Invalid argument var/run/ mknod var/run/log : Invalid argument mknod var/run/ndc : Invalid argument mknod var/run/printer : Invalid argument srw-rw-rw- 1 root wheel 0 Jan 23 11:52 log srw------- 1 root wheel 0 Jan 23 11:53 ndc srwxrwx--- 1 root wheel 0 Jan 23 11:53 printer I would figure that copying the file and setting the file typr would be different. Is this the rsyncd that is seeing the file system set nosuid or has anyone else run into this sort of problem? I would really rather not have suid files allowed on the backup filesystem. Regards, Steve -- Systems Administrator | D i m e n s i o n a l C o m m u n i c a t i o n s | support@dim.com | DSL/V90/K56flex/V34/ISDN/Frame/T1/T3 starts @$25/mo | 303.285.INET voice | http://www.dimensional.com/ info@dimensional.com | 888.3.DIMCOM tollfree | fast reliable internet access for home and business | 303.609.9373 emergency | Denver * Boulder * Longmont * Bailey * CO Springs |
Hi there, The "s" in the permissions isn't in reference to the setuid bit. It's referencing the fact that those files are Unix domain sockets (if they were setuid, the "s" would be in place of the user's "x", ie "-rwsr-xr-x"). The reason it is failing is because BSD's mknod (which rsync uses to create all special files) cannot be used to create Unix domain sockets. This also applies to named pipes A while back, I created a patch for rsync that would use socket(2)/bind(2) and mkfifo(2) to create those special files on systems where those functions are available. You can get the patch here: http://lists.samba.org/pipermail/rsync/2000-December/003349.html I have not tried applying the patch to 2.5.x. It's possible that it would require some tweaking. Good luck. Andrew> >Date: Thu, 24 Jan 2002 10:27:07 -0700 >From: Steve <stephen@dim.com> >To: rsync@lists.samba.org >Subject: suid files and bsd > > Currently I only have one machine backing up to another. I am >backing up to a filesystem that is mounted as nosuid. The syncing process >works perfectly except it fails on files that are suid. > >Example > >proc/ >root/ >tmp/ >mknod tmp/mysql.sock : Invalid argument >mknod tmp/orbit-daud/orb-12573780511489051058 : Invalid argument >mknod tmp/orbit-daud/orb-139425434385535813 : Invalid argument > > >mknod var/pwcheck/pwcheck : Invalid argument >var/run/ >mknod var/run/log : Invalid argument >mknod var/run/ndc : Invalid argument >mknod var/run/printer : Invalid argument > > >srw-rw-rw- 1 root wheel 0 Jan 23 11:52 log >srw------- 1 root wheel 0 Jan 23 11:53 ndc >srwxrwx--- 1 root wheel 0 Jan 23 11:53 printer > > >I would figure that copying the file and setting the file typr would be >different. Is this the rsyncd that is seeing the file system set nosuid >or has anyone else run into this sort of problem? I would really rather >not have suid files allowed on the backup filesystem. > >Regards, >Steve > >-- >Systems Administrator | D i m e n s i o n a l C o m m u n i c a t i o n s | >support@dim.com | DSL/V90/K56flex/V34/ISDN/Frame/T1/T3 starts @$25/mo | >303.285.INET voice | http://www.dimensional.com/ info@dimensional.com | >888.3.DIMCOM tollfree | fast reliable internet access for home and business | >303.609.9373 emergency | Denver * Boulder * Longmont * Bailey * CO Springs | >