mirror of https://github.com/apache/cloudstack.git
bug 11547: Reset iptables counter when a public interface on domR is removed
This commit is contained in:
parent
6fdbd309c3
commit
80fdf4053f
|
|
@ -37,8 +37,8 @@ then
|
|||
# remove rules
|
||||
iptables -D NETWORK_STATS -i eth0 -o $i > /dev/null;
|
||||
iptables -D NETWORK_STATS -i $i -o eth0 > /dev/null;
|
||||
iptables -D NETWORK_STATS -o $pubIf ! -i eth0 -p tcp > /dev/null;
|
||||
iptables -D NETWORK_STATS -i $pubIf ! -o eth0 -p tcp > /dev/null;
|
||||
iptables -D NETWORK_STATS -o $i ! -i eth0 -p tcp > /dev/null;
|
||||
iptables -D NETWORK_STATS -i $i ! -o eth0 -p tcp > /dev/null;
|
||||
fi
|
||||
done
|
||||
rm /root/removedVifs
|
||||
|
|
|
|||
|
|
@ -81,6 +81,7 @@ get_usage () {
|
|||
local dRIp=$1
|
||||
ssh -q -p 3922 -o StrictHostKeyChecking=no -i $cert root@$dRIp "\
|
||||
iptables -L NETWORK_STATS -n -v -x | awk '\$1 ~ /^[0-9]+\$/ { printf \"%s:\", \$2}';
|
||||
if [ -f /root/removedVifs ] ; then iptables -Z NETWORK_STATS ; fi;
|
||||
/root/clearUsageRules.sh > /dev/null;
|
||||
"
|
||||
if [ $? -gt 0 -a $? -ne 2 ]
|
||||
|
|
|
|||
Loading…
Reference in New Issue