[Pkg-sysvinit-commits] r262 -
sysvinit/trunk/debian/initscripts/etc/init.d
Thomas Hood
jdthood-guest at costa.debian.org
Thu Nov 24 22:25:28 UTC 2005
Author: jdthood-guest
Date: 2005-11-24 22:25:28 +0000 (Thu, 24 Nov 2005)
New Revision: 262
Modified:
sysvinit/trunk/debian/initscripts/etc/init.d/mountall.sh
sysvinit/trunk/debian/initscripts/etc/init.d/mountnfs.sh
Log:
Accept 64 from mount too
Modified: sysvinit/trunk/debian/initscripts/etc/init.d/mountall.sh
===================================================================
--- sysvinit/trunk/debian/initscripts/etc/init.d/mountall.sh 2005-11-24 20:05:03 UTC (rev 261)
+++ sysvinit/trunk/debian/initscripts/etc/init.d/mountall.sh 2005-11-24 22:25:28 UTC (rev 262)
@@ -23,10 +23,14 @@
#
# Mount local file systems in /etc/fstab.
#
- # Accept 96 (32/mount failure + 64/some mount succeeded)
- # as a valid return status from mount in mountall.sh.
- # It seems to be returned when some mount points were already mounted.
+
+ # Accept 64 or 96 (32/mount failure + 64/some mount succeeded)
+ # as valid return statuses from mount. This partly works around
+ # the problem of mount reporting an error status when
+ # some filesystems are already mounted.
#
+ # E.g., usually the proc filesystem is already mounted when
+ # this script runs.
do_mount() { mount -av -t nonfs,nonfs4,nosmbfs,nocifs,noncp,noncpfs,nocoda,noocfs2,nogfs ; }
@@ -35,7 +39,8 @@
log_action_msg "Will now mount local filesystems"
do_mount
ES=$?
- if [ 96 = $ES ] || [ 0 = $ES ]; then
+ if [ 0 = "$ES" ] || [ 96 = "$ES" ] || [ 64 = "$ES" ]
+ then
log_success_msg "Done mounting local filesystems."
else
log_failure_msg "Mounting local filesystems failed with error code ${ES}."
@@ -44,7 +49,8 @@
log_action_begin_msg "Mounting local filesystems"
do_mount >/dev/null
ES=$?
- if [ 96 = $ES ] || [ 0 = $ES ]; then
+ if [ 0 = "$ES" ] || [ 96 = "$ES" ] || [ 64 = "$ES" ]
+ then
log_action_end_msg 0
else
log_action_end_msg 1
Modified: sysvinit/trunk/debian/initscripts/etc/init.d/mountnfs.sh
===================================================================
--- sysvinit/trunk/debian/initscripts/etc/init.d/mountnfs.sh 2005-11-24 20:05:03 UTC (rev 261)
+++ sysvinit/trunk/debian/initscripts/etc/init.d/mountnfs.sh 2005-11-24 22:25:28 UTC (rev 262)
@@ -92,13 +92,19 @@
if [ -n "$NETFS" ]
then
do_mount() { mount -a -t$NETFS ; }
+
+ # Accept 64 or 96 (32/mount failure + 64/some mount succeeded)
+ # as valid return statuses from mount. This partly works around
+ # the problem of mount reporting an error status when
+ # some filesystems are already mounted.
if [ "$VERBOSE" != no ]
then
log_action_msg "Will now mount remote filesystems"
do_mount
ES=$?
- if [ 96 = $ES ] || [ 0 = $ES ]; then
+ if [ 0 = "$ES" ] || [ 96 = "$ES" ] || [ 64 = "$ES" ]
+ then
log_success_msg "Done mounting remote filesystems."
else
log_failure_msg "Mounting remote filesystems failed with error code ${ES}."
@@ -107,7 +113,8 @@
log_action_begin_msg "Mounting remote filesystems"
do_mount >/dev/null
ES=$?
- if [ 96 = $ES ] || [ 0 = $ES ]; then
+ if [ 0 = "$ES" ] || [ 96 = "$ES" ] || [ 64 = "$ES" ]
+ then
log_action_end_msg 0
else
log_action_end_msg 1
More information about the Pkg-sysvinit-commits
mailing list