MacLochlainns Weblog

Michael McLaughlin’s Technical Blog

Site Admin

Windows 7 Static IP

with 6 comments

There are some subtle changes between Windows 7 and either Windows XP and Windows Vista. Since I use virtualization (with VMWare Fusion) extensively to test environments, I seem to go through this drill too often. By the way, I upgraded to VMWare Fusion 3 before testing the production releases of Windows 7.

The easiest Windows 7 installation uses DHCP. That’s what I did before patching the OS, installing virus protection software, and installing a few tools and program. Then, I change from a dynamic IP to static IP address and add a meaningful name to the C:\Windows\System32\Drivers\etc\hosts file. Here are the steps to set a static IP address on Windows 7:

  1. Assuming that you’re in the Category view, you should navigate to the Control Panel, choose Network and Internet, and then click Network and Sharing Center. This is the window that you should see (click image to enlarge it):

NetworkSetup1

    Click the Local Area Connection to begin configuring your static IP address.

NetworkSetup2

  1. From the Local Area Connection Status window, click the Details button to see your existing connection details (most likely DHCP). If you’re running this in VMWare Fusion, the 172.16.153.129 is the first IP address allocated. You should note the default gateway and DNS server IP address, which should always be 172.16.153.2. Click the Close button when you’ve made note of those IP addresses for subsequent steps.

NetworkSetup3

  1. Back at the Local Area Connection Status window, click the Properties button. It will show you the Local Area Connection Properties dialog. Click on the Internet Protocol Version 4 (TCP/IPv4) in the item box of the dialog window.

NetworkSetup4

  1. Click the Use the following IP address radio button and enter the appropriate values for your static IP address. The default gateway and DNS server are generally different but are the same when you’re using NAT addressing inside VMWare.

NetworkSetup5

You should be completed now. If you test the connection, Windows 7 raises and error but everything works after you reboot the operating system.

Written by maclochlainn

November 26th, 2009 at 9:34 pm

6 Responses to 'Windows 7 Static IP'

Subscribe to comments with RSS or TrackBack to 'Windows 7 Static IP'.

  1. Will those steps be the same if I’m using a wireless connection?

    anonymous

    4 Dec 09 at 9:49 pm

  2. Generally, wireless IP addresses are allotted as DHCP addresses, but you’ll need to determine the range of wireless IP addresses that are available as static IP address, then you’ll need to define the use in the DNS server.

    maclochlainn

    4 Dec 09 at 10:20 pm

  3. Hi,

    I am troubleshooting with the connection using static IP address. I found on your last picture, that there are the Valid Static IPs only to 127??? Is that right?
    Because my internet provider gave me the IP ended by 228. Is there a problem or you can think of something else? Note: I don’t have problem to connect with my Win2000 and Linux-Ubuntu. Also the adapter is working, at work I am using Dynamic IP and there is everything fine…thanks a lot.

    Roman

    8 Dec 09 at 12:43 pm

  4. It’s hard to figure out what you need from what you’ve written. Can you do the following and post the results as a followup comment?

    1. Change the network settings back to DHCP.
    2. Reboot the server.
    3. When the server is back online, open a command shell (Run cmd.exe).
    4. Run this command, and put the results in a comment:

    C:\> IPCONFIG /ALL

    This is the part of the output that would help me identify what you may require in your settings:

    Windows IP Configuration
     
       Host Name . . . . . . . . . . . . : WIN-BIX95J1IL3W
       Primary Dns Suffix  . . . . . . . :
       Node Type . . . . . . . . . . . . : Hybrid
       IP Routing Enabled. . . . . . . . : No
       WINS Proxy Enabled. . . . . . . . : No
       DNS Suffix Search List. . . . . . : localdomain
     
    Ethernet adapter Local Area Connection:
     
       Connection-specific DNS Suffix  . : localdomain
       Description . . . . . . . . . . . : Intel(R) PRO/1000 MT Network Connection
       Physical Address. . . . . . . . . : 00-0C-29-59-59-E2
       DHCP Enabled. . . . . . . . . . . : Yes
       Autoconfiguration Enabled . . . . : Yes
       Link-local IPv6 Address . . . . . : fe80::e95e:2afc:3a3c:6a68%10(Preferred)
       IPv4 Address. . . . . . . . . . . : 192.168.251.131(Preferred)
       Subnet Mask . . . . . . . . . . . : 255.255.255.0
       Lease Obtained. . . . . . . . . . : Tuesday, December 08, 2009 6:07:06 PM
       Lease Expires . . . . . . . . . . : Tuesday, December 08, 2009 6:37:08 PM
       Default Gateway . . . . . . . . . : 192.168.251.2
       DHCP Server . . . . . . . . . . . : 192.168.251.254
       DNS Servers . . . . . . . . . . . : 192.168.251.2
       Primary WINS Server . . . . . . . : 192.168.251.2
       NetBIOS over Tcpip. . . . . . . . : Enabled

    This uses 192.* because it’s single NAT’d, and the VMWare Fusion default. As a note, the posting refers to a range in the 172.* range because that’s how VMWare Fusion maps IP addresses in a double NAT’d situation. Double NAT assignments like this occur in VMWare Fusion most frequently when the host’s IP address (Mac OS X) is in the 192.* subnet.

    - The range for static IP addresses is: 172.16.153.3 to 172.16.153.127
    - The range for dynamic IP addresses is: 172.16.153.128 to 172.16.153.255

    An alternate subnet configuration for a single NAT for most ISP DHCPconfigurations would have the following ranges with a 192.* subnet.

    - The range for static IP addresses is: 192.168.0.3 to 192.168.0.127
    - The range for dynamic IP addresses is: 192.168.0.128 to 192.168.0.255

    Look forward to hearing from you.

    maclochlainn

    8 Dec 09 at 7:22 pm

  5. The properties of the IPv4 is disabled in my windows !

    how can i enable it ??

    dmha

    27 Jan 10 at 2:45 pm

  6. If you navigate to the Control Panel, Network and Internet, and Network Connections, you should see a Local Area Connection icon. Click on that icon, it launches the Local Area Connection Status dialog. Click the Details … button and you’ll get the Network Connection Details dialog. In this dialog, you should see that you have either a IPv4 Default Gateway or IPv6 Default Gateway. If you have an IPv4 IP address, you should have properties for it. My guess is that you’re using an IPv6 gateway, which means you should set the properties for the IPv6. The interesting thing is that even if you’re not using the other protocol, the Properties dialog shouldn’t be disabled. Are you the Administrator account on the machine or a delegated user?

    maclochlainn

    28 Jan 10 at 12:33 am

Leave a Reply