Bug 13375:

Summary of changes:
  - Fix the order of source nat ip's : Static Nat IP's will be on top of Router source nat IP's. means Static NAT ip will take higher preference when compare to router ip while picking ip for source nat.

Reviewed-by: Abhi
This commit is contained in:
Naredula Janardhana Reddy 2012-02-15 11:31:47 +05:30
parent 566d967f20
commit ed0f9f6942
1 changed files with 1 additions and 1 deletions

View File

@ -214,7 +214,7 @@ add_snat() {
local ipNoMask=$(echo $1 | awk -F'/' '{print $1}')
logger -t cloud "$(basename $0):Added SourceNAT $pubIp on interface $ethDev"
sudo iptables -t nat -D POSTROUTING -j SNAT -o $ethDev --to-source $ipNoMask ;
sudo iptables -t nat -I POSTROUTING -j SNAT -o $ethDev --to-source $ipNoMask ;
sudo iptables -t nat -A POSTROUTING -j SNAT -o $ethDev --to-source $ipNoMask ;
return $?
}
remove_snat() {