Bug 25118 - rsync fails on non existent directories even if ignore is set
Summary: rsync fails on non existent directories even if ignore is set
Status: NEW
Alias: None
Product: Mageia
Classification: Unclassified
Component: Backports (show other bugs)
Version: 7
Hardware: All Linux
Priority: High critical
Target Milestone: ---
Assignee: QA Team
QA Contact:
URL: https://bugzilla.samba.org/show_bug.c...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-07-13 01:39 CEST by Marc Krämer
Modified: 2020-07-26 13:10 CEST (History)
6 users (show)

See Also:
Source RPM: rsync-3.1.3-3.mga7.src.rpm
CVE:
Status comment:


Attachments

Description Marc Krämer 2019-07-13 01:39:47 CEST
When using --delete-missing-args and --ignore-errors with a a file list it terminates anyway if one directory, that is not a sub of root, is not existing.


~$ mkdir test
~$ cd test
test$ mkdir -p src/a trg/a
test$ echo "/a/b/c" > list
test$ /usr/bin/rsync -slt --ignore-errors --force --ignore-missing-args --delete-missing-args --files-from=list --no-implied-dirs src `pwd`/trg
file has vanished: "/home/axel/test/src/a/b"
rsync warning: some files vanished before they could be transferred (code 24) at main.c(1196) [sender=3.1.2]
test$ diff -r src/ trg/
Only in trg/a: b


This behaviour results in data loss due stopped synchronisation. Please add the suggested patch.
The bug was introduced in mga6 with rsync-3.1.2.
Comment 1 Marja Van Waes 2019-07-13 17:57:44 CEST
Assigning to all packagers collectively, since there is no registered maintainer for this package.
Also CC'ing some submitters.

CC: (none) => luigiwalser, mageia, marja11, nicolas.salguero, smelror
Assignee: bugsquad => pkg-bugs

Comment 2 Marc Krämer 2020-07-22 09:02:19 CEST
this is fixed in 3.2.2
Comment 3 Marc Krämer 2020-07-23 11:12:23 CEST
can we backport/update current version of mga7?

Priority: Normal => High
Component: RPM Packages => Backports

Comment 4 David Walser 2020-07-23 14:05:21 CEST
As long as it doesn't break usage with existing servers out there, as has been an issue with rsync in the past, it could be an update.
Comment 5 Marc Krämer 2020-07-23 14:23:53 CEST
to my opinion, it fixes the ones intruduced before.
Having it in backports allows us to test it easier before we ship mga8 where the old version is not available anymore...
Comment 6 Marc Krämer 2020-07-23 14:24:26 CEST
btw. currently I'm runing the mga5 package due to the breakage in mga6!
Marc Krämer 2020-07-25 14:34:06 CEST

Assignee: pkg-bugs => mageia

Marc Krämer 2020-07-25 14:39:24 CEST

Assignee: mageia => qa-bugs

Comment 7 Marc Krämer 2020-07-25 14:39:44 CEST
new version submitted to backports testing.
Comment 8 Rolf Pedersen 2020-07-25 18:10:46 CEST
Howdy-
I've got my own rudimentary rsync backup script, to external drive, initially, and NAS raid 1, currently, that hasn't crashed/terminated prematurely for some years but I thought I'd try this version, fwiw.

[rolf@x570i ~]$ sudo urpmi http://mirrors.kernel.org/mageia/distrib/7/x86_64/media/core/backports_testing/rsync-3.2.2-1.mga7.x86_64.rpm
To satisfy dependencies, the following packages are going to be installed:
  Package                        Version      Release       Arch    
(medium "Core Release")
  lib64xxhash0                   0.7.0        2.mga7        x86_64  
(command line)
  rsync                          3.2.2        1.mga7        x86_64  
399KB of additional disk space will be used.
429KB of packages will be retrieved.
Proceed with the installation of the 2 packages? (Y/n) 


    http://mirrors.kernel.org/mageia/distrib/7/x86_64/media/core/release/lib64xxhash0-0.7.0-2.mga7.x86_64.rpm
installing /var/cache/urpmi/rpms/lib64xxhash0-0.7.0-2.mga7.x86_64.rpm                                                   
/var/cache/urpmi/partial/rsync-3.2.2-1.mga7.x86_64.rpm
Preparing...                     ######################################################################################
      1/2: lib64xxhash0          ######################################################################################
      2/2: rsync                 ######################################################################################
      1/1: removing rsync-3.1.3-4.mga7.x86_64
                                 ######################################################################################
[rolf@x570i ~]$

The command is thus:
[rolf@x570i rsync]$ sh ./rolf.backup.rsync.command327.sh
which script refers to a files list and I could provide more info, if needed, but didn't think it necessary.

There were a couple of errors reported, one related to a path in the list that is no longer, but the sync completed w/o crashing/terminating:

---
sending incremental file list
rsync: [sender] link_stat "/movie/lan" failed: No such file or directory (2)

sent 19 bytes  received 12 bytes  62.00 bytes/sec
total size is 0  speedup is 0.00
rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1287) [sender=3.2.2]
---
rsync: [receiver] close failed on "/mnt/327md0/backup/rolf/.mozilla/seamonkey/w1o08opq.default/Mail/pop.gmail.com/.motionEye.9hg0zM": Input/output error (5)
rsync error: error in file IO (code 11) at receiver.c(868) [receiver=3.2.2]

Thanks

CC: (none) => rolfpedersen

Comment 9 Marc Krämer 2020-07-26 13:10:46 CEST
I think, this still looks ok. I assume the file with the "error" was delted/renamed during transfer.

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