Welcome Guest ( Log In | Register )

      
Discover the best free computer help!
Learn more about Geeks to Go by taking the tour. Spyware, virus, trojan, fake security or privacy alerts? Read the malware cleaning guide.
 
Reply to this topicStart new topic
Can't access Linux, GRUB/MBR problems
The Admiral
post Aug 20 2008, 07:35 AM
Post #1


Tech Apprentice
Group Icon
Posts: 796
From: SL,UT
OS: Windows Vista, XP, Server 2003, Mac OS classic, Mac OS 10.x



Okay, long story short, I installed GRUB to the bootsector, but then overwrote the bootsector during the install of another OS. Is there a way I can boot into Linux and install GRUB to the Linux partition, or install GRUB to the partition without booting into it? My bootloader wants GRUB to be on the Linux partition, not the bootsector. Here's my partition table, MBR formatted:

Partition 1: NTFS (Vista)
Partition 2: NTFS (XP)
Partition 3: HFS+ (OSX)
Partition 4: Extended Partition
Partition 5: ext3 (maybe 2) (Ubuntu 8.06)
Partition 6: linux-swap (SWAP)
Go to the top of the page
 
+Quote Post
Tyger
post Aug 20 2008, 08:17 AM
Post #2


Member 2k
*****
Posts: 2,894
OS: win98, xp, winME



Whenever you want to add another operating system to a disk it's a good idea to save your boot sector to a file so that you can restore it if need be. It's very simple to do using the dd command:

dd if=/dev/sda bs=512 count=1 of=/boot/bootsector.img

done in root mode will save the file to the boot directory. Then you can use a live CD to restore the boot sector at will.

That being said, what you do in your particular case depends on what operating system replaced the boot sector. You could just use your live CD to redo the BS with grub, or you could use a Linux based repair disk to install grub. You will likely have to do some rewriting of the various configuration files. It it's Windows XP that replaced grub you could download grub4dos, which also has fat32 and ntfs versions of grub, and use the Windows boot sector in conjunction with grldr to boot the various operating systems. You would also need to do some configuration.
Go to the top of the page
 
+Quote Post
The Admiral
post Aug 20 2008, 08:30 AM
Post #3


Tech Apprentice
Group Icon
Posts: 796
From: SL,UT
OS: Windows Vista, XP, Server 2003, Mac OS classic, Mac OS 10.x



Well it isn't necessarily the bootsector that's the problem - the bootsector is how I want it. Right now, the bootloader is Darwin, which is OSX's. I like it mucho.

So I could just use the Ubuntu LiveCD to install Ubuntu again, this time with GRUB to the partition itself? Would that be easier than trying to install GRUB directly off the disk?
Go to the top of the page
 
+Quote Post
Tyger
post Aug 20 2008, 10:37 AM
Post #4


Member 2k
*****
Posts: 2,894
OS: win98, xp, winME



If you're going to be multibooting you might want to study a bit on how grub and bootloaders in general work. If you don't have any boot directory on your Ubuntu partition you would need to install grub to it. If you do have a boot directory you can probably make it boot without doing a reinstallation.

Grub itself has three parts, the part that installs on the boot sector, the 1.5 parts which access the file system on the bootable partition and the part2 which is the actual boot loader. You can probably just use the live CD to install grub to the Ubuntu partition without resinstalling but I don't use Ubuntu so I can give you any advice about that. Then you would have to use Darwin to chainload, there again I can't help you.
Go to the top of the page
 
+Quote Post
The Admiral
post Aug 20 2008, 10:46 AM
Post #5


Tech Apprentice
Group Icon
Posts: 796
From: SL,UT
OS: Windows Vista, XP, Server 2003, Mac OS classic, Mac OS 10.x



Okay, I'll check for a /boot when I get home. No chainbooting in this situation, Darwin is basically a bootloader of bootloaders, so selecting Vista from the Darwin prompt will load the BCD and show me a boot menu for Vista. Selecting XP will load boot.ini and show me a boot screen. Normal behavior for selecting Ubuntu would be to show GRUB, indicating that the bootloader is installed on the partition, not in the bootsector, because that's where Darwin is.

Also, if the GRUB is there and just not showing up in Darwin, which partition would I have to set to bootable to boot to Ubuntu; the extended partition or Ubuntu's logical partition?

This post has been edited by The Admiral: Aug 20 2008, 10:47 AM
Go to the top of the page
 
+Quote Post
silverbeard
post Aug 20 2008, 03:29 PM
Post #6


Trusted Tech
Group Icon
Posts: 686
OS: multi-boot (SimplyMepis/Ubuntu Server 64bit/Debian Etch 64bit/WinXP/Vista SP1)



The GRUB Page might be helpful.

The GRUB Manual has a lot to offer also.

GRUB can be installed on the /root partition you just need a way to point Darwin(?) to it. Or load GRUB to another boot media and use that to load Ubuntu.
Go to the top of the page
 
+Quote Post
The Admiral
post Aug 21 2008, 10:58 AM
Post #7


Tech Apprentice
Group Icon
Posts: 796
From: SL,UT
OS: Windows Vista, XP, Server 2003, Mac OS classic, Mac OS 10.x



Meh. I gave up, and decided to just reinstall Linux. But I have Fedora 9 on my USB flash drive, so I thought I'd just install F9 over Ubuntu. Worked great, and now I'm posting from F9! smile.gif
Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 

Collapse

> Similar Topics

    Topic Title Replies / Views Topic Information
No New Posts   4 / 195 2nd October 2008 - 07:20 PM
mlovelace started - last by hfcg
No New Posts 1 / 153 9th October 2008 - 02:32 PM
subcrew_react started - last by dsenette
No New Posts   2 / 136 6th November 2008 - 03:43 PM
JWD49 started - last by JWD49
No New Posts   0 / 348 10th November 2008 - 05:13 PM
Erixas started - last by Erixas

RSS Time is now: 1st December 2008 - 08:30 PM
Advertisements do not imply our endorsement of that product or service. The forum is run by volunteers who donate their time and expertise. We make every attempt to ensure that the help and advice posted is accurate and will not cause harm to your computer. However, we do not guarantee that they are accurate and they are to be used at your own risk.