diff --git a/startup/rc.d/init.d/netfs b/startup/rc.d/init.d/netfs index 42fed44..2474269 100644 --- a/startup/rc.d/init.d/netfs +++ b/startup/rc.d/init.d/netfs @@ -20,11 +20,11 @@ SourceIfNotEmpty /etc/sysconfig/network || exit 1 LOCKFILE=/var/lock/subsys/netfs -NFSFSTAB=`grep -vs '^#' /etc/fstab |awk '{ if (($3 == "nfs") && ($4 !~ /noauto/)) print $2}'` +NFSFSTAB=`grep -vs '^#' /etc/fstab |awk '{ if (($3 ~ /nfs/) && ($4 !~ /noauto/)) print $2}'` SMBFSTAB=`grep -vs '^#' /etc/fstab |awk '{ if (($3 == "smbfs") && ($4 !~ /noauto/)) print $2}'` CIFSFSTAB=`grep -vs '^#' /etc/fstab |awk '{ if (($3 == "cifs") && ($4 !~ /noauto/)) print $2}'` NCPFSTAB=`grep -vs '^#' /etc/fstab |awk '{ if ((($3 == "ncp") || ($3 == "ncpfs")) && ($4 !~ /noauto/)) print $2}'` -NFSMTAB=`grep -vs '^#' /proc/mounts |awk '{ if (($3 == "nfs") && ($2 != "/")) print $2}'` +NFSMTAB=`grep -vs '^#' /proc/mounts |awk '{ if (($3 ~ /nfs/) && ($2 != "/")) print $2}'` SMBMTAB=`grep -vs '^#' /proc/mounts |awk '{ if (($3 == "smbfs") && ($2 != "/")) print $2}'` CIFSMTAB=`grep -vs '^#' /proc/mounts |awk '{ if (($3 == "cifs") && ($2 != "/")) print $2}'` NCPMTAB=`grep -vs '^#' /proc/mounts |awk '{ if ((($3 == "ncp") || ($3 == "ncpfs")) && ($2 != "/")) print $2}'` @@ -37,7 +37,7 @@ start() [ -f /var/lock/subsys/portmap ] || service portmap start [ -f /var/lock/subsys/portmap ] && - action "Mounting NFS filesystems:" mount -a -t nfs + action "Mounting NFS filesystems:" mount -a -t nfs,nfs4 fi [ -z "$SMBFSTAB" ] || action "Mounting SMB filesystems:" mount -a -t smbfs [ -z "$CIFSFSTAB" ] || action "Mounting CIFS filesystems:" mount -a -t cifs @@ -50,7 +50,7 @@ stop() { if [ -n "$NFSMTAB" ]; then UnmountFilesystems 3 5 \ - '($3 == "nfs") && ($2 != "/") {print $2}' \ + '($3 ~ /nfs/) && ($2 != "/") {print $2}' \ "Unmounting NFS filesystem" \ "Unmounting NFS filesystem (retry)" fi