Short story: Machine boots, thanks a lot!!!
Long story: See below.
Longer story: I believe to know what went wrong, but I don’t know how this has been prevented before and how it should be prevented in future.
No worries I would have guessed that anyway. Do what I mean, not what I say
Exactly, that’s the problem.
That statement (with the correct partition number of course) did not work:
# grub2-install --modules=ext2 --force /dev/sda2
/usr/sbin/grub2-bios-setup: warning: File system `ext2' doesn't support embedding.
/usr/sbin/grub2-bios-setup: error: embedding is not possible, but this is required for cross-disk install.
Even with force it doesn’t want to write its files into LiveCD’s filesystem. (I think it should not have caused any trouble
because I had the correct files in sda2’s filesystem from my previous reinstallation)
Anyway, let’s do it right. (I always prefer to run without force first in order to understand what nasty things I force it into)
# mount /dev/sda2 /mnt
linux:/home/linux # grub2-install --modules=ext2 --boot-directory=/mnt /dev/sda2
/usr/sbin/grub2-bios-setup: warning: File system `ext2' doesn't support embedding.
/usr/sbin/grub2-bios-setup: warning: Embedding is not possible. GRUB can only be installed in this setup by using blocklists. However, blocklists are UNRELIABLE and their use is discouraged..
/usr/sbin/grub2-bios-setup: error: will not proceed with blocklists.
OK, dangerous things, we need to force it:
# grub2-install --modules=ext2 --boot-directory=/mnt/ --force /dev/sda2
/usr/sbin/grub2-bios-setup: warning: File system `ext2' doesn't support embedding.
/usr/sbin/grub2-bios-setup: warning: Embedding is not possible. GRUB can only be installed in this setup by using blocklists. However, blocklists are UNRELIABLE and their use is discouraged..
Installation finished. No error reported.
After this the machine boots just fine.
This was not required to get the machine boot. Haven’t had time to look into this yet. Could wrong info there cause trouble some day later???
So if I understand the warnings (which need to be overwritten with force) correctly the problem is that grub hides its essential parts, which are run before it can read the filesystem inside the free blocks
of the filesystem. If somebody modifies the filesystem contents, it could happen that grub breaks (if the filesystem uses the wrong “free” blocks). This seemed to have happend when the kernel was updated.
However, how has this worked before? This OpenSuse 12.2 is not very old and the kernel has not been updated very often. So it could have been luck. But I have an Ubuntu Lucid 10.04 LTS system, which is more
than 2 years old with exactly the same setup. And Ubuntu updates the kernel a.) more frequently than OpenSUSE and b.) does not remove old kernels if there was a kernel-internal ABI break. In effect the boot
filesystem there gets written to much more and it has been full several times (until I manually removed old kernels). So how can they manage to never have hidden grub parts overwritten? Do they re-install
grub each time after they update the kernel? That should work.
Maybe even OpenSUSE normally re-installs grub2 (in general the bootloader, because I think grub2 is not the only supported one) after each update of the /boot filesystem? But this very kernel.rpm had a problem in its %post section and did not do it??? Well I know, it’s open source I should read the code and not speculate wildly. But now I have spent so many hours on this issue that I need to do some real work first.
Yes, bugzilla, I hope I can still do it today,