Fix lfs grub
Hi
I have to fix my LFS system. I done dd copy of sdb1 which was lfs then put back on a new hard drive which was partition the same, The new drive was set as sdb1. then dd back the img to the same partition on new drive. When I try to boot all I get is the word "GRUB-" and flashing cursor. The original HD was 40gig new drive is 80gig But sdb1 was formatted as ext4 and partition 16gig the same as original |
Hi,
Is/was GRUB installed to the mbr? And if so: Are you sure this is still the case for your "new" HD? You might need to run grub-install /dev/sdX (8.4.3. Setting Up the Configuration). Hope this helps. |
Hi
Grub was installed on the sdb drive only. So your advice would be boot a live cd mount sdb1 then Code:
grub-install /dev/sdb1 |
Hi,
Quote:
I don't know what you have previously done, this being sdb. Did you originally put grub on the mbr of sdb or sda? Put it there where you have put it before. If this is sdb then: Code:
grub-install /dev/sdb Quote:
BTW: Is grub used that came with LFS or are you using grub that's part of another distro (the one on sda?) If another distro's grub is used: DO NOT use the above command, it will overwrite the one used by the other distro. Hope this helps. |
I used grub from lfs and yes it was put on sdb So as to only boot that drive, It is completely seperate from the other drives
|
Hi,
Quote:
Hope this helps. |
ok I have loaded Ubuntu live cd mounted lfs sdb1. I ran the command sudo grub-install /dev/sdb I get an error.
Code:
grub-probe: error: cannot find a device for /boot/grub. |
Hi
Ok have fixed problem here's how load live cd mount lfs system then run Code:
sudo grub-install --recheck --root-directory=/media/lfs /dev/sdb |
fix grub when transfering to new drive
Hi
Ok have fixed problem here's how load live cd mount lfs system then run Code:
sudo grub-install --recheck --root-directory=/media/lfs /dev/sdb |
Hi,
Glad to see you got this solved. BTW: Did you chroot into LFS or use Ubuntu's grub-install? And can you put up the [SOLVED] tag. |
I ran sudo command from ubuntu live cd not chroot.
So the other option would be to chroot into lfs here. I take it you have not tried copying to a new drive before? |
Hi,
Quote:
Code:
mount -v --bind /dev $LFS/dev Quote:
|
Well I hope this helps other ppl in the future (good excercise)
|
All times are GMT -5. The time now is 05:09 AM. |