Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 730708 - net-misc/rsync-3.2.{0,1} - segmentation fault with transfer logging enabled
Summary: net-misc/rsync-3.2.{0,1} - segmentation fault with transfer logging enabled
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Gentoo's Team for Core System packages
URL: https://www.mail-archive.com/gentoo-u...
Whiteboard: Fixed in >=net-misc/rsync-3.2.2
Keywords:
Depends on: 734170
Blocks:
  Show dependency tree
 
Reported: 2020-07-04 11:07 UTC by Rainer Meier
Modified: 2020-08-05 14:27 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Rainer Meier 2020-07-04 11:07:32 UTC
I am using rsync over ssh.The remote (ssh) user has its own rsyncd.conf in its home directory defining the sync services.

Whenever the "transfer logging = yes" option is used in one of them it will make the rsync server component segfault.

Example rsyncd.conf of user 'syncsshuser':

use chroot = false
strict modes = false
read only = true
write only = false
timeout = 120

[myshare]
        path = /srv/shares/myshare/
        write only = true
        read only = false
        transfer logging = yes
        auth users = rsyncuser
        secrets file = rsyncd.secrets


Of course it also needs rsyncd.secrets; eg.
rsyncuser:mysecret



Then run rsync on the remote system:
export RSYNC_PASSWORD=mysecret
rsync -e "ssh -i /path/to/id_rsy -l syncsshuser" /some/path/ rsyncsuser@remote-hostname::myshare/

This will result in a segmentation fault (SIGSEGV) when invoking rsync daemon on remote side. The client returns "rsync: didn't get server startup line" due to failed rsync daemon fork and broken communication.

Removing the "transfer logging" option from the configuration resolves the issue.

I found a potentially related topic on the mailing list: https://www.mail-archive.com/gentoo-user@lists.gentoo.org/msg181658.html



Reproducible: Always

Steps to Reproduce:
1. Create SSH user to run the sync with on remote host.
2. Create rsyncd.conf service with "transfer logging" enabled within the home directory of the sync user
3. Run sync using the defined service
Actual Results:  
Rsync fails:

rsync: didn't get server startup line
rsync error: error starting client-server protocol (code 5) at main.c(1777) [sender=3.2.0]

Expected Results:  
Transfer starting and synchronization to be initiated.

Not sure if this could be related to some communication issue with syslog or similar.
Comment 1 BT 2020-07-06 04:19:28 UTC
This should be fixed in 3.2.2. https://github.com/WayneD/rsync/commit/317beebef8b0f60eb36255b35cbea71c84f6ac38
Comment 2 Lars Wendler (Polynomial-C) (RETIRED) gentoo-dev 2020-07-06 08:00:19 UTC
Rainer, can you please test rsync-3.2.2 and report back your results?
Comment 3 Rainer Meier 2020-07-06 15:21:14 UTC
I confirm rsync 3.2.2 is resolving the problem.
Transfer logging with the default log format is working again and not segfaulting rsync.
Comment 4 Lars Wendler (Polynomial-C) (RETIRED) gentoo-dev 2020-07-06 17:56:57 UTC
Let's keep this bug open until a newer version has been stabilized.