https://bugzilla.novell.com/show_bug.cgi?id=717590 https://bugzilla.novell.com/show_bug.cgi?id=717590#c0 Summary: "mkinitrd" is not capable of setting override variables set in "/etc/sysconfig/initrd". Classification: openSUSE Product: openSUSE 11.4 Version: Final Platform: x86-64 OS/Version: SLES 11 Status: NEW Severity: Major Priority: P5 - None Component: Basesystem AssignedTo: bnc-team-screening@forge.provo.novell.com ReportedBy: D.Olsson@Netzwerk-Design.de QAContact: qa@suse.de Found By: --- Blocker: --- Created an attachment (id=450497) --> (http://bugzilla.novell.com/attachment.cgi?id=450497) Patch fixing reported bug, enabling defintions of override variables in "/etc/sysconfig/initrd". User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:5.0) Gecko/20100101 Firefox/5.0 When using "/etc/sysconfig/initrd" to set override variables, these are no longer used by "mkinitrd". The reason for this is this line in "/sbin/mkinitrd": diff -b mkinitrd-2.4.1-0.14.1-mkinitrd /sbin/mkinitrd 437c437 < local override="$(cat /etc/sysconfig/initrd | egrep \"^$1=\")" ---
local override="$(cat /etc/sysconfig/initrd | egrep "^$1=")"
It is *wrong* to use "\"" within the "$( )", while this translates into "egrep" being called with the argument "^SomeValue=", whereas the argument should be ^SomeValue= Reproducible: Always Steps to Reproduce: 1. Create a "/etc/sysconfig/initrd" file with the contents: resumedev="/dev/disk/by-label/swap02" 2. Run "mkinitrd" 3. Notice that the used "Resume device:" is *not* "/dev/disk/by-label/swap02", but instead the device used from "/proc/cmdline". Actual Results: Defined override variables found in "/etc/sysconfig/mkinitrd" are *not* being used! Expected Results: Defined override variables found in "/etc/sysconfig/mkinitrd" have to be used by "mkinitrd". Attached is a patch of "mkinitrd" that corrects the problem. Kindly notice that this bug *also* applies for (and was first found on) SLES 11 and SLES 11 SP1!! -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.