![insmod:错误:无法插入模块./hello.ko:操作不允许](https://linux22.com/image/923107/insmod%EF%BC%9A%E9%94%99%E8%AF%AF%EF%BC%9A%E6%97%A0%E6%B3%95%E6%8F%92%E5%85%A5%E6%A8%A1%E5%9D%97.%2Fhello.ko%EF%BC%9A%E6%93%8D%E4%BD%9C%E4%B8%8D%E5%85%81%E8%AE%B8.png)
在编写 hello world 内核模块时,insmod 命令显示此错误。我尝试了所有方法,但都不起作用。
~$ cd Desktop
~/Desktop$ cd hellomodule
~/Desktop/hellomodule$ make
make -C /lib/modules/5.3.0-45-generic/build M=/home/shivang_official/Desktop/hellomodule modules
make[1]: Entering directory '/usr/src/linux-headers-5.3.0-45-generic'
Building modules, stage 2.
MODPOST 1 modules
make[1]: Leaving directory '/usr/src/linux-headers-5.3.0-45-generic'
~/Desktop/hellomodule$ su
Password:
/Desktop/hellomodule# insmod ./hello.ko
insmod: ERROR: could not insert module ./hello.ko: Operation not permitted