diff --git a/systemvm/patches/debian/config/opt/cloud/bin/cs/CsDhcp.py b/systemvm/patches/debian/config/opt/cloud/bin/cs/CsDhcp.py index 23b74995364..da9e6168ee0 100755 --- a/systemvm/patches/debian/config/opt/cloud/bin/cs/CsDhcp.py +++ b/systemvm/patches/debian/config/opt/cloud/bin/cs/CsDhcp.py @@ -89,9 +89,10 @@ class CsDhcp(CsDataBag): gateway = gn.get_gateway() else: gateway = i['gateway'] - sline = "dhcp-option=tag:interface-%s-%s,3," % (device, idx) - line = "dhcp-option=tag:interface-%s-%s,3,%s" % (device, idx, gateway) - self.conf.search(sline, line) + if gateway != '0.0.0.0': + sline = "dhcp-option=tag:interface-%s-%s,3," % (device, idx) + line = "dhcp-option=tag:interface-%s-%s,3,%s" % (device, idx, gateway) + self.conf.search(sline, line) # Netmask netmask = '' if self.config.is_vpc():