|
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
On Sun, 21 May 2000, Steven J Pulito wrote:
> I had a windows partition and a linux partion and used lilo to dual boot.
>
> When I formatted the first partition and reinstalled windows it wiped the
> MBR and lilo. However the linux partion is still there. How do I
> reinstall lilo in the MBR?
Incase the other 2 didn't help enough...
Get a rescue disk. The 1st floppy of an installation set tends to be a
rescue disk. Both redhat & debian's are. Or a bootable cdrom. If you
don't have one, download an image.
ftp://ftp.valinux.com/pub/mirrors/redhat/redhat/redhat-6.2-ja/i386/images/boot.img
might work. Under windows you need rawrite to copy the image to a floppy:
ftp://ftp.valinux.com/pub/mirrors/redhat/redhat/redhat-6.2-ja/i386/dosutils/rawrite.exe
So you download those 2 files, put a blank floppy in a drive, run rawrite,
it asks you what image name, you tell it boot.img, it asks you what drive,
you probably tell it "a", it writes the disk, you reboot your box, *read*
the 1st screen when it boots up & do whatever it says to boot to rescue
mode. Or otherwise find your way to a command prompt.
Now you need to mount your linux partition that has /etc/lilo.conf on
it. What drive is that ? What partition ? If it's your 1st IDE hard
drive's 1st partition, than it's /dev/hda1. If it's your 1st scsi disk, I
believe it's /dev/scd1.. but you've probably got IDE, right ? You can
look at your partition tables w/ "fdisk /dev/hda" "fdisk /dev/hdb" etc. --
it'll tell you what key to hit for help. I think you hit "p" to show you
the list of existing partitions. Then exit without saving.
Now you know what partition it is. Say it's /dev/hda1. You need a mount
point. Make sure the directory /mnt exists and is empty. Any empty
directory will do, if you need one, use mkdir, but this is a typical mount
point that is usually available on rescue disks.
Given the above assumptions, mount like so:
mount /dev/hda1 /mnt
Now if you cd /mnt, you should see the root directory of your linux
partition. If you
cat /mnt/etc/lilo.conf
You should see your lilo.conf scroll by. If everything's gone well, run:
lilo -r /mnt
The -r tells it that your root directory is actually mounted in /mnt. You
should be good. Reboot your box. Pray. Cross your fingers. Scream
"work" pleadingly at the appropriate time. Whatever it is you do.
This really isn't a major problem and is quite recoverable.
___________________
www.ChaosReigns.com
______________________________________________________________________
Philadelphia Linux Users Group - http://plug.nothinbut.net
Announcements - http://lists.nothinbut.net/mail/listinfo/plug-announce
General Discussion - http://lists.nothinbut.net/mail/listinfo/plug
- References:
- [PLUG] lilo
- From: Steven J Pulito <stevenp@seas.upenn.edu>
|
|