Saturday, June 9, 2018

Change IP address using Powershell.


  1. Get-NetIPAddress
    1. get the InterfaceIndex number for the nic you want to change the IP address on.
  2. Remove-NetIPAddress -InterfaceIndex X
  3. New-NetIPAddress -InterfaceIndex X -IPAddress x.x.x.x -PrefixLength 23 -DefaultGateway x.x.x.x
  4. Set-DnsClientServerAddress -InterfaceIndex X -ServerAddresses  x.x.x.x, x.x.x.x

No comments:

Post a Comment

Thank you for your comment.