From fdfd1e7242795826ac4bf88bfe9365cd54d8b61a Mon Sep 17 00:00:00 2001 From: Russ Allbery Date: Fri, 27 Jun 2008 23:01:22 -0700 Subject: [PATCH] Exit successfully in init script if openafs isn't in modules.dep If the openafs module isn't listed in modules.dep, exit with a zero status from the init script even if modprobe fails. Otherwise, if a module package and openafs-client are installed at the same time and openafs-client is set up before the module package, the init script can find the module, fail the modprobe (because the dependency map hasn't yet been updated), and fail the whole installation. Exiting with a zero status still doesn't get OpenAFS started, but at least it doesn't leave the system in a partly installed state. Thanks to Durk Strooisma for the analysis. Closes: #486816 --- debian/changelog | 9 +++++++++ debian/openafs-client.init | 22 +++++++++++++++++++--- 2 files changed, 28 insertions(+), 3 deletions(-) diff --git a/debian/changelog b/debian/changelog index edf8bdfa6..5c3e67be9 100644 --- a/debian/changelog +++ b/debian/changelog @@ -3,6 +3,15 @@ openafs (1.4.7.dfsg1-3) UNRELEASED; urgency=low * When clearing the restart time while installing a new cell, pass -localauth to avoid an authentication failure. Thanks, Davor Ocelic. (Closes: #488152) + * If the openafs module isn't listed in modules.dep, exit with a zero + status from the init script even if modprobe fails. Otherwise, if a + module package and openafs-client are installed at the same time and + openafs-client is set up before the module package, the init script + can find the module, fail the modprobe (because the dependency map + hasn't yet been updated), and fail the whole installation. Exiting + with a zero status still doesn't get OpenAFS started, but at least it + doesn't leave the system in a partly installed state. Thanks to Durk + Strooisma for the analysis. (Closes: #486816) * Stop using quilt to manage patches and pre-apply them to the source package now that the package is maintained with Git. * Translation updates: diff --git a/debian/openafs-client.init b/debian/openafs-client.init index 969cf5133..69f4a1c95 100755 --- a/debian/openafs-client.init +++ b/debian/openafs-client.init @@ -28,7 +28,8 @@ PATH=/bin:/usr/bin:/sbin:/usr/sbin CACHEINFO=${CACHEINFO:-/etc/openafs/cacheinfo} -MODULEDIR=${MODULEDIR:-/lib/modules/`uname -r`/fs} +MODULEROOT=${MODULEROOT:-/lib/modules/`uname -r`} +MODULEDIR=${MODULEDIR:-$MODULEROOT/fs} exec 3>/dev/null exec