Programmatically insert and remove kernel modules in C
Is there anyway to do "insmod" and "rmmod" from C/C++ c开发者_高级运维ode? Other than running system(...), is there a Kernel API that will allow me to do this?
Have you looked at the module-init-tools source?
In addition to viewing the source for insmod and module-init-tools you could strace and ltrace a run of insmod.
 
         加载中,请稍侯......
 加载中,请稍侯......
      
精彩评论