Arch Linux

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#62546 - [mkinitcpio] Does not follow symlinks when locating modules

Attached to Project: Arch Linux
Opened by Jendrik (JeWe37) - Saturday, 04 May 2019, 21:41 GMT
Last edited by Dave Reisner (falconindy) - Sunday, 05 May 2019, 00:51 GMT
Task Type Bug Report
Category Packages: Core
Status Closed
Assigned To No-one
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:
When attempting to add a kernel module to an initramfs using the module_add function eg. in a hook, if this module is behind a symlink in /usr/lib/modules/[KERNEL VERSION] it will not be found. In order to fix this one can simply add the -L option to the find command in the function all_modules, which, once mkinitcpio is installed, is located in /usr/lib/initcpio/functions.

Additional info:
mkinitcpio-25-1-any

Steps to reproduce:
1. Install the proprietary NVIDIA drivers
2. Add "nvidia" to the MODULES list in /etc/mkinitcpio.conf
3. Attempt to run mkinitcpio
This task depends upon

Closed by  Dave Reisner (falconindy)
Sunday, 05 May 2019, 00:51 GMT
Reason for closing:  Works for me
Comment by Dave Reisner (falconindy) - Saturday, 04 May 2019, 23:20 GMT
How are you installing the nvidia driver such that you end up with a symlink? *Why* do you need this symlink?
Comment by Jendrik (JeWe37) - Saturday, 04 May 2019, 23:26 GMT
The usual installation drops the modules into /usr/lib/modules/extramodules-ARCH. Inside /usr/lib/modules/[KERNEL VERSION] there is then a symlink called "extramodules" to that other folder containing the nvidia kernel modules. It seems the nvidia proprietary drivers are not the only package to do this however, it seems broadcom-wl also adds its kernel module in the same manner. I do not know if it is the standard method or not, but it might well be.
Comment by Dave Reisner (falconindy) - Saturday, 04 May 2019, 23:42 GMT
So you're installing extra/nvidia? In that case, mkinitcpio finds the module just fine for me.

Btw, 'all_modules' isn't involved when installing modules from /etc/mkinitcpio.conf -- those are resolved individually through the depmod indicies.
Comment by Jendrik (JeWe37) - Saturday, 04 May 2019, 23:54 GMT
Hmmm... In that case I might have been tweaking too many variables at once leading me to misunderstanding this... However assuming the discrepancy between what can be added using module_add and what all_modules returns is not intended, changing this might make sense.
Comment by Dave Reisner (falconindy) - Sunday, 05 May 2019, 00:09 GMT
I disagree. Until you can determine why nvidia is being excluded, the discrepancy between the two is irrelevant. I could foresee duplicates if all_modules suddenly starts following symlinks.
Comment by Jendrik (JeWe37) - Sunday, 05 May 2019, 00:17 GMT
Well, in that case it likely is best left as is. It is working for me by now anyway after I added the -L, but given that I was tweaking quite a few other things at the same time to avoid having to build the image more often than absolutely necessary, I figure it was likely one of those things that finally made it all work.

Loading...