Skip to content
Advertisement

modprobe: ERROR: could not insert ‘tun’: Unknown symbol in module, or unknown parameter (see dmesg)

My server runs openvpn client, it was working fine. But after a server reboot, I couldn’t startup the openvpn client.

openvpn log says:

ERROR: Cannot open TUN/TAP dev /dev/net/tun: No such device (errno=19)

but

lyq@server:~$ ls /dev/net/tun -l
crw-rw-rw- 1 root root 10, 200 Feb 27 13:44 /dev/net/tun

After some searching, I found this command:

lyq@server:~$ sudo modprobe tun
modprobe: ERROR: could not insert 'tun': Unknown symbol in module, or unknown parameter (see dmesg)

and the ‘dmesg’ says:

[  991.073261] tun: Unknown symbol __sk_attach_filter (err 0)
[  991.073347] tun: Unknown symbol __sk_detach_filter (err 0)

I need help, thank you very much.

Advertisement

Answer

The “No such device” message means that no device driver with the major and minor numbers of the device node (10 and 100 in your case) exists. The reason for that is most likely that the “tun” driver failed to load, and the reason for that appears to be that the __sk_attach_filter and __sk_detach_filter symbols do not exist in the kernel you’re running.

Since you say this happened after a reboot, it is likely that the kernel image was upgraded some time before that reboot, and this is the first time the system boots with the new kernel. Missing symbol errors tend to be due to the module versions not matching the kernel version.

Did you build the kernel yourself, or did you install it from som package manager? If you installed it by yourself, try again and make sure to run “make modules_install” (see e.g. https://unix.stackexchange.com/questions/20864/what-happens-in-each-step-of-the-linux-kernel-building-process for information about the kernel build targets). If you installed via a package manager, check if there some kernel modules package or tun driver package that needs to be upgraded.

User contributions licensed under: CC BY-SA
5 People found this is helpful
Advertisement