I've been using a Raspberry Pi 3B (running Raspbian) with OpenVPN connected to a Portuguese IPVanish server for about a month now and everything has been great. In fact I've been amazed at the speeds and quality of service I've been getting.
It was initially very easy to set up, I simply followed this tutorial and it just worked. However, today it just stopped working. Nothing to my knowledge has changed and so I assumed it was a service issue. I contacted IPVanish and they told me all services were running as normal. I thought maybe the router had updated so I checked the firewall and enabled the port forwarding for 1194 on UDP and TCP but this didn't fix the problem. I even turned the firewall off temporarily to see the effect but still didn't fix the issue. I downloaded the cert again in case it was corrupted but still no joy.
Here is the content of my portugal.conf file:
client
dev tun
proto udp
remote lis-c09.ipvanish.com 443
resolv-retry infinite
nobind
persist-key
persist-tun
persist-remote-ip
ca /etc/openvpn/ca.ipvanish.com.crt
verify-x509-name lis-c09.ipvanish.com name
comp-lzo
verb 3
auth SHA256
cipher AES-256-CBC
keysize 256
tls-cipher TLS-DHE-RSA-WITH-AES-256-CBC-SHA:TLS-DHE-DSS-WITH-AES-256-CBC-SHA:TLS-RSA-WITH-AES-256-CBC-SHA
auth-user-pass /etc/openvpn/auth.txt
IPVanish don't supply a User Certificate
or a Private Key
so these have been left out, but this was working fine before as is.
The auth.txt
file simply contains my username and password on separate lines as it always has and I've checked my login with these and they work.
In the tutorial it states at the bottom of step 3:
If you are having issues getting the tunnel up first try rebooting your Raspberry Pi and then double check the configuration for errors.
After doing some Googling I found this command to display the log:
grep VPN /var/log/syslog
The output of this is:
...
Jun 19 14:44:09 raspberrypi systemd[1]: Stopping OpenVPN connection to portugal...
Jun 19 14:44:09 raspberrypi systemd[1]: Stopped OpenVPN service.
Jun 19 14:44:09 raspberrypi systemd[1]: Stopping OpenVPN service...
Jun 19 14:44:09 raspberrypi systemd[1]: Starting OpenVPN service...
Jun 19 14:44:09 raspberrypi systemd[1]: Started OpenVPN service.
Jun 19 14:44:09 raspberrypi systemd[1]: Stopped OpenVPN connection to portugal.
Jun 19 14:44:09 raspberrypi systemd[1]: Starting OpenVPN connection to portugal...
Jun 19 14:44:09 raspberrypi ovpn-portugal[655]: OpenVPN 2.4.0 arm-unknown-linux-gnueabihf [SSL (OpenSSL)] [LZO] [LZ4] [EPOLL] [PKCS11] [MH/PKTINFO] [AEAD] built on Jul 18 2017
Jun 19 14:44:09 raspberrypi systemd[1]: Started OpenVPN connection to portugal.
Which seems to suggest that the connaction has been established. But when I run ifconfig
I get:
eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.1.15 netmask 255.255.255.0 broadcast 192.168.1.255
inet6 fe80::cd06:9e93:85bd:e6ca prefixlen 64 scopeid 0x20<link>
ether b8:27:eb:fe:cb:48 txqueuelen 1000 (Ethernet)
RX packets 39800 bytes 2265408 (2.1 MiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 792 bytes 136823 (133.6 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
inet 127.0.0.1 netmask 255.0.0.0
inet6 ::1 prefixlen 128 scopeid 0x10<host>
loop txqueuelen 1000 (Local Loopback)
RX packets 4 bytes 156 (156.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 4 bytes 156 (156.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
wlan0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
ether b8:27:eb:ab:9e:1d txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
Any ideas why this has stopped working, what else should I be looking at?
Thanks,
Stu