You are not logged in.
Pages: 1
hey...
somehow grub2 won't install properly on my system.
partitions:
sda1 /boot
sda2 luksEncrypted /
sda4 luksEncrypted /home
things i tried:
$ grub-install '(hd0)'
grub-setup: error: Cannot read `/boot/grub/core.img' correctly
but
$ ls -l /boot/grub | grep core
-rw-r--r-- 1 root root 24791 2009-02-03 09:06 core.img
same with --recheck
i can install it with
$ grub-install --root-directory=/boot '(hd0)'
but then its in /boot/boot/grub/
when i try
$ grub-install --root-directory=/ '(hd0)'
it gives me the same error i got before.
any help would be greatly appreciated!
Offline
I have separate /boot partition too, and same error for me.
Any help will be appreciated.
Maybe I should install grub2-svn from the AUR.
Last edited by cwjiof (2009-02-17 13:34:47)
Offline
post your fstab here
Running ArchLinux on Compaq Presario v2000
Offline
fstab
none /dev/pts devpts defaults 0 0
none /dev/shm tmpfs defaults 0 0
/dev/sr0 /media/cd auto ro,user,noauto,unhide 0 0
/dev/sda1 /boot ext3 defaults 0 1
/dev/mapper/root / ext4 defaults,noatime 0 1
/dev/mapper/data /media/data ext4 defaults,noatime 0 1
/dev/mapper/home /home ext4 defaults,noatime 0 1
/swapfile swap swap defaults 0 0
Last edited by konni (2009-02-18 12:24:24)
Offline
Almost the same with me,
I used LVM2 and LUKS. So I have "/dev/mapper/..." in my fstab.
Offline
but the boot partition is a regular, unencrypted one. so i don't get the problem. especially why i can install in /boot/boot/grub and not in /boot/grub.
Offline
I am having this exact same problem with grub2-gfxmenu.
Offline
grub-install is just a wrapper for the grub mini-shell thingie. I've sort of given up on it, since it seems to only work in those few cases where /boot really is /dev/hda-something (or sda-something now) -- it fails miserably on RAID, etc.
Anyway, all you really need to do most of the time is:
$ grub
[ GNU GRUB the grub welcome text blah blah ]
grub> root (hdX,X)
grub> setup (hdX)
For instance if /boot is your first partition on your first hard drive, the commands are:
root (hd0,0)
setup (hd0)
All of the rest of grub-install is just some complicated logic for translating /dev/hda-something into those grub device names.
Two other things to double-check:
- if you first installed arch a long time ago (before the switch from "hd" to "sd" for IDE hard drives) the install CD will use the wrong device names. You need to make sure your root= line in /boot/grub/menu.lst says what you're used to seeing, unless you know that your last kernel upgrade changed your device names.
- sometimes grub-install gets confused about the difference between /boot/grub and /grub . When you're first booting, the stage 2 files are in /grub, because you're thinking relative to the boot partition (rootfs hasn't been mounted yet, so you are in /, not /boot).
Offline
grub-install --grub-setup=/bin/true /dev/sda
did solve this for me
Offline
grub-install is just a wrapper for the grub mini-shell thingie. I've sort of given up on it, since it seems to only work in those few cases where /boot really is /dev/hda-something (or sda-something now) -- it fails miserably on RAID, etc.
Anyway, all you really need to do most of the time is:
$ grub
[ GNU GRUB the grub welcome text blah blah ]
grub> root (hdX,X)
grub> setup (hdX)
For instance if /boot is your first partition on your first hard drive, the commands are:
root (hd0,0)
setup (hd0)All of the rest of grub-install is just some complicated logic for translating /dev/hda-something into those grub device names.
Two other things to double-check:
- if you first installed arch a long time ago (before the switch from "hd" to "sd" for IDE hard drives) the install CD will use the wrong device names. You need to make sure your root= line in /boot/grub/menu.lst says what you're used to seeing, unless you know that your last kernel upgrade changed your device names.
- sometimes grub-install gets confused about the difference between /boot/grub and /grub . When you're first booting, the stage 2 files are in /grub, because you're thinking relative to the boot partition (rootfs hasn't been mounted yet, so you are in /, not /boot).
Yeah, there's no grub command with grub2-gfxmenu.
Offline
Same problem here with GRUB2 and Fake-RAID running grub-install doesn't work for me so I need a grub promp to set everything manually.
Regards
André
Offline
had the same problem and solved it gladfully. Wrote the instructions into the wiki.
greets
Offline
Where exactly did you write your instructions in the wiki?
Regards
André
Offline
Remember with GRUB2:
(hdn,m) is the partition m on disc n, partition numbers starting with 1, disc numbers starting with 0
You do NOT use (hd0,0) anymore.
Offline
sry, it stopped working in the meantime. I don't think it would help. )-:
Offline
Pages: 1