0

I mainly use Azure for IaaS purposes (Linux and Windows VM's). We have a strict Front-End (FE) / Back-end (BE) segregation policy.

FE and BE are in the same Virtual Network, but in different Subnets/Cloud Services.

I've noticed that FE and BE VM's are getting different DNS suffixes via DHCP:

  • FE machines get frontend-something.a9.internal.cloudapp.net as DNS search suffix
  • BE machines get backend-something.a1.internal.cloudapp.net as DNS search suffix

FE machines can reach each other simply by hostname thanks to this search suffix but can't reach BE machines unless I add the BE DNS search suffix in their config.

My question is: Is there a way (via PowerShell / Azure CLI) to find out what DNS suffix is used in a subnet/Cloud Service ?

I need this to automate deployments and I can't predict what the internal DNS search suffix will be (like the "a9" and "a1" that I don't control and that appear in the DNS search suffixed examples above).

Kind Regards,

O.

0

If you use Get-AzureVM with -Debug you can look in the XML for InternalDnsSuffix. However, if you use ARM-based deployments, all VMs in the VNET get the same suffix.

Regards Gareth

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.