mirror of
https://github.com/apache/cloudstack.git
synced 2025-11-02 11:52:28 +01:00
bug 12704: Fix multiply public nics with redundant router
status 12704: resolved fixed
This commit is contained in:
parent
4db08d897e
commit
3b2e2b079b
@ -11,7 +11,7 @@ then
|
||||
service keepalived stop >> [RROUTER_LOG] 2>&1
|
||||
service conntrackd stop >> [RROUTER_LOG] 2>&1
|
||||
pkill -9 keepalived >> [RROUTER_LOG] 2>&1
|
||||
ifconfig eth2 down >> [RROUTER_LOG] 2>&1
|
||||
[RROUTER_BIN_PATH]/disable_pubip.sh >> [RROUTER_LOG] 2>&1
|
||||
echo Status: FAULT \(keepalived process is dead\) >> [RROUTER_LOG]
|
||||
exit
|
||||
fi
|
||||
|
||||
@ -1,4 +1,8 @@
|
||||
#!/bin/bash
|
||||
|
||||
ifconfig eth2 down
|
||||
ip link|grep BROADCAST|grep -v eth0|grep -v eth1|cut -d ":" -f 2 > /tmp/iflist
|
||||
while read i
|
||||
do
|
||||
ifconfig $i down
|
||||
done < /tmp/iflist
|
||||
service dnsmasq stop
|
||||
|
||||
@ -1,8 +1,12 @@
|
||||
#!/bin/bash
|
||||
|
||||
ifconfig eth2 down && \
|
||||
ifconfig eth2 hw ether [ETH2MAC] && \
|
||||
ifconfig eth2 [ETH2IP] netmask [ETH2MASK] && \
|
||||
ifconfig eth2 up && \
|
||||
set -e
|
||||
|
||||
ip link|grep BROADCAST|grep -v eth0|grep -v eth1|cut -d ":" -f 2 > /tmp/iflist
|
||||
while read i
|
||||
do
|
||||
ifconfig $i down
|
||||
ifconfig $i up
|
||||
done < /tmp/iflist
|
||||
ip route add default via [GATEWAY] dev eth2 && \
|
||||
service dnsmasq restart
|
||||
|
||||
@ -17,7 +17,7 @@ echo Enable public ip returned $ret >> [RROUTER_LOG]
|
||||
if [ $ret -ne 0 ]
|
||||
then
|
||||
echo Fail to enable public ip! >> [RROUTER_LOG]
|
||||
ifconfig eth2 down
|
||||
[RROUTER_BIN_PATH]/disable_pubip.sh >> [RROUTER_LOG] 2>&1
|
||||
service keepalived stop >> [RROUTER_LOG] 2>&1
|
||||
service conntrackd stop >> [RROUTER_LOG] 2>&1
|
||||
echo Status: FAULT \($last_msg\) >> [RROUTER_LOG]
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user