From 6a767732f959186e95c71d31a2ed49bb67a85473 Mon Sep 17 00:00:00 2001 From: Remi Bergsma Date: Sun, 14 Feb 2016 18:09:03 +0100 Subject: [PATCH] CLOUDSTACK-9287 - Bring up the private gw interface on state change to master --- .../patches/debian/config/opt/cloud/bin/cs/CsRedundant.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/systemvm/patches/debian/config/opt/cloud/bin/cs/CsRedundant.py b/systemvm/patches/debian/config/opt/cloud/bin/cs/CsRedundant.py index 92f27cedc16..7d34e303fa6 100755 --- a/systemvm/patches/debian/config/opt/cloud/bin/cs/CsRedundant.py +++ b/systemvm/patches/debian/config/opt/cloud/bin/cs/CsRedundant.py @@ -292,7 +292,7 @@ class CsRedundant(object): logging.debug("Setting router to master") dev = '' - ips = [ip for ip in self.address.get_ips() if ip.is_public() and ip.get_device() in PUBLIC_INTERFACE] + ips = [ip for ip in self.address.get_ips() if ip.is_public()] route = CsRoute() for ip in ips: if dev == ip.get_device(): @@ -307,7 +307,8 @@ class CsRedundant(object): try: gateway = ip.get_gateway() logging.info("Adding gateway ==> %s to device ==> %s" % (gateway, dev)) - route.add_defaultroute(gateway) + if ip.get_device() in PUBLIC_INTERFACE: + route.add_defaultroute(gateway) except: logging.error("ERROR getting gateway from device %s" % dev) else: