LinuxQuestions.org
Register a domain and help support LQ
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 10-30-2003, 12:16 PM   #1
zaltar
Member
 
Registered: Mar 2003
Distribution: Slackware 10.1
Posts: 44

Rep: Reputation: 15
Question fdisk /mbr can't get rid of GRUB?!


I have Win98SE on hda1 (this is a primary partition) and Debian "Woody" 3.0r1 on hda10 (this is a logic partition which belongs to Extended Memory).

I tried to make Grub work installing it on hda10 and on hda1, but it didn't.

In the first case Grub didn't show its list of OS, but at least Win could run.

In the second case Grub showed its list but Debian gave me a kernel panic suggesting me to use "init=option", even though I don't know which option I'm supposed to use, while Win simply couldn't run.

To fix this mess I put my Win98SE rescue floppy in its drive and turn my pc on, then pressing Shift-F5 I opened the DOS prompt and I inserted "fdisk /mbr", but rebooting I saw Grub.

I know this is a dumb description, yet I prefer not to be misunderstood, you see.

I heard "fdisk /mbr" can't handle system with more than 4 partitions and I have more than 4 partitions, but it's true?

Reply, guys.
 
Old 10-30-2003, 12:35 PM   #2
mwettach
Member
 
Registered: Oct 2003
Location: Germany
Distribution: SuSE 8.2, SuSE 9.1 on desktop (besides W2K). SuSE 9.1 on notebook (besides XP).
Posts: 44

Rep: Reputation: 15
The magical number of 4 partitions refers to the partition table which is at the beginning of your disk (close to the MBR). This table has space for 4 partitions.

You can have up to 4 "primary" partitions (but only one can be active / bootable at any time if you haven't installed a bootloader like GRUB or Lilo) or alternatively up to 3 primary and one extended partition, which latter in turn can be split into several logical partitions.

The logical partitions present no problem for fdisk <drive:> /mbr, because their respective partition tables are stored far away from the MBR, beginning at the address of the extended partition. So I doubt that you really have a problem with more than 4 partitions.

I have a similar setup to yours, but with SUSE Linux and Windows 2000. GRUB was installed into the MBR and is able to boot both systems. I admit that I let the install routine of SUSE Linux do most of the work. Perhaps you should do the same...

Or alternatively try Lilo?

Partition Magic also includes a bootloader (from OS/2), which you could use (you would have to install a boot loader into your linux partition then). You can get older versions of Partition Magic quite cheap with a magazine CD nowadays.

Last edited by mwettach; 10-30-2003 at 12:40 PM.
 
Old 10-30-2003, 01:03 PM   #3
Demonbane
LQ Guru
 
Registered: Aug 2003
Location: Sydney, Australia
Distribution: Gentoo
Posts: 1,796

Rep: Reputation: 47
If you really installed grub into hda1 then you just killed win98 bootsector, but don't panic yet there's a quick and easy way to recover without reinstalling. To install grub into the MBR you should just install into "hda", without putting any partition number.
To repair win9x bootsector grab this:
http://www.winimage.com/bootpa25.zip
copy bootpart.exe into your dos bootdisk, boot into c:\ then go:
bootpart win95 boot:c:
This should restore win9x bootsector and next time you boot it should boot directly into win98(if not make sure win98 partition is set to active)
Have you linux bootdisk handy, boot with it and install grub into hda(MBR) as per usual.
The kernel panic probably means you specified the wrong root= option or /etc/fstab is incorrect, sometimes grub sees the partition order differently than linux so try different parameters (hint:use a grub bootdisk/ debian cd rescue mode)

Last edited by Demonbane; 10-30-2003 at 01:05 PM.
 
Old 10-30-2003, 01:05 PM   #4
zaltar
Member
 
Registered: Mar 2003
Distribution: Slackware 10.1
Posts: 44

Original Poster
Rep: Reputation: 15
I have Partition Magic 8.0, which owns a boot manager called boot magic, yet it can't handle partitions far from 1024 cylinder, even if they're primary.

Some months ago I tried SUSE 8.1 and I can tell its installation of GRUB in the MBR was impressive 'cause everything could run fine.

Now with Debian is more difficult, perhaps I should try LILO even though I got trouble with the MBR using other linux distributions.

There's another way, luckly. I heard about GAG, a spanish boot manager which can handle up to 9 OS, it can boot logical partitions too. I gonna try that, I think.
Just a question: if I install GAG or another boot manager I need LILO or GRUB too?

See you.
 
Old 10-30-2003, 01:15 PM   #5
zaltar
Member
 
Registered: Mar 2003
Distribution: Slackware 10.1
Posts: 44

Original Poster
Rep: Reputation: 15
Thanx about bootpart, it'll surely be useful.

So I gotta install GRUB in hda not hda1, right?

If something goes wrong I grab bootpart, hoping I can make it fit into Win98SE rescue floppy.

As I said I got Win98SE on hda1 and Debian (every part of it) on hda10, can you show me how I should install GRUB to make it work fine?

I used this commands after entering grub from a terminal:

root (hd0,9)

install /boot/grub/stage1 d (hd0,0) /boot/grub/stage2 p /boot/grub/menu.lst

What do you think about that?
 
Old 10-30-2003, 01:22 PM   #6
Demonbane
LQ Guru
 
Registered: Aug 2003
Location: Sydney, Australia
Distribution: Gentoo
Posts: 1,796

Rep: Reputation: 47
just copy bootpart.exe it into your c: then run it there if necessary
ok when you do "root (hd0,9)" you see your debian partition type printed correctly right?
if that is the case then simply do
setup (hd0)
and it will install grub into MBR
but of course you gotta have grub config files in /boot/grub in your debian partition(or /boot partition)
 
Old 10-30-2003, 02:25 PM   #7
zaltar
Member
 
Registered: Mar 2003
Distribution: Slackware 10.1
Posts: 44

Original Poster
Rep: Reputation: 15
Bootpart can run directly from the hard disk and I can invoke it using the DOS prompt? cool.

About the message: yes, grub tell me it's an ext2 partition and since I got only 1 ext2 partition I guess it's right.

About the configuration files: if you mean stage1, stage2 and co. they're in /boot/grub.

 
Old 11-17-2003, 02:50 AM   #8
aus9
LQ Guru
 
Registered: Oct 2003
Posts: 5,124

Rep: Reputation: Disabled
zalter

I tried gag, its a boot manager rather than a boot loader....so you will need lilo or grub on each linux partition root to use gag.

(2) read this http://www.tldp.org/HOWTO/Linux+Win9...roc.html#AEN54
http://www.gnu.org/manual/grub-0.92/html_mono/grub.html

If that does not scare you, heh heh, post your grubconf file, in mdk its my menu.1st file


win98 = hda1 = grub speak (hd0,0)
woody = hda12 = grub speak (hd0,11)
mbr = first 512 bytes of hda = grub speak (hd0)
 
Old 11-21-2003, 09:11 AM   #9
zaltar
Member
 
Registered: Mar 2003
Distribution: Slackware 10.1
Posts: 44

Original Poster
Rep: Reputation: 15
I'm replying late, anyway I've already solved my problem installing gag too.
Thanx, anyhow.
Bye.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Grub - fdisk /MBR lucho707 Linux - Software 1 12-01-2005 12:07 AM
Get rid of Grub on MBR pddm Slackware - Installation 3 11-24-2005 07:23 AM
Getting rid of GRUB on a partition (NOT MBR) KuRe Linux - Newbie 1 03-31-2005 09:06 PM
I can't get rid of linux, can't delete partition with fdisk Dachy Linux - Newbie 14 05-05-2004 02:25 PM
I did fdisk/mbr, how to install GRUB again? yarnar Linux - Software 4 12-13-2003 03:15 AM


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

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration