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 |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
|
09-07-2003, 07:48 PM
|
#1
|
LQ Newbie
Registered: Sep 2003
Posts: 19
Rep:
|
Using GRUB for a dual-boot XP/RH9
Hello all,
I'm new at this, so forgive me if this has been answered before.
I have Win XP on my machine, and used Partition Magic to create a Linux partition, and a SWAP partition on my drive. Everything went OK, and I installed Linux with few problems. However, once I restart my computer, GRUB only shows Linux as the available operating systems to boot into. I went into XP's Recovery Console and tried a fixmbr, and now when I start up, I just get the message "No operating system found." What can I do to get them back? I know XP is still there, because I can go back into the recovery console, and all the files are there. I just can't boot. I didn't make a boot disk upon installation because my floppy drive does not work. Thanks!
|
|
|
09-07-2003, 07:56 PM
|
#2
|
Member
Registered: Jun 2003
Distribution: Fedora 9 64bit, RHEL 4.6
Posts: 96
Rep:
|
since you made no rescue floppy, I don't know many ways to rescue your linux system.
You could use a "live CD" like Knoppix to rewrite grub.conf is you have one available.
As for "No OS found". I always use a win98 startup disk (even on my NT machines) and do a fdisk /mbr to rewrite the windows MBR and it hasn't failed yet.
|
|
|
09-07-2003, 08:14 PM
|
#3
|
LQ Newbie
Registered: Sep 2003
Posts: 19
Original Poster
Rep:
|
Reovery console won't let me type fdisk /mbr. It says that command is not recognized. I then tried fixboot C:, and it wrote a new MBR to the C: drive, but that didn't help either. I'm not so worried about getting Linux back, as I just installed it, but I would like to get XP back, so I can try again.
|
|
|
09-07-2003, 08:42 PM
|
#4
|
Senior Member
Registered: Feb 2001
Location: Montreal, Quebec, Canada
Distribution: RedHat, Fedora, CentOS, SUSE
Posts: 1,403
Rep:
|
You can use the RedHat9 CD to boot into Rescue Mode.
Booting into Rescue Mode
http://www.redhat.com/docs/manuals/l...mode-boot.html
Once booted, you can install GRUB back into the MBR.
Code:
/sbin/grub-install /dev/hda
If you want winXP to appear in the GRUB menu, you will have to edit /boot/grub/grub.conf
For example:
Code:
title WindowsXP
rootnoverify (hd0,0)
chainloader +1
|
|
|
09-07-2003, 10:21 PM
|
#5
|
LQ Newbie
Registered: Sep 2003
Posts: 19
Original Poster
Rep:
|
Thanks Mathieu!
I've got Linux back and working now, but when I select WindowsXP, I get a message saying "NTLDR is missing. Press any key to restart." I'm hesitant to do anything for fear of losing Grub again. Any ideas?
|
|
|
09-07-2003, 11:28 PM
|
#6
|
LQ Guru
Registered: Aug 2003
Location: Sydney, Australia
Distribution: Gentoo
Posts: 1,796
Rep:
|
go in the xp recovery console again do you see NTLDR in root(C:\)?
actually can you describe how your harddisk is partitioned now?
|
|
|
09-07-2003, 11:35 PM
|
#7
|
LQ Newbie
Registered: Sep 2003
Posts: 19
Original Poster
Rep:
|
I have a 120GB hard drive, partitioned with a 80GB NTFS Windows XP partition, then a 500MB Linux SWAP partition, followed by a 35GB Linux partition.
|
|
|
09-07-2003, 11:38 PM
|
#8
|
Senior Member
Registered: Mar 2003
Location: New York, NY
Distribution: Debian Testing
Posts: 1,286
Rep:
|
this is offtopic - but im jealous of the 120g hd u have.
|
|
|
09-07-2003, 11:40 PM
|
#9
|
LQ Newbie
Registered: Sep 2003
Posts: 19
Original Poster
Rep:
|
Quote:
Originally posted by h/w
this is offtopic - but im jealous of the 120g hd u have.
|
Haha dont be. I had an 80 Gig drive that I lost to a power surge, so then I bought a 100 Gig drive that I lost to another power surge (2 months after the first), so I went out an bought a UPS and this 120 Gig drive (on sale at Circuit City for $100), and then another power surge hit, and my stupid UPS blew out my cpu power supply....ergh!!!
|
|
|
09-07-2003, 11:42 PM
|
#10
|
Senior Member
Registered: Mar 2003
Location: New York, NY
Distribution: Debian Testing
Posts: 1,286
Rep:
|
maybe u should resolve ur power issues b4 all this? hehe
wht r those things called that u need? surge-protectors?
|
|
|
09-08-2003, 06:17 AM
|
#11
|
Member
Registered: Sep 2003
Distribution: slackware
Posts: 85
Rep:
|
im am new to linus so i'll be humble and keep this brief but i fhave had hours of fun with windows bootloader that dont work stick with grub or change to lilo linux can recognize windoze but windoze cant recognize linux. any the problem with missing NTLDR is not ntdlr but the boot.ini is confused somehow or over written it happened to when i first started partitioning a lot when dual booted xp pro and win2k3 two nt systems dont work that well either. so anyway try fix / mbr again from recovery console, then check windows will boot then use your linux distro cd to setup lilo or grub i have never used grub so cant say if its better or worse but i can say that lilo is quite good at recognizing windoze
hope this helps
Last edited by oobe; 09-08-2003 at 06:19 AM.
|
|
|
09-08-2003, 06:57 AM
|
#12
|
LQ Newbie
Registered: Jul 2003
Posts: 11
Rep:
|
How many primary partitions do u have?
If it is more than one, use the grub command 'hide' to hide all but one primary partition(c .
|
|
|
09-08-2003, 10:39 AM
|
#13
|
Senior Member
Registered: Sep 2003
Posts: 3,171
Rep:
|
I have encountered this particular problem under circumstances not unlike those you describe. In my case, the damaged system was Windows NT. It took awhile, but I finally discovered that I had a problem with the volume boot record (not the master boot record) which - IIRC - had the wrong block size in it. As a consequence, I could not boot using the hard drive, but I could boot using a boot floppy.
You should construct an XP boot floppy. To do this you have to get into XP (I think). If you can't get into your XP, get into someone else's. You can also use Win NT or Win 2000.
Open a command line window, insert a floppy into the drive, and type this command:
format a:
This will write the proper XP volume boot record to the floppy.
Then, copy these files from the boot partition of YOUR Win XP system to the floppy:
boot.ini
ntldr
ntdetect.com
If you can't access the XP partition from XP, then mount it from Linux (you will need ntfs support in your kernel probably) and copy the files that way.
After you have done this, reboot your machine and make sure BIOS is set so that you boot first from floppy. Insert your boot floppy.
If everything goes well, the system will boot the floppy, transfer control to your XP system, and up it will come. If this works, then it absolutely confirms that your XP volume boot record is bad.
Once you have established this, you will need to obtain DiskProbe from here:
http://www.dynawell.com/support/ResK....asp#DiskTools
Using DiskProbe you will be able to recover your NTFS volume boot block, if you know how. It might work to copy the backup boot block from the end of the NTFS partition to the beginning. If that doesn't work, you will have to manually edit it. This can be painful, but I can help you with it if you get to that point.
|
|
|
09-10-2003, 10:36 PM
|
#14
|
LQ Newbie
Registered: Sep 2003
Posts: 19
Original Poster
Rep:
|
Well, I tried all of the above, and XP is being bitchy. It won't format ("you cannot format removable media"), and it won't copy anything to my A: drive ("access is denied"). My laptop has XP, but I don't have a floppy drive to use. Is there a way I can make a boot CD on my laptop, and use that on my desktop (where the problems are?). I'll look into adding NTFS support to Linux via the kernel, but Im still very new to Linux, so I'm pretty apprehensive about playing with the kernal.
|
|
|
09-10-2003, 11:11 PM
|
#15
|
LQ Newbie
Registered: Sep 2003
Posts: 19
Original Poster
Rep:
|
I installed the NTFS support-driver, and was able to copy boot.ini, and ntldr to my floppy (can you format a windows floppy in Linux?), but it would not let me copy ntdetect.com. It kept saying that it did not have read-write privlages. I'm about to give up, this is beyond annoying now!
|
|
|
All times are GMT -5. The time now is 12:39 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|