diff options
author | Waldemar Brodkorb <wbx@openadk.org> | 2013-07-16 18:36:19 +0200 |
---|---|---|
committer | Waldemar Brodkorb <wbx@openadk.org> | 2013-07-16 18:36:19 +0200 |
commit | 4d7e58f6be98eb1446e6b86434da0f1472934612 (patch) | |
tree | 865558e17b2e4285ebf05258b30caf0510d98b94 /package/base-files/src | |
parent | 67b446e46200c81339dde33e3501d17807e7e7ee (diff) |
umount all filesystems before network is going down
Diffstat (limited to 'package/base-files/src')
-rwxr-xr-x | package/base-files/src/etc/init.d/umount | 14 | ||||
-rw-r--r-- | package/base-files/src/etc/rc.shutdown | 6 |
2 files changed, 15 insertions, 5 deletions
diff --git a/package/base-files/src/etc/init.d/umount b/package/base-files/src/etc/init.d/umount new file mode 100755 index 000000000..bcd545999 --- /dev/null +++ b/package/base-files/src/etc/init.d/umount @@ -0,0 +1,14 @@ +#!/bin/sh +#INIT 55 + +case $1 in +autostop) + cd / + sync + for i in $(grep -v ^# /etc/fstab 2>/dev/null|awk '{ print $2 }');do + umount $i 2>/dev/null + done + ;; +esac +exit 0 + diff --git a/package/base-files/src/etc/rc.shutdown b/package/base-files/src/etc/rc.shutdown index 8716dc59e..5a1a0aa78 100644 --- a/package/base-files/src/etc/rc.shutdown +++ b/package/base-files/src/etc/rc.shutdown @@ -1,6 +1,2 @@ #!/bin/sh -cd / -sync -for i in $(grep -v ^# /etc/fstab 2>/dev/null|awk '{ print $2 }');do - umount $i 2>/dev/null -done +# add code for shutdown routine |