URL: <http://savannah.gnu.org/bugs/?44026>
Summary: legacy_configfile fail to boot system with xen pvgrub Project: GNU GRUB Submitted by: viliar Submitted on: Fri 16 Jan 2015 05:50:04 PM GMT Category: Booting Severity: Major Priority: 5 - Normal Item Group: Software Error Status: None Privacy: Public Assigned to: None Originator Name: Alex Originator Email: m_dor...@mail.ru Open/Closed: Open Discussion Lock: Any Release: Release: 2.02~beta1 Reproducibility: Every Time Planned Release: None _______________________________________________________ Details: I'm trying to replace old pvgrub in xen env with new pvgrub2 and use it for booting domU with grub2 and grub-legacy inside via universal grub.cfg (search apropriate config file and then boot system with it). According https://blog.xenproject.org/2015/01/07/using-grub-2-as-a-bootloader-for-xen-pv-guests/ I have compiled grub for i386-xen, x86_64-xen. domU with grub2 booting correct. But trying to load grub-legacy menu.lst inside domU with legacy_configfile has been failed: error: couldn't load file *kernel-version* error: you need to load the kernel first. Looks like where is no mapping real device (xen/xvda) with (hd0), so system cannot boot. Manual "set root" allow to boot system with legacy_kernel/legacy_initrd (see bellow) ============================================ Additional system information dom0: fedora21, xen 4.5. domU: fedora20/21 (kernel = "/usr/lib/xen/boot/grub-x86_64-xen.bin") grub: grub-2.02~beta2 (compiled with CFLAGS="-Wno-error=cpp" ./configure --target=x86_64 --with-platform=xen; make CFLAGS="-Wno-error=cpp" ./configure --target=i386 --with-platform=xen; make) pvgrub create: grub-bootstrap.cfg: normal (memdisk)/grub.cfg test grub.cfg: set root=(xen/xvda,msdos1) if search -s -f /boot/grub/menu.lst; then legacy_configfile /boot/grub/menu.lst fi tar cf memdisk.tar grub.cfg grub-mkimage -O x86_64-xen -c grub-bootstrap.cfg -m memdisk.tar -o grub-x86_64-xen.bin /usr/lib/grub/x86_64-xen/*.mod domU /boot/grub/menu.lst: title Fedora release 20 (Heisenbug) via grub-legacy config root (hd0,0) kernel /boot/vmlinuz-3.17.8-200.fc20.x86_64 root=/dev/xvda1 ro clocksource=xen ipv6.disable=1 biosdevname=0 net.ifnames=0 console=hvc0 initrd /boot/initramfs-3.17.8-200.fc20.x86_64.img Boot error: Booting `Fedora release 20 (Heisenbug) via grub-legacy config' error: couldn't load file /boot/vmlinuz-3.17.8-200.fc20.x86_64. error: you need to load the kernel first. Press any key to continue... Generated config vi legacy_configfile looks this way: |set root='(hd0,1)'; set legacy_hdbias='0' | |legacy_kernel '/boot/vmlinuz-3.17.8-200.fc20.x86_64' '/boot/vmlinuz-3.17.\| |8-200.fc20.x86_64' 'root=/dev/xvda1' 'ro' 'clocksource=xen' 'ipv6.disable=1\| |' 'biosdevname=0' 'net.ifnames=0' 'console=hvc0' | |legacy_initrd '/boot/initramfs-3.17.8-200.fc20.x86_64.img' '/boot/initramfs\| |-3.17.8-200.fc20.x86_64.img' | Variables: grub> ls (memdisk) (proc) (xen/xvda) (xen/xvda,msdos1) grub> set ?=18 DAY=16 HOUR=17 MINUTE=27 MONTH=1 SECOND=48 WEEKDAY=Friday YEAR=2015 check_signatures=no color_highlight=black/light-gray color_normal=light-gray/black config_directory=(memdisk) config_file=(memdisk)/grub.cfg default=0 feature_200_final=y feature_all_video_module=y feature_chainloader_bpb=y feature_default_font_path=y feature_menuentry_id=y feature_menuentry_options=y feature_nativedisk_cmd=y feature_ntldr=y feature_platform_search_hint=y feature_timeout_style=y grub_cpu=x86_64 grub_platform=xen lang= legacy_hdbias=0 locale_dir= net_default_ip=(null) net_default_mac=(null) net_default_server= pager= prefix=(memdisk)/boot/grub pxe_default_server= root=hd0,1 secondary_locale_dir= Manual "set root" allow to boot system with legacy_kernel/legacy_initrd: grub> set root=(xen/xvda,msdos1) grub> legacy_kernel '/boot/vmlinuz-3.17.8-200.fc20.x86_64' '/boot/vmlinuz-3.17.8 -200.fc20.x86_64' 'root=/dev/xvda1' 'ro' 'clocksource=xen' 'ipv6.disable=1' 'bio sdevname=0' 'net.ifnames=0' 'console=hvc0' grub> legacy_initrd '/boot/initramfs-3.17.8-200.fc20.x86_64.img' '/boot/initramf s-3.17.8-200.fc20.x86_64.img' grub> boot [ initramfs-3.17.8-200 8.92MiB 100% 17.09KiB/s ] [ 0.000000] Initializing cgroup subsys cpuset [ 0.000000] Initializing cgroup subsys cpu ... Fedora release 20 (Heisenbug) Kernel 3.17.8-200.fc20.x86_64 on an x86_64 (hvc0) localhost login: ... ============================================ I didn't find workarounds for it yet. Can make some other testing if it needed. Thank you. | _______________________________________________________ Reply to this item at: <http://savannah.gnu.org/bugs/?44026> _______________________________________________ Message sent via/by Savannah http://savannah.gnu.org/ _______________________________________________ Bug-grub mailing list Bug-grub@gnu.org https://lists.gnu.org/mailman/listinfo/bug-grub