Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 171658

Summary: module-init-tools: minor bug in modules-update
Product: Gentoo Linux Reporter: Jimmy.Jazz
Component: [OLD] Core systemAssignee: Gentoo Linux bug wranglers <bug-wranglers>
Status: RESOLVED DUPLICATE    
Severity: normal    
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description Jimmy.Jazz 2007-03-21 10:24:39 UTC
Hello,

modules-update returns sometimes an error when called from /sbin/rc. Your system won't obligatory have one of the ".../System.map*" files available at this time while the loop "for" will always return /System.map.
The variable cfg will be set and you get a error message during the boot process from depmod, like "FATAL: /System.map not found" or something like that.

As a solution, i suggest you:

--- /root/modules-update        2007-03-20 23:14:21.000000000 +0100
+++ /sbin/modules-update        2007-03-20 23:14:54.000000000 +0100
@@ -402,9 +402,9 @@
                for cfg in /lib/modules/${KV}/build /usr/src/linux-${KV} \
                           /boot /usr/src/linux ""
                do
-                       cfg="${cfg}/System.map"
+                       scfg="${cfg}/System.map"
                        for suffix in -genkernel-{${arch},'*'}-${KV} -${KV} "" ; do
-                               scfg=$(echo ${cfg}${suffix})
+                               scfg=$(echo ${scfg}${suffix})
                                scfg=${scfg%% *}
                                [[ -f ${scfg} ]] && cfg=${scfg} && break 2
                        done

Also, if System.map* isn't found, depmod won't be called with the -F option.

Jj

Reproducible: Always
Comment 1 Jakub Moc (RETIRED) gentoo-dev 2007-03-21 10:38:31 UTC
Please search.


*** This bug has been marked as a duplicate of bug 165134 ***