linuxmint / linuxmint/mintupdate

dkms with non-available modules forces updated to stop - and does not provide instructions

Open
#888 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

BUG
Dominant language
Python
Stars
425
Forks
190
PR merge metrics
No merged PRs in 30d

Description

Describe the bug
I updated several of my 21.3 installations to linuxmint 22 - and had a hard time on two computers due to
dkms kernel modules that are not available for the new kernel on linuxmint 22.

Normally, dkms -modules are compiled, when installing a new kernel.
There are several reasons, why the necessary packages might not be available for the new kernel:

  • kernel module is not available / outdated and does not work with the new kernel
  • functionality of dkms-modules are integrated in the new kernel (so no dkms-module required anymore).
    • change in the software stack e.g. pulseaudo -> pipwire transition

In my case, the problems had been caused by the following modules, but the issue applies more generally:
bt-usb/4.1
nvidia-dkms-390

Currently, mintupdate tries to compile the dkms-modules (several times) for the new kernel and then stops with a cryptic error message: "kernel could not be installed due to Error"

At this point, currently the only option in mintupdate is to abort the installation - this however leaves the user with a mix of updated and old packages - and without instruction about the source of the problem and how to proceed.

Expected behavior
mintupdate should point to a solution to the problem.

  • If possible: Print a clear statement that the new kernel could not be installed, since a dkms-module (which one) can not be build for the new kernel.
  • Print a list with the dkms-modules currently used by the old kernel
    • $dkms status #show kdms modules of the current kernel
  • Provide hints on how to proceed/ solve the issue:
    1. Ask the user to check if the dkms-modules are still required
    2. If modules are still required by the user: Provide a hint on how to completely restore the old system (using timeshift)
    3. If modules are not required anymore: Provide a hint on how to remove the kernel modules
      4. $sudo dkms remove modulename/versionnumber #remove module from kernel
      5. $sudo apt remove packagename #remove package/source
      6. mintupdate has to be started again, to install the new kernel and to complete the update.
      7. after a successful update - install new dkms drivers/ modules, if necessary/ available

Distribution:

  • Linux Mint CE: 21.3 -> 22

Software version:
mintupdate 6.0.9

Logs:
Copy & paste the log output from Update Manager > View > Information here.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in the Update Manager flow that installs a new kernel and reproduce the failure with an unavailable DKMS module such as bt-usb or nvidia-dkms-390. Use dkms status to identify the affected module; done means the failure names it clearly and provides actionable recovery or removal guidance before the user retries the update.

Written by the indexing model from the issue text.

Assessment

Tech stack
linux, python
Domain
operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.