Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

What do I need to do to change the RPCNFSDCOUNT setting without a full service restart?

I need to reload the NFS configuration without restarting the service. The RPCNFSDCOUNT thread count is too low for the workload but I cannot get the management to agree on a schedule for a change window.

A normal service can frequently do this with a SIGHUP. I did attempt this with a kill -HUP $(pidof rpc.mountd), but that was unsuccessful in getting the new RPCNFSDCOUNT setting applied from /etc/sysconfig/nfs on this old Fedora 8 box.

The man pages for the other NFS daemons incline me to think that HUP'ing those processes won't be of any benefit, and I'm rather reluctant to HUP the kthreadd process that is the parent process of the nfsd threads themselves.

share|improve this question
up vote 4 down vote accepted

And after an obvious mental lapse, I remembered the /proc filesystem. /proc/fs/nfsd, specifically, controls the runtime settings of the nfsd service.

In my case, this meant echo '32' > /proc/fs/nfsd/threads sets the number of threads to 32.

share|improve this answer

You can execute rpc.nfsd from the command line and specify the number of processes to add or remove if the nfs server is already running.

From man 8 rpc.nfsd

/usr/sbin/rpc.nfsd [options] nproc

Note that if the NFS server is already running, then the options for
specifying host, port, and protocol will be ignored.  The number of 
processes given will be  the  only option  considered,  and  the  number
of  active nfsd processes will be increased or decreased to match this 
number. In particular rpc.nfsd 0 will stop all  threads  and thus close 
any open connections.
share|improve this answer
Actually, at least with Fedora 8, 'service nfs reload' ONLY runs exportfs -r per the /etc/init.d/nfs script. – Magellan May 9 '12 at 17:07
@Adrian You are right. See my edit. – uther May 9 '12 at 17:23
Most Interesting. Thanks. – Magellan May 9 '12 at 17:28

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.