Skip to content

Commit bbb2dd0

Browse files
committed
Merge pull request #1536 from ntavares/useextdns_rvmvip47
Honour GS use_ext_dns and redundant VR VIPThis patch addresses two issues: On redundant VR setups, the primary resolver being handed out to instances is the guest_ip (primary IP for the VR). This might lead to problems upon failover, at least while the DHCP lease doesn't update (because the primary resolver will be checked first until times out, however it'll be gone upon failover). If Global Setting use_ext_dns is true, we don't want the VR to be the primary resolver at all. * pr/1536: This patch addresses two issues: Signed-off-by: Will Stevens <williamstevens@gmail.com>
2 parents 170765e + c269097 commit bbb2dd0

2 files changed

Lines changed: 11 additions & 2 deletions

File tree

systemvm/patches/debian/config/opt/cloud/bin/cs/CsConfig.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,8 +68,11 @@ def get_domain(self):
6868

6969
def get_dns(self):
7070
dns = []
71-
# Check what happens with use_ext_dns
72-
dns.append(self.address().get_guest_ip())
71+
if not self.cl.get_use_ext_dns():
72+
if not self.is_vpc() and self.cl.is_redundant():
73+
dns.append(self.cl.get_guest_gw())
74+
else:
75+
dns.append(self.address().get_guest_ip())
7376
names = ["dns1", "dns2"]
7477
for name in names:
7578
if name in self.cmdline().idata():

systemvm/patches/debian/config/opt/cloud/bin/cs/CsDatabag.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -148,3 +148,9 @@ def get_gateway(self):
148148
if "gateway" in self.idata():
149149
return self.idata()['gateway']
150150
return False
151+
152+
def get_use_ext_dns(self):
153+
if "useextdns" in self.idata():
154+
return self.idata()['useextdns']
155+
return False
156+

0 commit comments

Comments
 (0)