Correct PPTP server firewall rules chain.
[tomato/davidwu.git] / release / src / router / nfs-utils / nfs.rc
blobe7d31cc77e1112d6e3ab2abe555c3dfba94df888
1 #!/bin/sh
3 STATUS=`nvram get nfs_enable`
4 if [ "$STATUS" == "0" ]; then
6 logger Stoping NFS Server ...
8 /usr/bin/killall portmap 2>/dev/null
10 /usr/bin/killall statd 2>/dev/null
12 /usr/bin/killall nfsd 2>/dev/null
14 /usr/bin/killall mountd 2>/dev/null
16 logger NFS Server stoped ...
17 else
19 logger Starting NFS Server ...
21 if [ ! -d /var/lib/nfs ]; then
22 mkdir -p /var/lib/nfs
23 touch /var/lib/nfs/etab
24 touch /var/lib/nfs/rmtab
28 if [ -z "`pidof portmap`" ]; then
29 logger - portmap on
30 portmap
33 sleep 1
35 if [ -z "`pidof statd`" ]; then
36 logger statd on
37 statd
40 sleep 2
42 logger - exportfs on
43 exportfs -r
45 if [ -z "`pidof nfsd`" ]; then
46 logger - nfsd on
47 nfsd
50 sleep 1
52 if [ -z "`pidof mountd`" ]; then
53 logger - mountd on
54 mountd
57 logger NFS Server Started ...