HomeWindowsWindows networkingXP: Set or configure static network IP address wtih netsh from command...

XP: Set or configure static network IP address wtih netsh from command line

Setting the IP address from the command line from XP is simple with the netsh command. This is ideal for use in batch files.


To set the following settings on the network interface “Local Area Network”

IP address: 192.168.50.100
Subnet mask: 255.255.255.0
Gateway: 192.168.50.1

use the following command (one line):

netsh int ip set address name="Local Area Connection" source=static 192.168.50.100 255.255.255.0 192.168.50.1 1

The order of the values in the command is IP address, subnet mask, and gateway. The 1 at the end is a routing metric for the gateway address. The value 1 will work for most circumstances.

Quinn McHenry
Quinn McHenry
Quinn was one of the original co-founders of Tech-Recipes. He is currently crafting iOS applications as a senior developer at Small Planet Digital in Brooklyn, New York.
RELATED ARTICLES

1 COMMENT

LEAVE A REPLY

Please enter your comment!
Please enter your name here

- Advertisment -

Most Popular

Recent Comments

Cleveland Furia on How to Clear Google Activity
Sid Wohlfarth on How to Clear Google Activity
Riley Magsayo on How to Clear Google Activity
สมัครรับเครดิตฟรี ทันที on How to improve Remote Desktop Protocol Performance
Neal Wangstad on How to Clear Google Activity
Slavcho Andov on How to install Ubuntu
Slavcho Andov on How to fix bad sectors
Sheraz Ali on How to Backup Android