]>
git.ipfire.org Git - ipfire-2.x.git/blob - src/initscripts/init.d/nfs-server
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 #$LastChangedBy: bdubbs $
8 #$Date: 2006-09-10 19:41:47 -0500 (Sun, 10 Sep 2006) $
12 .
/var
/ipfire
/nfs
/nfs-server
16 boot_mesg
"Starting NFS mountd..."
17 loadproc
/usr
/sbin
/rpc.mountd
19 boot_mesg
"Starting NFS nfsd..."
20 loadproc
/usr
/sbin
/rpc.nfsd
-p $PORT $PROCESSES
22 boot_mesg
"Starting NFS statd..."
23 loadproc
/usr
/sbin
/rpc.statd
25 if [ "$QUOTAS" = "yes" ]; then
26 boot_mesg
"Starting NFS rquotad..."
27 loadproc
/usr
/sbin
/rpc.rquotad
30 boot_mesg
"Mounting nfsd virtual filesystem..."
31 /bin
/mount
-t nfsd none
/proc
/fs
/nfsd
2>&1 > /dev
/null
34 # Make ceratin that the list is refreshed on
36 boot_mesg
"Exporting NFS Filesystems..."
37 /usr
/sbin
/exportfs
-ra 2>&1 > /dev
/null
42 boot_mesg
"Stopping NFS statd..."
43 killproc
/usr
/sbin
/rpc.statd
45 boot_mesg
"Stopping NFS nfsd..."
49 boot_mesg
"Stopping NFS mountd..."
50 killproc
/usr
/sbin
/rpc.mountd
52 if [ "$QUOTAS" = "yes" ]; then
53 boot_mesg
"Stopping NFS rquotad..."
54 killproc
/usr
/sbin
/rpc.rquotad
57 boot_mesg
"Refreshing NFS Exported Filesystems..."
58 /usr
/sbin
/exportfs
-au 2>&1 > /dev
/null
61 boot_mesg
"Unmounting NFS Virtual Filesystem..."
62 /bin
/umount
/proc
/fs
/nfsd
2>&1 > /dev
/null
65 # Remove a pid file that isn't done automatically
66 boot_mesg
"Removing the rpc.statd pid file if it exists"
67 if [ -f /var
/run
/rpc.statd.pid
]; then
68 rm -f /var
/run
/rpc.statd.pid
73 boot_mesg
"Reloading NFS Server..."
74 /usr
/sbin
/exportfs
-ra
85 statusproc
/usr
/sbin
/rpc.mountd
86 ## Special case for nfsd with no full path
88 statusproc
/usr
/sbin
/rpc.statd
89 if [ "$QUOTA" = "yes" ]; then
90 statusproc rpc.rquotad
95 echo "Usage: $0 {start|stop|reload|restart|status}"
100 # End $rc_base/init.d/nfs-server