0

when I try to install qemu-kvm I get an error message that my own driver can not be added again to the DMKS tree.

$ sudo apt -y install qemu-kvm
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Note, selecting 'qemu-system-x86' instead of 'qemu-kvm'
qemu-system-x86 is already the newest version (1:8.2.2+ds-0ubuntu1.7).
The following packages were automatically installed and are no longer required:
  linux-headers-6.8.0-59 linux-headers-6.8.0-59-generic linux-image-6.8.0-59-generic linux-modules-6.8.0-59-generic
  linux-modules-extra-6.8.0-59-generic linux-tools-6.8.0-59 linux-tools-6.8.0-59-generic
Use 'sudo apt autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 98 not upgraded.
1 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Setting up mydriver-kmd (1.1.0) ...
Error! DKMS tree already contains: mydriver-1.1.0
You cannot add the same module/version combo more than once.
dpkg: error processing package mydriver-kmd (--configure):
 installed mydriver-kmd package post-installation script subprocess returned error exit status 3
Errors were encountered while processing:
 mydriver-kmd

The issue is that I am not trying to add a new kernel headers package or anything of that sort. It also says that qemu-system-x86 is already installed. But I am not sure what it was trying to add the mydrvier-kmd to the source tree again.

So, why dpkg thinks it needs to add my driver again to the dkms tree even though it was trying to remove Linux header packages? should not it try to remove my driver instead of try to add it?

What do I need to fix? How can I tell dpkg that it should not add my driver when removing Linux headers?

2
  • What are the contents of /usr/src/mydriver/dkms.conf? I know that this is the file that tells dkms how to install and what version the driver is. Commented Jun 24 at 2:44
  • looks like there is an entry in /var/lib/dpkg/status for myderiver. If I remove that, dkms no longer tries to add it to the dkms tree. Commented Jun 24 at 3:40

0

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.