Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 39052 - rsync script does not create pid file!
Summary: rsync script does not create pid file!
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Server (show other bugs)
Hardware: x86 Linux
: High critical (vote)
Assignee: SpanKY
URL:
Whiteboard:
Keywords:
: 39049 (view as bug list)
Depends on:
Blocks:
 
Reported: 2004-01-22 11:07 UTC by Stephen Bosch
Modified: 2004-01-22 23:42 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 Stephen Bosch 2004-01-22 11:07:30 UTC
When the user starts an rsync daemon using the /etc/init.d/rsyncd script, a pid file is not created in /var/run. When the user then tries to gracefully stop the daemon using the same script, the stop fails; the daemon continues to run. Manually killing the process works, but there is no cleanup, and runscript continues to think that the process is running, even though it is not.

Reproducible: Always
Steps to Reproduce:
1.add "--config=/etc/conf.d/rsyncd" to /etc/make.conf
2.run '/etc/init.d/rsyncd start'
3.run '/etc/init.d/rsyncd stop' or '/etc/init.d/rsyncd restart'


Actual Results:  
root@moose:/home/sfbosch# /etc/init.d/rsyncd restart
 * Stopping rsyncd...
cat: /var/run/rsyncd.pid: No such file or directory
kill: usage: kill [-s sigspec | -n signum | -sigspec] [pid | job]... or kill -l
[sigspec]                                                                 [ !! ]

root@moose:/home/sfbosch#

Expected Results:  
root@moose:/home/sfbosch# /etc/init.d/rsyncd restart
 * Stopping rsyncd...                                                     [ ok ]
 * Starting rsyncd...                                                     [ ok ]
root@moose:/home/sfbosch#
Comment 1 Martin Holzer (RETIRED) gentoo-dev 2004-01-22 11:14:51 UTC
*** Bug 39049 has been marked as a duplicate of this bug. ***
Comment 2 SpanKY gentoo-dev 2004-01-22 18:22:27 UTC
uhh, why are you using --config=/etc/conf.d/rsyncd ?
Comment 3 SpanKY gentoo-dev 2004-01-22 18:23:42 UTC
actually, i lied, i dont really care why you're doing it, thats just wrong :)

if you change the default config file location it's your problem to make sure that you have the pid location set correctly

the default config file sets the .pid to /var/run/rsyncd.pid
Comment 4 Stephen Bosch 2004-01-22 22:49:44 UTC
There is no default config, which is why you have to set the config in the first place.

That's the bug -- if there had been a default config, rsync would be starting and stopping normally, and it doesn't.

Try it yourself.
Comment 5 Stephen Bosch 2004-01-22 22:52:27 UTC
Note also that it is the ebuild that installs the /etc/conf.d/rsyncd file, but neglects to put in the standard /etc/rsyncd.conf file.
Comment 6 SpanKY gentoo-dev 2004-01-22 22:54:39 UTC
there is a default config, /etc/rsync/rsyncd.conf
Comment 7 Stephen Bosch 2004-01-22 23:23:26 UTC
This is silly.

Here are the facts. The default rsync ebuild does not start nor stop properly. Why? Because the ebuild doesn't create /etc/rsyncd/rsyncd.conf. I had to create it myself -- that's the only reason my system even has one.

The ebuild *does* create /etc/conf.d/rsyncd, and so that is why I suggested that in the "steps to reproduce". I see no sense in adding extra steps if they're not necessary.

If you haven't even tried to reproduce it, then pass the bug on to somebody else. I'm not the first person to have this problem -- have a look in the forums.
Comment 8 SpanKY gentoo-dev 2004-01-22 23:32:57 UTC
you've neglected to give me the version your working with here

and, looking at a quick test, the file is installed just fine over here:
root@vapier 0 etc # ebuild /usr/portage/net-misc/rsync/rsync-2.6.0.ebuild clean unpack compile install
<snip>
root@vapier 0 etc # ls /var/tmp/portage/rsync-2.6.0/image/etc/rsync/
rsyncd.conf
root@vapier 0 etc # ebuild /usr/portage/net-misc/rsync/rsync-2.5.7.ebuild clean unpack compile install
<snip>
root@vapier 0 etc # ls /var/tmp/portage/rsync-2.5.7/image/etc/rsync/
rsyncd.conf

perhaps you can see why i say this is an invalid bug ... ive tried to reproduce it and guess what ! no bugs here !
Comment 9 Stephen Bosch 2004-01-22 23:38:30 UTC
I'm using 2.6.0.

Okay - fine -- I just unmerged it and re-merged it, and now the file is created properly. Don't ask me what was happening before, I'm just happy it's fixed.

It *is* odd, however, that this seems to happen to people from time to time. Any idea why? What would cause some config files to not be created?

Comment 10 SpanKY gentoo-dev 2004-01-22 23:42:38 UTC
no idea ... there is a little logic to check to see if the file exists already and if it doesnt, dont install the conf ... perhaps that tripped up in the past ...

cant say really because like i said, i've never had this bug ;)