Hi Kevint1985!
Have you tried the following command from an elevated command prompt?
route -p add 0.0.0.0 mask 0.0.0.0 192.168.44.3 if 10
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
I am trying to add multiple default gateways to a VM IPV4 Configuration. However the attempts ive made only seem to allow me to add 1. Ive tried the following but nothing is setting 2. The reason we use 2 DGWs is for failover to alternate DCs. Please help!
This command doesnt allow me to use a string for IPAddress
New-NetIPAddress -AddressFamily IPV4 -IPAddress <IPAddress> -DefaultGateway "DGW1","DGW2" -InterfaceAlias 8
$wmi = get-wmiobject win32_networkadapterconfiguration -filter "ipenabled = 'true'"
$wmi.SetGateways("DGW1", 1)
$wmi.SetGateways("DGW2", 2)
$wmi.SetGateways("DGW1", 1),("DGW2", 2)
Hi Kevint1985!
Have you tried the following command from an elevated command prompt?
route -p add 0.0.0.0 mask 0.0.0.0 192.168.44.3 if 10
Thanks that added 192.168.44.3 as an additional DGW
thanks for the tip. Is there a reason it reads back Ok! but when checking in the network adapter IPV4 settings it doesnt appear?. But if you do a print it shows?