I have recently compiled a kernel, I selected a load of modules to be installed with the kernel/os.

I have installed this kernel/FS on to a usb and it boots fine.

When I use lsmod I see no modules listed.

I go into /lib/modules and see no makefile, I can how ever cat out the module files and they will reference something like: kernel/fs/nls/nls_iso8859-15.ko

I then follow this the path cd linux-4.1.6/fs/nls and I can see the above mentioned file... I try to run the makeFile here and all i get is make: Nothing to be done for `Makefile'.

I try want to get the modules installed with this kernel, but I am lost as to what to do. am I going about everything the wrong way?

  • Modules are a way to unload code that's not currently needed; did you expect the modules to be loaded? You can test manual loading with insmod. – Jeff Schaller Oct 7 '15 at 12:47
  • I honestly didnt know what to expect. very new to this level of linux.... at most I use linux as a web developer. I can configure network protocols and your nginx for you in linux... thats about it – TheHidden Oct 7 '15 at 13:48

lsmod showing no modules is a sign that you compiled drivers statically into the kernel. Make sure you enable loadable modules support when you build your kernel, and you will be able to load files from /lib/modules just fine:

insmod /lib/modules/kernel/fs/nls/nls_iso8859-15.ko

If you need to make an individual kernel module, you need to specify the kernel you're building it for:

 make -C /lib/modules/`uname -r`/build M=$PWD
  • can you expand a bit about static compiling, I am very new to this level of linux. how do i enable this? – TheHidden Oct 7 '15 at 9:27
  • Loadable kernel modules are enabled via one of the first options you see in "Loadable modules support" when running make menuconfig. Whether a particular module is statically compiled into the kernel is configured individually for each module, also in make menuconfig. – Dmitry Grigoryev Oct 7 '15 at 9:32
  • enable loadable module support is ticked and so is the sub option "module unloading" is also ticked.. do I need to tick anything else? Force module loading? – TheHidden Oct 7 '15 at 9:53

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.