Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Description of problem:
The current rsync version in RHEL 7.6 has a bug that is significantly hurting our performance. It sets the modification time with utimensat() on every destination file, even when they haven't changed, when the source filesystem has nanosecond granularity and the destination filesystem has second granularity.
Version-Release number of selected component (if applicable):
3.1.2-4.el7
How reproducible:
Very
Steps to Reproduce:
Assuming /tmp is a filesystem like ext4 with nanosecond granularity
1. cd /tmp
2. mkdir in out
3. dd if=/dev/zero of=out.ext3 bs=1M count=10
4. mkfs -t ext3 out.ext3
answer y
5. sudo mount -o loop out.ext3 /tmp/out
6. sudo chown $LOGNAME out
7. echo hello >in/file
9. rsync -a in/ out/
10. strace -f rsync -a in/ out/ 2>&1 | grep utimensat
Actual results:
Prints two calls to utimensat every time command 10 is run.
Expected results:
No calls to utimensat.
Additional info:
This bug was introduced in bug #1393543 which upgraded to rsync-3.1.2-4 and introduced support for nanosecond timestamps. This is a known bug upstream that was fixed in rsync-3.1.3, released January 2018. Here is the patch:
https://git.samba.org/?p=rsync.git;a=patch;h=0f8e9e2d8638e47d646a6baba694b303ac84e695;hp=c4a3f55be35726d0a033996dc37b0fb248b45cb5
I added the patch to a private build of the rsync-3.1.2-4.el7.src.rpm and it solved the problem.
Besides the extra overhead of unnecessarily setting the timestamp, this hurts our performance worse because we are writing into a filesystem based on overlayfs and it is causing every file to be copied into the upper layer. Those files are then processed further by our application (cvmfs) which has even more overhead.
There were also two security fixes in rsync-3.1.3 that do not appear to be in the RHEL 7.6 distribution. See these descriptions:
https://rsync.samba.org/security.html#s3_1_3https://download.samba.org/pub/rsync/src/rsync-3.1.3-NEWS
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory, and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.
https://access.redhat.com/errata/RHBA-2020:1046