For days i have searched for an answer regarding an issue with OpenVPN. I made a VPN with my raspberry pi running raspbian. When i connect to the VPN, my IP address changes but i cannot connect to the internet. I have tried on Windows 10, an iPhone, and a Galaxy s7. My Raspberry Pi is connected to the router directly with an Ethernet cable.
All devices connect to the VPN but eventually say, "This site can't be reached. [URL]'s server DNS address could not be found "
I know that there are tons of support pages already out there about this but i have tried everything with no success. Listed below are the files if you need them.
local 192.168.1.103 dev tun proto udp port 1194 ca /etc/openvpn/easy-rsa/keys/ca.crt cert /etc/openvpn/easy-rsa/keys/RaspberryVPN.crt key /etc/openvpn/easy-rsa/keys/RaspberryVPN.key dh /etc/openvpn/easy-rsa/keys/dh1024.pem server 10.8.0.0 255.255.255.0 ifconfig 10.8.0.1 10.8.0.2 push "route 10.8.0.1 255.255.255.255" push "route 10.8.0.0 255.255.255.0" push "route 192.168.1.103 255.255.255.0" push "dhcp-option DNS 184.108.40.206" client-to-client push "redirect-gateway def1" duplicate-cn keepalive 10 120 tls-auth /etc/openvpn/easy-rsa/keys/ta.key 0 cipher AES-128-CBC comp-lzo user nobody group nogroup persist-key persist-tun status /var/log/openvpn-status.log 20 log /var/log/openvpn.log verb 1
#!/bin/sh #iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -o eth0 -j SNAT --to-source 192.168.1.103 iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -o eth0 -j MASQUERADE
# interfaces(5) file used by ifup(8) and ifdown(8) # Please note that this file is written to be used with dhcpcd # For static IP, consult /etc/dhcpcd.conf and 'man dhcpcd.conf' # Include files from /etc/network/interfaces.d: source-directory /etc/network/interfaces.d auto lo iface lo inet loopback iface eth0 inet static address 192.168.1.103 netmask 255.255.255.0 network 192.168.1.0 broadcast 192.168.1.255 gateway 192.168.1.1 pre-up /etc/firewall-openvpn-rules.sh allow-hotplug wlan0 iface wlan0 inet manual wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf allow-hotplug wlan1 iface wlan1 inet manual wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf
client dev tun proto udp remote [EXTERNAL IP] 1194 resolv-retry infinite nobind persist-key persist-tun mute-replay-warnings ns-cert-type server key-direction 1 cipher AES-128-CBC comp-lzo verb 1 mute 20