main/rsync: rsync error: protocol incompatibility (code 2) at flist.c(998) [Receiver=3.2.4]
This problem started occurring after commit 586e4055 (CVE-2022-29154) on alpine 3.16.2 with rsync-3.2.4-r2. The environment consists of an alpine rsnapshot container pulling from an alpine rsyncd container.
echo 1 > /var/run/rsnapshot.pid
/usr/bin/rsync -a --delete --numeric-ids --relative --delete-excluded \
--include=.var/app/io.mpv.Mpv/config/mpv/mpv.conf --exclude=.cache/ \
--exclude=.conan/data/ --exclude=.config/google-chrome/ \
--exclude=.irssi/perl/ --exclude=.local/share/containers/ \
--exclude=.nvm/ --exclude=.pyenv/ --exclude=.var/ \
--exclude=container-roots/ --exclude=LittleNavmap/ --exclude=sandbox/ \
--exclude=Zoiper5/ --link-dest=/mnt/state.0// rsync://zarya:39775/mnt/ \
/mnt/.sync//
ERROR: rejecting unrequested file-list name: /.
rsync error: protocol incompatibility (code 2) at flist.c(998) [Receiver=3.2.4]
----------------------------------------------------------------------------
rsnapshot encountered an error! The program was invoked with these options:
/usr/bin/rsnapshot sync
----------------------------------------------------------------------------
ERROR: /usr/bin/rsync returned 2 while processing rsync://zarya:39775/mnt/
/bin/rm -rf /mnt/.sync//
WARNING: Rolling back "/"
/bin/cp -al /mnt/state.0 /mnt/.sync
touch /mnt/.sync/
rm -f /var/run/rsnapshot.pid
Although the above log already has an absolute path target, I have also tried putting the target in a sub-directory since the patch mentions it. The result is the same.
echo 1 > /var/run/rsnapshot.pid
/usr/bin/rsync -a --delete --numeric-ids --relative --delete-excluded \
--include=.var/app/io.mpv.Mpv/config/mpv/mpv.conf --exclude=.cache/ \
--exclude=.conan/data/ --exclude=.config/google-chrome/ \
--exclude=.irssi/perl/ --exclude=.local/share/containers/ \
--exclude=.nvm/ --exclude=.pyenv/ --exclude=.var/ \
--exclude=container-roots/ --exclude=LittleNavmap/ --exclude=sandbox/ \
--exclude=Zoiper5/ rsync://zarya:38257/mnt/ /mnt/.sync/zarya/
ERROR: rejecting unrequested file-list name: /.
rsync error: protocol incompatibility (code 2) at flist.c(998) [Receiver=3.2.4]
----------------------------------------------------------------------------
rsnapshot encountered an error! The program was invoked with these options:
/usr/bin/rsnapshot sync
----------------------------------------------------------------------------
ERROR: /usr/bin/rsync returned 2 while processing rsync://zarya:38257/mnt/
touch /mnt/.sync/
rm -f /var/run/rsnapshot.pid