0

Discussion topic: Wireguard setup on raspberry pi is working but no internet access

Reply
This message was authored by averter This message was authored by: averter

Wireguard setup on raspberry pi is working but no internet access

I have successfully configured a wireguard vpn at home on my raspberry pi, and I am able to connect to the lan from outside/work. The steps are 1- set a static ip on the rpi, 2- create a port forwarding rule at 51820 to the rpi, and 3- open a firewall exception that redirects the port to the rpi.

All is well except that when I connect to the lan I have no access to the internet. In other words, I can access the devices on my lan but nothing else. Before I had the same setup in a non-sky router and everything worked well, including internet access. I have tried to connect to the LAN from my laptop and mobile and both do not have internet access. I have also checked and the router is not assigning an IP to my laptop or mobile when they are connect to the rpi 😕.
Is there anything that I might check on the router configuration to enable internet access? Thank you in advance.

Reply

All Replies

This message was authored by mae-3 This message was authored by: mae-3

Re: Wireguard setup on raspberry pi is working but no internet access

@averter 

 

Can you please post the routing table on the Rpi showing a route from the Wireguard VPN subnet to the subnet gateway that the internet resides on at 192.168.0.1? And appropriate DNS entries for the RPi subnets?

-------

Zen internet on FTTP (900Mbps down, 100Mbps up). SAT> IP (Apple 4K 2nd gen TV to LG C1 OLED UHD TV/Dolby Atmos Denon AVR, DacMagic Plus for Hi-Res audio), hosting own blog/forum (cluster), OPNsense & Zenarmor L4/L7 NGFW & DPI IDS/IPS, Asus ET12 Pro Tri-Band wifi, Linux, Gamer: Xbox Series X/i7 laptop, round-robin DNS over HTTPS, non-proprietary VoIP HD AMR-WB (G.722.2) and more... Beta tester Apple iOS/watchOS/tvOS/iPadOS/macOS.
averter
Topic Author
This message was authored by averter This message was authored by: averter

Re: Wireguard setup on raspberry pi is working but no internet access

Thanks for your quick reply @mae-3. I am not an expert on networking, and so can you please let me know what commands I should run on the terminal to get the info you need? Besides the rpi, I also have linux on my laptop/can also run `route -n'/other commands from there. Thank you in advance.

 

P.S: I have changed the rooter default LAN TCP/IP Setup to 192.168.1.0/24 instead of 192.168.0.0/24

This message was authored by mae-3 This message was authored by: mae-3

Re: Wireguard setup on raspberry pi is working but no internet access

@averter 

 

When logged into the Wireguard VPN and on the terminal prompt type  'netstat -rn' without the single quotes and post the resulting text, please.

-------

Zen internet on FTTP (900Mbps down, 100Mbps up). SAT> IP (Apple 4K 2nd gen TV to LG C1 OLED UHD TV/Dolby Atmos Denon AVR, DacMagic Plus for Hi-Res audio), hosting own blog/forum (cluster), OPNsense & Zenarmor L4/L7 NGFW & DPI IDS/IPS, Asus ET12 Pro Tri-Band wifi, Linux, Gamer: Xbox Series X/i7 laptop, round-robin DNS over HTTPS, non-proprietary VoIP HD AMR-WB (G.722.2) and more... Beta tester Apple iOS/watchOS/tvOS/iPadOS/macOS.
This message was authored by mae-3 This message was authored by: mae-3

Re: Wireguard setup on raspberry pi is working but no internet access

@averter 

 

There will be one of two reasons one doesn't have internet access through the VPN.

 

1. One hasn't configured DNS through the VPN tunnel for the client endpoint.

2. There isn't a route from the VPN tunnel to the internet subnet at 192.168.1.0/24 on the Wireguard server.

 

There is an excellent tutorial at this URL for Wireguard for Ubuntu at:- https://www.digitalocean.com/community/tutorials/how-to-set-up-wireguard-on-ubuntu-20-04 

-------

Zen internet on FTTP (900Mbps down, 100Mbps up). SAT> IP (Apple 4K 2nd gen TV to LG C1 OLED UHD TV/Dolby Atmos Denon AVR, DacMagic Plus for Hi-Res audio), hosting own blog/forum (cluster), OPNsense & Zenarmor L4/L7 NGFW & DPI IDS/IPS, Asus ET12 Pro Tri-Band wifi, Linux, Gamer: Xbox Series X/i7 laptop, round-robin DNS over HTTPS, non-proprietary VoIP HD AMR-WB (G.722.2) and more... Beta tester Apple iOS/watchOS/tvOS/iPadOS/macOS.
averter
Topic Author
This message was authored by averter This message was authored by: averter

Re: Wireguard setup on raspberry pi is working but no internet access

Here is the output from `netstat -rn'~

 

Kernel IP routing table
Destination     Gateway         Genmask         Flags   MSS Window  irtt Iface
0.0.0.0         192.168.43.245  0.0.0.0         UG        0 0          0 wlp0s20f3
10.6.0.0        0.0.0.0         255.255.255.0   U         0 0          0 centaurusA
169.254.0.0     0.0.0.0         255.255.0.0     U         0 0          0 wlp0s20f3
192.168.43.0    0.0.0.0         255.255.255.0   U         0 0          0 wlp0s20f3

 

where wlp0s20f3 is the device name associated with the wireless card of my laptop and centaurusA is the rpi hostname

averter
Topic Author
This message was authored by averter This message was authored by: averter

Re: Wireguard setup on raspberry pi is working but no internet access

Thanks @mae-3 . I've looked up the guide you linked and by comparing it with my setup I clearly have configured my wireguard server for IPv4 only. I also don't have the ufw command available.

Based on the above info, I've tried a few things:

  • Disabled IPv6 in Sky router. Although it seems to have worked (the "Attached devices" tab shows only IPv4 addresses) the ethernet interface of the rpi is still being assigned an IPv4 and IPv6 address (for some reason).
  • Changed the public interface of the rpi from a strange string (eba38261566 something) back into eth0. I vaguely remember that it was eth0 when I was using a non-sky router, and so that might have mixed up things in wireguard's server configuration?

Still, none of the above has solved it ☹️. I will keep trying other stuff.

averter
Topic Author
This message was authored by averter This message was authored by: averter

Re: Wireguard setup on raspberry pi is working but no internet access

@mae-3  Can you please check the output from netstat? I still haven't managed to solve this issue 😞

This message was authored by mae-3 This message was authored by: mae-3

Re: Wireguard setup on raspberry pi is working but no internet access

@averter 

 

The VPN tunnel goes via the 10.0.6.0 subnet from the netstat stats but all traffic will exit via 192.168.43.245 in the first instance,

-------

Zen internet on FTTP (900Mbps down, 100Mbps up). SAT> IP (Apple 4K 2nd gen TV to LG C1 OLED UHD TV/Dolby Atmos Denon AVR, DacMagic Plus for Hi-Res audio), hosting own blog/forum (cluster), OPNsense & Zenarmor L4/L7 NGFW & DPI IDS/IPS, Asus ET12 Pro Tri-Band wifi, Linux, Gamer: Xbox Series X/i7 laptop, round-robin DNS over HTTPS, non-proprietary VoIP HD AMR-WB (G.722.2) and more... Beta tester Apple iOS/watchOS/tvOS/iPadOS/macOS.
Reply

Was this discussion not helpful?

No problem. Browse or search to find help, or start a new discussion on Community.

Start a new discussion

On average, new discussions are replied to by our users within 4 hours

New Discussion