help-grub
[Top][All Lists]
Advanced

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

Re: grub in mac


From: Andrei Borzenkov
Subject: Re: grub in mac
Date: Wed, 11 Nov 2015 07:14:43 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0

11.11.2015 06:52, Peter Cheung пишет:
Here you go, thanks again:
/Users/peter/NetBeansProjects/PeterI>$base/sbin/grub-bios-setup -v 
--no-rs-codes -m device.map -c ../../`pwd`/temp/boot/grub/core.img -b 
../../toolchain/lib/grub/i386-pc/boot.img /dev/disk2
/toolchain/sbin/grub-bios-setup: info: adding `hd0' -> `/dev/disk2' from 
device.map.
/toolchain/sbin/grub-bios-setup: info: /dev/disk2 is present.
/toolchain/sbin/grub-bios-setup: info: Looking for /dev/disk2.
/toolchain/sbin/grub-bios-setup: info: /dev/disk2 is a parent of /dev/disk2.
/toolchain/sbin/grub-bios-setup: info: Looking for /dev/disk2.
/toolchain/sbin/grub-bios-setup: info: /dev/disk2 is a parent of /dev/disk2.
/toolchain/sbin/grub-bios-setup: info: transformed OS device `/dev/disk2' into 
GRUB device `hd0'.
/toolchain/sbin/grub-bios-setup: info: reading 
/boot/grub/../../toolchain/lib/grub/i386-pc/boot.img.
/toolchain/sbin/grub-bios-setup: info: reading 
/boot/grub/../..//Users/peter/NetBeansProjects/PeterI/temp/boot/grub/core.img.
/toolchain/sbin/grub-bios-setup: info: root is `(null)', dest is `hd0'.
/toolchain/sbin/grub-bios-setup: info: Opening dest.
/toolchain/sbin/grub-bios-setup: info: drive = 0.
/toolchain/sbin/grub-bios-setup: info: the size of hd0 is 0.
/toolchain/sbin/grub-bios-setup: info: changing current directory to /dev.
/toolchain/sbin/grub-bios-setup: info: changing current directory to fd.
/toolchain/sbin/grub-bios-setup: info: /dev/rdisk1 is not present.
/toolchain/sbin/grub-bios-setup: info: Looking for /dev/rdisk1.
/toolchain/sbin/grub-bios-setup: info: /dev/rdisk1 is a parent of /dev/rdisk1.
/toolchain/sbin/grub-bios-setup: info: Looking for /dev/rdisk1.
/toolchain/sbin/grub-bios-setup: info: /dev/rdisk1 is a parent of /dev/rdisk1.
/toolchain/sbin/grub-bios-setup: info: drive = 1.
/toolchain/sbin/grub-bios-setup: error: guessing the root device failed, 
because of `disk `hostdisk//dev/rdisk1' not found'.


The file core.img must be on partition that is accessible at boot time. Your file is on /dev/disk1 so GRUB tries to resolve it.

Do not use grub-bios-setup, this is internal tool. Use grub-install which will copy GRUB binaries to /boot/grub in suitable location and call grub-bios-setup with correct parameters. In Linux that would be (assuming /boot is on the first partition of image)

losetup -P /dev/loop0 /path/to/image
mount /dev/loop0p1 /mnt
grub-install --boot-directory=/mnt /dev/loop0



reply via email to

[Prev in Thread] Current Thread [Next in Thread]