LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Fixing LILO/MBR with Mandriva CD (https://www.linuxquestions.org/questions/linux-software-2/fixing-lilo-mbr-with-mandriva-cd-859717/)

galapogos 01-31-2011 05:05 AM

Fixing LILO/MBR with Mandriva CD
 
Hi,

I have a Mandriva One 2010.2 Live CD which I used to install Mandriva onto a hard drive. My boot loader is LILO.

The boot sector seems to be corrupted as I tried to run LILO to repair another drive. I must have somehow overwritten my boot sector in the process, and now it doesn't boot up.

How can I fix my MBR and get my LILO back up and running? I still have the Live CD

Thanks.

BroX 01-31-2011 07:33 PM

You should boot with the live CD, and mount your root partition which contains your (corrputed) boot loader.
NOTE: this is an example; change sda1 to the appropriate partition.

As root, do:
Code:

# mount /dev/sda1 /mnt/
Now you can chroot to your root partition,
Code:

# chroot /mnt/
Check if it is the right partition with
Code:

# ls /mnt/
This should give you the root directories, i.e. /boot, /etc, /bin, /lib, etc.

And run lilo
Code:

# /sbin/lilo
to install the bootloader on to the MBR.

Hope this helps.

galapogos 01-31-2011 10:38 PM

Hi,

That didn't seem to work. Apparently lilo.conf no longer exists...

I've tried downloading the Mandriva Free 2010.2 DVD and boot up to the recovery mode, but it didn't work either - complained that no recovery CD was found. Doh.

If I re-install from Mandriva One to the existing partitions, will it overwrite my user files/applications/etc?

Is there any other way?

Thanks!

Edit: Nevermind I copied lilo.conf from an older Mandriva 2010.0 installation, editing the UUIDs and it worked. Thanks!


All times are GMT -5. The time now is 04:47 AM.