How to Fix ‘Failed to Load Kernel Modules’ in Ubuntu

Encountering the systemd notification “Failed to start Load Kernel Modules” (or systemd-modules-load.service failure) during Ubuntu boot indicates that the operating system was unable to insert one or more required hardware driver modules into the active Linux kernel. While the system may continue booting into a functional desktop, missing kernel modules can leave audio hardware, Wi-Fi adapters, virtualization hypervisors, or proprietary graphics cards non-functional. Resolving this issue involves querying systemd diagnostics to identify the specific failing module and removing obsolete module references.

Identify Which Kernel Module Failed to Load

The systemd-modules-load service manages kernel module insertion at boot time. Querying its status reveals the exact module name triggering the error exit code.

  1. Open a terminal window (press Ctrl + Alt + T).
  2. Check the status of the systemd unit:
    systemctl status systemd-modules-load.service
  3. Review the output lines marked in red or tagged with error codes.
  4. To inspect detailed diagnostic journal entries for this service, run:
    sudo journalctl _PID=$(systemctl show --property MainPID --value systemd-modules-load.service)
  5. Alternatively, search recent boot logs for module loading failures:
    sudo journalctl -b -u systemd-modules-load.service
  6. Note the module name reported in the logs (e.g. vboxdrv, kvm, loop, or custom hardware drivers).

Inspect and Clean Module Configuration Files

Systemd reads module names to load automatically from multiple directory locations. Outdated or uninstalled software often leaves orphaned module declarations behind.

  1. Inspect the primary module configuration file:
    cat /etc/modules
  2. Inspect all supplementary module drop-in files:
    ls -la /etc/modules-load.d/
    cat /etc/modules-load.d/*.conf
  3. Inspect package-managed module directories:
    ls -la /usr/lib/modules-load.d/
  4. If you find a configuration file requesting a module from an application you have already uninstalled (such as VirtualBox or VMware), open the file in nano and delete the problematic line:
    sudo nano /etc/modules-load.d/problematic-module.conf
  5. Save the file and test module loading immediately:
    sudo systemctl restart systemd-modules-load.service

Test Manual Module Insertion with modprobe

Testing manual insertion using modprobe reveals whether the module is missing entirely, corrupted, or rejected due to Secure Boot signature constraints.

  1. Attempt to insert the failing module manually:
    sudo modprobe -v <module-name>
  2. If the terminal outputs FATAL: Module <module-name> not found, the module was compiled for an older kernel version and must be rebuilt.
  3. If the terminal outputs Operation not permitted or Key was rejected by service, UEFI Secure Boot is active and rejecting unsigned third-party kernel modules.

Rebuild Missing Modules Using DKMS

Third-party drivers (such as NVIDIA graphics or VirtualBox host modules) rely on Dynamic Kernel Module Support (DKMS) to compile module binaries against new Linux kernels.

  1. Inspect the current status of all DKMS modules:
    dkms status
  2. If any module displays a broken or installed mismatch, reinstall the DKMS package:
    sudo apt install --reinstall dkms
  3. Rebuild all modules for your currently running kernel version:
    sudo dkms autoinstall -k $(uname -r)
  4. Update your initramfs boot images to incorporate the freshly compiled modules:
    sudo update-initramfs -u -k all

Reinstall Linux Kernel Generic Headers and Modules

If core distribution modules (such as storage or network modules) are failing, essential kernel packages may have been corrupted during an interrupted package update.

  1. Reinstall the official kernel headers and extra module packages:
    sudo apt update && sudo apt install --reinstall linux-image-generic linux-headers-generic linux-modules-extra-$(uname -r)
  2. Reboot your system:
    sudo reboot
  3. Verify that systemd-modules-load.service now reports active (exited) with zero errors:
    systemctl status systemd-modules-load.service

Get the best tech tips delivered straight to your inbox.

Join thousands of readers mastering Apple, Google, Microsoft, and Linux.