wesmon wroteOn the client I'd like to get all traffic except for VPN traffic to go out the local router/internet connection.
Do you mean to say that all traffic that is not addressed to 192.168.10.x, should not go through the VPN?
wesmon wrote
The client's ip is 192.168.0.50 with a gateway of 192.168.0.1
The VPN server is 10.1.10.111 and the DHCP is 192.168.10.x
After reading through your entire post, what I think you mean to say is that the
remote host address is 10.1.10.111, and the
VPN server is 192.168.10.1, serving the 192.168.10.x subnet
How do you access the 10.1.10.111 network?
client
remote 10.1.10.111 2019
route 192.168.10.0 255.255.255.0 vpn_gateway 3
Isn't vpn_gateway 192.168.10.1?
So, specifying that the route to 192.168.10.x is through 192.168.10.1 is completely redundant? (ie: you can remove this line).
Its redundant because when you connect the VPN, the route will be installed by openvpn automatically.
If you want such fine grained control, use the "
route-nopull" command. With route-nopull, you can specify each route individually from the client.conf file and no routes will be added automatically by the vpn, without your explicit instruction.
wesmon wroteHere is the server config:
local 10.1.10.111
push "dhcp-option DNS 10.1.10.1"
push "dhcp-option DNS 8.8.4.4"
dev tap
server 192.168.10.0 255.255.255.128
push "redirect-gateway def1"
You can immediately delete the line --
push "redirect-gateway def1" , because that specific push will cause all the client traffic to be routed through VPN -- you already said you don't want that.
Also, why dev tap and not tun?
here is the minimum changes to make:
In server .conf
- remove push "redirect-gateway def1"
- replace tap with tun