summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWilliam Hubbs <williamh@gentoo.org>2012-03-29 11:44:12 -0500
committerWilliam Hubbs <williamh@gentoo.org>2012-03-29 11:44:12 -0500
commit0571a7e05b658fc95da56d9df61e725eeda75a3c (patch)
tree31b54006401dcd0be2315f5fbb58f943c49036fb
parent300c03203dd5f9f525dc330d24bacc0e07f57766 (diff)
downloadopenrc-0571a7e05b658fc95da56d9df61e725eeda75a3c.tar.gz
openrc-0571a7e05b658fc95da56d9df61e725eeda75a3c.tar.bz2
openrc-0571a7e05b658fc95da56d9df61e725eeda75a3c.tar.xz
init.d/fsck: only check local file systems
On linux systems, fsck was not taking into account which filesystems were local or remote. This commit adds the -t option, with an appropriate value, to the fsck call so that remote file systems are not checked. reported-by: Vladimir Berezhnoy <non7top@gmail.com> X-Gentoo-Bug: 408363 X-Gentoo-Bug-URL: http://bugs.gentoo.org/show_bug.cgi?id=408363
-rw-r--r--init.d/fsck.in7
1 files changed, 6 insertions, 1 deletions
diff --git a/init.d/fsck.in b/init.d/fsck.in
index d53a7ed..0e93d21 100644
--- a/init.d/fsck.in
+++ b/init.d/fsck.in
@@ -71,7 +71,12 @@ start()
done
if [ "$RC_UNAME" = Linux ]; then
- fsck_opts="$fsck_opts -C0 -T"
+ local skiptypes x
+ for x in $net_fs_list $extra_net_fs_list; do
+ skiptypes="${skiptypes}no${x},"
+ done
+ skiptypes="${skiptypes}noopts=_netdev"
+ fsck_opts="$fsck_opts -C0 -T -t $skiptypes"
if [ -z "$fsck_passno" -a -z "$fsck_mnt" ]; then
fsck_args=${fsck_args--A -p}
if echo 2>/dev/null >/.test.$$; then