简体   繁体   中英

Wireguard refuses to run on Fedora 31: protocol not supported

I recently install wireguard-tools and restarted my machine several times. However, it will simply not run. I get this error every time:

Warning: `/etc/wireguard/myprovider.conf' is world accessible
[#] ip link add myprovider type wireguard
Error: Unknown device type.
Unable to access interface: Protocol not supported
[#] ip link delete dev myprovider
Cannot find device "provider"

I then ran dkms status and it came up entirely blank, even after a restart. Looking online, it doesn't seem like anyone else's dkms went blank. My kernel version is 5.5.13-200.fc31.x86_64, which is the latest I can go to. I've tried the general advice of cleaning packages, updating and then reinstalling wireguard but it has not worked. What should I do from here? Does this require a reinstall of the whole OS?

What does modinfo wireguard show?

Wireguard is included Linux 5.6 and higher. On your 5.5 kernel you'll need to install the a kernel module.

I'm a Debian user, but on fedora this should work:

$ sudo dnf copr enable jdoss/wireguard
$ sudo dnf install wireguard-dkms wireguard-tools

wireguard-tools only install's the tools, wireguard-dkms the kernel module, this will do the actual work.

reference

I solved it by upgrading wireguard:

sudo apt-get upgrade wireguard

Here is the terminal results:

(...)
Preparing to unpack .../92-wireguard-dkms_1.0.20200520-0ppa1~18.04_all.deb ...

-------- Uninstall Beginning --------
Module:  wireguard
Version: 1.0.20200401
Kernel:  5.3.0-46-generic (x86_64)
-------------------------------------

Status: Before uninstall, this module version was ACTIVE on this kernel.

wireguard.ko:
 - Uninstallation
   - Deleting from: /lib/modules/5.3.0-46-generic/updates/dkms/
 - Original module
   - No original module was found for this module on this kernel.
   - Use the dkms install command to reinstall any previous module version.

depmod...

DKMS: uninstall completed.

-------- Uninstall Beginning --------
Module:  wireguard
Version: 1.0.20200401
Kernel:  5.3.0-51-generic (x86_64)
-------------------------------------

Status: Before uninstall, this module version was ACTIVE on this kernel.

wireguard.ko:
 - Uninstallation
   - Deleting from: /lib/modules/5.3.0-51-generic/updates/dkms/
 - Original module
   - No original module was found for this module on this kernel.
   - Use the dkms install command to reinstall any previous module version.

depmod...

DKMS: uninstall completed.

------------------------------
Deleting module version: 1.0.20200401
completely from the DKMS tree.
------------------------------
Done.
(...)

Then sudo wg-quick up {conf_name} worked again.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM