diff options
author | Mike Frysinger <vapier@gentoo.org> | 2013-03-24 19:37:22 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2013-03-24 19:37:22 +0000 |
commit | 73b192be3cc7de32646e0a0de98b2bc38d4c47e0 (patch) | |
tree | 2219cf70c62ad25075b948d10598e6ec61f9762e /net-fs/nfs-utils/files | |
parent | Remove hplip blocker, bug 410459 (diff) | |
download | gentoo-2-73b192be3cc7de32646e0a0de98b2bc38d4c47e0.tar.gz gentoo-2-73b192be3cc7de32646e0a0de98b2bc38d4c47e0.tar.bz2 gentoo-2-73b192be3cc7de32646e0a0de98b2bc38d4c47e0.zip |
Process /etc/exports.d/*.exports too #459600 by Joakim Tjernlund.
(Portage version: 2.2.0_alpha169/cvs/Linux x86_64, signed Manifest commit with key FB7C4156)
Diffstat (limited to 'net-fs/nfs-utils/files')
-rwxr-xr-x | net-fs/nfs-utils/files/nfs.initd | 34 |
1 files changed, 16 insertions, 18 deletions
diff --git a/net-fs/nfs-utils/files/nfs.initd b/net-fs/nfs-utils/files/nfs.initd index c99a1bf849e9..ab25b4d18bee 100755 --- a/net-fs/nfs-utils/files/nfs.initd +++ b/net-fs/nfs-utils/files/nfs.initd @@ -1,7 +1,7 @@ #!/sbin/runscript -# Copyright 1999-2011 Gentoo Foundation +# Copyright 1999-2013 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/net-fs/nfs-utils/files/nfs.initd,v 1.26 2011/09/18 01:51:51 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-fs/nfs-utils/files/nfs.initd,v 1.27 2013/03/24 19:37:22 vapier Exp $ extra_started_commands="reload" @@ -17,20 +17,18 @@ smnotify=/usr/sbin/sm-notify depend() { local myneed="" - if [ -e /etc/exports ] ; then - # XXX: no way to detect NFSv4 is desired and so need rpc.idmapd - myneed="${myneed} $( - awk '!/^[[:space:]]*#/ { - # clear the path to avoid spurious matches - $1 = ""; - if ($0 ~ /[(][^)]*sec=(krb|spkm)[^)]*[)]/) { - print "rpc.svcgssd" - exit 0 - } - }' /etc/exports - )" - fi - config /etc/exports + # XXX: no way to detect NFSv4 is desired and so need rpc.idmapd + myneed="${myneed} $( + awk '!/^[[:space:]]*#/ { + # clear the path to avoid spurious matches + $1 = ""; + if ($0 ~ /[(][^)]*sec=(krb|spkm)[^)]*[)]/) { + print "rpc.svcgssd" + exit 0 + } + }' /etc/exports /etc/exports.d/*.exports 2>/dev/null + )" + config /etc/exports /etc/exports.d/*.exports need portmap rpc.statd ${myneed} ${NFS_NEEDED_SERVICES} use ypbind net dns rpc.rquotad rpc.idmapd rpc.svcgssd after quota @@ -46,7 +44,7 @@ mkdir_nfsdirs() { waitfor_exportfs() { local pid=$1 - ( sleep ${EXPORTFS_TIMEOUT:-30}; kill -9 $pid 2>/dev/null ) & + ( sleep ${EXPORTFS_TIMEOUT:-30}; kill -9 ${pid} 2>/dev/null ) & wait $1 } @@ -91,7 +89,7 @@ start() { # Exportfs likes to hang if networking isn't working. # If that's the case, then try to kill it so the # bootup process can continue. - if grep -qs '^[[:space:]]*/' /etc/exports ; then + if grep -qs '^[[:space:]]*/' /etc/exports /etc/exports.d/*.exports ; then ebegin "Exporting NFS directories" ${exportfs} -r & waitfor_exportfs $! |