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-11-2008, 11:37 PM   #1
streams &dragonflies
Member
 
Registered: Sep 2007
Location: Canada
Distribution: (Ubuntu Studio, Ubuntu) & JAD (Suse 10.2)
Posts: 38

Rep: Reputation: 15
Question what is the real way for my bios to see my partition with a linux OS I want grub on?


I have serious booting problems in this round of multi linux OS installations.
In order to get around it I had to edit Suse's (Yast) menu.lst which is my master grub and my Hardy Ubuntu menu.lst (which I installed grub on the / of my slave disk and was trying to chainload) both via live CD gksudo nautilus so that both lists point to root in (hd2,1) although on this second disk grub sees itself as (hd1,1) with it's own device map perspective. The tricky thing is that Yast would change my chainloader entry differently and render my Ubuntu unbootable.

my entry:
title: Ubuntu
rootnoverify (hd2,1) as grub sees it
chainloader +1

but then Yast kept saving this entry as:

title
rootnoverify (hd0,0) which is where suse's master grub is
chainloader (hd2,1) +1

Also I had lost all my Gutsy Ubuntu boot files since I erased my separate boot partition (bios can't boot past 137 Gigs) by mistake and then I lost my Suse boot files in a previous install attempt with Ubuntu's install right afterwards. I would like to re-install my gutsy Ubuntu's grub to the boot partition.

If I succeed, I need to know how to read my Suse partition (hd0,11) since I want to keep it's own grub and boot files on it's root partition and not worry about any new grub installations on the separate boot partition wiping out the Suse boot files again. I will chainload openSuse from Ubuntu's grub. I then will re-install my hardy and chainload it from the other drive (I did not install all the packages off the Ubuntu Studio DVD, so I had no Xserver or gui- that's another question on my mind- the gui is not in the base packages?)

It seems that the 15 Gigs dedicated to openSuse are within the bootable sectors for my computer's bios, even though I created that partition later on so it is called sda11! Here is my fdisk output:

ubuntu@ubuntu:~$ sudo fdisk -l

Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x0002145b

Device Boot Start End Blocks Id System
/dev/sda1 * 1 24 192748+ 83 Linux
/dev/sda2 25 60558 486239355 f W95 Ext'd (LBA)
/dev/sda3 60559 60801 1951897+ 82 Linux swap / Solaris
/dev/sda5 7766 20825 104904450 83 Linux**********************Data
/dev/sda6 25728 43109 139620883+ 7 HPFS/NTFS
/dev/sda7 43110 54601 92309458+ 7 HPFS/NTFS
/dev/sda8 54602 60558 47849571 83 Linux********************Ubuntu gutsy/
/dev/sda9 4548 7765 25848553+ 7 HPFS/NTFS
/dev/sda10 20826 25727 39375283+ 7 HPFS/NTFS
/dev/sda11 25 2039 16185424+ 83 Linux ******************* openSuse /
/dev/sda12 2040 4547 20145478+ 83 Linux*********************/Susehome

Partition table entries are not in disk order

Disk /dev/sdb: 36.4 GB, 36420075520 bytes
255 heads, 63 sectors/track, 4427 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xc52e3703

Device Boot Start End Blocks Id System
/dev/sdb1 * 1 3046 24466963+ 7 HPFS/NTFS******************windows
/dev/sdb2 3047 4427 11092882+ 83 Linux********************/ubuntuH/home

Disk /dev/sdc: 18.4 GB, 18400000000 bytes
255 heads, 63 sectors/track, 2237 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xf34e1a69

Device Boot Start End Blocks Id System
/dev/sdc1 1995 2237 1951897+ 82 Linux swap / Solaris
/dev/sdc2 1 1994 16016773+ 83 Linux************************UbuntuHardy/

Partition table entries are not in disk order
ubuntu@ubuntu:~$


I will be installing everything back in the same place, any ideas would help...

Last edited by streams &dragonflies; 10-11-2008 at 11:44 PM. Reason: clarified which is which partition
 
Old 10-12-2008, 08:20 AM   #2
mk27
Member
 
Registered: Sep 2008
Distribution: fedora, gentoo, ubuntu
Posts: 148

Rep: Reputation: 23
You know you are really giving yourself a headache by using multiple grub.conf's (aka. menu.1st). GRUB can only use one of them anyway (that may be why things have gotten so confused). That's kind of the point: you have one bootloader for multiple partitions.

Pick one of those menu.1st's (you might as well use the one that you currently actually access at boot time -- notice there is not a choice of menus, there is a menu with choices) and erase the other one (or keep a copy to consult, but do not fool youself into believing that grub uses it). Just because you have multiple OS's on one machine DOES NOT mean that you need more than one installation of GRUB (in reality, since there is only one boot sector, you can not have more than one functional grub installation). As long as "root" in each entry points to the correct partition, and that partition contians a kernel, System.map, and (optionally) an initrd in the place you say they are, you will boot that partition (Ubuntu, Suse, whatever) fine even if the partition has absolutely no grub file on it at all. The kernel, the System.map, and the initrd ARE NOT part of grub. At all. You DO NEED a seperate set of those on each partition.

Of course, grub.conf must be on a partition somewhere, and what's installed on your boot sector points to that location and loads that grub.conf. If you have two linux's and a windows (like me), all you need is one menu.1st with three correct entries. Even if it's located on the "linux one" partition, you can still boot the "linux two" entry without having to worry about a distinct set of Suse/Ubuntu configuration files.

Post an actual copy of all the menu.1st's you think you are using if you need this clarified further.

(the easy way, since you are re-installing by the sound of things, will be to not opt for a grub installation from one disto. Then you go and edit the one grub.conf from the distro that did install it so that you have an entry for the other one.)

Last edited by mk27; 10-12-2008 at 08:26 AM.
 
Old 10-13-2008, 07:28 PM   #3
streams &dragonflies
Member
 
Registered: Sep 2007
Location: Canada
Distribution: (Ubuntu Studio, Ubuntu) & JAD (Suse 10.2)
Posts: 38

Original Poster
Rep: Reputation: 15
Thankyou for your reply, but shoot, I am pretty decided, after others advice and sites about booting, that chainloading is the best bet for me.

Last fall, when I had my 2 linux distros on the same drive, and I chose Ubuntu as the only grub (by mounting and formatting /boot and installing grub there) all went super smooth! Now that I had wanted to keep that Ubuntu version (for a while), install the latest Suse distro on same drive, next intall Ubuntu Hardy on my new SCSI and (as you say)-install its grub on /boot-making it the only grub well everything went haywire! ( I erased /boot before formatting it-don't ask!) Ubuntu's grub did not "detect" the other distros anymore! And all of their config, initrd, kernels were all gone, save a Gutsy boot.bkup I had- which is why I am paranoid now about the config. method, or singular grub for multibooting. At least with chainloading, you have all the bootfiles on each distro's / and you can only fudge up one distro at a time. Also the many sites claim that a separate /boot partition is only advisable when you have the grub error 18 (or similar) issue. The only alternative I see is to only let one distro- the one beyond the bios limit, have its bootfiles and grub on the /boot partition and then not install the other OS's grubs at all, which is sort of what you are advising.

Enough with the long story!- I really need to confirm:


What am I reading off of fdisk -l ? How is my bios seeing my partitions?

/dev# beginning end blocks?

Is it the "beginning" "end" (bytes on the disk) or the blocks? although they seem to be 2 ways of "seeing" the same thing.

This is a specification for my IDE limitations:

" ATA Specification (for IDE disks) - the 137 GB limit
At most 65536 cylinders (numbered 0-65535), 16 heads (numbered 0-15), 255 sectors/track (numbered 1-255), for a maximum total
capacity of 267386880 sectors (of 512 bytes each), that is,136902082560 bytes (137 GB). This is not yet a problem (in1999), but will be a few years from now."

taken from linuxPlanet Tutorials


So is my Suse distro within the beginning 137 Gigs thus and can boot fine?- or is grub still going to read the / at (hd2,11) and say that this partition is # too high and I am confused about this being an extended partition as it has it's own partition table with the logical partitions within...

Note: Refer back to my actual fdisk in my earlier post if you need to.

Last edited by streams &dragonflies; 10-13-2008 at 08:44 PM. Reason: added details
 
Old 10-13-2008, 10:09 PM   #4
CJS
Member
 
Registered: May 2008
Location: California, USA
Distribution: Ubuntu 8.10
Posts: 247

Rep: Reputation: 49
Quote:
Originally Posted by streams &dragonflies View Post
What am I reading off of fdisk -l ? How is my bios seeing my partitions?
On start up, Grub sees the order of drives as the same as the BIOS boot order, because on start up Grub must use BIOS to access the drives. But the BIOS boot order has nothing to do with the device order in Linux's /dev directory, because Linux works through the kernel (not through BIOS) to access the drives; Linux's /dev directory is ordered by the type of device, so for HDDs they would be ordered by whether they are IDE, SATA, USB, and so on. A good way to figure out the order of your drives on start up is to press "c" at the Grub menu to get the Grub CLI, then type in the following without pressing enter:
Code:
grub> geometry (hd
And press TAB for tab-completion to see a list of your drives, starting with (hd0). Then to see the size and partitions of a drive such as (hd1), use:
Code:
grub> geometry (hd1)
That should give you some clues as to how grub sees your drives on start up.
Quote:
Originally Posted by streams &dragonflies View Post
So is my Suse distro within the beginning 137 Gigs thus and can boot fine?- or is grub still going to read the / at (hd2,11) and say that this partition is # too high and I am confused about this being an extended partition as it has it's own partition table with the logical partitions within..
Your sda11 partition starts at about ~17 GB, so you should be fine.

Last edited by CJS; 10-13-2008 at 10:11 PM.
 
Old 10-14-2008, 12:11 AM   #5
streams &dragonflies
Member
 
Registered: Sep 2007
Location: Canada
Distribution: (Ubuntu Studio, Ubuntu) & JAD (Suse 10.2)
Posts: 38

Original Poster
Rep: Reputation: 15
Hi CJS,
thanks for the quick reply!
Well I found out that my stoopid computer that I still love (HP workstation circa 2001/02) had a latest bios flash which still reads things the older way, I think! When you edit the grub entry, you see that it's read root(hd0,11) and bios/grub message error 18! Selected cylinder exceeds maximum supported by BIOS. Even if I try the config.file way it still defaults to reading the root this way, so I can't boot into Suse without it being in the first 1023 cylinders/ 512 mb or maybe it's 8 GIGs, according to a LQWiki.

Also, I have an aside problem: I cp all my Ubuntu 7.10 bkup kernel and other files to my /boot part. and hoped for the best but that menu.lst entry starts up ubuntu / and one data part. (files read as clean) but fails (code 9) thanks to 2 partitions with long UUID #s says can't resolve- and I can only get into recovery mode shell and I have no idea what to do there!!! So I'm back on familiar ubuntu live cd and I end up doing gksudo nautilus mostly and some grub commands.... like my
disk geometry output furthur down!

I remember that I erased, created and moved partitions before wiping out my boot partition- and my boot bkup files do not reflect those new partition UUIDs. I don't know how to disable the automount of these partitions at boot time! According to docs, I can go into Ubuntu alternate disk's recovery mode, go backwards to partitioning section and then mount /BOOT and re-install grub there and remount the rest without changing/formatting all other partitions but I hope this is relatively data safe because I had way too big partitions to backup on DVDs and no budget for a bkup external drive to create bkups! It does not talk about formatting /BOOT but I would hope that the DVD would then proceed to create new initrd files or whichever creates the fstabs at install so the new UUIDs are now reflected...


Most importantly- I want to proceed with the fixing of my Suse boot and keep it separate: I heard that creating 2 /boot partitions in the begining of the drive is possible and I could house my Suse /boot files in the /BOOT2 partition. Keeping my Gutsy grub as master and hoping to find a way to get back into Gutsy eventually. Any no nos? Warnings?
I have one primary partition "available" and I might separate my 200 mb /boot in 2. I should really just call my Gutsy a lost cause my situation is so hairy, but I'm feeling miserable now anyways- I need to see my ol' Gutsy desktop to cheer me up!

grub> geometry (hd2)
drive 0x82: C/H/S = 60801/255/63, The number of sectors = 976773168, /dev/sdc
Partition num: 0, Filesystem type is ext2fs, partition type 0x83
Partition num: 2, Filesystem type unknown, partition type 0x82
Partition num: 4, Filesystem type is ext2fs, partition type 0x83
Partition num: 5, Filesystem type unknown, partition type 0x7
Partition num: 6, Filesystem type unknown, partition type 0x7
Partition num: 7, Filesystem type is ext2fs, partition type 0x83
Partition num: 8, Filesystem type unknown, partition type 0x7
Partition num: 9, Filesystem type unknown, partition type 0x7
Partition num: 10, Filesystem type is ext2fs, partition type 0x83
Partition num: 11, Filesystem type is ext2fs, partition type 0x83

I should ask a question in an Ubuntu section but I'm tired for now!
 
Old 10-14-2008, 08:00 AM   #6
JZL240I-U
Senior Member
 
Registered: Apr 2003
Location: Germany
Distribution: openSuSE 13.1 / 12.3_64-KDE, Ubuntu 14.04, Fedora 20, Mint 17, Chakra
Posts: 3,688

Rep: Reputation: Disabled
Quote:
Originally Posted by mk27 View Post
...GRUB can only use one of them anyway (that may be why things have gotten so confused). That's kind of the point: you have one bootloader for multiple partitions....
Wrong. Look here: http://www.justlinux.com/forum/showthread.php?t=147959



Quote:
Originally Posted by mk27 View Post
...Just because you have multiple OS's on one machine DOES NOT mean that you need more than one installation of GRUB (in reality, since there is only one boot sector, you can not have more than one functional grub installation). ...
Of course you can. You simply chainload the next instance of GRUB.
 
  


Reply

Tags
ata, boot parameters, disk, limit


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 failed to load linux (grub think ext3 partition as fat) khairilthegreat Linux - Newbie 7 08-09-2007 01:12 PM
BIOS to GRUB/Linux Boot Slow After Disk Transfer donv2 Linux - Newbie 2 04-23-2005 12:48 AM
porting zipslack to real linux partition webboss Slackware 12 11-16-2004 06:24 AM
Dumb Newbie - lost linux partition + BIOS problem? BlendedRacer Linux - Newbie 2 06-28-2004 10:23 PM


All times are GMT -5. The time now is 07:23 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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration