[Bug 276464] New: Kernel update does not correctly quote arguments in /etc/lilo.conf
https://bugzilla.novell.com/show_bug.cgi?id=276464 Summary: Kernel update does not correctly quote arguments in /etc/lilo.conf Product: openSUSE 10.2 Version: Final Platform: PC OS/Version: Other Status: NEW Severity: Normal Priority: P5 - None Component: Kernel AssignedTo: kernel-maintainers@forge.provo.novell.com ReportedBy: bjoern@cs.tu-berlin.de QAContact: qa@suse.de This bug is an duplicate of #117642 but I'm not allowed to edit bug #117642: "You are not permitted to edit bugs in product SUSE LINUX 10.0." The bug #117642 is still in openSUSE 10.2. After installing a new kernel (tested with kernel-default-2.6.18.8-0.3.i586.rpm and kernel-default-2.6.21-200.1.i586.rpm) the postinstall scriptlet modifies /etc/lilo.conf. This is an example lilo entry: image = /lx/fedora/boot/vmlinuz label = fedora6 root = /dev/hda10 vga = 791 append = "resume=/dev/hda5" initrd = /lx/fedora/boot/initrd optional The kernel-default postinstall scriptlet removes the quotes. Lilo reports this as an syntax error. [...] append = resume=/dev/hda5 [...] I have all the lastes updates installed especially perl-Bootloader-0.4.14-1.2. -- 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, or are watching someone who is.
https://bugzilla.novell.com/show_bug.cgi?id=276464#c1 Jeff Mahoney <jeffm@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|kernel- |aosthof@novell.com |maintainers@forge.provo.nove| |ll.com | --- Comment #1 from Jeff Mahoney <jeffm@novell.com> 2007-06-18 14:23:24 MST --- This looks like a problem in perl-Bootloader, not the kernel package. Assigning to Alexander. -- 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. ---
https://bugzilla.novell.com/show_bug.cgi?id=276464 Alexander Osthof <aosthof@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED -- 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.
https://bugzilla.novell.com/show_bug.cgi?id=276464#c2 Alexander Osthof <aosthof@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution| |FIXED --- Comment #2 from Alexander Osthof <aosthof@novell.com> 2007-07-23 08:23:31 MST --- This problem is fixed with the perl-Bootloader (0.4.14) from online update sources, thus I close this bug RESOLVED FIXED. If related errors still occur, feel free to reopen this bug. -- 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.
https://bugzilla.novell.com/show_bug.cgi?id=276464#c3 Björn Voigt <bjoern@cs.tu-berlin.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |REOPENED Resolution|FIXED | --- Comment #3 from Björn Voigt <bjoern@cs.tu-berlin.de> 2007-07-23 09:24:13 MST --- Sorry, I have perl-Bootloader-0.4.14-1.2 installed. But both during install and deinstall of kernel-default-2.6.18.8-0.5.i586.rpm the quotes are removed for this Lilo line: append = "resume=/dev/hda5" -- 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.
https://bugzilla.novell.com/show_bug.cgi?id=276464#c4 --- Comment #4 from Alexander Osthof <aosthof@novell.com> 2007-07-24 01:46:39 MST --- Hmmm... thought I have fixed that issue. Anyway, I'll take a look. -- 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.
https://bugzilla.novell.com/show_bug.cgi?id=276464 Alexander Osthof <aosthof@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|REOPENED |ASSIGNED -- 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.
https://bugzilla.novell.com/show_bug.cgi?id=276464#c5 --- Comment #5 from Alexander Osthof <aosthof@novell.com> 2007-07-24 01:50:17 MST --- Now I know why I've overseen the problem: it only occurs if the append line consists of exactly one parameter, in your case "resume=/dev/hda5". Working on a fix. -- 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.
https://bugzilla.novell.com/show_bug.cgi?id=276464#c6 Alexander Osthof <aosthof@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |NEEDINFO Info Provider| |bjoern@cs.tu-berlin.de --- Comment #6 from Alexander Osthof <aosthof@novell.com> 2007-10-09 06:54:15 MST --- Could you please test with latest maintenance update, thus perl-Bootloader 0.4.19? Thanks in advance. -- 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.
https://bugzilla.novell.com/show_bug.cgi?id=276464#c7 Björn Voigt <bjoern@cs.tu-berlin.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEEDINFO |ASSIGNED Info Provider|bjoern@cs.tu-berlin.de | --- Comment #7 from Björn Voigt <bjoern@cs.tu-berlin.de> 2007-10-13 11:02:19 MST --- Yes. The problem still exists. Last Kernel update for 10.2 (kernel-default-2.6.18.8-0.7) also causes a broken /etc/lilo.conf. $ rpm -q kernel-default perl-Bootloader kernel-default-2.6.18.8-0.7 perl-Bootloader-0.4.19-2.1 $ lilo [...] Syntax error at or above line 44 in file '/etc/lilo.conf' Line 44 in my broken /etc/lilo.conf is: append = resume=/dev/hda5 -- 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.
https://bugzilla.novell.com/show_bug.cgi?id=276464#c8 --- Comment #8 from Alexander Osthof <aosthof@novell.com> 2007-10-22 02:57:19 MST --- Due to lack of resources, this issue most likely won't be fixed until code 11. Adjusting product. -- 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.
https://bugzilla.novell.com/show_bug.cgi?id=276464#c9 --- Comment #9 from Björn Voigt <bjoern@cs.tu-berlin.de> 2007-10-22 12:30:54 MST --- I don't think that fixing of this issue is so difficult as it looks. There is already a function "Quote" in Core.pm: # string Quote (string text, string when) sub Quote { my $self = shift; my $text = shift; my $when = shift; if ($when eq "always" || ($when eq "blanks" && index ($text, " ") >= 0) || ($when eq "blanks" && $text eq "")) { $text = "\"$text\""; } return $text; } The problem is, that Quoting only occurs if $when is "blanks" or "always". But for instance, "=" should always be quoted, as "man lilo.conf" says: Note: The command line root= parameter passed to the kernel will be: 'root=LABEL=MyDisk'; i.e., without the quotation marks. If the root= parameter is passed from the boot time boot: prompt, no quotes are used. The quotes are only there to sat- isfy the requirements of the boot-installer parser, which treats an equal sign as an operator. The kernel command line parser is very much simpler, and must not see any quotation marks. Simply stated, only use the quotation marks within /etc/lilo.conf. My patch quotes "=" unconditional. If it's guarantied, that $when must be "always" or "blanks" then it also could be used in case of "blanks". This is the patches function "Quote": # string Quote (string text, string when) sub Quote { my $self = shift; my $text = shift; my $when = shift; if ($when eq "always" || ($when eq "blanks" && index ($text, " ") >= 0) || ($when eq "blanks" && $text eq "") || index ($text, "=") >= 0) { $text = "\"$text\""; } return $text; } I tested the patched function a bit. My problem that kernel-update removes the quotes of append = "resume=/dev/sda5" is solved with the patch and I see no side effects. But maybe some more testing and/or code cleanup should follow. -- 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.
https://bugzilla.novell.com/show_bug.cgi?id=276464#c10 --- Comment #10 from Björn Voigt <bjoern@cs.tu-berlin.de> 2007-10-22 12:32:30 MST --- Created an attachment (id=179769) --> (https://bugzilla.novell.com/attachment.cgi?id=179769) Quoting fix -- 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.
https://bugzilla.novell.com/show_bug.cgi?id=276464#c11 Alexander Osthof <aosthof@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution| |WONTFIX --- Comment #11 from Alexander Osthof <aosthof@novell.com> 2007-11-30 03:50:19 MST --- Fixed for openSUSE 10.3, I recommend upgrading to it. This issue won't be fixed for 10.2 anymore, thus closing WONTFIX. -- 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.
https://bugzilla.novell.com/show_bug.cgi?id=276464#c12 Björn Voigt <bjoern@cs.tu-berlin.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |REOPENED Component|Kernel |Kernel Product|openSUSE 10.2 |openSUSE 10.3 Resolution|WONTFIX | --- Comment #12 from Björn Voigt <bjoern@cs.tu-berlin.de> 2007-11-30 15:56:01 MST --- Sorry, but the problem is also included in openSUSE 10.3. So, I re-opened this bug. A possible fix is in comment #9. -- 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.
https://bugzilla.novell.com/show_bug.cgi?id=276464#c13 Alexander Osthof <aosthof@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|REOPENED |RESOLVED Resolution| |FIXED --- Comment #13 from Alexander Osthof <aosthof@novell.com> 2007-12-03 02:58:14 MST --- Maybe this was a little bit unclear. I've already fixed this problem for 10.3 and submitted a new package of perl-Bootloader, but it isn't released yet. So, please be patient, an online-update of perl-Bootloader should be available soon. Thus, closing RESOLVED FIXED. -- 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.
participants (1)
-
bugzilla_noreply@novell.com