Monday 3 March 2014

Add a static IP route

TechNet: Add a static IP route

route adddestinationmasksubnetmaskgatewaymetriccostmetricifinterface

example #1: route add 10.0.0.0 mask 255.0.0.0  192.168.1.1

by adding this to a workstation you are saying they the route to the 10.0.0.0 network is via gateway 192.168.1.1. This assumes the workstation is on network 192.168.1.0.

This command would result in a temporary route to make it persistent add –p to the command.

example #2: route add 10.0.0.0 mask 255.0.0.0  192.168.1.1 –p

Powershell 4.0:

New-NetRoute

Get-NetRoute | Format-List -Property *

No comments:

Post a Comment