Browse Source

fix startup scripts, nfsd is not killable (kernel thread)

Waldemar Brodkorb 13 years ago
parent
commit
fe9fcae3c7
2 changed files with 3 additions and 5 deletions
  1. 1 1
      package/nfs-utils/Makefile
  2. 2 4
      package/nfs-utils/files/nfsd.init

+ 1 - 1
package/nfs-utils/Makefile

@@ -5,7 +5,7 @@ include ${TOPDIR}/rules.mk
 
 PKG_NAME:=		nfs-utils
 PKG_VERSION:=		1.2.3
-PKG_RELEASE:=		4
+PKG_RELEASE:=		5
 PKG_MD5SUM:=		1131dc5f27c4f3905a6e7ee0d594fd4d
 PKG_DESCR:=		Utilities for NFS kernel server implementation
 PKG_SECTION:=		net/fs

+ 2 - 4
package/nfs-utils/files/nfsd.init

@@ -7,7 +7,7 @@
 case $1 in
 autostop) ;;
 autostart)
-	test x"${portmap:-NO}" = x"NO" && exit 0
+	test x"${portmap:-NO}" = x"NO" || test x"${rpcbind:-NO}" = x"NO" && exit 0
 	test x"${nfs_server:-NO}" = x"NO" && exit 0
 	exec sh $0 start
 	;;
@@ -18,9 +18,8 @@ start)
 	/bin/touch /var/lib/nfs/xtab
 	/bin/touch /var/lib/nfs/sm
 	chown nfs:nfs /var/lib/nfs/sm
-	/usr/sbin/exportfs -r
-	/usr/sbin/mountd
 	/usr/sbin/nfsd
+	/usr/sbin/mountd
 	if [ ${nfs_server_version} -eq 4 ];then
 		mkdir -p /var/lib/nfs/rpc_pipefs
 		mount -t rpc_pipefs rpc_pipefs /var/lib/nfs/rpc_pipefs
@@ -29,7 +28,6 @@ start)
 	fi
 	;;
 stop)
-	kill $(pgrep -f /usr/sbin/nfsd)
 	kill $(pgrep -f /usr/sbin/mountd)
 	if [ ${nfs_server_version} -eq 4 ];then
 		kill $(pgrep -f /usr/sbin/idmapd)