Programmatically insert and remove kernel modules in C


Programmatically insert and remove kernel modules in C



Is there anyway to do "insmod" and "rmmod" from C/C++ code? Other than running system(...), is there a Kernel API that will allow me to do this?


How to set C++ environment variable in Linux ubuntu?

1:

How do I use python to hit this command and return the result?How to use a defined struct from another source file?problem with fork()

2:

Help with this compile error
In addition to viewing the source for insmod and module-init-tools you could strace and ltrace a run of insmod.. How do I benefit from argc and argv in C++, the standard way? [closed]
get an ioctl file descriptor for ethernet port

78 out of 100 based on 43 user ratings 638 reviews