Site icon New Generation Enterprise Linux

Stop the kernel from loading modules you actually wanted to disable

Kernel News & Module Management

Stop the kernel from loading modules you actually wanted to disable

Technical Briefing | 11/22/2026

We have all been there. You blacklist a kernel module because it keeps causing a conflict or your hardware doesn’t even need it. You update modprobe.d, reboot, and there it is again, sitting in lsmod like it owns the place. It turns out the blacklist command is not a global ban hammer; it just tells modprobe not to load the module automatically when a device is detected. If something else calls that module directly, or if it is baked into the initramfs, your blacklist file is essentially just a polite suggestion that the kernel is going to ignore.

Why the initramfs is the real culprit

The initramfs is a compressed archive that gets loaded into memory before your root partition is even mounted. If your module is pulled in during the initramfs generation phase, it will be loaded long before your blacklist configs on the root filesystem are even visible to the kernel. Most distros try to be helpful and include all modules that might be necessary for your hardware, but this often leads to bloated images and unwanted drivers getting active early. You have to strip the module out of the image entirely to stop it from loading.

echo 'omit_dracutmodules+=" name_of_module "' > /etc/dracut.conf.d/block-module.conf
dracut -f
  • Check /etc/modprobe.d/ for existing blacklist entries that might be conflicting
  • Verify your initramfs builder configuration, whether it is dracut or mkinitcpio
  • Rebuild your initramfs image explicitly after changing module configurations
  • Use lsinitrd or lsinitcpio to verify the module is actually gone from the image

Once you have verified the module is no longer in the initramfs, you can safely assume it won’t load on boot. If you still see it appearing later, look for udev rules or systemd services that might be triggering it based on hardware events. Don’t waste your afternoon fighting with modprobe configs when the solution has been sitting in your boot directory this whole time.

Linux Admin Automation  |  © www.ngelinux.com  |  11/22/2026
0 0 votes
Article Rating
Exit mobile version