* Merged newxml into HEAD
[linux_from_scratch.git] / bootscripts / blfs / init.d / nfs-server
blobeff9cb6f799f975f00d91e534e72f525d130637c
1 #!/bin/sh
2 # Begin $rc_base/init.d/nfs-server
4 # Based on sysklogd script from LFS-3.1 and earlier.
5 # Rewritten by Gerard Beekmans - gerard@linuxfromscratch.org
7 . /etc/sysconfig/rc
8 . $rc_functions
10 case "$1" in
11 start)
12 echo "Starting NFS Server..."
13 loadproc /usr/sbin/rpc.mountd
14 loadproc /usr/sbin/rpc.nfsd 8
15 loadproc /usr/sbin/rpc.statd
18 stop)
19 echo "Stopping NFS Server..."
20 killproc /usr/sbin/rpc.nfsd
21 killproc /usr/sbin/rpc.mountd
24 reload)
25 echo "Reloading NFS Server..."
26 /usr/sbin/exportfs -ra
29 restart)
30 $0 stop
31 sleep 1
32 $0 start
35 status)
36 statusproc /usr/sbin/rpc.mountd
37 statusproc /usr/sbin/rpc.nfsd
41 echo "Usage: $0 {start|stop|reload|restart|status}"
42 exit 1
44 esac
46 # End $rc_base/init.d/nfs-server