FritzBox: Set up WireGuard VPN in Linux

How to set up WireGuard with the FritzBox under Linux.

My new Linux laptop must of course also have the option of accessing the home network on the move using VPN. So in addition to Tailscale, Wireguard is now to be set up.

Creating a WireGuard connection in Fritz!Box

First we create the connection in the Fritzbox. We can do this under Shares – VPN (WireGuard).

We connect a new single unit, assign a name and confirm the new connection. At the end we are given the option to download the configuration file. We do this, of course.

Setting up in Linux

Now let’s move on to Linux. First we install WireGuard:

sudo apt install wireguard resolvconf

Make a wireguard connection

We can copy the configuration file to the “/etc/wireguard/” folder, but any other location will do. We establish the connection with the following command.

sudo wg-quick up /etc/wireguard/wg0-client-01.conf

Here I had another specific error message:

wg-quick: The config file must be a valid interface name, followed by .conf

The message is a bit misleading. My problem was that the file name, without .conf, was longer than 16 characters. After I changed this, the connection was established.

Check the status of the connection

The following command can be used to check the connection status.

sudo wg show

Disconnect

To disconnect, we use the following command:

wg-quick down /etc/wireguard/wg0-client-01.conf

Graphical user interface

If you don’t want to fiddle around on the command line, you can check out the “Wireguird” software. The .deb file is available here for download.

Here we can import the configuration file and then connect at the click of a button. In principle, just like under Windows.

Conclusion

Easier than expected! Works!

SaleBestseller No. 1
FRITZ!Box 7530 AX | DSL-Router | Wi-Fi 6 bis zu 2,4 GBit/s | Dualband WLAN...
  • Leistungsstarker DSL-Router mit Wi-Fi 6 bis zu 2.400 MBit/s und DSL-Geschwindigkeiten bis 300 MBit/s...
  • WLAN Mesh - Mehrere WLAN-Zugangspunkte werden zu einem WLAN-Netz zusammengefasst, erweiterbar mit...
  • Höchste Sicherheitsstandards - modernes WLAN mit WPA3-Verschlüsselung und regelmäßigen...
SaleBestseller No. 2
AVM FRITZ!Box 7530 WLAN AC+N Router (DSL/VDSL 866 MBit/s (5GHz...
  • Paketmenge Artikel- 1
  • Produkttyp — NETZWERK-ROUTER
  • Betriebssystem - FRITZ! OS
SaleBestseller No. 3
AVM Fritz!Box 7590 High-End WLAN AC + N Router (VDSL-/ADSL, 4x4 MU-MIMO mit...
  • High-End WLAN AC+N Router nach Multi-User-MIMO mit 1.733 (5 GHz) + 800 MBit/s (2,4 GHz...
  • Telefonanlage für Internet und Festnetz mit Voice-to-Mail und Fax-to-Mail, integrierte...
  • Mediaserver (UPnP AV) verteilt Filme, Fotos und Musik im Heimnetz an geeignete Empfänger, wie...

Leave a Reply

Your email address will not be published. Required fields are marked *