LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 10-21-2010, 10:00 PM   #1
theKbStockpiler
Member
 
Registered: Sep 2009
Location: Central New York
Distribution: RPM Distros,Mostly Mandrake Forks;Drake Tools/Utilities all the way!GO MAGEIA!!!
Posts: 986

Rep: Reputation: 53
Unhappy Multiple booting from two drives assistance needed.


I installed three O.S on one drive. I disconnected this drive and installed two more OS's on the the next drive. On the first drive all three were bootable and on the second only the first O.S. would boot. The second drive booted both O.S at first and then stopped. I used a rescue disk on the second drive with two on it and it made no difference. I did the same to the first drive and I sort of joined the to boot loaders together in a non appreciative way.

Is is practical to do what I tried doing and should I just multiboot off one drive? I would like about eight O.S's on the same computer.


Thanks in advance!
 
Old 10-22-2010, 05:28 AM   #2
Mr. Bit
LQ Newbie
 
Registered: Jun 2006
Posts: 6

Rep: Reputation: 3
Quote:
Is is practical to do what I tried doing and should I just multiboot off one drive?
It is absolutely practical to do what you're trying to do, but I think you're overcomplicating your situation by swapping disks in and out... Let's assume you're using grub or grub2 as your boot loader...

Quote:
I installed three O.S on one drive. I disconnected this drive and installed two more OS's on the the next drive.
OK, when you installed the OS'es the grubs would have been configured with just the drives/OS'es it knew about.

When you put the two drives live together, the available grubs' configurations would have been messed up.

Quote:
On the first drive all three were bootable and on the second only the first O.S. would boot. The second drive booted both O.S at first and then stopped.
I think that's why the OS stopped booting.

Quote:
I used a rescue disk on the second drive with two on it and it made no difference. I did the same to the first drive and I sort of joined the to boot loaders together in a non appreciative way.
Ok, well a rescue disk is good, and joining the boot loaders is ok, it is just the manner in which you do it which is important: Assuming you're currently booting off the MBR of the first disk and pointing at the /boot/grub configuration on the second disk (e.g. that's my current config), you can use the rescue disk to harvest all the 'other' grubs' configurations (the menu.lst or grub.cfg files) and select/edit the lines describing the additional OSes into the one config file in the active boot partition. If you've been adding and removing disks during the installs, you may need to play with the
Code:
root (hd0,0)
entries to align it with your current hardware configuration. For example, change it to
Code:
root (hd1,0)
Don't forget, you only need one MBR active and it needs to point to only one /boot/grub configuration file to get all your OSes accessible.

If you have any more problems, paste the output of
Code:
sfdisk -l
and your grub config file.

Quote:
I would like about eight O.S's on the same computer.
It is possible - only the disk space is your limiting factor - but you'll probably need to get into extended partitions to do so, and share swap space amongst the linux OS'es. But have you ever considered creating VMs for the OSes you want to play with? A VM means you can have as many OS'es as you want running at the same time...

HTH
 
1 members found this post helpful.
Old 10-22-2010, 06:26 AM   #3
JZL240I-U
Senior Member
 
Registered: Apr 2003
Location: Germany
Distribution: openSuSE Tumbleweed-KDE, Mint 21, MX-21, Manjaro
Posts: 4,629

Rep: Reputation: Disabled
Sharing swap is only reasonable, I do it all the time. You need about 10 GB in average for a distribution. With disks in excess of 2 TB available compute for yourself how many you can put on a disk . Here is a link to: GRUB How to install and boot 145 operating systems

http://www.justlinux.com/forum/showthread.php?t=147959
 
1 members found this post helpful.
Old 10-22-2010, 01:07 PM   #4
theKbStockpiler
Member
 
Registered: Sep 2009
Location: Central New York
Distribution: RPM Distros,Mostly Mandrake Forks;Drake Tools/Utilities all the way!GO MAGEIA!!!
Posts: 986

Original Poster
Rep: Reputation: 53
Iv'e even started drinking "I mean" using WINE again.

I Googled "Boot Manager" today but I have made it this far so I will try to edit Grub which it looks like you are recommending.If all fails I will try something like "Gag". I could not find a decent guide to Grub but trying to configure it will probably have better results. I have been reading MS guides for info and even using WINE!

If possible it would be great to know What Grub stores and Where it stores it.
 
Old 10-22-2010, 01:32 PM   #5
yancek
LQ Guru
 
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 10,492

Rep: Reputation: 2488Reputation: 2488Reputation: 2488Reputation: 2488Reputation: 2488Reputation: 2488Reputation: 2488Reputation: 2488Reputation: 2488Reputation: 2488Reputation: 2488
Quote:
If possible it would be great to know What Grub stores and Where it stores it
It would be helpful to members if you posted the operating systems you are using because some use Grub2, others use Grub Legacy and others still use Lilo.

Here's a link to Grub Legacy documentation:

http://www.gnu.org/software/grub/manual/legacy/

And to Grub2 tutorial:

http://www.dedoimedo.com/computers/grub-2.html
 
1 members found this post helpful.
Old 10-22-2010, 06:46 PM   #6
theKbStockpiler
Member
 
Registered: Sep 2009
Location: Central New York
Distribution: RPM Distros,Mostly Mandrake Forks;Drake Tools/Utilities all the way!GO MAGEIA!!!
Posts: 986

Original Poster
Rep: Reputation: 53
I'm booting into Mandriva 10 presently.

I'm wondering if having two Mandriva's 10 and 08 is causing an issue? The last time I tried to load some O.S's I attempted to get 1 version of XP and Mandriva 08 on the first IDE drive and Mandriva 10 on the second which is a SATA. The boot loader found a good version of XP on the second drive from before so I was going to leave it. What happens in my closet with me and my computer is my business. That is going to be added to my sig. next.


The rescue disks I presenly have allow the use of a terminal and just reinstall the boot loader. I got this Grub file from Mandriva 10 and this is the fdisk for it as well.


Quote:
timeout 10
color black/cyan yellow/cyan
gfxmenu (hd1,5)/boot/gfxmenu
default 0

title linux
kernel (hd1,5)/boot/vmlinuz BOOT_IMAGE=linux root=UUID=c05235e9-0f5d-404c-824f-28dd338be6a3 splash=silent vga=788
initrd (hd1,5)/boot/initrd.img

title linux-nonfb
kernel (hd1,5)/boot/vmlinuz BOOT_IMAGE=linux-nonfb root=UUID=c05235e9-0f5d-404c-824f-28dd338be6a3
initrd (hd1,5)/boot/initrd.img

title failsafe
kernel (hd1,5)/boot/vmlinuz BOOT_IMAGE=failsafe root=UUID=c05235e9-0f5d-404c-824f-28dd338be6a3 failsafe
initrd (hd1,5)/boot/initrd.img

title windows
root (hd1,0)
map (0x81) (0x80)
map (0x80) (0x81)
makeactive
chainloader +1

title windows1
root (hd0,0)
makeactive
chainloader +1

title Mandriva Linux (Official)
root (hd0,4)
configfile /boot/grub/menu.lst




[root@localhost KbS]# sfdisk -l

Disk /dev/sda: 19457 cylinders, 255 heads, 63 sectors/track
Units = cylinders of 8225280 bytes, blocks of 1024 bytes, counting from 0

Device Boot Start End #cyls #blocks Id System
/dev/sda1 * 0+ 2549 2550- 20482843+ 7 HPFS/NTFS
/dev/sda2 2550 10388 7839 62966767+ 5 Extended
/dev/sda3 0 - 0 0 0 Empty
/dev/sda4 0 - 0 0 0 Empty
/dev/sda5 2550+ 2740 191- 1534176 82 Linux swap / Solaris
/dev/sda6 2741+ 10388 7648- 61432528+ 83 Linux

Disk /dev/sdb: 60801 cylinders, 255 heads, 63 sectors/track
Units = cylinders of 8225280 bytes, blocks of 1024 bytes, counting from 0

Device Boot Start End #cyls #blocks Id System
/dev/sdb1 * 0+ 6373 6374- 51199123+ 7 HPFS/NTFS
/dev/sdb2 6374 12938 6565 52733362+ 5 Extended
/dev/sdb3 0 - 0 0 0 Empty
/dev/sdb4 0 - 0 0 0 Empty
/dev/sdb5 6374+ 12747 6374- 51199123+ 83 Linux
/dev/sdb6 12748+ 12938 191- 1534176 82 Linux swap / Solaris
[root@localhost KbS]#
The IDE drive is a 160 gig and the SATA is a 500 gig.
 
Old 10-22-2010, 07:53 PM   #7
Mr. Bit
LQ Newbie
 
Registered: Jun 2006
Posts: 6

Rep: Reputation: 3
Quote:
I'm booting into Mandriva 10 presently.
I'm wondering if having two Mandriva's 10 and 08 is causing an issue?
No.

Quote:
The rescue disks I presenly have allow the use of a terminal and just reinstall the boot loader.
I find a Puppy Linux CD can be a faithful friend in times of need.

Quote:
I got this Grub file from Mandriva 10 and this is the fdisk for it as well.

gfxmenu (hd1,5)/boot/gfxmenu
I would say that translates as follows...
hd1=disk sdb
5=partition 5 (sdb5)
Which means you're counting from 1 and that entry maps to a valid partition in your sfdisk -l output
(stay with me here...)

Quote:
kernel (hd1,5)/boot/vmlinuz BOOT_IMAGE=linux root=UUID=c05235e9-0f5d-404c-824f-28dd338be6a3 splash=silent vga=788
initrd (hd1,5)/boot/initrd.img
kernel (hd1,5)/boot/vmlinuz BOOT_IMAGE=linux-nonfb root=UUID=c05235e9-0f5d-404c-824f-28dd338be6a3
initrd (hd1,5)/boot/initrd.img
kernel (hd1,5)/boot/vmlinuz BOOT_IMAGE=failsafe root=UUID=c05235e9-0f5d-404c-824f-28dd338be6a3 failsafe
initrd (hd1,5)/boot/initrd.img
Which means all these are valid entries pointing to /dev/sdb5
(which exists...)

Quote:
title windows
root (hd1,0)
map (0x81) (0x80)
map (0x80) (0x81)
makeactive
chainloader +1
BTW1. I'd say that the "map" entries are a byproduct of you swapping disks in and out.
BTW2. I would expect to see a "rootnoverify" entry for Win OSes.. but if it works for you...

So, if you're *still* counting from 1, this is /dev/sdb0
Which doesn't exist in your sfdisk -l output...
(still with me?...)

mmm...

(so, it's broken...what to do?)

Ok, lets work backwards...

If this entry were to be valid, it must point to /dev/sdb1
But then you're counting from zero
Which means the (hd1,5) entries above should really be
Quote:
kernel (hd1,4)

(ok, seems reasonable, so lets pursue this idea...)

Quote:
title windows1
root (hd0,0)
makeactive
chainloader +1
Now, IF we revert to counting from zero THEN we're pointing to the /dev/sda1 NTFS entry. Good. We can see that one.


So the conclusion is:
Your config file is: Sometimes zero, sometimes one...

Can you see how grub could be getting all mixed up?


Therefore, start from scratch:
If you work from the premise that
Quote:
/dev/sda = hd0
and
/dev/sdb = hd1
AND

you count from 1

THEN

Quote:
/dev/sda1 * 0+ 2549 2550- 20482843+ 7 HPFS/NTFS = (hd0,1)
/dev/sda6 2741+ 10388 7648- 61432528+ 83 Linux = (hd0,6)
/dev/sdb1 * 0+ 6373 6374- 51199123+ 7 HPFS/NTFS = (hd1,1)
/dev/sdb5 6374+ 12747 6374- 51199123+ 83 Linux = (hd1,5)
ALTERNATIVELY, IF

you count from 0

THEN

Quote:
/dev/sda1 * 0+ 2549 2550- 20482843+ 7 HPFS/NTFS = (hd0,0)
/dev/sda6 2741+ 10388 7648- 61432528+ 83 Linux = (hd0,5)
/dev/sdb1 * 0+ 6373 6374- 51199123+ 7 HPFS/NTFS = (hd1,0)
/dev/sdb5 6374+ 12747 6374- 51199123+ 83 Linux = (hd1,4)
Well, that's my thought processes laid bare: Follow one or other of those numbering conventions, and I believe you'll be closer to a series of mappings that will work for you.

I hope it helps with your issue.

Regards!
 
1 members found this post helpful.
Old 10-22-2010, 09:43 PM   #8
theKbStockpiler
Member
 
Registered: Sep 2009
Location: Central New York
Distribution: RPM Distros,Mostly Mandrake Forks;Drake Tools/Utilities all the way!GO MAGEIA!!!
Posts: 986

Original Poster
Rep: Reputation: 53
I found a Arch tutorial and managed to get the grub terminal output/

One of the better guides I have read is http://wiki.archlinux.org/index.php/GRUB and ran "grub> find /boot/grub/stage1" which returned "(hd0.5) and (hd1,4) if it matters.


This is from the device map from /grub/mapfolder (hd0) /dev/sdb (hd1) /dev/sda



Thanks for your expertise!

Last edited by theKbStockpiler; 10-22-2010 at 10:14 PM. Reason: Add more confusion
 
Old 10-23-2010, 05:59 PM   #9
Mr. Bit
LQ Newbie
 
Registered: Jun 2006
Posts: 6

Rep: Reputation: 3
Quote:
... which returned "(hd0.5) and (hd1,4) if it matters.
Well that's encouraging since that matches the linux partitions when you count from zero (see previous post):

Code:
/dev/sda6 2741+ 10388 7648- 61432528+ 83 Linux = (hd0,5)
/dev/sdb5 6374+ 12747 6374- 51199123+ 83 Linux = (hd1,4)
 
Old 10-24-2010, 01:42 AM   #10
theKbStockpiler
Member
 
Registered: Sep 2009
Location: Central New York
Distribution: RPM Distros,Mostly Mandrake Forks;Drake Tools/Utilities all the way!GO MAGEIA!!!
Posts: 986

Original Poster
Rep: Reputation: 53
I don't think that Grub is all that Grand right now.

I spent close to twenty hours on this and I can not find the info to go about this in an educated manner. I can understand the guides I read but they don't have enough info to do anything. If you have a problem with Grub you need to manually re-write your list file and no one on the Web knows how to do it but they can manage to write a guide for doing nothing. I'm sure their sites get a lot of hits though.

Here are some things I have learned from fooling with it.

Grub will only rewrite its MBR. Whatever the code does that runs it is mostly a mystery. The code tries to blindly fix the MBR. I tried it enough times that it would not boot at all. Grub will make a boot menu list of operating systems and not be able to boot them. You get the # 18 error.
If you put more than two OS on Grub it makes another boot menu so you first choose from one menu and go to another menu. This time around I installed XP Pro and Mandriva 08 on the first drive with Mandriva 10 on the second while leaving all the drives hooked up. When you go to the boot menu it lists O.S's it can't boot as well. When you reinstall a Linux Distro the install software will find old windows Versions and accurately put them on the menu but not the old Linux ones. If you put the MBR on a partition it will not load Grub. The set up menu (delete button) of BIOS just selects which drive to use the MBR from. Grub will use either drive natively if left on either (boot from setting).God knows why it is there anyway.

I don't think Grub is good enough to boot more than two O.S's. I had to repartition the drives with a windows installer to re-install a Linux with Grub. It would hang while booting the only Linux distro along with XP. Grub is using old info while installing fresh. Incidentally some times windows won't install on a Raw drive. It likes to go over another O.S so long as it is newer than it. It will just hang during the hardware stage.

So my advice to anyone is not to put more than two O.S's on Grub unless you know someone personally that can assist you with it. Saying the term "chainload" does not give you the ability to do it. I'm going to get some software that can help document what Grub does. I have the link stored on a thumb drive in Abiword but I don't have Abiword on this Distro yet so I will have to edit it in later. Trying something like Gag has got to be the more practical than fooling with Grub and not being able to obtain info to change the list file. If you can't build one from scratch you don't have the expertise to re-write it.

Thanks to everyone and especially Mr.Bit for your help! It allowed me to search for more info. Maybe I can find some stuff on Grub2 down the line.



Edit: this is the link for the software I mentioned.http://www.cgsecurity.org/wiki/TestDisk_Download


Here are the best links I could find for Grub that have actual information. I would like to thank the people that are responsible for keeping them on the Web!
http://www.gnu.org/software/grub/man...#Configuration

http://tldp.net/HOWTO/Remote-Serial-...WTO/index.html
http://mirror.href.com/thestarman/asm/mbr/GRUB.htm
http://www.centos.org/docs/5/html/In...ub-whatis.html
http://mirror.href.com/thestarman/asm/mbr/GRUB.htm
http://www.pcguide.com/byop/byop_Wor...Bootloader.htm

The Grub manual has a lot of info presented in a confusing way.
http://www.gnu.org/software/grub/manual/grub.html

Last edited by theKbStockpiler; 10-28-2010 at 12:20 AM.
 
  


Reply



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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Multiple Blade servers booting from multiple disk drives simultaneously NGC_cheryl Linux - Enterprise 0 11-26-2007 08:38 AM
multiple booting two hard drives with linux distros slim case Linux - Newbie 3 07-04-2005 09:02 PM
Booting with multiple hard drives Sledge Linux - Newbie 4 01-17-2005 10:44 PM
Advice needed on FC2 partitioning and multiple drives dbruso Linux - Newbie 2 09-14-2004 03:35 PM
Dual Booting with XP, multiple Hard Drives and LILO problems melliott Linux - General 15 01-21-2004 12:34 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 11:27 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
Open Source Consulting | Domain Registration