Thursday, October 8, 2009

How to Change IP Settings Remotely

In order to edit or change the IP settings of a remote client in your enterprise, you would need some tools and a set of command line knowledge. To get there in no time, simply follow these steps:


* Download the PsExec tool. This tool helps you run software on remote machines over command line.


*Unpack the zip file under your c:\ . Open up a command line, navigate thru the pstools to find PsExec.exe .


* The command goes like this;


c:\psexec \\remotemachineip -u username -p password cmd.exe



\\remotemachineip : Here you can enter the IP of the remote client OR the computer name of the client. i recommend going for the IP to avoid DNS problems.

-u : user name that has administrative rights on the remote client. In an enterprise, please DO include the domain and the user name as domain\username.

Example : contoso\administrator01 .

-p : password of the user name that has administrative rights on the client machine.

cmd.exe : this is the tool we will need to edit ip settings.

* After entering the command , you will see some lines passing through and finally you will get c:\windows \system32 . This means that you have successfully logged in the client machine and its cmd.

* type netsh and press enter. Netsh is a tool that allows you to mess with your network settings.

*type int and press enter. int stands for Interface.

* Under netsh interface , enter this command that will change the IP settings.


ip set address local static theipnumber thesubnetmask thegateway metric




theipnumber : this is the desired ip address.

thesubnetmask : this is the subnet mask suitable for the desired IP

thegateway : gateway IP that will let the client machine to Internet

metric : the metric of the gateway that will prioritise the entries of different gateways respectfully.