You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The sample steps that follow expect a simple environment already created. If you want to run the steps as they are displayed in this document, first build the test environment described in [create a vnet](/previous-versions/azure/virtual-network/virtual-networks-create-vnet-classic-pportal).
27
+
The sample steps that follow expect an environment already created. If you want to run the steps as they're displayed in this document, first build the test environment described in [create a vnet](/previous-versions/azure/virtual-network/virtual-networks-create-vnet-classic-pportal).
28
28
29
29
## How to specify a static private IP address when creating a VM
30
+
30
31
To create a VM named *DNS01* in the *FrontEnd* subnet of a VNet named *TestVNet* with a static private IP of *192.168.1.101*, complete the following steps:
31
32
32
33
1. From a browser, navigate to https://portal.azure.com and, if necessary, sign in with your Azure account.
33
-
2. Select **NEW** > **Compute** > **Windows Server 2012 R2 Datacenter**, notice that the **Select a deployment model** list already shows **Classic**, and then select **Create**.
34
-
35
-

36
-
3. Under **Create VM**, enter the name of the VM to be created (*DNS01* in the scenario), the local administrator account, and password.
37
-
38
-

39
-
4. Select **Optional Configuration** > **Network** > **Virtual Network**, and then select **TestVNet**. If **TestVNet** is not available, make sure you are using the *Central US* location and have created the test environment described at the beginning of this article.
40
-
41
-

42
-
5. Under **Network**, make sure the subnet currently selected is *FrontEnd*, then select **IP addresses**, under **IP address assignment** select **Static**, and then enter *192.168.1.101* for **IP Address** as seen below.
34
+
35
+
1. Select **NEW** > **Compute** > **Windows Server 2012 R2 Datacenter**, notice that the **Select a deployment model** list already shows **Classic**, and then select **Create**.
43
36
44
-

45
-
6. Select **OK** under **IP addresses**, select **OK** under **Network**, and then select **OK** under **Optional config**.
46
-
7. Under**Create VM**, select **Create**. Notice the tile below displayed in your dashboard:
37
+
:::image type="content" source="./media/virtual-networks-static-ip-classic-pportal/figure01.png" alt-text="Screenshot that shows the Azure portal with the New > Compute > Windows Server 2012 R2 Datacenter tile highlighted.":::
38
+
39
+
1. In**Create VM**, enter the name of the VM to be created (*DNS01* in the scenario), the local administrator account, and password.
47
40
48
-

41
+
:::image type="content" source="./media/virtual-networks-static-ip-classic-pportal/figure02.png" alt-text="Screenshot that shows how to create a VM by entering the name of the VM, local administrator user name, and password.":::
42
+
43
+
1. Select **Optional Configuration** > **Network** > **Virtual Network**, and then select **TestVNet**. If **TestVNet** isn't available, make sure you're using the *Central US* location and have created the test environment described at the beginning of this article.
44
+
45
+
:::image type="content" source="./media/virtual-networks-static-ip-classic-pportal/figure03.png" alt-text="Screenshot that shows the Optional Configuration > Network > Virtual Network > TestVNet option highlighted.":::
46
+
47
+
1. In **Network**, make sure the subnet currently selected is *FrontEnd*, then select **IP addresses**, under **IP address assignment** select **Static**, and then enter *192.168.1.101* for **IP Address** as seen in the following screenshot.
48
+
49
+
:::image type="content" source="./media/virtual-networks-static-ip-classic-pportal/figure04.png" alt-text="Screenshot that highlights the IP Addresses field where you type the static IP address.":::
50
+
51
+
1. Select **OK** under **IP addresses**, select **OK** under **Network**, and then select **OK** under **Optional config**.
52
+
53
+
1. Under **Create VM**, select **Create**. Notice the following tile displayed in your dashboard:
54
+
55
+
:::image type="content" source="./media/virtual-networks-static-ip-classic-pportal/figure05.png" alt-text="Screenshot that shows the Creating Windows Server 2012 R2 Datacenter tile.":::
49
56
50
57
## How to retrieve static private IP address information for a VM
51
-
To view the static private IP address information for the VM created with the steps above, execute the steps below.
52
58
53
-
1. From the Azure portal, select **BROWSE ALL** > **Virtual machines (classic)** > **DNS01** > **All settings** > **IP addresses** and notice the IP address assignment and IP address as seen below.
54
-
55
-

59
+
To view the static private IP address information for the VM created with the previous steps, execute the following steps.
60
+
61
+
1. From the Azure portal, select **BROWSE ALL** > **Virtual machines (classic)** > **DNS01** > **All settings** > **IP addresses** and notice the following IP address assignment and IP address information:
62
+
63
+
:::image type="content" source="./media/virtual-networks-static-ip-classic-pportal/figure06.png" alt-text=" Screenshot of create VM in Azure portal.":::
56
64
57
65
## How to remove a static private IP address from a VM
58
66
59
67
Under **IP addresses**, select **Dynamic** to the right of **IP address assignment**, select **Save**, and then select **Yes**, as shown in the following picture:
60
-
61
-

68
+
69
+
:::image type="content" source="./media/virtual-networks-static-ip-classic-pportal/figure07.png" alt-text="Screenshot that shows how to remove the static private IP address from a VM by selecting Dynamic to the right of the IP address assignment label.":::
62
70
63
71
## How to add a static private IP address to an existing VM
64
72
65
73
1. Under **IP addresses**, shown previously, select **Static** to the right of **IP address assignment**.
66
-
2. Type *192.168.1.101* for **IP address**, select **Save**, and then select **Yes**.
74
+
75
+
1. Type *192.168.1.101* for **IP address**, select **Save**, and then select **Yes**.
67
76
68
77
## Set IP addresses within the operating system
69
78
70
-
It’s recommended that you do not statically assign the private IP assigned to the Azure virtual machine within the operating system of a VM, unless necessary. If you do manually set the private IP address within the operating system, ensure that it is the same address as the private IP address assigned to the Azure VM, or you can lose connectivity to the virtual machine. You should never manually assign the public IP address assigned to an Azure virtual machine within the virtual machine's operating system.
79
+
It’s recommended that you don't statically assign the private IP assigned to the Azure virtual machine within the operating system of a VM, unless necessary. If you do manually set the private IP address within the operating system, ensure that it's the same address as the private IP address assigned to the Azure VM. Failure to match the IP address could result in loss of connectivity to the virtual machine.
71
80
72
81
## Next steps
82
+
73
83
* Learn about [reserved public IP](/previous-versions/azure/virtual-network/virtual-networks-reserved-public-ip) addresses.
84
+
74
85
* Learn about [instance-level public IP (ILPIP)](/previous-versions/azure/virtual-network/virtual-networks-instance-level-public-ip) addresses.
86
+
75
87
* Consult the [Reserved IP REST APIs](/previous-versions/azure/reference/dn722420(v=azure.100)).
0 commit comments