Sunday, January 18, 2009

Using Static IP Address With Vista ICS

I have been trying to figure out a way to access Internet via Vista ICS from my OpenSolaris box. Since my OS box is a file server, it doesn't make sense to use a DHCP or else it will get a different IP address upon each boot up which is not convenient.

After some time of experimenting with it, I managed to get the static IP assigned to the OS box, and here are the steps.

For ease of naming, I will call the Vista host as 'H', this is the computer with ICS turned on that will connect to the outside world. The client computer that wishes to use ICS we shall call as 'C', and in my case it is running OpenSolaris snv_101b.

  • Make sure both H and C are connected somehow, either wired or wireless is entirely up to you. The bottom line is they must be connected. The most time-wasting mistake is to try troubleshooting a network connectivity at software level while the root-cause is due to unplugged cable(s).
  • There is nothing to configure at H side once ICS is up and running
  • To make sure ICS really works, you may want to enable DHCP at C to see if it can talk to the outside world
  • Once C is working with DHCP, disable the auto configuration by unchecking the "Configure network automatically' box.


  • Set the following parameter

    IP address: 192.168.0. x where x is between 2 and 254, inclusive

    Subnet mask: 255.255.255.0

    Gateway address: 192.168.0.1 (this address is fixed by M$)


  • Check /etc/resolv.conf and make sure the following lines are there:


    domain mshome.net
    nameserver 192.168.0.1



  • Open and edit /etc/nsswitch.conf (root privilege required), search for the following lines:


    hosts: files

    ipnodes: files



    Change the above lines to:

    hosts: files dns

    ipnodes: files dns
Now C should be able to access the Internet normally while having a static private IP. Have fun. :)

No comments: