1 (edited by christian 2020-07-14 10:54:17)

Topic: help setting up nfs

I'm a naive user trying to set up nfs, I've installed the nfs-utils and rpcbind packages.  When I run:

sudo rc-service nfs start

I get as output:

/sbin/rpc.statd: No such file or directory
 * Starting NFS statd ...
 * start-stop-daemon: /sbin/rpc.statd does not exist                      [ !! ]
 * ERROR: rpc.statd failed to start
 * ERROR: cannot start nfs as rpc.statd would not start

I haven't had any luck searching around, so I'm asking here.

2

Re: help setting up nfs

Hello christian,

you can modify the file /etc/init.d/rpc.statd and change to the following:

#!/sbin/openrc-run
# Copyright 1999-2015 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2

[ -e /etc/conf.d/nfs ] && . /etc/conf.d/nfs

rpc_bin=/usr/sbin/rpc.statd
rpc_pid=/var/run/rpc.statd.pid

depend() {
    use ypbind net
    need portmap
    after quota
}

start() {
    # Don't start rpc.statd if already started by someone else ...
    # Don't try and kill it if it's already dead ...
    if killall -q -0 ${rpc_bin} ; then
        return 0
    fi

    ebegin "Starting NFS statd"
    start-stop-daemon --start --exec ${rpc_bin} -- --no-notify ${OPTS_RPC_STATD}
    eend $?
}

stop() {
    ebegin "Stopping NFS statd"
    start-stop-daemon --stop --exec ${rpc_bin} --pidfile /var/run/rpc.statd.pid
    eend $?
}

If this helps, there is an error within the package and the corresponding initd-script in the repositorie which should be corrected.
But first things first: Is this helping?

Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

3

Re: help setting up nfs

Thank you!!  I made the change and that fixed the issue immediately.  I'll work on finishing setting everything up in a little bit.  I really appreciate your help.

4 (edited by christian 2020-07-15 22:45:11)

Re: help setting up nfs

Almost got everything working, but having trouble with autofs.  Command

sudo automount -f -v

gives:

lookup(file): file map /etc/auto.master missing or not readable

I think it should be trying to access /etc/autofs/auto.master instead, but I don't know how to fix it.

I tried copying my file from /etc/autofs/ to /etc/, in that case I get:

Starting automounter version 5.1.2, master map /etc/auto.master
using kernel protocol version 5.02
mount_init: mount(bind): umount failed for /tmp/autoactQsF
lookup(file): failed to read included master map auto.master
mount_init: mount(bind): umount failed for /tmp/autopDLv9J
mounted indirect on /nfs with timeout 300, freq 75 seconds

EDIT:  I found a bug report here, is there any known fix?