diff options
author | Waldemar Brodkorb <wbx@openadk.org> | 2009-11-27 19:28:17 +0100 |
---|---|---|
committer | Waldemar Brodkorb <wbx@openadk.org> | 2009-11-27 19:28:17 +0100 |
commit | 7d36caec53dbfeea4e696205ae71bdae8246a082 (patch) | |
tree | 8fb78c6d6bd9739206d4535e94fc2d79785f4a78 /package/base-files | |
parent | 83f5e16fffe029232114ee9f54b8df41d5841912 (diff) |
minor fixes to bridgeing scripts
Diffstat (limited to 'package/base-files')
-rwxr-xr-x | package/base-files/extra/etc/network/if-post-down.d/bridge | 24 | ||||
-rwxr-xr-x[-rw-r--r--] | package/base-files/extra/etc/network/if-pre-up.d/bridge | 0 | ||||
-rwxr-xr-x | package/base-files/extra/sbin/update (renamed from package/base-files/extra/usr/sbin/update) | 3 |
3 files changed, 27 insertions, 0 deletions
diff --git a/package/base-files/extra/etc/network/if-post-down.d/bridge b/package/base-files/extra/etc/network/if-post-down.d/bridge new file mode 100755 index 000000000..eda1fe3bf --- /dev/null +++ b/package/base-files/extra/etc/network/if-post-down.d/bridge @@ -0,0 +1,24 @@ +#!/bin/sh + +if [ ! -x /usr/sbin/brctl ] +then + exit 0 +fi + +case "$IF_BRIDGE_PORTS" in + "") + exit 0 + ;; + none) + INTERFACES="" + ;; + *) + INTERFACES="$IF_BRIDGE_PORTS" + ;; +esac + +for IF in $INTERFACES; do + ip link set down dev $IF && brctl delif $IFACE $IF +done + +ip link set down dev $IFACE || exit 1 diff --git a/package/base-files/extra/etc/network/if-pre-up.d/bridge b/package/base-files/extra/etc/network/if-pre-up.d/bridge index 766084de1..766084de1 100644..100755 --- a/package/base-files/extra/etc/network/if-pre-up.d/bridge +++ b/package/base-files/extra/etc/network/if-pre-up.d/bridge diff --git a/package/base-files/extra/usr/sbin/update b/package/base-files/extra/sbin/update index 57e9cf268..a812bb23d 100755 --- a/package/base-files/extra/usr/sbin/update +++ b/package/base-files/extra/sbin/update @@ -9,6 +9,7 @@ fi cd / mount -o remount,rw / +umount /etc check_exit() { if [ $? -ne 0 ];then @@ -59,5 +60,7 @@ case $1 in esac sync +mount --bind /etc /tmp/.cfgfs/root +echo "Check with cfgfs status if you need to merge and save any changes in /etc." echo "You should reboot now." |