Bug 53265 - rpc.statd fails to start.
rpc.statd fails to start.
Product: Red Hat Linux
Classification: Retired
Component: nfs-utils (Show other bugs)
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Pete Zaitcev
Brian Brock
Depends On:
  Show dependency treegraph
Reported: 2001-09-05 15:17 EDT by lars
Modified: 2007-04-18 12:36 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2004-04-19 15:32:04 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description lars 2001-09-05 15:17:42 EDT
Description of Problem:

Any attempt to start rpc.statd fails with the following error in

nfslock: rpc.statd startup succeeded
rpc.statd[8286]: Cannot access current directory after dropping privs:

Version-Release number of selected component (if applicable):


How Reproducible:

Just run rpc.statd; you can also run the 'nfslock' init script.

Steps to Reproduce:

Actual Results:

Expected Results:

Additional Information:

Just for kicks I tried changing to /tmp and then rpc.statd by hand, and it
still fails with the same error.  The error is accurate; an strace of the
process concludes with:

8222  setuid32(0x1d)                    = 0
8222  getgid32()                        = 29
8222  getuid32()                        = 29
8222  access(".", R_OK|W_OK|X_OK)       = -1 EACCES (Permission denied)
Comment 1 lars 2001-09-05 15:39:23 EDT
So, the problem is pretty obvious.  rpc.statd changes to uid 29/gid 29
(rpcuser/rpcuser), and tries to chdir() to /var/lib/nfs/statd.  The permissions
in /var/lib/nfs look like this:

-rw-r--r--    1 root     root          799 Sep  4 16:21 etab
-rw-r--r--    1 root     root         2077 Sep  5 15:33 rmtab
drwxr-xr-x    4 root     root         4096 Sep  5 15:45 statd
-rw-r--r--    1 root     root         1952 Sep  5 14:51 xtab
The statd() directory should be chgrp'd to rpcuser, and then chmod'd to allow
group read/write/execute access.
Comment 2 Bob Matthews 2001-09-10 10:55:05 EDT
The nfs-utils RPM should make /var/lib/nfs/statd owned by rpcuser by default. 
What happens if you reinstall the nfs-utils RPM?

Note You need to log in before you can comment on or make changes to this bug.