Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I know how to use hotspot shield or private VPN to use Pandora/Hulu outside of US. However, those VPN solutions route all traffic through VPN gateway. So even browsing a local site, the routing path is going through gateway in US, then back to my local destination site. How can I configure Windows 7 routing table to set traffic to Pandora/Hulu going through VPN gateway, where other traffic just use the original internet connection? I know in Windows Command Line Prompt, there is a tool - route which seems like it. But I don't know how to use it.

The other question is how to figure out what IP/subnet is related to Pandora/Hulu? I guess nslookup is not sufficient since there may be some other host with different hostname belongs to hulu.

share|improve this question

migrated from Oct 28 '11 at 9:25

This question came from our site for system and network administrators.

up vote 4 down vote accepted

Yes, the first step is to identify the IP addresses you want to route - the actual routing is fairly straightforward.

When you are connected to the VPN and do

route print

It will show a default route, something like:

Active Routes:
Network Destination        Netmask          Gateway       Interface  Metric     20

The IP address of the gateway and interface will be provided by your VPN provider at connection time.

The destination and netmask means "match all traffic to this route, and send it to the gateway"

You want to delete this, and replace it with a default route that is out of your internet connection. Like this (assuming was your own router):

route delete mask
route add mask

Now all traffic will go out of your router, and none through the VPN.

Then you figure out the hulu network range - lets say it is, and add a route for it:

route add mask

So what this is saying is, any traffic destined for any address in the range should be sent to the VPN gateway.

Determining the hulu range might be difficult to deduce, but you could do some googling as you won't be the first to try and figure out what ranges they use. Failing that, you could install wireshark and observe what traffic flows through the VPN when accessing hulu (you'll want to make sure you don't run anything else at the same time).

share|improve this answer
I want to try this, is there anyway to return to the default routing table if I mess something up? – Arya Oct 18 '12 at 2:31
@Arya route print will show the current routing table, so you can just add/delete any entries to restore it. Also, unless you use the /p switch, none of the routing changes are persistant, so simply rebooting will get you back to normal. – Paul Oct 18 '12 at 3:04

Go into the VPN Properties window, Networking tab, select 'Internet Protocol Version 4 (TCP/IPv4)', click 'Properties'. In Internet Protocol Version 4 (TCP/IPv4) Properties window click 'Advanced...'. Untick 'Use default gateway on remote network'. Click Ok, Ok, Ok.

share|improve this answer
Thanks, it works.But, how to set traffic to Pandora/Hulu going through VPN gateway? – Green Lei Apr 20 at 2:22

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .