[PATCH] One more -x to not traverse cyclic bind-mounts

Jeff Hansen jhansen at cardaccess-inc.com
Thu Jan 13 11:24:21 MST 2011


This patch allows one to repeat the '-x' option a third time to stop 
rsync from traversing potentially cyclic bind mounts that are on the 
same filesystem.

For example, the following scenario would cyclically traverse the bind 
mounts until the OS (Linux in this case) hits a maximum traversal count, 
thank goodness.  Other OSes may traverse the bind mount indefinitely...

su
cd
mkdir ~/cycle
touch ~/cycle/file.txt
mkdir ~/cycle/cycle
mount -o bind ~/cycle ~/cycle/cycle
rsync -avxx ~/cycle ~/cycle2

Please let me if there is any feedback on this patch and when/if this 
patch can be merged.  Thanks!

-Jeff

-- 
//Jeff Hansen
////Card Access, Inc.//
//11778 So. Election Rd., Ste. 260//
//Salt Lake City, UT 84020//
//JHansen at CardAccess-inc.com// <mailto:JHansen at CardAccess-inc.com>
//www.CardAccess-inc.com <http://www.cardaccess-inc.com/>//
//801-748-4900 ext 26 (Office)//
//801-748-4901 (fax)//

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.samba.org/pipermail/rsync/attachments/20110113/1b9cb3c1/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: rsync-3.0.7-one-file-system.patch
Type: text/x-patch
Size: 2549 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/rsync/attachments/20110113/1b9cb3c1/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5622 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://lists.samba.org/pipermail/rsync/attachments/20110113/1b9cb3c1/attachment-0001.bin>


More information about the rsync mailing list