Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

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 have problem with OpenVPN on Linux, because it overrides my gateways, so all network traffic goes through VPN tunnel. I want to push through tunnel only traffic from specific subnet. My routes without OpenVPN running:

default         192.168.0.1     0.0.0.0         UG    0      0        0 wlan0
192.168.0.0     *               255.255.255.0   U     0      0        0 wlan0

After enabling VPN:

default         172.22.73.193   128.0.0.0       UG    0      0        0 tun0
default         192.168.0.1     0.0.0.0         UG    0      0        0 wlan0
static-78-8-9-5 192.168.0.1     255.255.255.255 UGH   0      0        0 wlan0
172.22.73.192   *               255.255.255.192 U     0      0        0 tun0
192.168.0.0     *               255.255.255.0   U     0      0        0 wlan0

I tried to delete first route with command sudo route del default gw 172.22.73.193, but it always fails with SIOCDELRT: No such process.

Can I achieve that by changing OpenVPN

share|improve this question
    
Do post your OVPN client config file – HackToHell Feb 6 '13 at 11:50
    
Shouldn't that be route del -net default gw 172.22.73.193? – Paul Feb 6 '13 at 12:38

The server you are connecting to is probably an Online VPN Service Provider, which uses push "redirect-gateway" to send ALL your client data over the VPN. To stop this you can add route-nopull to your client config file.

share|improve this answer

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.