how to config to support some sites not use vpn

Need help configuring your VPN? Just post here and you'll get that help.

Moderators: TinCanTech, TinCanTech, TinCanTech, TinCanTech, TinCanTech, TinCanTech

Forum rules
Please use the [oconf] BB tag for openvpn Configurations. See viewtopic.php?f=30&t=21589 for an example.
Post Reply
lanshine
OpenVpn Newbie
Posts: 2
Joined: Sun Nov 12, 2017 6:13 am

how to config to support some sites not use vpn

Post by lanshine » Sun Nov 12, 2017 6:42 am

I have a openVPN server installed on my VPS. On my labtop, when I start openVPN, all the traffic go through VPN.
Now I want just some of sites go through VPN and the other through non-VPN, how should I do?

I tried to add vpn_gateway route on my client, but failed.
And here is my server and client VPN config.

server:

Code: Select all

port 443
dev tun
server 10.10.10.0 255.255.255.0
ifconfig-pool-persist ipp.txt
ca ca.crt
cert server.crt
key server.key
dh dh2048.pem
push "route 10.10.10.0 255.255.255.0"
push "redirect-gateway"
comp-lzo
keepalive 10 60
ping-timer-rem
persist-tun
persist-key
group nobody
daemon

client:

Code: Select all

client
remote xx.xx.xx.xx 443
dev tun
comp-lzo
ca ca.crt
cert client1.crt
key client1.key
route-delay 2
route-method exe
redirect-gateway def1
#max-routes 1000 
#route-nopull

dhcp-option DNS 8.8.8.8
dhcp-option DNS 8.8.4.4
dhcp-option DNS 4.2.2.1
dhcp-option DNS 4.2.2.2
verb 3

lanshine
OpenVpn Newbie
Posts: 2
Joined: Sun Nov 12, 2017 6:13 am

Re: how to config to support some sites not use vpn

Post by lanshine » Sat Dec 16, 2017 1:13 pm

solved. nothing to do with vpn settings.
just add route item for traffic that don't need via vpn.

Post Reply