[Pkg-sysvinit-commits] r725 - in sysvinit/trunk/debian: .
initscripts/etc/init.d
Thomas Hood
jdthood-guest at costa.debian.org
Wed Feb 1 15:48:39 UTC 2006
Author: jdthood-guest
Date: 2006-02-01 15:48:37 +0000 (Wed, 01 Feb 2006)
New Revision: 725
Modified:
sysvinit/trunk/debian/changelog
sysvinit/trunk/debian/initscripts/etc/init.d/mountall.sh
Log:
Suppress error message about /proc already being mounted
Modified: sysvinit/trunk/debian/changelog
===================================================================
--- sysvinit/trunk/debian/changelog 2006-02-01 13:41:04 UTC (rev 724)
+++ sysvinit/trunk/debian/changelog 2006-02-01 15:48:37 UTC (rev 725)
@@ -20,6 +20,8 @@
(Closes: #349149)
* bootclean: Don't fail to clean all directories in /tmp
(Closes: #350218)
+ * mountall.sh: Suppress error message about /proc already being mounted
+ (Closes: #349275)
* checkroot.sh: Don't try to enable swap if a swap device is
/dev/mapper/* or a swapfile (Closes: #346329, #348534)
* checkroot.sh: Remove some code specific to pre-2.4-Linux
Modified: sysvinit/trunk/debian/initscripts/etc/init.d/mountall.sh
===================================================================
--- sysvinit/trunk/debian/initscripts/etc/init.d/mountall.sh 2006-02-01 13:41:04 UTC (rev 724)
+++ sysvinit/trunk/debian/initscripts/etc/init.d/mountall.sh 2006-02-01 15:48:37 UTC (rev 725)
@@ -21,34 +21,28 @@
#
# Mount local file systems in /etc/fstab.
#
-
- # 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.
-
- mount_all() { mount -av -t nonfs,nonfs4,nosmbfs,nocifs,noncp,noncpfs,nocoda,noocfs2,nogfs ; }
-
if [ "$VERBOSE" = no ]
then
log_action_begin_msg "Mounting local filesystems"
- MOUNT_OUT="$(LC_ALL=C mount_all)"
+ mount -a -t proc >/dev/null 2>&1 # Ignore error message due to /proc already being mounted
+ ES_TO_REPORT=$?
+ mount -a -t noproc,nfs,nfs4,smbfs,cifs,ncp,ncpfs,coda,ocfs2,gfs
ES=$?
- echo "$MOUNT_OUT" | sed -e '/already mounted/d' -e '/nothing was mounted/d'
- if [ 0 = "$ES" ] || [ 96 = "$ES" ] || [ 64 = "$ES" ]
+ ES_TO_REPORT=$(($ES_TO_REPORT | $ES))
+ if [ 0 = "$ES_TO_REPORT" ]
then
log_action_end_msg 0
else
- log_action_end_msg 1 "code $ES"
+ log_action_end_msg 1 "code $ES_TO_REPORT"
fi
else
log_action_msg "Will now mount local filesystems"
- mount_all
+ mount -a -t proc >/dev/null 2>&1 # Ignore error message due to /proc already being mounted
ES=$?
- if [ 0 = "$ES" ] || [ 96 = "$ES" ] || [ 64 = "$ES" ]
+ [ 0 = "$ES" ] || log_failure_msg "Mounting proc filesystems failed with error code ${ES}."
+ mount -a -t noproc,nfs,nfs4,smbfs,cifs,ncp,ncpfs,coda,ocfs2,gfs
+ ES=$?
+ if [ 0 = "$ES" ]
then
log_success_msg "Done mounting local filesystems."
else
More information about the Pkg-sysvinit-commits
mailing list