Bug 995086 - cleaning up /lib/modules/<kernel>
cleaning up /lib/modules/<kernel>
Product: Fedora
Classification: Fedora
Component: kernel (Show other bugs)
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Kernel Maintainer List
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2013-08-08 10:02 EDT by Henrique Martins
Modified: 2013-09-05 13:57 EDT (History)
6 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2013-09-05 13:57:30 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Henrique Martins 2013-08-08 10:02:12 EDT
Description of problem:
Not sure whether this is a bug or "just the way it is", but today I found that I have several /lib/modules/<kernel> directories, with no modules left in there, i.e just an empty extra subdirectory, and things like modules.alias, modules.dep, modules.symbols, and their corresponding .bin files.

This only on systems where I either have VirtualBox or the Nvidia modules nstalled.  Who is supposed to clean them up, when I yum remove the kernel and kernel-devel packages?

Version-Release number of selected component (if applicable):
All going back to where I started using those modules.  On one of my systems all the way back to 3.5.0-2.fc17.x86_64, and including around 40 kernels my system had from then on.

How reproducible:
Always, I guess

Steps to Reproduce:
1. Install VirtualBox and/or the Nvidia driver
2. Maybe install kmod/akmod packages for the above
3. Upgrade your system to a new kernel, yum erase the old one

Actual results:
/lib/modules/<old_kernel> not erased, but not much useful left there

Expected results:
Removal of /lib/modules/<old_kernel>

Additional info:
Comment 1 javiertury 2013-09-05 12:18:38 EDT
In my computer there are over 27 kernel modules directories with a size of 382M.

I also have akmod-VirtualBox, kmod-VirtualBox and bumblebee-nvidia(nvidia related). Additionally in my case I found that inside many of the /lib/modules/kernelversion/extra directories there was still the bbswitch.ko file(related to bumblebee and bumblebee-nvidia through the bbswitch package).
Comment 2 Josh Boyer 2013-09-05 13:57:30 EDT
There's nothing rpm/yum can do to clean up the directories when it removes the kernels if other packages are placing modules there.  Wherever you got these third party modules from should fix their packages to clean up properly.

Fedora doesn't provide or support third party module packages.

Note You need to log in before you can comment on or make changes to this bug.