You are not logged in.

#1 2011-06-04 02:23:54

CheesyBeef
Member
Registered: 2008-06-04
Posts: 190

[SOLVED] Grub2 goes straight to GRUB > command line

When I boot, Grub2 goes straight to the command line displaying "GRUB >"

Then, if I specify my correct grub.cfg file with:

configfile (hd1,msdos9)/grub/grub.cfg

and press enter, it boots just fine.

I have a system with my Arch install on /dev/sdb2 and my grub boot partition on /dev/sda9 (hd1,msdos9)


Notes on how this started/what I've done:

- This started because I decided to edit my grub entries, then I re-ran grub-install /dev/sdb and rebooted and it showed me the command line rather than the menu.
- I tried various commands using grub-install to fix the problem, such as:

grub-install /dev/sdb

and

grub-install --root-directory=/boot /dev/sdb

as well as created many new grub.cfg files with grub-mkconfig and none of these steps have worked.

Any ideas what to do?

Thanks

EDIT: See below for solution smile

Last edited by CheesyBeef (2011-06-04 06:50:50)

Offline

#2 2011-06-04 05:18:44

CheesyBeef
Member
Registered: 2008-06-04
Posts: 190

Re: [SOLVED] Grub2 goes straight to GRUB > command line

Yay, I finally fixed this problem (only took all day >.<)

The following are the steps I took.  I'm not sure what exactly resolved the issue, but I assume it was due to either conflicting grub legacy files in my /boot/grub folder, or grub legacy still being installed to my mbr.  Anyway, I basically did a complete fresh install of grub2:

1) First I copied /boot/grub/ to /boot/grub-bak/, then deleted /boot/grub

# mkdir /boot/grub-bak
# cp -r /boot/grub/* /boot/grub-bak/*
# rm -r /boot/grub

2) Next I basically followed the Arch Wiki on GRUB2 again, issuing the following commands:

- Backed up then cleared the master boot record of the device I wish to install grub to (/dev/sdb)
Note: replace *user* with your username

# dd if=/dev/sdb of=/home/*user*/Documents/backupmbr.img bs=446 count=1
# dd if=/dev/zero of=/dev/sdb bs=446 count=1

- Loaded dm-mod module then installed grub (as wiki instructs) with the following:

# modprobe dm-mod
# grub_bios-install --boot-directory=/boot --no-floppy --recheck /dev/sdb

- Copy over some files:

# cp /usr/share/grub/{unicode.pf2,ascii.pf2} /boot/grub

- Make a new grub.cfg file:

# grub-mkconfig -o /boot/grub/grub.cfg

Finally, I rebooted and all went well smile

Last edited by CheesyBeef (2011-06-04 05:30:25)

Offline

Board footer

Powered by FluxBB