Virtual IP (VIP) is a public IP address and created when a cloud service is created.
A VIP is a public IP address that can be used to access Virtual machine in Azure. All VM in same domain name share a single VIP. By using a reserved IP address, you can ensure that the virtual IP address for you Virtual Machine never changes.
Default behavior of VIP address works as:
~ VIP is lost or changed when virtual machine is stopped or deallocated.
~ VIP is lost or changed when cloud service is deleted.
In this blog, we will discuss that VIP gets changed or lost whenever we stop/deallocate the Virtual Machine (VM).
I have already created a VM with the default settings like cloud service, virtual network etc.
We can see the information about our VM below:
When we created a VM, a virtual IP address 22.214.171.124 gets assigned by azure itself, automatically.
We can also check the value of the virtual IP address through PowerShell commands:
The values are same as we saw in the portal.
Now, let’s stop the virtual machine and we will see that the virtual IP address gets changed whenever we restart the virtual machine.
So we can see the new value has been assigned as the Virtual IP.
We can also see the values of virtual ip address from the IP addressess section of the virtual machine.
So, we have learned about the behaviour of virtual ip address that its value is lost or change when we stop or de-allocate the virtual machine.
We can overcome from this behaviour by using reserved virtual ip address. We will learn more about it in upcoming blogs.
Have a nice learning!!