diff options
author | Antoine Jacoutot <ajacoutot@cvs.openbsd.org> | 2011-07-08 00:54:05 +0000 |
---|---|---|
committer | Antoine Jacoutot <ajacoutot@cvs.openbsd.org> | 2011-07-08 00:54:05 +0000 |
commit | 8bff98f77d1dae9d9a7cfa5ed02b3678e039b81e (patch) | |
tree | b55305fd76cca1f64f1c2a7f78bc84007e71107a /etc/rc.d/nfsd | |
parent | 569a946e8485d69d15870139b3a04b9c78783714 (diff) |
Add the nfs startup scripts.
ok robert@
Diffstat (limited to 'etc/rc.d/nfsd')
-rw-r--r-- | etc/rc.d/nfsd | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/etc/rc.d/nfsd b/etc/rc.d/nfsd new file mode 100644 index 00000000000..7cebb40862d --- /dev/null +++ b/etc/rc.d/nfsd @@ -0,0 +1,21 @@ +#!/bin/sh +# +# $OpenBSD: nfsd,v 1.1 2011/07/08 00:54:04 ajacoutot Exp $ + +daemon="/sbin/nfsd" + +. /etc/rc.d/rc.subr + +rc_reload=NO + +rc_pre() { + [ -s /etc/exports -a `sed -e '/^#/d' < /etc/exports | wc -l` -ne 0 ] && + rm -f /var/db/mountdtab && \ + echo -n > /var/db/mountdtab +} + +rc_post() { + pkill -f "^nfsd: server$" +} + +rc_cmd $1 |