In the below articles, we have learnt how to create Virtual Machine using the default configurations.

In both the articles, as shown below, we have used IP Address to connect to the Virtual Machine using RDP protocol.

1_rdpconnect

By default, the IP Address that we have used are dynamic IP Addresses. That means, Azure could use the same IP Address to some other machine at any point of time. For example, when we Stop (Deallocate) the Virtual Machine and then start the same, we might see a different IP Address. In case if you see the same IP Address again after starting the Virtual Machine, it’s just your luck. This is definitely going to break your references of the IP Address of a given Virtual Machine. The only way to get rid of this is to convert the Dynamic IP Address to a Static IP Address. In this article, we will discuss how to convert a Dynamic IP Address to a Static IP Address.

Below is the screen capture of the Overview tab of the Virtual Machine that I just created.

2_vm_overview

Click on the IP Address shown in the above screen capture. You will be taken to the following blade of the IP Address settings.

3_static

By default, the Assignment is Dynamic. I just updated it to Static and clicked on Save.

Clicking on Save button will start the process of saving the changes as shown below.

4_saving

After a few seconds, the changes get reflected and you can view the changes in the Virtual Machine’s Overview blade as shown below.

5_viewchanges

DNS Name Label:

You can also assign a DNS Label to your IP Address by providing a DNS name in the DNS Name Label section of the IP Address Configuration blade as shown below.

6_dnslabel

Once you provide a unique name, click on Save button to save the changes. You can view the DNS name Label in the Virtual Machine’s Overview blade as shown below.

7_vm_overviewbladewithdnslabel

You can also use the DNS Name to do a remote desktop as shown below. This feature comes in very handy if you don’t want to refer the IP Address of your Virtual Machine in any of your work for example, while configuring your Load Balancers, in your code’s configurations, Custom Domains etc.

9_loginpopup

Other Important Notes:

That’s it. Hope you enjoyed reading the article. Your feedback is appreciated.

Summary:

In this article, we have learnt the following.

  • Converted a Dynamic IP Address to a Static IP Address
  • Created a DNS Label for an IP Address