diff options
author | Miloslav Trmac <mitr@volny.cz> | 2006-03-27 02:12:15 +0000 |
---|---|---|
committer | Miloslav Trmac <mitr@volny.cz> | 2006-03-27 02:12:15 +0000 |
commit | 9b2bf404ff0594fc96c4b230a7b8d384afb14e65 (patch) | |
tree | a6bd69d4ebd3b276d0de403a7e3c8de9cd53bcc0 /rc.d/init.d/network | |
parent | 2a11a3e64d43ef85e91de1051fad9d63d568ff07 (diff) | |
download | initscripts-9b2bf404ff0594fc96c4b230a7b8d384afb14e65.tar initscripts-9b2bf404ff0594fc96c4b230a7b8d384afb14e65.tar.gz initscripts-9b2bf404ff0594fc96c4b230a7b8d384afb14e65.tar.bz2 initscripts-9b2bf404ff0594fc96c4b230a7b8d384afb14e65.tar.xz initscripts-9b2bf404ff0594fc96c4b230a7b8d384afb14e65.zip |
Add support for DHCP on bridges (#125259, original patch by Anders Kaseorg
<anders@kaseorg.com>):
- rc.d/init.d/network: Initialize bridges after bridged interfaces,
deinitialize them before bridged interfaces
- sysconfig/network-scripts/ifdown-eth: Destroy bridges lazily when the last
bridged interface is stopped
- sysconfig/network-scripts/ifup-eth:
* Handle bridges before checking for module presence or wireless devices
* Add bridges lazily when the first bridged interface is started
Diffstat (limited to 'rc.d/init.d/network')
-rwxr-xr-x | rc.d/init.d/network | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/rc.d/init.d/network b/rc.d/init.d/network index cf0fa00a..2a287dd6 100755 --- a/rc.d/init.d/network +++ b/rc.d/init.d/network @@ -94,12 +94,11 @@ case "$1" in # bring up all other interfaces configured to come up at boot time for i in $interfaces; do - unset DEVICE TYPE SLAVE BRIDGE + unset DEVICE TYPE SLAVE eval $(LANG=C fgrep "DEVICE=" ifcfg-$i) eval $(LANG=C fgrep "TYPE=" ifcfg-$i) eval $(LANG=C fgrep "SLAVE=" ifcfg-$i) - eval $(LANG=C fgrep "BRIDGE=" ifcfg-$i) - + if [ -z "$DEVICE" ] ; then DEVICE="$i"; fi if [ "${DEVICE##cipcb}" != "$DEVICE" ] ; then @@ -110,9 +109,8 @@ case "$1" in xdslinterfaces="$xdslinterfaces $i" continue fi - - if [ -n "$BRIDGE" ]; then - is_available $i + + if [ "$TYPE" = "Bridge" ]; then bridgeinterfaces="$bridgeinterfaces $i" continue fi @@ -197,18 +195,17 @@ case "$1" in # get list of bonding, cipe, and xdsl interfaces for i in $interfaces; do - unset DEVICE TYPE BRIDGE + unset DEVICE TYPE eval $(LANG=C fgrep "DEVICE=" ifcfg-$i) eval $(LANG=C fgrep "TYPE=" ifcfg-$i) - eval $(LANG=C fgrep "BRIDGE=" ifcfg-$i) - + if [ -z "$DEVICE" ] ; then DEVICE="$i"; fi if [ "${DEVICE##cipcb}" != "$DEVICE" ] ; then cipeinterfaces="$cipeinterfaces $i" continue fi - if [ -n "$BRIDGE" ]; then + if [ "$TYPE" = "Bridge" ]; then bridgeinterfaces="$bridgeinterfaces $i" continue fi |