Hello All,
Long time lover of the software. I have a VPN service which I use (PIA) to connect my rPi devices to for streaming.
I just stood up a new pi and I am now on a Jessie variant of Raspbian. Where the old devices are still running Wheezy.
Anyway the issue I have is quite strange. I have configured the new pi almost identical to the old device. However, upon bootup the problem child device will establish a VPN connected, but I cannot resolve DNS.
I am using the same config files from the old device:
OVPN config
client
dev tun
proto udp
remote us-east.privateinternetaccess.com 1194
resolv-retry infinite
nobind
persist-key
persist-tun
ca ca.crt
tls-client
remote-cert-tls server
auth-user-pass
comp-lzo
verb 1
reneg-sec 0
crl-verify crl.pem
Startup Script
#! /bin/sh
# /etc/init.d/VPNConnection
### BEGIN INIT INFO
# Short-Description: Simple script to start a program at boot
# Description: A simple script from http://www.stuffaboutcode.comwhich will start / stop a program a boot / shutdown.
### END INIT INFO
# If you want a command to always run, put it here
# Carry out specific functions when asked to by the system
case “$1″ in
start)
echo “Starting VPN Connection”
# Connect to the VPN
cd /etc/openvpn
sudo openvpn US-East.ovpn
;;
stop)
echo “Stopping VPN Connection”
# Disconnect
killall openvpn
;;
*)
echo “Usage: /etc/init.d/VPNConnection {start|stop}”
exit 1
;;
esac
Normally I would try to solve this on my own, but this one behavior has me quite confused.
The device boots up, VPN connects, no DNS.
If I close down the VPN with the script mentioned above and I start a screen session and then run the script again manually the VPN establishes and I have DNS resolution. I am still a novice when it comes to Linux, I do not understand how it can work when you invoke it manually, but fail when it runs at boot.
Any help appreciated,
-Wooley