Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 49707

Summary: rsync-2.6.2-r1 fails to start, looking for config file in wrong directory
Product: Gentoo Linux Reporter: Aaron Riekenberg <aaron>
Component: New packagesAssignee: Martin Holzer (RETIRED) <mholzer>
Status: RESOLVED FIXED    
Severity: normal CC: gustav.schaffter
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 49534    

Description Aaron Riekenberg 2004-05-02 07:59:22 UTC
After I emerge rsync-2.6.2-r1, rsyncd looks for the configuration file /etc/rsyncd.conf instead of /etc/rsync/rsyncd.conf.  Since /etc/rsyncd.conf is not created by the ebuild, rsyncd fails to start.

Reproducible: Always
Steps to Reproduce:
1. emerge =net-misc/rsync-2.6.2-r1
2. /etc/init.d/rsyncd start


Actual Results:  
/var/log/daemon.log contains the following:

May  2 09:41:41 files rsyncd[5792]: rsync: unable to open configuration file
"/etc/rsyncd.conf": No such file or directory 
May  2 09:41:41 files rsyncd[5792]: rsync error: syntax or usage error (code 1)
at clientserver.c(586) 

Also, ps shows rsync is not running.


The problem here is the following call to sed in the src_unpack function in the
ebuild:
    sed -i \
        -e 's|/etc/rsyncd.conf|/etc/rsync/rsyncd.conf|g' \
        rsync.h \
        || die "sed rsync.h failed"

rsync.h does not contain /etc/rsyncd.conf with rsync-2.6.2-r1, so this sed does
nothing.

I changed the call to econf in src_compile from this:

    econf \
        $(use_with build included-popt) \
        $(use_with acl acl-support) \
        || die

to this:
    econf \
        $(use_with build included-popt) \
        $(use_with acl acl-support) \
        --with-rsyncd-conf=/etc/rsync/rsyncd.conf \
        || die

and it fixed the problem.  It also seems a little less evil than using sed on a
header file.
Comment 1 Craig Bradney 2004-05-02 09:38:23 UTC
Same issue here, it will start, but wont read the conf file. Then u cant kill it because it doesnt know where the pid file is.
Comment 2 Martin Holzer (RETIRED) gentoo-dev 2004-05-02 15:20:48 UTC
*** Bug 49731 has been marked as a duplicate of this bug. ***
Comment 3 Martin Holzer (RETIRED) gentoo-dev 2004-05-02 15:52:02 UTC
fixed with rsync-2.6.2-r2.ebuild
Comment 4 Martin Holzer (RETIRED) gentoo-dev 2004-05-02 15:52:19 UTC
closing