Skip to content
October 8, 2007 / Upnishad

Quickly switch between networks

Most of the laptop users must have faced this problem. You have to switch between DHCP and static IP settings when you switch between different networksat home and in office. There ways to switch profiles but netsh comes in handy if you want to quickly switch networks. On the Windows command prompt, give the following commands for the type of network you want to switch to.

Using DHCP (dynamic IP Address)
———————–
netsh interface ip set address name=”Local Area Connection” dhcp
netsh interface ip set dns name=”Local Area Connection” dhcp

Using Static IP Address
———————-
netsh interface ip set address name=”Local Area Connection” source=static addr=192.168.1.2 mask=255.255.0.0
netsh interface ip set address name=”Local Area Connection” gateway=192.168.0.1 gwmetric=0
netsh interface ip set dns name=”Local Area Connection” source=static addr=192.168.0.1
netsh interface ip add dns name = “Local Area Connection” addr = 192.168.0.2

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: