Red Hat Bugzilla – Bug 745246
Need automatic conversion from grub1 to grub2 for all possible cases
Last modified: 2013-05-31 13:37:56 EDT
Since the plan is to force a replacement of grub2 (removing grub1) on upgrades, we need to do an automatic conversion from grub1 to grub2 configs on the system at that time, excluding any cases which are known not to work.
This can probably be done either in post or with a %triggerun.
In the case of password enabled grub1 configs, we should consider simply deploying a working grub2 config without the password, if possible, as that is better than a non-booting system IMHO.
-1 blocker: we are already doing this with supported upgrade methods (anaconda-based). upgrading with yum is not a support method and is not included in the release criteria.
one obvious consideration is that we shouldn't try to convert EFI systems to grub2. I believe the script could check if the system's EFI based by looking for some file or other in /sys which only shows up if the system's EFI-booted, though.
Discussed at 2011-10-14 blocker review meeting. Agreed this is not a blocker as we do not support yum upgrades, and in any case doing a yum upgrade does not result in a non-bootable configuration as grub remains in the MBR or boot sector and its configuration file remains in place.
I just upgraded, using "preupgrade", two Fedora 15 systems to Fedora 16, and in both systems the upgrade did NOT replace grub1 with grub2, and I was left running grub1 configured to run an old Fedora 15 kernel (which was luckily not deleted yet). I had to manually run on each system:
/sbin/grub2-mkconfig -o /boot/grub2/grub.cfg
(as recommended in http://fedoraproject.org/wiki/Upgrading_Fedora_using_yum#Fedora_15_-.3E_Fedora_16)
Which worked correctly, and now Fedora boots to the new Fedora 16 kernel.
Someone above commented that "upgrading with yum is not a support method". Preupgrade is also not supported??? That would be utterly ridiculous, since *everybody* I know uses only this method to upgrade. The last time I actually burnt a DVD of Fedora was when I wanted to install it on a new machine. Preupgrade is much more convenient, and also much faster, and there is no reason why it should work. So would a big boot message (or whatever) urging you to quickly run these commands, or you risk running an old kernel which will most likely be automatically deleted from your system after a few updates.
I just noticed that this bug is a duplicate of bug 737731
(In reply to comment #5)
> I just noticed that this bug is a duplicate of bug 737731
No; this bug is a catch-all for all upgrade methods, not limited to preupgrade as bug 737731.
(In reply to comment #4)
> I just upgraded, using "preupgrade", two Fedora 15 systems to Fedora 16, and in
> both systems the upgrade did NOT replace grub1 with grub2, and I was left
Yes, that is a bug. It sounds like https://fedoraproject.org/wiki/Common_F16_bugs#preupgrade-bootloader-fail but might be something else.
> Someone above commented that "upgrading with yum is not a support method".
> Preupgrade is also not supported???
Preupgrade is not yum upgrade. Preupgrade is supported, yum isn't.
Thanks for all the explanations. One nitpick: https://fedoraproject.org/wiki/Common_F16_bugs#preupgrade-bootloader-fail should mention Fedora *15*, not 14. I preupgraded from Fedora 15, not 14.
(In reply to comment #7)
> should mention Fedora *15*, not 14. I preupgraded from Fedora 15, not 14.
No. But there is no reason to discuss that on two bugs at once. goto bug 737731.
This issue was solved for f16 by anaconda by default installing the new bootloader. The guidelines for manual upgrade with yum also mentioned that the new boot loader had to be installed.
Marking as closed.