Why I have 2 different IP?

Barbara Allison 0 Reputation points
2023-08-27T09:43:52.7066667+00:00

Hello,

On my Windows VM I connect using public IP address , But in VM cmd when I type "ipconfig" in IPv4 filed I find another IP like "10.0.0.X" , I need to set default IP "IPv4" = public IP , what should I do ?

Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
7,585 questions
Azure Virtual Network
Azure Virtual Network
An Azure networking service that is used to provision private networks and optionally to connect to on-premises datacenters.
2,311 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. msrini-MSFT 9,276 Reputation points Microsoft Employee
    2023-08-27T09:48:40.6433333+00:00

    Hi,

    In Azure, when you assign an Public IP to your Virtual Machine, azure platform takes care of the NAT and sends the packet to your guest OS with the Private IP address. When you send the packet out to Internet, Azure platform changes the source IP to your Public IP and sends it out.

    This is the default behavior in Azure.

    Can you provide me the scenario why you want to directly assign a public IP to your guest OS ?

    Regards,

    Karthik Srinivas

    0 comments No comments