Created
October 19, 2011 18:53
-
-
Save knzm/1299289 to your computer and use it in GitHub Desktop.
How to recover grub boot loader on MacBook Air
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Boot from Live CD | |
root@ubuntu:~# dmesg | grep DMI | |
[ 0.000000] DMI 2.4 present. | |
[ 0.000000] DMI: Apple Inc. MacBookAir1,1/Mac-F42C8CC8, BIOS MBA11.88Z.00BB.B03.0803171226 03/17/08 | |
root@ubuntu:~# mount --bind /dev /mnt/dev | |
root@ubuntu:~# mount --bind /sys /mnt/sys | |
root@ubuntu:~# mount -t proc none /mnt/proc | |
root@ubuntu:~# chroot /mnt /bin/bash | |
root@ubuntu:/# mount -f / | |
root@ubuntu:/# grub-install /dev/sda | |
Searching for GRUB installation directory ... found: /boot/grub | |
Installing GRUB to /dev/sda as (hd0)... | |
Installation finished. No error reported. | |
This is the contents of the device map /boot/grub/device.map. | |
Check if this is correct or not. If any of the lines is incorrect, | |
fix it and re-run the script `grub-install'. | |
(hd0) /dev/sda | |
root@ubuntu:/# exit | |
root@ubuntu:~# umount /mnt/sys | |
root@ubuntu:~# umount /mnt/proc | |
root@ubuntu:~# umount /mnt/dev | |
root@ubuntu:~# umount /mnt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
ref.
http://www5.big.or.jp/~yamamori/sun/rescue/grub.htm
https://forums.ubuntulinux.jp/viewtopic.php?pid=57491