summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorCarl Byington <carl@five-ten-sg.com>2015-06-10 12:10:31 -0700
committerAlex Harpin <development@landsofshadow.co.uk>2015-11-09 21:36:28 +0000
commitf01623dc129ff2fb4cd8d2f1870956d29fe3de19 (patch)
tree85c6a6adb3ed709271c63a955643a7b0771c7c61 /scripts
parentb1ca6fb8bdadec7554b9f6bb6ade1a9c19be65ea (diff)
downloadvyatta-cfg-quagga-f01623dc129ff2fb4cd8d2f1870956d29fe3de19.tar.gz
vyatta-cfg-quagga-f01623dc129ff2fb4cd8d2f1870956d29fe3de19.zip
dhcp bound/reboot must ignore old values
Signed-off-by: Alex Harpin <development@landsofshadow.co.uk>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/vyatta-static-dhcp.pl4
1 files changed, 4 insertions, 0 deletions
diff --git a/scripts/vyatta-static-dhcp.pl b/scripts/vyatta-static-dhcp.pl
index 2b9ed9c4..179ecb5e 100755
--- a/scripts/vyatta-static-dhcp.pl
+++ b/scripts/vyatta-static-dhcp.pl
@@ -14,6 +14,10 @@ GetOptions("interface=s" => \$iface,
"reason=s" => \$reason);
# check if an update is needed
+if (($reason eq "BOUND") || ($reason eq "REBOOT")) {
+ $oip = "";
+ $orouters = "";
+}
exit(0) if (($iface ne $dhcp) || (($oip eq $nip) && ($orouters eq $nrouters)));
logger("DHCP address on $iface updated to $nip,$nrouters from $oip,$orouters: Updating static route $route in table $table.");
my $tab;