Hi,
I followed this tutorial (
https://help.ubuntu.com/14.04/serverguide/openvpn.html) to install OpenVPN on a azure virtual machine with Ubuntu server 14.04.
I followed the simple server and client configuration and i was able to connect from a remote windows 7 client to the server. But when i tried to implement the routing of all traffic through the server (
http://openvpn.net/index.php/open-source/documentation/howto.html#redirect) the client fails to connect.
In log window of OpenVPN Connection (client) appears:
"open_tun, tt->ipv6=0"
"CreateFile failed on TAP device: \\.\Global\{821234DD-...}.tap"
"All TAP-Windows adapters on this system are currently in use."
Server configuration file:
port 1194
proto udp
dev tun
ca ca.crt
cert server.crt
key server.key
dh dh2048.pem
server 10.8.0.0 255.255.255.0
ifconfig-pool-persist ipp.txt
push "redirect-gateway def1"
push "dhcp-option DNS 10.8.0.1"
push "redirect-gateway def1 bypass-dhcp"
keepalive 10 120
comp-lzo
persist-key
persist-tun
status openvpn-status.log
verb 3
Client configuration file
client
dev tun
proto udp
remote <server-ip> 1194
resolv-retry infinite
nobind
persist-key
persist-tun
ca ca.crt
cert client.crt
key client.key
comp-lzo
verb 3
I also runned the following commands:
iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -o eth0 -j MASQUERADE
iptables -A INPUT -i tun+ -j ACCEPT
iptables -A FORWARD -i tun+ -j ACCEPT
Can you guys help me?
Thanks in advance,
Pedro