mwyborski / Linux-Magic-Trackpad-2-Driver

499 stars 84 forks source link

Cannot load (unsigned) DKMS module with secure boot enabled #43

Closed mthaak closed 5 years ago

mthaak commented 5 years ago

Putting this out there for people experiencing the same problem because it took me a while to install this driver properly.

My setup is a Lenovo Thinkpad 5th gen. notebook with Ubuntu 18.04.2 LTS running kernel 4.18.0-25-generic.

After installing the driver using scripts/install.sh I didn't enroll the new key using MOK (for some reason the password I set wasn't accepted). Which I think lead to module not being loaded on startup due to secure boot, this was evident when rmmod said the module was not loaded. When I tried insmod then I got the error "insmod: ERROR: could not insert module ./hid-magicmouse.ko: Operation not permitted".

So what I did is disable secure boot altogether by following this website: https://wiki.ubuntu.com/UEFI/SecureBoot/DKMS. Then after boot the driver worked perfectly.

Also on Ubuntu 18.04 you can install mtrack using sudo apt install xserver-xorg-input-mtrack, which will uninstall all the xserver-xorg-input-*-hwe-18.04 packages due to a conflict. So you should not forget to directly install xserver-xorg-input-all afterwards to replace the removed input packages. Because if you don't, you cannot use your keyboard and mouse after reboot