LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 01-20-2008, 02:23 PM   #1
.dllmigraine
LQ Newbie
 
Registered: Sep 2007
Posts: 21

Rep: Reputation: 15
Exclamation Stuck in grub


Hi:

I deleted the partition for Fedora 7 vai gparted. I have a Knoppix live iso, but I don't know how to boot from it via grub. Even after configuring
boot sequence via BIOS, I still go right back to grub.

B.T.W.- GNU Grub ver. 0.97


Any assistance would be appreciated.


Thanks,

Steve
 
Old 01-20-2008, 02:43 PM   #2
hal8000b
Member
 
Registered: Mar 2001
Location: UK
Distribution: Mint, Arch, Debian7
Posts: 189

Rep: Reputation: 23
I'm not sure if you are asking how to remove grub and restore windows, or how to repair grub, so I'll answer both.


Boot with your knoppix ISO, set your BIOS to boot from CDROM.


To remove grub.
At a konsole type
sudo fdisk -l

this will list your partitions, your HD will be either sda or hda.

To remove grub type
sudo install-mbr /dev/hda

(replace hda with your HD)



To repair grub:
You need to know which is your Fedora root partition, boot into knoppix then type
fdisk -l

this will list all partitions, you will also see them on KDE desktop so you can browse partitions.

Suppose your Fedora /partition is /dev/hda5

You need to mount this partition as rw, so at a konsole

sudo mount -o dev,rw /mnt/hda5

(change hda5 with your / partition )
then change root into the mount partition

chroot /dev/hda5

Finally install grub:
grub-install /dev/hda

(note the last command is the hard drive, not a partition, so hda writes grub to the mbr of hda, could be sda in your case)


Hope that helps
 
Old 01-20-2008, 03:12 PM   #3
.dllmigraine
LQ Newbie
 
Registered: Sep 2007
Posts: 21

Original Poster
Rep: Reputation: 15
Exclamation

Quote:
Originally Posted by hal8000b View Post
I'm not sure if you are asking how to remove grub and restore windows, or how to repair grub, so I'll answer both.


Boot with your knoppix ISO, set your BIOS to boot from CDROM.


To remove grub.
At a konsole type
sudo fdisk -l

this will list your partitions, your HD will be either sda or hda.

To remove grub type
sudo install-mbr /dev/hda

(replace hda with your HD)



To repair grub:
You need to know which is your Fedora root partition, boot into knoppix then type
fdisk -l

this will list all partitions, you will also see them on KDE desktop so you can browse partitions.

Suppose your Fedora /partition is /dev/hda5

You need to mount this partition as rw, so at a konsole

sudo mount -o dev,rw /mnt/hda5

(change hda5 with your / partition )
then change root into the mount partition

chroot /dev/hda5

Finally install grub:
grub-install /dev/hda

(note the last command is the hard drive, not a partition, so hda writes grub to the mbr of hda, could be sda in your case)


Hope that helps

Thanks for the assistance. I should have mentioned that I can't boot from the CD even after configuring the settings in BIOS. I'm just brought back to the same grub prompt:

grub>

Where minimal Bash-like line editing is supported. Absolutely perplexed by this.

Since I deleted the partition on the main (hd0), it doesn't recognize any
partition details for the obvious reason.

I really appreciate your thoughtful advice. I don't know much about Linux.

A possible solution may be to reconfigure master/slave settings for the HDD and CD/ROM drive. However, If I changed the respective jumpers to
HDD Primary slave, and CD/ROM Primary master, I'm not sure if the system
would boot in such a bizarre sequence.

I can't find any information on a command line in grub> which would direct a boot load from a specified cd/rom - very foreign environment for me.

Thanks again for any help.
 
Old 01-20-2008, 07:46 PM   #4
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 18,469

Rep: Reputation: 3084Reputation: 3084Reputation: 3084Reputation: 3084Reputation: 3084Reputation: 3084Reputation: 3084Reputation: 3084Reputation: 3084Reputation: 3084Reputation: 3084
Quote:
Originally Posted by .dllmigraine View Post
I can't boot from the CD even after configuring the settings in BIOS. I'm just brought back to the same grub prompt:
You can't boot any CD, or you can't boot the Windoze CD ???
 
Old 01-27-2008, 08:35 AM   #5
.dllmigraine
LQ Newbie
 
Registered: Sep 2007
Posts: 21

Original Poster
Rep: Reputation: 15
Exclamation

Quote:
Originally Posted by syg00 View Post
You can't boot any CD, or you can't boot the Windoze CD ???
No, I can't boot with any CD. I keep going back to grub. Although I share your disdain for 'Windowze', I need to put an OS that is a bit more learner friendly for my Father.


I'm planning on installing a compatible version of a Linux distribution on my Mac Book Pro and G5 Quad. Do you have any suggestions?

Thanks,

Steve
 
Old 01-30-2008, 12:46 AM   #6
.dllmigraine
LQ Newbie
 
Registered: Sep 2007
Posts: 21

Original Poster
Rep: Reputation: 15
O.K. I've spent several hours trying to work out a solution for this problem and ended up damaging my HDD's with critical information on one.

I even tried to populate a menu.lst, and received a read error.

I went through a variety of grub commands learning a bit of the syntax as I went along.

I'm left with my Asus board hanging a bit, and continuously returning the following error: Invalid System disk, replace the disk and press any key.

Prior to this, I found and old fdisk, and ran a variety of commands in grub while configuring the boot sequence through BIOS. Couldn't get anything to
happen.

Any and all advice would be appreciated. I need to get my HDD up and running and install a dual boot with a good Linux distro.

I'd be grateful to hear back from some of you experienced users.

Thanks
 
Old 01-30-2008, 02:57 PM   #7
.dllmigraine
LQ Newbie
 
Registered: Sep 2007
Posts: 21

Original Poster
Rep: Reputation: 15
Help? Please?
 
Old 01-30-2008, 03:43 PM   #8
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 18,469

Rep: Reputation: 3084Reputation: 3084Reputation: 3084Reputation: 3084Reputation: 3084Reputation: 3084Reputation: 3084Reputation: 3084Reputation: 3084Reputation: 3084Reputation: 3084
Sorry to hear you're still in strife. Is this a desktop or laptop ?.
Some (most ???) laptops have a "magic" key to allow you to select from a boot menu (F12 on most Dells), or to force a CD boot (<c> on my old Toshiba). Have a look in your user guide.
Else maybe pull the hard-disk out - simply remove one of the cables will suffice; this will prove you can boot the CD o.k. No reason you shouldn't be able to - won't help with the disk problem of course.
In need a I would use an external housing to get it connected just to repair the MBR - that's probably your problem. Likely the disk itself is o.k.
Poorly designed BIOS too by the sounds of it.

Last edited by syg00; 01-30-2008 at 03:47 PM. Reason: Addendum
 
Old 01-30-2008, 05:06 PM   #9
.dllmigraine
LQ Newbie
 
Registered: Sep 2007
Posts: 21

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by syg00 View Post
Sorry to hear you're still in strife. Is this a desktop or laptop ?.
Some (most ???) laptops have a "magic" key to allow you to select from a boot menu (F12 on most Dells), or to force a CD boot (<c> on my old Toshiba). Have a look in your user guide.
Else maybe pull the hard-disk out - simply remove one of the cables will suffice; this will prove you can boot the CD o.k. No reason you shouldn't be able to - won't help with the disk problem of course.
In need a I would use an external housing to get it connected just to repair the MBR - that's probably your problem. Likely the disk itself is o.k.
Poorly designed BIOS too by the sounds of it.
No, it's a desktop with an ASUS P4P800VM board, P4 3.2 Ghz, and 1.5 Gb of
RAM. I've never flashed the BIOS on this unit. And the design is crap.

Thanks for the suggestions.
 
  


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
Stuck with GRUB jaktomas1 Linux - General 2 01-04-2008 05:33 AM
Stuck at GRUB New2Linux06 Linux - Newbie 3 10-06-2007 03:21 PM
Grub stuck? Tov Linux - Newbie 3 11-17-2006 04:32 AM
Stuck on Grub linuxnoob360 Linux - Newbie 1 09-01-2004 04:30 PM
Ok, new at this and stuck in grub! some1 Slackware - Installation 6 08-12-2004 07:58 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 12:25 PM.

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