rsync --delete-missing-args fails with "error: protocol incompatibility"
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
rsync (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned | ||
Xenial |
Won't Fix
|
Undecided
|
Unassigned | ||
Bionic |
Fix Released
|
Low
|
Lena Voytek | ||
Focal |
Fix Released
|
Low
|
Lena Voytek |
Bug Description
[Impact]
Rsync crashes when using --delete-
Backporting this fix will allow users to delete missing source args when some files in the list have missing parent folders without interruption.
This is fixed by patching in an upstream commit that allows files with missing parent folders to be handled without aborting.
[Test Plan]
# lxc launch images:ubuntu/focal builder
# lxc exec builder bash
# apt update
# apt dist-upgrade
# apt install -y rsync
# mkdir -p a/1 b/1; echo "/1/2/3" > list
# rsync --dry-run --stats -Pav --delete-
* This should crash with exit code 2 after printing the following:
building file list ...
0 files...
file has vanished: "/root/a/1/2"
2 files to consider
ABORTING due to invalid path from sender: 1/2/3
rsync error: protocol incompatibility (code 2) at generator.c(1278) [generator=3.1.3]
[Where problems could occur]
Since the remove operation will now continue when files in the list have missing parent folders, other errors and warnings with different behaviors could arise instead.
A warning that may arise the most often in these situations is the following:
warning: some files vanished before they could be transferred (code 24) at main.c(1207) [sender=3.1.3]
This appears at the end of the above test case with the new code. The behavior is expected, but it may cause regressions due to changes in the output of certain use cases.
[Original Description]
Running
rsync --delete-
fails with error message like
ABORTING due to invalid path from sender: dir1/dir2/dir3
rsync error: protocol incompatibility (code 2) at generator.c(1271) [generator=3.1.2]
if the listed directories are trying to delete full subtree of files.
According to https:/
See also: https:/
Could you update the rsync package or backport the fix?
ProblemType: Bug
DistroRelease: Ubuntu 18.04
Package: rsync 3.1.2-2.1ubuntu1.1
ProcVersionSign
Uname: Linux 5.4.0-47-lowlatency x86_64
ApportVersion: 2.20.9-0ubuntu7.17
Architecture: amd64
CurrentDesktop: MATE
Date: Fri Sep 18 18:27:53 2020
EcryptfsInUse: Yes
InstallationDate: Installed on 2019-01-05 (621 days ago)
InstallationMedia: Ubuntu 18.04.1 LTS "Bionic Beaver" - Release amd64 (20180725)
SourcePackage: rsync
UpgradeStatus: No upgrade log present (probably fresh install)
Related branches
- Sergio Durigan Junior (community): Approve
- Canonical Server: Pending requested
-
Diff: 74 lines (+60/-0)2 files modifieddebian/changelog (+9/-0)
debian/patches/allow-missing-parent-dir-delete-missing-args.patch (+51/-0)
- Sergio Durigan Junior (community): Approve
- Canonical Server: Pending requested
- git-ubuntu import: Pending requested
-
Diff: 97 lines (+63/-1)4 files modifieddebian/changelog (+9/-0)
debian/control (+2/-1)
debian/patches/allow-missing-parent-dir-delete-missing-args.patch (+51/-0)
debian/patches/series (+1/-0)
Changed in rsync (Ubuntu Bionic): | |
status: | New → Triaged |
Changed in rsync (Ubuntu Focal): | |
status: | New → Triaged |
tags: | added: server-next |
Changed in rsync (Ubuntu Xenial): | |
status: | New → Triaged |
tags: | removed: server-next |
tags: | added: server-todo |
Changed in rsync (Ubuntu Bionic): | |
assignee: | nobody → Lena Voytek (lvoytek) |
Changed in rsync (Ubuntu Focal): | |
assignee: | nobody → Lena Voytek (lvoytek) |
Changed in rsync (Ubuntu Bionic): | |
status: | Triaged → In Progress |
Changed in rsync (Ubuntu Focal): | |
status: | Triaged → In Progress |
description: | updated |
I forgot to mention that according to https:/ /bugs.debian. org/cgi- bin/bugreport. cgi?bug= 863334 this issue does not exist in version 3.1.1-3. That should help pinpointing the actual problem if you want to backport the fix instead of upgrading the whole rsync package to latest version.