LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > SUSE / openSUSE
User Name
Password
SUSE / openSUSE This Forum is for the discussion of Suse Linux.

Notices


Reply
  Search this Thread
Old 01-11-2009, 05:42 PM   #1
Wylbur
LQ Newbie
 
Registered: Jan 2009
Distribution: SuSE
Posts: 6

Rep: Reputation: 0
SuSE 11.0 64bit GRUB Loop


I need a few pointers so I can get a system straighted out that I use for a "file server" and DHCP/WINS server. Right now I can't get GRUB correctly straightened out so the system will boot.

I have googled, yahoo!ed, gone to OpenSuSE and searched. No joy.

History:

I had a system with a working Open SuSE 10.3 64 bit. It was running on a 500GB drive (SATA - NON-RAID). I realized that I had set it up incorrectly (I had set up the partitions to be a bit too small and was about to have out of space problems), so I obtained a second 500GB drive and installed it on SATA1 (the original drive was SATA0).

So I used the partition software on the 10.3 system to build a 100GB partition on the new drive for "/" and 300GB for /home. Then I copied the data from the 10.3 system to the new drive.

Ok, now I disconnected SATA0 (and went into SETUP and set it all up for SATA1 to boot...) and put a SuSE 11.0 64bit install DVD in the DVD drive and booted. I asked it to verify the media (which took some time, but gave the message that all was OK).

At this point I rebooted from the DVD and went to INSTALL. I answered the questions and set up for an upgrade install. That appears to have run just fine, updated the installed packages, repositories, etc. So far so good.

Ok, it now comes time to boot the new system, and GRUB got bent out of shape (I'm sorry, but I lost where I wrote down the error message it came up with).

At this point I decided to reboot with the DVD and tell it to do a repair. So I went to expert and told it to rebuild the GRUB loader. So if I allow the system to boot from the DVD, it times out on the boot from disk (by this I mean I let it run to where it goes to the disk to boot). This results in an almost immediate reboot.

Ok, so I took the DVD out and rebooted, and it gets to GRUB 1.5 throws up a message Grub loading, please wait, and then it goes to POST and back through boot.

Enough of this, so I reconnected SATA0, went through SETUP and set the system to boot from SATA0 and committed this change. Then I made the mistake of trying to fix GRUB to boot SATA1 (on request not default). And now we go into GRUB and the exact same things start happening with the SATA0 SuSE 10.3 install!

So, I get the 10.3 64 bit install DVD and attempt to fix GRUB on SATA0. Everything looks good. But it still does the "Grub" reboot loop.

I do have a LIVE 11.0 DVD, and I can't seem to get it to find and boot the system (from SATA0 or SATA1). I have used that same methodology for my dual boot laptop to fix a W/2K and Linspire (and now SuSE 11.0 32 bit install). I also can't seem to get SDA1 mounted so that I can run #grub to try to repair things from there.

Lastly, if I remember correctly, I even had a Knoppix Live CD booted and could look at all the partitions (Ok, I've been up for a long time working on this and things are getting fuzzy).

So I'm lost. Anyone have any idea how to get this corrected?

Regards,
Wylbur (Obviously of the Wrong Brothers)
 
Old 01-11-2009, 06:41 PM   #2
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,126

Rep: Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120
If Knoppix sees the data use that. Open a terminal and su to root
Code:
find /boot/grub/stage1
root (hd0,1)   <<<=== use what the previous command returned
setup (hd0)   <<<=== presumably
quit
Then reboot from the disk (I only tested on a virtual OpenSuse)
 
Old 01-11-2009, 09:25 PM   #3
Wylbur
LQ Newbie
 
Registered: Jan 2009
Distribution: SuSE
Posts: 6

Original Poster
Rep: Reputation: 0
No joy.

I had to mount the partitions (no biggie), but the find /boot/grub/stage1 failed (said it couldn't find it). OK, I'm already at that mount point, so I issued #find grub/stage1. Again, it doesn't return with anything. So issuing #setup (hd0) is going to be a problem (my guess).

But, the nice thing is, my data is still on the drives (given that the one is supposed to be a backup of the other until I can get a USB drive attached...).

Still,
Wylbur (Obviously of the Wrong Brothers)
 
Old 01-11-2009, 09:28 PM   #4
CJS
Member
 
Registered: May 2008
Location: California, USA
Distribution: Ubuntu 8.10
Posts: 247

Rep: Reputation: 49
Hi Wylbur, in order to get a clearer picture of your setup, how about downloading the Boot Info Script to the desktop of the Live CD you are using, and then do the following as root user, but replace <username> with your username:
Code:
bash /home/<username>/Desktop/boot_info_script*.sh
That will create a "RESULTS.txt" file in the same directory from where the script is run, namely your desktop; please copy/paste the contents of that file to your next post. That will help clarify your setup and hopefully what your booting problem might be.
 
Old 02-08-2009, 08:51 PM   #5
Wylbur
LQ Newbie
 
Registered: Jan 2009
Distribution: SuSE
Posts: 6

Original Poster
Rep: Reputation: 0
Sorry for taking so long to respond.

The Koppix CD does not let me post that file where I need it -- to this laptop. And I've had a few things that required a lot of my time (things I get paid for).

What I am preparing to do is install Debian on a soon to be defined partition and see if it has the same problems with GRUB that SuSE's install is having. But it will take me a day or so, because the Debian DVD iso is downloading at a snails pace.

Regards,
Wylbur
 
Old 02-15-2009, 03:09 PM   #6
Wylbur
LQ Newbie
 
Registered: Jan 2009
Distribution: SuSE
Posts: 6

Original Poster
Rep: Reputation: 0
SuSE 11.0 64bit GRUB Loop

Ok, finally, I got the Debian install to run.

Before I did that, I noticed an oddity with the BIOS settings. I changed the settings to allow the SATA drives to be seen as SATA and not treated as IDE.

This resulted in GRUB getting to 1.5 "something" and then behaved as if the reset button had been pushed.

So, I allowed the reboot to take place, but with the SuSE 11.0 64bit Install DVD in the tray. It came up and did a "boot from disk", which selected the Debian system, which booted (it took some time, I guess because it was the first time it was being run).

OK, so I told the system to reboot, and this time I selected the SuSE 11.0 install. It crashed.

So another reboot and I selected the 10.3 Install and it worked!

The 10.3 system is on SDA1, the 11.0 is SDB1 and Debian is SDB3 with SWAP on SDA2.

I'm trying to find time to boot the SuSE 11.0 install again, in an attempt to "repair" the 11.0 system (and fix GRUB to make the 10.3 system default until the 11.0 system is functional).

Does anyone have any idea why this is such a problem?

Regards,
Wylbur
 
Old 02-15-2009, 06:12 PM   #7
mingus725
LQ Newbie
 
Registered: Feb 2006
Location: Atlanta, Georgia, USA
Distribution: openSUSE, Ubuntu, Fedora, Gentoo
Posts: 4

Rep: Reputation: 0
It's very difficult to pin down the problem without knowing your bios boot configuration, how grub was installed in 10.3 and 11.0, what is in menu.lst and device.map.

In openSUSE, the YaST Boot Loader module uses a program to interrogate the MBR and PBRs to try to determine the best boot setup; that pgm creates a scriptlet which is fed to the grub shell for grub stage1 installation - the file is /etc/grub.conf. Debian still uses the vanilla grub-install script that comes in the grub package. But with both (the SuSE program adds intelligence not in the script), there is guesswork. That's because bios's don't pass the boot configuration, made worse by bios's often being flakey with how the boot devices are handled. Your description, especially what occurred following the bios setup change, suggests that the pointer embedded in grub stage1 that is placed in the PBR, is wrong in 11.0 but OK in 10.3.

If you want to post back the grub.conf files for comparison, along with the 2 menu.lst and device.map files, along with your fdisk, I'll take a look. Admittedly, a lot, but not atypical in this kind of analysis.
 
Old 02-15-2009, 09:28 PM   #8
Wylbur
LQ Newbie
 
Registered: Jan 2009
Distribution: SuSE
Posts: 6

Original Poster
Rep: Reputation: 0
Well here goes:

/etc/grub.conf contains:
setup --stage2=/boot/grub/stage2 (hd0,0) (hd0,0)

.../stage2 is binary info (actual program?)

ALICE shows:

Device Type/Filesystem Size Flags Status
/dev/sda 465.76 GiB
/dev/sda1 Ext3FS 30.01 GiB boot, type mounted on /
/dev/sda2 Unknown 4.01 GiB type Unable to find mountpoint
/dev/sda3 Extended 100.01 GiB lba, type Not Busy
/dev/sda5/ Unknown 100.01 GiB lvm, type Not mounted

/dev/sdb 465.76 GiB
/dev/sdb1 Ext3FS 100.01 GiB boot, type Not Mounted
/dev/sdb2 Ext3FS 300.00 GiB type Not Mounted
/dev/sdb3 EXT3FS 65.75 GiB type Not Mounted

Now, I know what sdb1 is supposed to be, and that is a copy of sda1 updated from 10.3 to 11.0.

I know what sda2 is, and that is a 4Gig swap
And sda3/5 is 100.01 Gig of space I haven't recovered from an old LVM "partition".
So sdb2 is the /home for sdb1 which is all the old lvm data.
And lastly, sdb3 is the Debian install that I just did.

Configuration on this machine (Gigabyte Motherboard):
1 IDE plug
4 SATA plugs

I have the ability to select which SATA is primary for boot (which is probably how I got into this screwed up mess, by changing between the two drives to do the 11.0 install).

The SATA adapter on this motherboard apparently supports RAID 0/1 with two drives, and possibly RAID 5 with 4 drives (I decided I do not want to play with RAID using the BIOS, but if I decide to do RAID have Linux handle it).

I hope this answers your questions.

Regards,
Wylbur
 
Old 02-16-2009, 10:21 AM   #9
mingus725
LQ Newbie
 
Registered: Feb 2006
Location: Atlanta, Georgia, USA
Distribution: openSUSE, Ubuntu, Fedora, Gentoo
Posts: 4

Rep: Reputation: 0
Thumbs down

From what you posted, all I can tell you is that in whichever openSUSE instance (10.3 vs 11.0) the /etc/grub.conf comes from, grub stage1 was installed in the boot sector of the first partition on whichever disk in that instance's /boot/grub/device.map is defined to be grub's (hd0).

Quick summary of grub mechanics: The file /boot/grub/device.map aligns the bios boot device sequence with grub disk notation. (So if sda with 10.3 on sda1 was the first boot disk, then (hd0) = sda). When grub is installed, this notation is used to determine which disk/partition stage1 is installed to and which disk/partition that stage1 should find its stage2 on. Grub stage1 is a small piece of bootstrap code that can be placed in the MBR or a PBR; embedded with the stage1 will be a pointer to the location of stage2 (the actual loader program). Therefore, if (hd0) = sda, then "setup --stage2=/boot/grub/stage2 (hd0,0) (hd0,0)" instructs the grub shell to put stage1 in the sda1 boot sector pointing to that same partition to find stage2 where it will be found under the /boot/grub subdirectory (grub can read most file systems).

In this instance, stage1 is installed in a partition boot sector, which means that stage1 will have to be called by code in the MBR, which is executed by the bios at boot. This will be "generic" (DOS) code which simply looks at the MBR partition table for whichever partition is marked "active", finds that partition's boot sector, and transfer control to the code there (in this case, the stage1). If SuSE is alone on the disk, usually it will use this setup, i.e., install stage1 to its root partition boot sector and install generic boot code to the MBR. (If SuSE is on a logical partition or there is another OS on the disk, SuSE will probably put stage1 in the MBR instead.)

From your posts I can't reconstruct what you did and therefore how the 11.0 grub was set up. I suspect that you copied the contents of sda1 to sdb1 and later switched the bios boot configuration, which would have the device.map on sdb1 wrong (i.e., (hd0) would now = sdb, not sda). My guess is that you did not copy the boot sector, though. During the upgrade the grub install failed, probably again due to device.map being backwards. The fundamental problem appears to be that the grub stage1 that fails when you boot, has an invalid pointer for finding its stage2.

To sort this out, the starting point is deciding which disk should be the first boot hard disk. When you reinstall grub, you need to have this already configured in the bios, and if the bios setup supports it, the other disk defined as the second boot hard disk.

Next, you have a complication created by your Debian install. Unless you manually installed the Debian stage1 to sdb3, then it is likely that the Debian stage1 is either in the sdb MBR or the sda MBR; most likely, whichever disk was configured as first boot drive when you installed Debian. And that stage1 will have a pointer looking for stage2 in sdb3.

Let me suggest you do this: Configure the bios to boot from sdb, i.e., SATA1; if the bios permits, configure SATA0 as the second boot disk. Then boot your SuSE DVD into Rescue System (which will take you to a command line prompt, login as root), or the Knoppix LiveCD (get into a terminal as root). Then do:
Code:
grub
find /boot/grub/stage2
Grub should return: (hd0,0), which with sdb the first boot disk means sdb1. Then do:

Code:
setup (hd0) (hd0,0)
quit
That will put stage1 in the sdb MBR pointing to sdb1 for stage2. Reboot (still booting from SATA1 as configured in the bios). You should get the 11.0 grub menu. Try booting from it. Don't be surprised if that fails; the menu file (/boot/grub/menu.lst) may need to be fixed, too. So if it fails and locks, reboot the machine. Or it may just return you to the menu. From the menu, you can hit Escape to drop the splash screen. Then hit the 'c' key to drop from the text menu into the shell. Then do:

Code:
root (hd0,0)
kernel /boot/vmlinuz root=/dev/sdb1
initrd /boot/initrd
boot
That should boot you into 11.0. I suggest you then open a text editor as root and modify /boot/grub/device.map for the correct boot disk alignment, and modify /boot/grub/menu.lst as necessary. You can also do this from YaST Boot Loader, just be certain that it knows that you are booting from sdb as the first boot disk.

Good luck.
 
Old 03-02-2009, 08:25 PM   #10
Wylbur
LQ Newbie
 
Registered: Jan 2009
Distribution: SuSE
Posts: 6

Original Poster
Rep: Reputation: 0
I finally got 10.3 working again, backed up my /home and blew the whole thing away and re-installed from scratch. Easiest way to get it all fixed.

Thanx,
Wylbur
 
  


Reply

Tags
grub, loop, reboot, suse



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
gpt label in parted, partitions look OK. GrUB not booting 64bit OS on 8th primary digital8doug Linux - Newbie 1 12-31-2008 02:20 PM
YUM on suse 10.1 64bit sagar.1986 SUSE / openSUSE 0 11-30-2006 10:53 AM
Mplayer for Suse 10.0 64bit dolphans1 SUSE / openSUSE 1 01-11-2006 10:42 AM
Grub stuck in an endless loop. dikadika Linux - General 4 02-27-2005 07:46 PM
SuSE 9.2 64Bit w/ Quake3 Marvelloard Linux - Software 0 02-11-2005 10:08 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > SUSE / openSUSE

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