OpenVPN service running but not listening

This forum is for admins who are looking to build or expand their OpenVPN setup.
Forum rules
Please use the [oconf] BB tag for openvpn Configurations. See https://forums.openvpn.net/viewtopic.php?f=30&t=21589 for an example.
virinom
OpenVpn Newbie
Posts: 1
Joined: Thu Apr 20, 2017 2:20 pm

OpenVPN service running but not listening

Postby virinom » Thu Apr 20, 2017 2:27 pm

Hi,
I installed openvpn to my centos 6 x64 server.
Here is my server configuration

IDK why but oconf BB tag not working for me

[oconf=]port 1194 #- port
proto udp #- protocol
dev tun
tun-mtu 1500
tun-mtu-extra 32
mssfix 1450
reneg-sec 0
cipher AES-256-CBC
auth SHA-256
ca /etc/openvpn/easy-rsa/2.0/keys/ca.crt
cert /etc/openvpn/easy-rsa/2.0/keys/server.crt
key /etc/openvpn/easy-rsa/2.0/keys/server.key
dh /etc/openvpn/easy-rsa/2.0/keys/dh4096.pem
plugin /usr/lib64/openvpn/plugins/openvpn-plugin-auth-pam.so /etc/pam.d/login
client-cert-not-required
username-as-common-name
server 10.8.0.0 255.255.255.0
push "redirect-gateway def1"
push "dhcp-option DNS 8.8.8.8"
push "dhcp-option DNS 8.8.4.4"
keepalive 5 30
comp-lzo
persist-key
persist-tun
status 1194.log
verb 3[/oconf]


Openvpn service is running but when i try to connect it from client i got openvpn connection reset by peer (wsaeconnreset) (code=10054)
I added these rules to iptables

Code: Select all

iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -o eth0 -j MASQUERADE
iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -j SNAT --to-source MY_SERVER_IP

How can i fix this?
Thanks

Return to “Server Administration”

Who is online

Users browsing this forum: No registered users and 3 guests