setting ip address in command line

if u want to set up ip address via cmd in windows >>:—

netsh interface ip set address name=”Local Area Connection” static 192.168.0.1 255.255.255.0 192.168.0.1 1
the last 1 indicates the metric and it can be 2,3…

( Metric is the number of hops to the destination. Anything on the local LAN is one hop and each router crossed after that is an additional hop. The Metric is used to determine the best route)

if want to set up dns >>:–

1.netsh interface ip set dns “Local Area Connection” static 192.168.1.28  (THIS IS FOR primary dns server)

2.netsh interface ip add dns name=”Local Area Connection”  192.168.1.67 index=2 (THIS IS FOR secondary dns server)

if want to get ip via dhcp >>:–

netsh interface ip set address name=”Local Area Connection” dhcp

if u wanna have dns via dhcp >>:–

netsh interface ip set dns name=”Local Area Connection” dhcp

I hope this is informative to u guys 🙂

Advertisements

Tags: , , , ,

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: