From b81d81eb5700ebf282b8c89967255561011f47ed Mon Sep 17 00:00:00 2001 From: "Steinar H. Gunderson" Date: Wed, 25 Jul 2007 01:27:48 +0200 Subject: [PATCH] Imported Debian patch 1.1.0-12 --- debian/changelog | 17 +++++++++++++++++ debian/control | 2 +- debian/nfs-common.init | 12 ++++++------ 3 files changed, 24 insertions(+), 7 deletions(-) diff --git a/debian/changelog b/debian/changelog index ff701b5..840d305 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,20 @@ +nfs-utils (1:1.1.0-12) unstable; urgency=low + + * Yet another round of fixing the boot issues, mostly in nfs-common.init: + * Be a bit smarter about setting AUTO_NEED_IDMAPD; check not only that + /etc/exports exists, but also that it contains things that look like + uncommented exports. + * Don't exit 0 immediately if statd, idmapd (if enabled) or gssd (if + enabled) can't be found, as we might need statd to get /usr up even if we + can't get to idmapd and gssd. (The AUTO_NEED_IDMAPD fix above should fix + the default situation, but it's good to take a bit of extra care.) + Instead, start statd regardless, and just skip idmapd and gssd starting + (set NEED_{IDMAPD,GSSD}=no) if it can't be found. + * Let nfs-common depend on initscripts (>= 2.86.ds1-38.1) to make sure we + have a version with the proper mountnfs logic. + + -- Steinar H. Gunderson Wed, 25 Jul 2007 01:27:48 +0200 + nfs-utils (1:1.1.0-11) unstable; urgency=low * Include the nfs man page, which was also forgotten. The new nfs man page diff --git a/debian/control b/debian/control index 83439ec..6191419 100644 --- a/debian/control +++ b/debian/control @@ -33,7 +33,7 @@ Description: support for NFS kernel server Package: nfs-common Architecture: any -Depends: portmap | rpcbind, adduser, ucf, lsb-base (>= 1.3-9ubuntu3), netbase (>= 4.24), ${shlibs:Depends} +Depends: portmap | rpcbind, adduser, ucf, lsb-base (>= 1.3-9ubuntu3), netbase (>= 4.24), initscripts (>= 2.86.ds1-38.1), ${shlibs:Depends} Provides: nfs-client Conflicts: nfs-client Replaces: nfs-client, nfs-kernel-server (<< 1:1.0.7-5), mount (<< 2.13~) diff --git a/debian/nfs-common.init b/debian/nfs-common.init index 54701d7..80dce3e 100644 --- a/debian/nfs-common.init +++ b/debian/nfs-common.init @@ -63,7 +63,7 @@ fi # condition in nfs-kernel-server's init script does, which has a value in # itself. # -if [ -f /etc/exports ]; then +if [ -f /etc/exports ] && grep -q '^ .*/' /etc/exports; then AUTO_NEED_IDMAPD=yes fi @@ -84,11 +84,6 @@ case "$NEED_GSSD" in ;; esac -# Exit if required binaries are missing. -[ -x $PREFIX/sbin/rpc.statd ] || exit 0 -[ -x /usr/sbin/rpc.idmapd ] || [ "$NEED_IDMAPD" = no ] || exit 0 -[ -x /usr/sbin/rpc.gssd ] || [ "$NEED_GSSD" = no ] || exit 0 - do_modprobe() { if [ -x /sbin/modprobe -a -f /proc/modules ] then @@ -130,6 +125,11 @@ case "$1" in exit $? fi + # Don't start idmapd and gssd if we don't have them (say, if /usr is not + # up yet). + [ -x /usr/sbin/rpc.idmapd ] || NEED_IDMAPD=no + [ -x /usr/sbin/rpc.gssd ] || NEED_GSSD=no + if [ "$NEED_IDMAPD" = yes ] || [ "$NEED_GSSD" = yes ] then do_modprobe nfs -- 2.39.2