I can successfully connect to my OpenVPN server from command line using openvpn --config client.conf
. The client.conf file contains redirec-gateway
directive to route all traffic through the VPN server. All this works fine.
Now, how can I achieve the same result with Network Manager and nm-applet?
I tried simply configuring the connection. It initializes correctly but doesn't route the traffic through the server. It's as if I ticked "Use this connection only for resources on its network" when I didn't.
It seems that when I connect from the command line, the VPN route is added at the top
# ip route show
default via 192.168.10.5 dev tun0
default via 192.168.1.1 dev eth0 proto static metric 1024
but it's added as second when connecting from the applet
# ip route show
default via 192.168.1.1 dev eth0
default via 192.168.10.5 dev tun0 proto static metric 1024
This is on Ubuntu 15.04 Vivid and OpenVPN 2.3.2.