[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: disaster with LILO, Debian Linux, Windows, and booting



Spongebob wrote:

> I did something wrong installing a newly-compiled kernel. Unfortunately, I
> forgot to back up /boot, and now I have a mess. I think the map file got
> corrupted.
> 
> I now have a system which will either boot windows and nothing else or
> will print an L and halt depending upon which partition I set with lilo
> -M.
> 
> Windows is on /dev/hda1, Linux root is on /dev/hda4. In lilo.conf,
> boot=/dev/hda
> root=/dev/hda4
> 
> How do I fix this? I'm using Timo's rescue disk to give me access to my
> hard disk. (Using rescue root=/dev/hda4 off the Debian install cd's
> doesn't work for some reason. It gives me an "unable to open initial
> terminal" error and freezes.)
> 
> Thank you.


I used the following sequence:
lilo -A /dev/hda 1      # it was already active, so this didn't do anything
lilo -M /dev/hda        # install new MBR
cp /boot /boot.bak      # backup boot dir
delete the files in /boot
copy the image files and corresponding System.map files listed in
        /etc/lilo.conf from /boot.bak to /boot
lilo    # rerun lilo

I had tried the preceding steps without deleting /boot several times 
without success. Deleting /boot/map before rerunning lilo seems to have 
been the key. I shouldn't have to do that. Bug in lilo perhaps? Or does 
lilo get info from the System.map files? In that case one of them (that 
didn't get copied back to /boot) could have been corrupted.




Reply to: