Wireguard client kernel module fails loading with modprobe after dietpi upgrade on odroid xu4

Wireguard client kernel module fails loading with modprobe after dietpi upgrade on odroid xu4

Required Information

  • DietPi version | v8.21.1
  • Distro version | bullseye
  • Kernel version | Linux DietPi 5.4.253-current-odroidxu4 #2 SMP PREEMPT Mon Aug 14 01:33:04 UTC 2023 armv7l GNU/Linux
  • Architecture | armhf
  • SBC model | Odroid XU3/XU4/MC1/HC1/HC2 (armv7l)

Additional Information (if applicable)

  • Software title | wireguard client
  • Was the software title installed freshly or updated/migrated? dietpi upgraded to 8.21.1

Steps to reproduce

I have recently upgraded to dietpi 8.21.1 on odroid xu4 and my wireguard client stopped working

root@DietPi:~# modprobe wireguard
modprobe: FATAL: Module wireguard not found in directory /lib/modules/5.4.253-current-odroidxu4

I tried rebooting, purging wireguard, reinstalling, rebooting again but it didn’t work

root@DietPi:~# apt purge wireguard wireguard-tools
root@DietPi:~# apt install wireguard wireguard-tools
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following additional packages will be installed:
  linux-image-5.10.0-25-rt-armmp linux-image-rt-armmp
Suggested packages:
  linux-doc-5.10 debian-kernel-handbook
Recommended packages:
  firmware-linux-free apparmor
The following NEW packages will be installed:
  linux-image-5.10.0-25-rt-armmp linux-image-rt-armmp wireguard wireguard-tools
0 upgraded, 4 newly installed, 0 to remove and 0 not upgraded.
Need to get 37.4 MB of archives.
After this operation, 176 MB of additional disk space will be used.

Note that the wireguard package requires 5.10.0-25 whereas the latest is 5.4.253

I also tried compiling wireguard from source

root@DietPi:~# git clone https://git.zx2c4.com/wireguard-linux-compat
root@DietPi:~# git clone https://git.zx2c4.com/wireguard-tools
root@DietPi:~# make -C wireguard-linux-compat/src -j$(nproc)
make: Entering directory '/root/wireguard-linux-compat/src'
make[1]: Entering directory '/root/wireguard-linux-compat/src'
make[1]: *** /lib/modules/5.4.253-current-odroidxu4/build: No such file or directory.  Stop.
make[1]: Leaving directory '/root/wireguard-linux-compat/src'
make: *** [Makefile:26: module] Error 2
make: Leaving directory '/root/wireguard-linux-compat/src'

I managed to compile wireguard from source after installing linux headers

root@DietPi:~# apt-get install linux-headers-current-odroidxu4

And then following instructions from

Problem solved

1 Like