Red Hat Bugzilla – Bug 132456
mkinitrd fails to compute dependecies from custom kernel modules.dep
Last modified: 2007-11-30 17:10:49 EST
Description of problem:
mkinitrd fails to compute dependencies from certain modules.dep
files, which results for example in failing to compute that
ext3 depends on jbd, which is then not included in the initramfs.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. set the locale to
2. make sure you have gawk-3.1.4-1
3. test on the attached modules.dep files with
the attached script extracted from mkinitrd
dependency calcucation function
mkinitrd fails to compute ext3 dependency on jbd
mkinitrd should realize ext3 depends on jbd and include
jbd in initramfs
See attached patch. Setting LC_CTYPE=C before the AWK
invocation appears to fix the problem.
Interestingly enough, changing the line containing
dep=sprintf(..., dep, ...) to
tmp=sprintf(..., dep, ...); dep=tmp also fixes the problem,
although I don't know why.
Created attachment 103790 [details]
A patch to mkinitrd to fix the problem
Created attachment 103791 [details]
A fragment of mkinitrd computing module dependencies
This is an excerpt from mkinitrd I used for testing. I suspect that the locale
setting of en_US.UTF-8 is required to reproduce the bug. The modules.dep from
2.6.8-1.521-ps kernel works with original mkinitrd, whereas the file from
2.6.8-1.541-ps kernel does not. After adding LC_CTYPE before the AWK
invocation, it works with both files.
Created attachment 103792 [details]
modules.dep from kernel version 2.6.8-1.521-ps
This modules.dep file works with the original mkinitrd.
Created attachment 103793 [details]
modules.dep from kernel version 2.6.8-1.541-ps
This module.dep does not work with the original mkinitrd.
This is due to a bug in gawk. We've reverted back to gawk 3.1.3-9 in
the devel tree.
*** This bug has been marked as a duplicate of 131498 ***
Changed to 'CLOSED' state since 'RESOLVED' has been deprecated.