Sign up ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I have several network cards but for know I need to route all remote connections to one of them. So I added the following route:

route add mask metric 1 (where is a default gateway of required network card)

But now local connections to locahost do not work. How can I keep them working?

share|improve this question

2 Answers 2

up vote 1 down vote accepted

If you want your default route to be a specific NIC, this is accomplished through your Network Connections > Advanced > Advanced Settings... > Adapters and Bindings tab > Connections window (I'm currently on Vista, but is the same area for all OS). You can change the order in which Windows will use the NICs. Just move the NIC you want to the top of the list and that should take care of the default route (as long as you don't have any specific routes that would supersede the NIC order).

You could also add specific route as you have done and possibly adjust the metric if there are conflicting routes as Hyppy stated, but you'd also need the -p switch to make the route persistent across reboots. If you use the first method, you shouldn't need to add any routes at all.

share|improve this answer

Up your metric. A metric value determines priority. If your custom route's metric is lower than the route for the destination, then it will route those connections through to your gateway.

share|improve this answer
Connection Properties -> Properties on TCP/IP -> Advanced TCP/IP -> at bottom of page is the metric settings. –  Robert Jun 15 '12 at 16:20
I was thinking more the metric for the route itself, in the command –  Hyppy Jun 15 '12 at 17:05
windows has a specific route for that the new route he added shouldn't conflict with. It will match on the network pattern before looking at the metric. –  August Jun 15 '12 at 17:42

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.