Empty menu.lst grub file generated

Hi all,
I experience a serious issue here, somewhat annoying.
I had exactly the same problem month ago when upgrading to openSUSE-12.1 but
failed to reproduce it reliably. It stopped happening back then, so I forgot
about it. Now it is back and reproduceably in every attempt:

I upgraded my openSUSE-Tumbleweed to 12.2-RC2 using online repositories.
Surprisingly few problems choked up. I had everything back and working after
only a few hours. And nuch more stable now.

However there is one serious issue:
whenever the grub (1) bootloader is rewritten (kernel upgrade or manual
edit) a menu.lst is generated that only contains the leading entry lines but
no bootable sections at all.
When I copy an old, working menu.lst file back in place and start
yast2>bootloader those entries are actually parsed and offered. After
clicking ok to write the content the menu.lst file is stripped of all
sections again. Also freshly created entries are erased. No way to get any
bootable section in there, except of restoring my backed up menu.lst
manually. This works, but is somehat annoying in case I accidentially forget
about it. This means fiddling around with a rescue disk and stuff, since on
my system the keyboard is not usable inside the grub shell (firmware
related).

I get no error messages, no terminal output, nothing.
Just those stripped menu.lst files in a reproduceable manner.

Anyone got an idea what might be the cause ?


arkascha

So openSUSE 12.1 and Tumbleweed for 12.1 both default to Grub Legacy but upgrading to openSUSE 12.2 would switch you to using Grub 2. Sounds like you are straddling the fence with Grub Legacy doing the boot while perhaps Grub 2 is in control of your boot menu. You could give these two commands a try to see what you got:

For KDE ALT-F2: kdesu /sbin/yast2 bootloader

OR

For GNOME do ALT-F2: gnomesu /sbin/yast2 bootloader

You could then try to complete the switch to Grub 2 as it should be. I have a utility for Grub 2 you can find here:

GNU Grub2 Command Help/Config Editor - Version: 1.75 - Blogs - openSUSE Forums

Thank You,

On 18/08/12 10:27, arkascha wrote:
> I upgraded my openSUSE-Tumbleweed to 12.2-RC2
Umm
Sounds like you don’t really know what you are doing

Hi,

>> On 18/08/12 10:27, arkascha wrote:
>> I upgraded my openSUSE-Tumbleweed to 12.2-RC2

> caf4926 wrote:
> Umm
> Sounds like you don’t really know what you are doing

what a constructive help this is.
Please note that there are reasons for this shift. Though I do agree that
this shift is probably not really called an ‘upgrade’ :slight_smile:

arkascha

Hi,
thanks for taking a look at this !

>> arkascha;2480647 Wrote:
>> Hi all,
>> I experience a serious issue here, somewhat annoying.
>> I had exactly the same problem month ago when upgrading to
>> openSUSE-12.1 but
>> failed to reproduce it reliably. It stopped happening back then, so I
>> forgot
>> about it. Now it is back and reproducibly in every attempt:
>>
>> I upgraded my openSUSE-Tumbleweed to 12.2-RC2 using online
>> repositories.
>> Surprisingly few problems choked up. I had everything back and working
>> after
>> only a few hours. And much more stable now.
>>
>> However there is one serious issue:
>> whenever the grub (1) bootloader is rewritten (kernel upgrade or manual
>> edit) a menu.lst is generated that only contains the leading entry
>> lines but
>> no bootable sections at all.
>> When I copy an old, working menu.lst file back in place and start
>> yast2>bootloader those entries are actually parsed and offered. After
>> clicking ok to write the content the menu.lst file is stripped of all
>> sections again. Also freshly created entries are erased. No way to get
>> any
>> bootable section in there, except of restoring my backed up menu.lst
>> manually. This works, but is somewhat annoying in case I accidentally
>> forget
>> about it. This means fiddling around with a rescue disk and stuff,
>> since on
>> my system the keyboard is not usable inside the grub shell (firmware
>> related).
>>
>> I get no error messages, no terminal output, nothing.
>> Just those stripped menu.lst files in a reproducible manner.
>>
>> Anyone got an idea what might be the cause ?

> jdmcdaniel3 wrote:
> So openSUSE 12.1 and Tumbleweed for 12.1 both default to Grub Legacy
> but upgrading to openSUSE 12.2 would switch you to using Grub 2. Sounds
> like you are straddling the fence with Grub Legacy doing the boot while
> perhaps Grub 2 is in control of your boot menu. You could give these two
> commands a try to see what you got:
> Code:
> --------------------
> For KDE ALT-F2: kdesu /sbin/yast2 bootloader
> --------------------

As written I was using yast2 bootloader to generate the grub entries. This
was exactly my problem. I currently don’t see what you are trying to make me
do different with this way of invoking the utility.
As before it generates the empty menu.lst file.

> You could then try to complete the switch to Grub 2 as it should be. I
> have a utility for Grub 2 you can find here:
>
> ‘GNU Grub2 Command Help/Config Editor - Version: 1.75 - Blogs -
> openSUSE Forums’ (http://tinyurl.com/7b2zspv)

Well, as written I am using grub1, NOT grub2.
Actually grub2 is deinstalled completely and grub1 worked before using
openSUSE-12.1 and openSUSE-Tumbleweed.

It’s not that I don’t want to switch to grub2. I saw openSUSE-12.2 installed
grub2 alongside grub1 and configured it. However that configuration did not
work, whilst the grub1 installation did, which was configured by the same
process (post upgrade initial configuration). Odd, but that is what I
experienced. Because of grub1 working and me never having had problems with
it I though: ok, stick with grub1 and fine.
Because of the problems written I finally tried to deinstall grub2
completely, but to no success. Things are still not working.

I hesitate to use grub2:
I am using a MacBook Pro. These machines use EFI for booting and there are
always some problems one has to get around when installaing and configuring
the boot process. Since grub1 always worked like charm I though there really
has to be a good reason for me to switch to grub2 now. Actually grub1 still
workes fine (currently using that system), only the menu.lst file has to be
restored manually since yast2 bootloader corrupts it in a reproduceable
manner.
If yast2 bootloader is unable to write the file it should not offer to do
so.

arkascha


arkascha

You should not use yast2 bootloader on a MacBook. If it reinstalls the bootloader and rewrites a generic boot code, your hybrid MBR might not be happy, and if you inadvertently install Grub in MBR, it will screw up your GPT header.

grub2-efi (not grub2) should be fine … provided you can boot Linux on a MacBook in UEFI mode (don’t know how and haven’t tried - but I would like to get rid of rEFIT at some point).

On 08/21/2012 10:46 AM, arkascha wrote:
> what a constructive help this is.

when you do things that no one here [or in written documentation or
how-tos] suggests, approves of, or supports–we can only assume you have
not read enough and therefore don’t know how to do correctly.

therefore, his (unstated advice) to learn how to do it so you do know
what you are doing, is very sound and extremely constructive indeed.

> Please note that there are reasons for this shift. Though I do agree that
> this shift is probably not really called an ‘upgrade’

if you have problems because you do not follow instructions/guides/best
practices it is difficult for us to even begin to figure out what causes
your current problem, or the same problem you had when you
wrote “when upgrading to openSUSE-12.1”

so, i can only guess that the problem you had in 12.1 and now in
FrankensteinopenSUSE 12.1-Tumbleweed-12.2-RC2 are all from a botched
upgrade…

which of these three (only three supported ways) did you follow
precisely to get from what previous version of openSUSE to 12.1?:

http://tinyurl.com/35p966c
http://tinyurl.com/6kvoflv
http://tinyurl.com/7l4m2td


dd http://tinyurl.com/DD-Caveat http://tinyurl.com/DD-Hardware
http://tinyurl.com/DD-Software

It’s not YaST. It’s the Perl Bootloader - IMO the most buggy piece of software in openSUSE history. Try to set this in /etc/sysconfig/bootloader:

LOADER_TYPE="none"

See this post and some other posts in this thread: http://forums.opensuse.org/english/get-technical-help-here/install-boot-login/471406-how-does-yast-use-grub-4.html#post2434159

Hello,

> dd@home.dk wrote:
> On 08/21/2012 10:46 AM, arkascha wrote:
>> what a constructive help this is.
>
> when you do things that no one here [or in written documentation or
> how-tos] suggests, approves of, or supports–we can only assume you have
> not read enough and therefore don’t know how to do correctly.
>
> therefore, his (unstated advice) to learn how to do it so you do know
> what you are doing, is very sound and extremely constructive indeed.

Why does the fact that I did not following any of the typical usage cases
automatically mean that I do not know what I am doing ?

In my eyes one of the strong things about Linux is that unlike other systems
you are allowed to do what you want with it. Not only what someone else
tells you what is allowed. Am I wrong with that?

I am not trying to get help from some support line that has clear guidelines
what usage case is supported by them and what not. I just ask around in a
forum trying to find someone who has got an idea what might be wrong on my
system.
I never claimed the openSUSE project team did something wrong and now has to
solve my problems. I never claimed the software is buggy because it did not
do what I expected when I did that ‘upgrade’.

I just asked if someone has got an idea.
Sorry if that is wrong in your view.

>> Please note that there are reasons for this shift. Though I do agree that
>> this shift is probably not really called an ‘upgrade’
>
> if you have problems because you do not follow instructions/guides/best
> practices it is difficult for us to even begin to figure out what causes
> your current problem, or the same problem you had when you
> wrote “when upgrading to openSUSE-12.1”

That is currect, I will do my best to provide information in the hope that
someone here more familiar with the boot aspects has an idea for me. Thanks
for giving it a try!

> …]
> which of these three (only three supported ways) did you follow
> precisely to get from what previous version of openSUSE to 12.1?:
> …]
Right, clearly my mistake:
I actually did not upgrade to 12.1, but I “upgraded” / made the switch
from openSUSE-12.1 to openSUSE-Tumbleweed. This was when I first
experienced these problems: for a certain period of time all kernel upgrades
(quite frequent in Tumbleweed) produced these empty menu.lst files. As
written that problem did not accur any more over the last month.
I did that switch by replacing two or three repository urls with the
corresponding tumbleweed alternatives. I did that using yast2 software
management. For all the upgrades afterwards I used plain zypper up calls.

When now switching to openSUSE-12.2 again I did the same:
changed the repository urls to the openSUSE-12.2 alternatives and ran a
distribution upgrade (zypper dup). Afterwards I manually switched some
packages between repositories to reduce the wild mixture. For example I
switched all kde related packages to the KDE-4.9 repository (using yast2’s
“switch to this repository” feature).

After the switch to 12.2 I found a new (additional) grub2 entry in the boot
menu. That entry (autogenerated during the upgrade) did not work (halted
before any boot messages were written). So i ignored it and used the “old”
entries still there, note that these were upgraded to the new kernel
versions as provided by 12.2. These entries did work, those were grub1
entries as far as I can tell.
During my attempts to give grub2 a try I reinstalled the bootloaded
(yast2>bootloader>“Ok”). This was when suddenly the boot menu contained no
entry any more and I had the problem to get the system back. I succeeded
using a rescue disk and restoring a backup version if the menu.lst file. I
did that cause I noticed that indeed that file had been stripped of any
entries. And because I had that similar issue ealier (as written) I recalled
some steps. With that restored menu.lst file the system boots fine.

I completely failed to get grub2 to work. This might be because I have a
MacBook Pro using EFI. Since grub1 works fine I decided to stay with it,
deinstalled grub2 using yast2, but still these empty files are written. Note
that I did not force any package deinstallation. Yast2 offered
desinstallation, and I only accepted. zypper tells all package dependencies
are satisfied. But obviously I cannot tell if there are any packages still
left related to grub2. I chose the files I deinstalled by package name and
description. I did that because I assumed there are conflicts between grub1
and grub2 packages.


arkascha

please try again wrote:

>
> arkascha;2481142 Wrote:
>>
>>
>> I hesitate to use grub2:
>> I am using a MacBook Pro. These machines use EFI for booting and there
>> are
>> always some problems one has to get around when installaing and
>> configuring
>> the boot process. Since grub1 always worked like charm I though there
>> really
>> has to be a good reason for me to switch to grub2 now. Actually grub1
>> still
>> workes fine (currently using that system), only the menu.lst file has
>> to be
>> restored manually since yast2 bootloader corrupts it in a
>> reproduceable
>> manner.
>> If yast2 bootloader is unable to write the file it should not offer to
>> do
>> so.
>>
>
> You should not use yast2 bootloader on a MacBook. If it reinstalls the
> bootloader and rewrites a generic boot code, your hybrid MBR might not
> be happy, and if you inadvertently install Grub in MBR, it will screw up
> your GPT header.
>
> grub2-efi (not grub2) should be fine … provided you can boot Linux
> on a MacBook in UEFI mode (don’t know how and haven’t tried - but I
> would like to get rid of rEFIT at some point).

Ok, sounds like it makes sense :slight_smile:
I do not use rEFIT on this machine. Did that on an older machine, but when
installing openSUSE-12.1 back then SUSE just installed fine without rEFIT.
Might be because it uses grub-efi, I didn’t notice cause I was not
interested in that. Simply because things worked out of the box.

I will read about details to grub-efi. Thanks 1


arkascha

On 08/21/2012 12:02 PM, arkascha wrote:
> In my eyes one of the strong things about Linux is that unlike other systems
> you are allowed to do what you want with it. Not only what someone else
> tells you what is allowed. Am I wrong with that?

no, of course you are correct in that… no question!

but when you ask a question and do not tell us why and how your
situation varies from the norm here, then we rightly or wrongly assume
you have told us what we need to know in order to try to help you…

but, what you had told us by the time caf said you don’t know what you
are doing…we could only assume you were dipping into RC2 to ‘fix’ a
12.1 + Tumbleweed problem… which a ‘knowing’ openSUSE user wouldn’t do!

so, i draw your eye to the time you first revealed you were doing things
because you have unfamiliar hardware and compare that to the time caf
posted (over five hours earlier) or when i responded to your’s (16
minutes after i posted…but before i could possibly understand why
you were dipping into RC2 and Tumbleweed, since i hadn’t read
yours[working off line via nntp, like you]…)

so, seems a lot might have been avoided had you put Mac in your subject
line…that way one of VERY few Mac’ers here could help (and now
is)–good luck to you (i well support all brave enough to try to break
through Apple’s walls.)

last: don’t assume caf is a bad actor here, he is not…short sometimes
(he is rushed, always), but well worth listening to!


dd

No. It does not. 12.2 has it in its list of installable boot loaders. You’re not dual booting with OS X, are you?

If you boot openSUSE 12.1 (DVD, not CD!) on a UEFI or EFI machine (whether is is from Apple or not), it will boot and install ELILO. Thus it is not surprising that menu.lst is empty. If you dual boot and use rEFIt, it performs a MBR installation and uses Legacy Grub.

On 2012-08-21 12:33, dd@home.dk wrote:
> so, seems a lot might have been avoided had you put Mac in your subject line…

MAC!!!

I would not have wasted time reading the thread trying to see if I could help. I know nothing
of macs, that should have been said in the first post prominently.


Cheers / Saludos,

Carlos E. R.
(from 12.1 x86_64 “Asparagus” at Telcontar)

And I would have checked this thread earlier instead of assuming you guys were going to help. lol!

All help is relative and as luck would have it, I am not related to any of you. lol! Not to mention that not all Mac’s are equal too.

I have a very high opinion of a Big Mac!

http://images.businessweek.com/ss/06/05/what_things_cost/image/bigmac.jpg

Thank You for using openSUSE.