Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

How might I force traffic to a specific IP address through a particular network interface, in Windows?

After a bit of rudimentary Googling, this question comes close to answering my question, but my situation is a bit different - http://serverfault.com/questions/92575/how-to-route-different-traffic-thru-different-network-interfaces-in-windows

I'm a bit confused by his question/answer because I'm not quite sure how I would identify which interface has the higher metric.

Usage case - I have an iPhone 5 w/LTE connectivity, and I want to use RDP to connect to a specific (and static) IP address. All other traffic, as usual, should travel through the corporate LAN, but initiating an RDP connection to this particular IP address (my home computer) should use the iPhone's network adapter interface.

How might I accomplish this with the route command?

some example IP addresses:

My corporate LAN IP - 192.168.100.1 My iPhone 5 IP - 12.11.10.9

share|improve this question

1 Answer 1

up vote 1 down vote accepted

You would want to set up a route for static IP with a netmask of 255.255.255.255 and a gateway of 12.11.10.9:

route add yourSpecificStaticIP mask 255.255.255.255 12.11.10.9

This will route traffic to yourSpecificStaticIP over the iPhone network interface. You will need to remove the route if at any point you do not want to use the iPhone, and you will need to recreate the route any time you reboot your machine, unless you use the persist (-p) option.

share|improve this answer
    
Perfect, thank you! –  Alex Karpowitsch Apr 19 '13 at 16:25

Your Answer

 
discard

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.