Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 203646 - net-fs/nfs-utils - rpc.statd fails to start due to is_running() in init script returning wrong value
Summary: net-fs/nfs-utils - rpc.statd fails to start due to is_running() in init scrip...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Network Filesystems
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-12-29 02:31 UTC by sourlover
Modified: 2007-12-29 13:46 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 sourlover 2007-12-29 02:31:44 UTC
If rpc.statd (from nfs-utils-1.1.0-r1) is not running, and I try to start it with "/etc/init.d/rpc.statd start" nothing happens, i.e. there is no output and statd is not started.

I've traced the problem to the is_running() function. The single command in that function should be returning nonzero if rpc.statd is not running, but this does not happen. I've checked by changing the function to:

is_running() {
   killall -0 rpc.statd 2>/dev/null
   echo $?
}

With that change, if rpc.statd is not running, "/etc/init.d/rpc.statd start" prints 0, and nothing else happens (in this case it would be expected, since the echo command itself will return 0, but the point is that killall does, too).

The strange thing is, if I run the command outside emerge (if rpc.statd is not running), I get the expected behaviour:

# killall -0 rpc.statd; echo $?
rpc.statd: no process killed
1

I'm confused. Does portage perhaps override killall to an internal function? In any case, the behavior is wrong..

Reproducible: Always

Steps to Reproduce:
Comment 1 Jakub Moc (RETIRED) gentoo-dev 2007-12-29 02:42:28 UTC

*** This bug has been marked as a duplicate of bug 60362 ***
Comment 2 sourlover 2007-12-29 02:44:38 UTC
I did find that bug before, along with a number of others, but nothing there helps solve this problem. Please don't close bugs without looking into them.
Comment 3 Jakub Moc (RETIRED) gentoo-dev 2007-12-29 02:45:54 UTC
Yeah I did look at the bug. Complain to whomever closed the original one, this is the same dupe like the rest of others there.


*** This bug has been marked as a duplicate of bug 60362 ***
Comment 4 sourlover 2007-12-29 02:52:00 UTC
It does actually contain more info than the others. And since I can't reopen them, what am I supposed to do? Mail vapier (he closed the "original" bug)?
If you were trying to be helpful, you might have assigned the bug to him insted of closing it.
Comment 5 Jakub Moc (RETIRED) gentoo-dev 2007-12-29 02:56:40 UTC
This is exact same thing like Bug 175287 which was marked as dupe bug 60362; so yeah, take this w/ vapier and ask him why's the original bug resolved.
Comment 6 SpanKY gentoo-dev 2007-12-29 06:38:52 UTC
i dont know why you think it's a duplicate because it isnt
Comment 7 SpanKY gentoo-dev 2007-12-29 06:41:09 UTC
prob because i mis-duped Bug 175287 ... oh well

legate: do you have RPCSTATDOPTS set ?
Comment 8 SpanKY gentoo-dev 2007-12-29 06:48:03 UTC
no, that isnt the problem ... problem is that the killall detects the init.d script itself which is also named "rpc.statd" :/
Comment 10 sourlover 2007-12-29 13:46:39 UTC
Wow, way to think outside the box.. It's one of those things I never would have come up with, without going all-out with ltrace or the like. Especially since the next call in start() is a "return 0", which I just assumed was getting run.

And I was really starting to question my sanity.. Whatever you're making, you need to be in a higher pay grade. Thanks.