Bug 735981 - Update breaks behaviour of --one-file-system --relative --delete
Summary: Update breaks behaviour of --one-file-system --relative --delete
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: rsync
Version: 6.6
Hardware: Unspecified
OS: Unspecified
Target Milestone: rc
: ---
Assignee: Michal Ruprich 🐧
QA Contact: BaseOS QE Security Team
Depends On:
TreeView+ depends on / blocked
Reported: 2011-09-06 11:12 UTC by Simon Matter
Modified: 2017-09-06 08:54 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2017-09-06 08:54:34 UTC

Attachments (Terms of Use)

Description Simon Matter 2011-09-06 11:12:31 UTC
Description of problem:
The recent rsync update on RHEL5.7 breaks the options --relative --delete. If it's inteneded behaviour it is at least a regression I guess.

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. on remotehost: mount /var and /var/opt on separate filesystems
2. on remotehost: cp -a /etc /var/opt/XXX
3. on target host: rsync -aHv --delete --numeric-ids --relative --delete-excluded remotehost:/var /home/snapshots/TEST
4. on target host, repeat but with -x: rsync -aHvx --delete --numeric-ids --relative --delete-excluded remotehost:/var /home/snapshots/TEST
Actual results:
/home/snapshots/TEST/var/opt/XXX/ is still there with its content

Expected results:
/home/snapshots/TEST/var/opt/XXX/ should have been removed

Additional info:
This has worked with rsync from EL5.6. With -xx it works but it also removes the mount point itself (which is expected with -xx) but -x should include the the mount point as empty directory, and therefore clean up on the target side.
I have tested with latest rsync from upstream (3.0.8) and it also has the bug/feature. Older versions (at least the 2.x series) work okay and do what the manual says. I consider this a regression at least for EL5.7.

Comment 2 mahaveer darade 2012-05-24 12:53:06 UTC
I tried to check if RHEL-5.5 & RHEL-5.6 works as expected but found that nothing gets deleted under mount point. 

[root@dhcp209-81 /]# mount | grep -i 210.105 on /mnt type nfs (rw,addr= on /mnt/alsa type nfs (rw,addr=
[root@dhcp209-81 /]# ls /mnt/alsa/
bashrc  beah_beaker.conf  beah.conf  blkid  bluetooth  bonobo-activation
[root@dhcp209-81 /]# 
[root@dhcp209-81 /]# cat /etc/redhat-release 
Red Hat Enterprise Linux Server release 5.5 (Tikanga)
[root@dhcp209-81 /]# 

[root@dhcp209-98 /]# ls /tmp/
[root@dhcp209-98 /]# rsync -aH --delete --numeric-ids --relative --delete-excluded /tmp/
root@'s password: 
[root@dhcp209-98 /]# ls /tmp/mnt/alsa/
bashrc  beah_beaker.conf  beah.conf  blkid  bluetooth  bonobo-activation
[root@dhcp209-98 /]# rsync -axH --delete --numeric-ids --relative --delete-excluded /tmp/
root@'s password: 
[root@dhcp209-98 /]# ls /tmp/mnt/alsa/
bashrc  beah_beaker.conf  beah.conf  blkid  bluetooth  bonobo-activation
[root@dhcp209-98 /]# 
[root@dhcp209-98 /]# 
[root@dhcp209-98 /]# cat /etc/redhat-release 
Red Hat Enterprise Linux Server release 5.6 (Tikanga)
[root@dhcp209-98 /]# rpm -qa | grep -i rsync
[root@dhcp209-98 /]# 

As per man page: 
 -x, --one-file-system
              This  tells  rsync to avoid crossing a filesystem boundary when recursing.  This does not limit the user’s ability to specify items to
              copy from multiple filesystems, just rsync’s recursion through the hierarchy of each directory that the user specified, and  ***also  the
              analogous  recursion  on the receiving side during deletion***.

So I guess rsync won't delete files under mount point on receiving end. CMIIW.

Comment 3 Michal Luscon 2012-05-28 15:25:36 UTC
I am confirming the modification of rsync behaviour between 2.x and 3.x version.

Comment 4 RHEL Product and Program Management 2012-06-12 01:14:52 UTC
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated in the
current release, Red Hat is unfortunately unable to address this
request at this time. Red Hat invites you to ask your support
representative to propose this request, if appropriate and relevant,
in the next release of Red Hat Enterprise Linux.

Comment 5 Pavel Šimerda (pavlix) 2014-02-12 15:51:20 UTC
This Bugzilla has been reviewed by Red Hat and is not planned on being addressed in Red Hat Enterprise Linux 5, and therefore will be moved to Red Hat Enterprise Linux 6. If this bug is critical to production systems, please contact your Red Hat support representative and provide sufficient business justification.

Comment 9 Tomáš Hozza 🤓 2017-09-06 08:54:34 UTC
Red Hat Enterprise Linux 6 transitioned to the Production 3 Phase on May 10, 2017.  During the Production 3 Phase, Critical impact Security Advisories (RHSAs) and selected Urgent Priority Bug Fix Advisories (RHBAs) may be released as they become available.

The official life cycle policy can be reviewed here:

This issue does not appear to meet the inclusion criteria for the Production Phase 3 and will be marked as CLOSED/WONTFIX. If this remains a critical requirement, please contact Red Hat Customer Support to request a re-evaluation of the issue, citing a clear business justification.  Red Hat Customer Support can be contacted via the Red Hat Customer Portal at the following URL:


Note You need to log in before you can comment on or make changes to this bug.