-
A corrupted MBR is not fun, trust me on this one.
So, somehow I corrupted my MBR. When my bios is supposed to show lilo instead I just get a long list of "99"s. So no booting into linux or windows. Anyways, I've been looking but I can't find any USB linux boot disks that can fix an MBR. I've found plenty of CD and floppy ones, but the computer I'm using to write this doesn't have a CD burner (and mine doesn't have a floppy drive). So, does anyone have any suggestions?
`Only dead fish swim with the stream. . .
-
That is corrupted talk!
Task B3 in the last link of my signature refers. Dead easy to fix with any Linux Live CD!
Even if you have no floppy drive and no CD drive you can put Grub into a USB pen drive, boot up Grub and use it to fire up the Linux. Then you restore Lilo.
Last edited by saikee; 08-30-2007 at 07:41 PM.
-
Cool. Goood to know that it's easy. One question though, by "putting grub on the USB" do you mean just the grub boot loader or do you mean putting a whole knoppix linux CD on the USB drive?
`Only dead fish swim with the stream. . .
-
Just Grub or a part of it really because you don't even build it.
Get any Live CD that has Grub on any PC that can read CD/DVD and support USB pen drive. Boot up the Live CD and insert the pen drive.
Mount the pen drive and make a /boot/grub directory in the USB pen drive. Say it is in the first partition and the pen drive is the second disk so the partition known to Grub as (hd1,0)
Use "find / -name stage1" to find the location of the Grub directory in the boot up Linux and Copy the content Grub directory in the pen drive's /boot/grub
Invoke a Grub shell in a Linux terminal and make the pen drive bootable by Grub by commands
Code:
grub
root (hd1,0)
setup (hd1)
Take this pen drive to any PC with unbootable Linux and arrange the Bios to boot the usb device first.
You get a Grub prompt and nothing else. But there isn't a PS system that cannot be booted by a Grub Prompt.
In the Grub prompt you can check the disk partition geometry by
Code:
geometry (hd0)
geometry (hd1)
etc
Having locate the partition of the unbootable Linux, say it is in (hd2,1) that has lilo.conf you can ask Grub to display its Lilo.conf content by
Code:
cat (hd2,1)/etc/lilo.conf
You can then use GRub's kernel command to boot the Linux previous booted by Lilo by the 4 lines of command
Code:
root (hd2,1)
kernel <content from the "image=" statement"> plus <ro> Plus <root=device name>
initrd <any relevant initrd file>
boot
You do similar for an Unbootable Linux that has Grub
For Dos, WIndows, Solaris or BSD you chainload the system
Code:
root <relevant partition in GRub term>
chainloader +1
boot
That is what I call "real fun" when your MBR is corrupted because a Linux user does not need a MBR to boot any PC system. We have Grub! GRub can be installed in any bootable media; floppy, CD, DVD, internal hard disk, USB pen drive, USB external hard disk, etc....
Last edited by saikee; 08-31-2007 at 03:30 AM.
-
Thanks for the help, I actually was able to burn a CD, so all is well. Well, kind of. I'm able to boot an old kernel, but not my newest one. This is an unrelated problem that I talk about here: http://justlinux.com/forum/showthread.php?p=873313 . Once again, thanks for the help.
--Gabe
`Only dead fish swim with the stream. . .
-
Never realized that. New PC's do not come with floppy drives any more, so your "good old" MS-dos flop containing FDISK.exe cannot do the job anymore...
I've got an gparted-live cd lying around. whenever I'm in that kind of trouble, can that CD help me?
It's a known "problem" with OS/2. It runs continuously until the underlying hardware crumbles under you hands....
the irony of quality
-
One can burn a Dos bootable floppy disk image into a CD. It is called emulation mode and the CD boots up as Drive "A".
The MS fdisk.exe can also be "sourced" from FreeDos which provides a bootable iso image to be burn into a CD. It is always there whenever we need it.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|