Can't install openvpn-openssl kmod-tun kernel packages

It seems like it's no longer possible to install the openvpn-openssl package on either opkg (24.x) or the new apk installer (25.x). As a result it's impossible to get OpenVPN working. I'm sure there's a way to hack around this but it seems like a file just needs to be restored in the repo.

It fails because openvpn-openssl depends on kmod-tun which depends on kernel (which is a confusing name for a package). An error message in the Luci software (package) GUI says that kernel isn't available in any repo.

If you just use "opkg install" over ssh then it seems to succeed but you never get the expected VPN menu in Luci.

With 25.x, you get error 8 from wget during "apk update" and everything goes downhill from there.

Maybe the kernel package was just deleted by mistake?

kmod <> kernel version mismatch should only exist in snapshots and unofficial builds.

As for the packages, it's an ongoing issue - 25.12.0 RC4 apk update - how to preserve the repo package list - #2 by efahl.

If you want help, post actual errors instead of complaining about it "not working".

Post your ubus call system boardtoo.

kernel is faux empty package representing the actual kernel version installed.

That's interesting. Can I just hack it somehow to reflect the actual kernel version? (Sorry I don't even know where to find it.)

I assume that opkg is trying to fetch it because it sees that the version number is mismatched so it assumes that it needs to sync it up.

Perhaps what happened is that this fake kernel package wasn't updated when I bounced through various firmware versions. I guess it doesn't matter why if apk is eventually going to replace opkg.

All firmware images were straight from OpenWrt. No custom anything.

If this hack isn't going to fly then I can dig up the exact data requested by @frollic Not an unreasonable request, just trying for simplicity first.

Did you install the luci package? If not, then that's why there's no luci menus. Do opkg list '*openvpn*' and you'll see the 30-odd packages related, and I suspect you want luci-app-openvpn and maybe a language pack.

Yes - upgrade the system like using owut to have repos and kernel in sync.

1 Like

Originally, I had installed the unmodified 24.10.5 factory image for my router. I flashed it directly over the OEM firmware. OpenWrt then booted up just fine but for the kernel package failure above.

I'm sure that my attempt to install the 3 required OpenVPN packages via opkg under ssh was successful. The opkg update and install phases succeeded with no errors, as stated above. But there was no VPN menu in Luci.

I then tried a number of other unmodified OpnWrt images for the same router, including package reinstallation both via ssh and Luci. The kernel package error persisted. No VPN menu ever appeared.

Then, after considering your feedback, I pushed the button in Luci to reset all the settings to their defaults. I then restored 24.10.5 via a sysupgrade without any of the boxes checked (so no settings backed up or preserved) also in Luci.

After flashing, I went back to ssh and did the exact same thing as before:

opkg update
opkg install openvpn-openssl
opkg install luci-app-openvpn
opkg install ip-full

Once again, there were no errors. I exited ssh and power-cycled the router.

When it came back up, I logged in to find that the VPN menu had appeared this time. I've since gotten the VPN to work as expected.

I have no idea what went wrong the first several times. Anyone else with this problem might try resetting factory defaults, flashing again with no boxes checked for settings preservation, and power-cycling after installing the 3 packages.

What's weirder is that I've installed OpenWrt on the same model of router for several clients without ever having encountered the kernel package issue (but prior to 24.10.5). I'll never know what happened but thanks for your feedback @frollic @anon63541380 @efahl which might help others as well.

1 Like

You have to mention the router model (ubus call system board) - some are dual-partition and accidentally take kernel from one partition and rootfs/squashfs from another and you get "incompatible modules"