hello, Firstly sorry for my english 🙂
I am trying to build my own router based on raspberry PI2 (raspian OS).
Computer -> WIFI -> raspberry PI -> USB modem 3G/LTE -> VPN -> Internet
I don't have problem with WIFI connection to rasberry, and no problem with internet connection (USB modem - huawei).
I have problem with OpenVPN (i think it Can be connected with routing). When i connect with usb modem there is internet but if i after connect with openvpn (Private Internet Access) i don't have internet.
Here few logs:
After connect with wvdial:
root@routerlte:/etc/openvpn# ping google.com
PING google.com (216.58.209.46) 56(84) bytes of data.
64 bytes from waw02s05-in-f46.1e100.net (216.58.209.46): icmp_seq=1 ttl=57 time=298 ms
64 bytes from waw02s05-in-f46.1e100.net (216.58.209.46): icmp_seq=2 ttl=57 time=298 ms
OpenVpn connection:
root@routerlte:/etc/openvpn# openvpn France.ovpn
Wed Feb 24 03:37:29 2016 OpenVPN 2.3.4 arm-unknown-linux-gnueabihf [SSL (OpenSSL)] [LZO] [EPOLL] [PKCS11] [MH] [IPv6] built on Jan 23 2016
Wed Feb 24 03:37:29 2016 library versions: OpenSSL 1.0.1k 8 Jan 2015, LZO 2.08
Enter Auth Username: ********
Enter Auth Password: **********
Wed Feb 24 03:37:39 2016 UDPv4 link local: [undef]
Wed Feb 24 03:37:39 2016 UDPv4 link remote: [AF_INET]108.61.123.88:1194
Wed Feb 24 03:37:40 2016 WARNING: this configuration may cache passwords in memory -- use the auth-nocache option to prevent this
Wed Feb 24 03:37:40 2016 [Private Internet Access] Peer Connection Initiated with [AF_INET]108.61.123.88:1194
Wed Feb 24 03:37:43 2016 TUN/TAP device tun0 opened
Wed Feb 24 03:37:43 2016 do_ifconfig, tt->ipv6=0, tt->did_ifconfig_ipv6_setup=0
Wed Feb 24 03:37:43 2016 /sbin/ip link set dev tun0 up mtu 1500
Wed Feb 24 03:37:43 2016 /sbin/ip addr add dev tun0 local 10.195.1.6 peer 10.195.1.5
RTNETLINK answers: No such device
Wed Feb 24 03:37:43 2016 ERROR: Linux route add command failed: external program exited with error status: 2
Wed Feb 24 03:37:43 2016 Initialization Sequence Completed
After VPN connection:
root@routerlte:/home/pi# ping google.com
PING google.com (216.58.209.46) 56(84) bytes of data.
^C
--- google.com ping statistics ---
4 packets transmitted, 0 received, 100% packet loss, time 3008ms
And ifconfig:
root@routerlte:/home/pi# ifconfig
eth0 Link encap:Ethernet HWaddr b8:27:eb:e2:50:84
inet6 addr: fe80::e113:91c9:9202:9a0/64 Scope:Link
UP BROADCAST 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:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:596 errors:0 dropped:0 overruns:0 frame:0
TX packets:596 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:46087 (45.0 KiB) TX bytes:46087 (45.0 KiB)
ppp0 Link encap:Point-to-Point Protocol
inet addr:164.127.244.8 P-t-P:10.64.64.64 Mask:255.255.255.255
UP POINTOPOINT RUNNING NOARP MULTICAST MTU:1500 Metric:1
RX packets:10 errors:0 dropped:0 overruns:0 frame:0
TX packets:8 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:3
RX bytes:560 (560.0 B) TX bytes:157 (157.0 B)
tun0 Link encap:UNSPEC HWaddr 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00
inet addr:10.106.1.6 P-t-P:10.106.1.5 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:356488 errors:0 dropped:352755 overruns:0 carrier:0
collisions:0 txqueuelen:100
RX bytes:0 (0.0 B) TX bytes:531969800 (507.3 MiB)
wlan0 Link encap:Ethernet HWaddr 74:da:38:5b:54:33
inet addr:192.168.100.1 Bcast:192.168.100.255 Mask:255.255.255.0
inet6 addr: fe80::8334:3d06:e544:15f8/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:9116 errors:0 dropped:22 overruns:0 frame:0
TX packets:3148 errors:0 dropped:24 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:650562 (635.3 KiB) TX bytes:681255 (665.2 KiB)
wwan0 Link encap:Ethernet HWaddr 00:1e:10:1f:00:00
inet addr:169.254.62.145 Bcast:169.254.255.255 Mask:255.255.0.0
inet6 addr: fe80::b0b4:a7ba:fee8:b03/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:93 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:27945 (27.2 KiB)
Look at tun0: dropped:352755
Thanks a lot for help 🙂
Best Regards
Bart