summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Bächler <thomas@archlinux.org>2010-06-09 20:06:02 +0200
committerThomas Bächler <thomas@archlinux.org>2010-06-09 20:06:02 +0200
commit0937312b298e8604e12bbc3c8ab3bbfa89914be2 (patch)
tree7e66bd1d596675baad51e7625904fcd427b14e7c
parent3228db8a5fc703579250b7656bf5ea4c876aa099 (diff)
network, rc.conf: Add NETWORK_PERSIST option2010.06-2
Setting NETWORK_PERSIST="yes" will skip network shutdown. This is needed to cleanly halt or reboot the systemif your root device is on NFS. It does not affect network profiles.
-rwxr-xr-xnetwork5
-rw-r--r--rc.conf4
2 files changed, 9 insertions, 0 deletions
diff --git a/network b/network
index d23b3a9..977e81e 100755
--- a/network
+++ b/network
@@ -233,6 +233,11 @@ case "$1" in
# exit
#fi
+ if [ "${NETWORK_PERSIST}" = "yes" -o "${NETWORK_PERSIST}" = "YES" ]; then
+ status "Skipping Network Shutdown" true
+ exit 0
+ fi
+
stat_busy "Stopping Network"
rm_daemon network
error=0
diff --git a/rc.conf b/rc.conf
index 252a9b1..de182c3 100644
--- a/rc.conf
+++ b/rc.conf
@@ -71,6 +71,10 @@ INTERFACES=(eth0)
gateway="default gw 192.168.0.1"
ROUTES=(!gateway)
+# Setting this to "yes" will skip network shutdown.
+# This is required if your root device is on NFS.
+NETWORK_PERSIST="no"
+
# Enable these network profiles at boot-up. These are only useful
# if you happen to need multiple network configurations (ie, laptop users)
# - set to 'menu' to present a menu during boot-up (dialog package required)