grub wont bot what I want

I don’t know why.
Try that (more useful in that case since I guess you already know where your grubs are and you’re more interested in stage2 than in stage1)

file -s  /dev/{sda*,sdb*} | grep -i bootloader 

It might provide some interesting info, such as the 1st sector of stage2 the bootloader in the partition is using… although with stage1 in extended partitions, I don’t know. :frowning:

I know why findgrub doesn’t work for you - thanks to your fdisk -l posting.

fdisk -l 2>/dev/null | sed -n 's|^Disk \(/dev/[hs]d[a-z]\):.*|\1|p'

is looking for the string “Disk”. But in your french version, you have:

>:(

However removing the “k” from Disk should fix it (for french). But it’s kind of stupid to translate fdisk output (IMHO). And now I understand why it didn’t work either for some people in the french forum.

Thank you, @jdd. You made my day! :slight_smile:

This menu boots by default the third entry, pointing to an older kernel, replaced by the one of the first entry in your other menu (on sdb6):

###Don't change this comment - YaST2 identifier: Original name: linux###
title openSUSE 11.3 (usuelle)
root (hd0,5)
kernel /boot/vmlinuz-**2.6.34.7-0.7**-default root=/dev/disk/by-id/ata-WDC_WD5000BEVT-00ZAT0_WD-WXNY08N61636-part6 resume=/dev/disk/by-id/ata-IC35L120AVV207-0_VNVD06G4D2PX4L-part5 splash=silent quiet showopts vga=0x317
initrd /boot/initrd-2.6.34.7-0.7-default

Hello :-). I was sure you where is the neiborhood :slight_smile:

file -s /dev/{sda*,sdb*} | grep -i bootloader
/dev/sda2: x86 boot sector; GRand Unified Bootloader, stage1 version 0x3, LBA flag 0x1, 1st sector stage2 0x318258b, GRUB version 0.97; partition 1: ID=0x82, starthead 254, startsector 63, 4208967 sectors; partition 2: ID=0x5, starthead 254, startsector 4209030, 15534855 sectors, extended partition table, code offset 0x48
/dev/sdb2: x86 boot sector; GRand Unified Bootloader, stage1 version 0x3, LBA flag 0x1, 1st sector stage2 0x35d300fb, GRUB version 0.97; partition 1: ID=0x82, starthead 254, startsector 63, 4208967 sectors; partition 2: ID=0x5, starthead 254, startsector 4209030, 41945715 sectors, extended partition table, code offset 0x48
/dev/sdb6: x86 boot sector; GRand Unified Bootloader, stage1 version 0x3, LBA flag 0x1, 1st sector stage2 0x8a21f65, GRUB version 0.97, code offset 0x48

extended is sdb2

have to save the LANG, use default and restore :slight_smile:

this is irrelevant, this entry don’t even boot. I just booted it with the grub mini terminal, to see it was an uncomplete 11.3 install (it started the first YaST install boot :-)) - will be removed soon, don’t worry.

removing the “k” is not enough, there no output either :frowning:

Could you just tell me if

LC_ALL=C /sbin/fdisk -l

outputs in english on that system?

yes!!!

good luck!

Good. I’ll change that in the script then. I hope the couple strings I read from the bootsectors are not in french. :wink:

@jdd
Would you mind testing this version for me: [noparse]http://unixversal.com/linux/openSUSE/findgrub23.tgz[/noparse]](http://unixversal.com/linux/openSUSE/findgrub23.tgz). The archive contains 2 files. cfingrub is the same script with coloured output. I have to pack it in an archive because the escape sequences it uses get lost while pasting the code in the forum.
If it works, I’ll post the new findgrub in its thread in the development subforum.

Btw I added the kernel option ( -k or --kernel) at your request months ago before I realized what you really asked me and wrote another script to find and load another kernel without restarting. It was in the french forum and - as always - I can not find it anymore.

Back to your problem that I’ve been trying to understand meanwhile.

I think you mean the following entry:

#title openSUSE 11.3 (/dev/sda6)
# root (hd2,5)
# configfile /boot/grub/menu.lst
###Don't change this comment - YaST2 identifier: Original name: openSUSE 11.3 - 2.6.34.7-0.5 (ancienne, /dev/sdb6)###
title openSUSE 11.3 - 2.6.34.7-0.5 (ancienne) (/dev/sdb6)
root (hd0,5)
configfile /boot/grub/menu.lst

It refers to the Grub whose stage1 and stage2 are installed in sdb6 (hd0,5).

As it is a logical partition, it cannot be booted directly but only chainloaded from another Grub and it displays the boot menu (/boot/grub/menu.lst) in sdb6. This is normal so far.

I have to wait for your findgrub output to see if you have grub in MBR (I assume you don’t cause I know you don’t like that). findgrub looks at the bootsectors in a different way that file -s does and is more reliable (file -s /dev/sda doesn’t show Grub in MBR on my system while findgrub does).

If you had Grub in MBR of your first HD (question is which one it is?) and it was rooted to (hd0,8 - sdb9) when you installed Grub, that would answer your question. The same goes for the Grub installed in sdb2:

You also have a Grub installed on sda2 (but this partition doesn’t have the bootflag):

And which one is the IDE disk?

Possible explanations are:

  • it will be booted from sda which has Grub in MBR looking for stage2 in sdb9
  • it will be booted from sdb which has Grub in MBR looking for stage2 in sdb9
  • it will be booted from sdb2 which has Grub in bootsector looking for stage2 in sdb9

You could simply reinstall Grub in sdb2 with:


grub
grub> find /boot/grub/stage2
  (hd0,5)
grub> root (hd0,5)
grub> setup (hd0,1)
grub> quit

But you have to take care of what you put in your device.map at this point. Currently, it looks like hd0 is mapped to sdb. Of course you can also install Grub in the MBR by using setup (hd0) instead of setup (hd0,1). I won’t do anything like that from YaST - no offense meant to YaST fans.

gogalthorp wrote:
> With out seeing what I asked for no way to know

Another item that may be relevant that I don’t think we’ve seen is the
associated device.map files from the two grub installations.

Cheers, Dave

PS I’m only skimming this topic but I haven’t managed to get a clear
understanding of the situation as it has developed. Does anybody have a
clear enough view to summarise?

I’m back at home, so I can’t anymore (for two weeks) test the questionable machine, but I can still test french install :-))