Does changing the DNS setting for a virtual network in Azure require Azure virtual machines to restart or not?

Ghulam Abbas 151 Reputation points
2023-12-18T10:54:19.27+00:00

Is it necessary to reboot Azure VMs after changing the DNS setting in Azure portal on the vNet level? Although the Azure portal displays a message that VMs and Application gateways(v2 SKU) within this virtual network must be restarted to utilize the updated DNS server settings, elsewhere it has been suggested that we can use ipconfig / renew to apply the new DNS settings without rebooting the VMs. Can someone please advise / clarify? Thank you.

Azure DNS
Azure DNS
An Azure service that enables hosting Domain Name System (DNS) domains in Azure.
619 questions
Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
7,369 questions
Microsoft Entra
{count} votes

1 answer

Sort by: Most helpful
  1. KapilAnanth-MSFT 38,056 Reputation points Microsoft Employee
    2023-12-18T11:06:49.35+00:00

    @Ghulam Abbas

    Welcome to the Microsoft Q&A Platform. Thank you for reaching out & I hope you are doing well.

    It is recommend that you restart your VMs and Application gateway for the new DNS Server changes to be updated.

    Refer : Change DNS servers of a virtual network

    Restart the VMs that are connected to the virtual network, so they're assigned the new DNS server settings. VMs continue to use their current DNS settings until they're restarted

    For App gateway, see : Why am I seeing 502 errors or unhealthy backend servers after I changed the DNS servers for the virtual network?

    The instances of your application gateway use the virtual network's DNS configuration for name resolution. After changing any DNS server configuration, you need to restart (Stop and Start) the application gateway for the new DNS servers to get assigned. Until then, FQDN-based name resolutions for outbound connectivity could fail.

    Kindly let us know if this helps or you need further assistance on this issue.

    Thanks,

    Kapil


    Please don’t forget to close the thread by clicking "Accept the answer" wherever the information provided helps you, as this can be beneficial to other community members.