2
1
What I have:
- OSX/PC
- VDS (ubuntu server)
- VPN provider account
What I did:
- Installed
openvpn
on VDS. - Successfully connected from PC to VDS server.
- Successfully connected from VDS to VPN provider with my login/password.
- Lost all connections.
Why did this happen? What should I do? I read something about routes and iptable rules, but I can't make sense of it.
Here are my confs:
PC/OSX client.conf
:
client
dev tun1
proto udp
remote VDS_SERVER_PUBLIC_IP 1194
resolv-retry infinite
remote-random
nobind
tun-mtu 1500
tun-mtu-extra 32
mssfix 1450
persist-key
persist-tun
ping 15
ping-restart 0
ping-timer-rem
reneg-sec 0
ca ./ca.crt
cert ./client01.crt
key ./client01.key
remote-cert-tls server
VDS server.conf
:
port 1194
proto udp
dev tun1
tls-server
;server 192.168.100.0 255.255.255.0
server 10.8.8.0 255.255.255.0
client-to-client
max-clients 10
keepalive 10 120
persist-key
persist-tun
status openvpn-status.log
push redirect-gateway
push route 192.168.0.0 255.255.155.0
duplicate-cn
ca /etc/openvpn/keys1/ca.crt
cert /etc/openvpn/keys1/server1.crt
key /etc/openvpn/keys1/server1.key
dh /etc/openvpn/keys1/dh2048.pem
VDS client.conf
:
client
dev tun
proto udp
remote VPN_PROVIDER_PUBLIC_IP 1194
resolv-retry infinite
remote-random
nobind
tun-mtu 1500
tun-mtu-extra 32
mssfix 1450
persist-key
persist-tun
ping 15
ping-restart 0
ping-timer-rem
reneg-sec 0
remote-cert-tls server
#mute 10000
auth-user-pass
comp-lzo
verb 3
pull
fast-io
cipher AES-256-CBC
<ca>
-----BEGIN CERTIFICATE-----
qwe
-----END CERTIFICATE-----
</ca>
key-direction 1
<tls-auth>
#
# 2048 bit OpenVPN static key
#
-----BEGIN OpenVPN Static key V1-----
qwe
-----END OpenVPN Static key V1-----
</tls-auth>
1You are pushing
redirect-gateway
to your client which will break all your current non-local connections – dotvotdot – 2016-03-22T02:12:52.460