Gentoo Archives: gentoo-user

From: Nikos Chantziaras <realnc@×××××.com>
To: gentoo-user@l.g.o
Subject: [gentoo-user] Re: Since when does module-rebuild delete modules for previous kernel version?
Date: Sat, 10 Jul 2021 08:22:51
Message-Id: scblcf$jo5$1@ciao.gmane.io
In Reply to: [gentoo-user] Since when does module-rebuild delete modules for previous kernel version? by Nikos Chantziaras
1 On 08/07/2021 02:09, Nikos Chantziaras wrote:
2 > So I just noticed that when I run:
3 >
4 > emerge @module-rebuild
5 >
6 > after having installed a kernel update, the kernel modules of the
7 > previous kernel version are being deleted. I am sure this didn't use to
8 > be the case.
9 Found the issue. On my new system, I had this in my make.conf:
10
11 UNINSTALL_IGNORE="/usr/src"
12
13 because /usr/src is a symlink to a directory on my HDD (as I don't want
14 to write all that data to my SSD.) Portage would bark about it during
15 depclean if I don't put that in UNINSTALL_IGNORE.
16
17 From "man make.conf":
18
19 UNINSTALL_IGNORE = [space delimited list of fnmatch patterns]
20
21 This variable prevents uninstallation of files that match
22 specific fnmatch(3) patterns. [...] Defaults to
23 "/lib/modules/*".
24
25 Right. However, it's obvious I've hit a portage inconsistency here. For
26 example, when I use:
27
28 CONFIG_PROTECT="blah"
29
30 in make.conf, "blah" is appended to CONFIG_PROTECT. But for whatever
31 reason, this is not the case for UNINSTALL_IGNORE. It completely nukes
32 the default value instead. I had to change this to:
33
34 UNINSTALL_IGNORE="${UNINSTALL_IGNORE} /usr/src"
35
36 and now all is fine.

Replies