[Bug 957383] New: request GRUB2 config option to set needed EFI loader options/flags
http://bugzilla.suse.com/show_bug.cgi?id=957383 Bug ID: 957383 Summary: request GRUB2 config option to set needed EFI loader options/flags Classification: openSUSE Product: openSUSE Distribution Version: Leap 42.1 Hardware: x86-64 OS: openSUSE 42.1 Status: NEW Severity: Normal Priority: P5 - None Component: Bootloader Assignee: mchang@suse.com Reporter: 9b3e05a5@opayq.com QA Contact: jsrain@suse.com CC: arvidjaar@gmail.com Found By: --- Blocker: --- Splitting off from Bug 956526 - PANIC on Xen Dom0 restart https://bugzilla.suse.com/show_bug.cgi?id=956526 ------------ Michael Chang 2015-11-26 08:35:53 UTC I think a patch like this would allow to set xen loader options via, say, SUSE_EFI_XEN_LOADER_CMDLINE="-mapbs" in /etc/default/grub. But we'd better not to invent new settings if not required. So I'm support Andrei's suggestion, better to clarify why -mapbps is needed or is supported and possibility to detect it as part of auto configuration settings. Index: grub-2.02~beta2/util/grub-mkconfig.in =================================================================== --- grub-2.02~beta2.orig/util/grub-mkconfig.in +++ grub-2.02~beta2/util/grub-mkconfig.in @@ -260,7 +260,8 @@ export GRUB_DEFAULT \ GRUB_DISABLE_SUBMENU \ GRUB_CMDLINE_LINUX_RECOVERY \ GRUB_USE_LINUXEFI \ - SUSE_BTRFS_SNAPSHOT_BOOTING + SUSE_BTRFS_SNAPSHOT_BOOTING \ + SUSE_EFI_XEN_LOADER_CMDLINE if test "x${grub_cfg}" != "x"; then rm -f "${grub_cfg}.new" Index: grub-2.02~beta2/util/grub.d/20_linux_xen.in =================================================================== --- grub-2.02~beta2.orig/util/grub.d/20_linux_xen.in +++ grub-2.02~beta2/util/grub.d/20_linux_xen.in @@ -176,7 +176,7 @@ linux_entry () message="$(gettext_printf "Loading Xen %s with Linux %s ..." ${xen_version} ${version})" sed "s/^/$submenu_indentation/" <<-EOF echo '$(echo "$message" | grub_quote)' - chainloader \$cmdpath/${xen_basename} ${xen_basename} $section + chainloader \$cmdpath/${xen_basename} ${xen_basename} $section ${SUSE_EFI_XEN_LOADER_CMDLINE} } EOF for f in ${grub_dir}/$xen_cfg ${xen_dir}/${xen_basename} ${rel_dirname}/${basename} ${rel_dirname}/${initrd}; do ------------ boo35 boo35 2015-11-26 14:12:31 UTC Note that there are other EFI flags that are available/useful. E.g., in the Xen thread alone are mentioned /basevideo, /mapbs, noexitboot & /query I'd guess a longer list can be extracted from the tiaonocore sources. I'm not sure which vendors are using the tiaonocore UEFI vs. 'other'. Although auto-detection may be possible, for which failure? Only one? More? Trying to identify all cases of failure, and all possible flag-combo solutions isn't a tenable solution. The flexibility to have the enduser diagnose (nrokennesss, performances issue, etc), and add flags to config -- as is currently often done for both Kernel & Xen is imo preferable. The "SUSE_EFI_XEN_LOADER_CMDLINE" string seems a simple enough approach. If/when grub@suse and grub@upstream coordinate, pushing that cmdline upstream makes sense. Of course, getting EFI fixed is the best solution; I've already contacted the H/W vendor, and they're working on this issue. ------------ -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.suse.com/show_bug.cgi?id=957383
http://bugzilla.suse.com/show_bug.cgi?id=957383#c1
Michael Chang
http://bugzilla.suse.com/show_bug.cgi?id=957383
http://bugzilla.suse.com/show_bug.cgi?id=957383#c2
Raymund Will
http://bugzilla.suse.com/show_bug.cgi?id=957383
http://bugzilla.suse.com/show_bug.cgi?id=957383#c4
Michael Chang
http://bugzilla.suse.com/show_bug.cgi?id=957383
http://bugzilla.suse.com/show_bug.cgi?id=957383#c5
--- Comment #5 from Michael Chang
Yes, 'xen.efi' command-line options are currently not covered.
To rectify that, we need to add something there, but I'd like to propose GRUB_CMDLINE_XENEFI to match the existing 'GRUB_CMDLINE_XEN' and to follow the example of 'GRUB_USE_LINUXEFI', maybe prefixed with 'SUSE_' (if deemed unavoidable). And please retain that '$section' as last parameter.
Thanks for your feedback, Raymund. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.suse.com/show_bug.cgi?id=957383 http://bugzilla.suse.com/show_bug.cgi?id=957383#c6 boo35 boo35 <9b3e05a5@opayq.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Flags|needinfo?(9b3e05a5@opayq.co | |m) | --- Comment #6 from boo35 boo35 <9b3e05a5@opayq.com> --- (In reply to Michael Chang from comment #4)
Please test the package from this repoistory.
http://download.opensuse.org/repositories/home:/michael-chang:/branches:/ Base:/System/openSUSE_Tumbleweed/
You'll have to add your xen efi loader commad line option in /etc/default/grub as something like:
SUSE_CMDLINE_XENEFI="-mapbs"
Run 'grub2-mkconfig -o /boot/grub2/grub.cfg' (or update-bootloader --refresh) to get /boot/grub2/grub.cfg re-generated with new xen command line options.
Upgrading, zypper in --force \ grub2 \ grub2-branding-upstream \ grub2-i386-pc \ grub2-x86_64-efi \ grub2-x86_64-xen Notice the "no such file or directory" messages ... Retrieving package grub2-2.02~beta2-300.2.x86_64 (1/5), 2.4 MiB ( 20.4 MiB unpacked) Retrieving: grub2-2.02~beta2-300.2.x86_64.rpm ...........................[done (137.0 KiB/s)] (1/5) Installing: grub2-2.02~beta2-300.2 ..............................................[done] Additional rpm output: ?? install-info: No such file or directory for /usr/share/info/grub-dev.info ?? install-info: No such file or directory for /usr/share/info/grub2.info ... Checking rpm -qa | grep -i grub grub2-2.02~beta2-300.2.x86_64 grub2-branding-upstream-2.02~beta2-300.2.x86_64 grub2-i386-pc-2.02~beta2-300.2.x86_64 grub2-x86_64-efi-2.02~beta2-300.2.x86_64 grub2-x86_64-xen-2.02~beta2-300.2.x86_64 Mod'ing the grub config EDIT /etc/default/grub + SUSE_CMDLINE_XENEFI=" /mapbs" Then grub2-mkconfig -o /boot/grub2/grub.cfg Results in grep mapbs /boot/grub2/grub.cfg chainloader $cmdpath/xen-4.6.0_08-405.efi xen-4.6.0_08-405.efi /mapbs config.1 chainloader $cmdpath/xen-4.6.0_08-405.efi xen-4.6.0_08-405.efi /mapbs config.2 On reboot, no errors on startup. And this error, https://bugzilla.suse.com/show_bug.cgi?id=956526#c16 gone as well on subsequent reboot, indicating the " /mapbs" was properly inserted. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.suse.com/show_bug.cgi?id=957383 http://bugzilla.suse.com/show_bug.cgi?id=957383#c7 boo35 boo35 <9b3e05a5@opayq.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Flags| |needinfo?(mchang@suse.com) --- Comment #7 from boo35 boo35 <9b3e05a5@opayq.com> --- To mention When I was instructed on this in #irc, the _specific_ guidance given was grub edits in the following order: xen-<version>.cfg ==> [config.#] ==> "options= ..." Your patch creates the inverse order of config & options xen-<version>.cfg ==> "options= ..." ==> [config.#] Reading the thread/commit http://lists.xen.org/archives/html/xen-devel/2015-07/msg05138.html http://xenbits.xen.org/gitweb/?p=xen.git;a=patch;h=cbf41e0514389b65f545e1b1c... I'm not clear whether it's order sensitive or not. Is it? Worth a closer check. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.suse.com/show_bug.cgi?id=957383
Michael Chang
http://bugzilla.suse.com/show_bug.cgi?id=957383
Leonardo Chiquitto
participants (1)
-
bugzilla_noreply@novell.com