Re: grub2-mkconfig with 3.2.10 kernels?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, Mar 18, 2012 at 5:00 PM, Michael D. Setzer II
<mikes@xxxxxxxxxxxxxxxx> wrote:
> Just did an update and it included a new kernel, but then on
> reboot after running grub2-mkconfig noticed that the newest one
> was not first. Seems to be sorting the 9 before the 10?
>
> Is this a bug?
> I use the default="0", so this makes it not use the latest?

Looks like a bug in mkconfig's sorting code. [1]
Simply replace sort -n (numerical) with sort -V (version) in
grub-mkconfig_lib (patch attach, run from "/", use at your own risk,
may eat your children, etc)
I've reported it in bugzilla [2].

- Gilboa
[1] http://lists.gnu.org/archive/html/grub-devel/2012-03/msg00159.html
[2] https://bugzilla.redhat.com/show_bug.cgi?id=804558
--- usr/lib/grub/grub-mkconfig_lib.old	2012-03-19 10:57:20.568836288 +0200
+++ usr/lib/grub/grub-mkconfig_lib	2012-03-19 10:57:25.951592474 +0200
@@ -163,7 +163,7 @@
     a="$b"
     b="$c"
   fi
-  if (echo "$a" ; echo "$b") | sort -n | head -n 1 | grep -qx "$b" ; then
+  if (echo "$a" ; echo "$b") | sort -V | head -n 1 | grep -qx "$b" ; then
     return 0
   else
     return 1
-- 
users mailing list
users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
Have a question? Ask away: http://ask.fedoraproject.org
[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux