Red Hat Bugzilla – Bug 119044
Kudzu removes valid duplicate entries from modules.conf
Last modified: 2014-03-16 22:43:29 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040315
Description of problem:
If you have more than one if/else/endif constructs in modules.conf,
kudzu considers the else and endif lines as duplicates and removes
them, thus breaking the config.
The construc I noticed this with is this:
if -f /etc/modules.conf.d/*.conf
if -f /etc/modules.conf.d/`uname -r`/*.conf
include /etc/modules.conf.d/`uname -r`/*.conf
Version-Release number of selected component (if applicable):
0.99.65-1 - 184.108.40.206-1 at least
Steps to Reproduce:
1. Add the example construct in description to modules.conf
2. Run kudzu so that it detects new hardware and rewrites modules.conf
Actual Results: The second endif disappears breaking modutils.
Expected Results: The endif should stay there..
Also affects at least RHL 9 and RHEL 3.
The new modutils in FC2-test doesn't support if-else-endif constructs
and based on a quick check isn't affected by this in any other way
either, but something to keep in mind for the future there too.
Created attachment 98820 [details]
Don't consider lines beginning with else and endif as duplicates
Very low priority since these type of constructs are rare so this is more FYI.
In any case this patch fixes the problem for me.
This almost certainly won't be fixed, as modprobe.conf doesn't support
conditionals, and that's where all the new development is.
Yup, wasn't expecting this to be fixed, reported just to
1) have data available about existence of such an issue
2) point out that checking if similar issue can happen in the new
modprobe.conf format (yes I know it doesn't support conditionals but
just perhaps some other option/command) wouldn't hurt