VM - DNS unable to resolve

Kei Moon 151 Reputation points
2021-02-19T16:11:04.767+00:00

I am new to Azure, please bear with me. I created a Windows 2012 VM server. When I try to connect the server using RDP from the Azure portal, it is working fine. However, when I tried to access with the DNS name, which I setup in the portal, it is not resolving. Then I setup DNS forward look up in VM, which still did not help. I am not sure if this process is even needed. When I do 'Test Connection' in the portal, I get "Network connectivity blocked by security group rule: DefaultRule_DenyAllInBound". So I allowed DNS(TCP) in Inbound port rules. It still did not help. I do not understand why I cannot even ping the public IP. To sum up, 1. How do I resolve the DNS name? Is setting up DNS forward/reverse look up in the VM needed? 2. Why can't I ping public IP of the VM? I appreciate your time reading this post.

Azure DNS
Azure DNS
An Azure service that enables hosting Domain Name System (DNS) domains in Azure.
691 questions
Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
7,990 questions
0 comments No comments
{count} votes

Accepted answer
  1. Andreas Baumgarten 111.1K Reputation points MVP
    2021-02-19T18:33:40.073+00:00

    Hi @Kei Moon ,

    Related to question 1:
    You are talking about the DNS name resolution for the public IP of the VM?
    The name resolution for the public IP of the VM is done by MS DNS servers. No need to change anything in the VM OS config.

    Related to question 2:
    If you have Network Security Groups (NSGs) associated in the subnet or to the VM: ICMP Protocol is blocked by default
    If it's a Windows VM: Maybe the OS Firewall is blocking ICMP?

    This is the configuration of a VM (Windows, OS Firewall allowing ICMP) with public IP, DNS name for public IP and allowing inbound ICMP rules in the NSGs:

    70078-vmpublicdns.jpg

    70129-vmnsgicmp.jpg

    The result:

    70165-vmpingresult.jpg

    ----------

    (If the reply was helpful please don't forget to upvote and/or accept as answer, thank you)

    Regards
    Andreas Baumgarten

    1 person found this answer helpful.
    0 comments No comments

1 additional answer

Sort by: Most helpful
  1. Kei Moon 151 Reputation points
    2021-02-19T20:45:14+00:00

    Thank you for you help. I do not have ICMP as a default rule.
    70159-image.png


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.