OpenVPN connected but cannot online

June 20, 2015 1.7k views
VPN

Hi there,

I had setup a OPENVPN server on my droplet with the following instruction :

https://www.digitalocean.com/community/tutorials/how-to-set-up-an-openvpn-server-on-ubuntu-14-04

I able to connect it with my openVPN client but unfortunately it unable to get online.
my situation :

  1. I able to connect to my VPN server through VPN client but wont online.
  2. my web site which shared hosted on this VPN server is down.
  3. I still can ssh from my terminal to access the server.

your help would be greatly appreciated

System information as of Sat Jun 20 14:35:23 CST 2015

System load: 0.03 Processes: 79
Usage of /: 22.2% of 19.56GB Users logged in: 1
Memory usage: 22% IP address for eth0: 128.199.255.87
Swap usage: 0% IP address for tun0: 10.8.0.1

$ ifconfig eth0
eth0 Link encap:Ethernet HWaddr 04:01:15:09:14:01
inet addr:128.199.255.87 Bcast:128.199.255.255 Mask:255.255.192.0
inet6 addr: fe80::601:15ff:fe09:1401/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:1078 errors:0 dropped:0 overruns:0 frame:0
TX packets:892 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:112860 (112.8 KB) TX bytes:164498 (164.4 KB)

$ ifconfig tun0
tun0 Link encap:UNSPEC HWaddr 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00
inet addr:10.8.0.1 P-t-P:10.8.0.2 Mask:255.255.255.255
UP POINTOPOINT RUNNING NOARP MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:100
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)

1 Answer

edit /etc/sysctl.conf and un-comment net.ipv4.ip_forward=1

un-comment push "redirect-gateway def1 bypass-dhcp"

have you restart you apache/ngix web server?

Have another answer? Share your knowledge.