Updating OES server leaves system unbootable

  • 7005381
  • 23-Feb-2010
  • 27-Apr-2012

Environment

Novell Open Enterprise Server 2 (OES 2) Linux Support Pack 1
Novell Open Enterprise Server 2 (OES 2) Linux Support Pack 2

Situation

First, the described issue only hits a small fraction of OES installations.

Situation: An OES2 machine shall be updated to the next Service Pack.
The machine has two disks, a system disk with standard partitioning,
3 primary partitions, /boot, swap / and a second disk with a NSS partition.
The partition table looks similar to

sda1   /boot
sda2   swap
sda3  /
sdb1  Netware partition

The machine is rebooted of the SUSE Linux Enterprise Server SP3 DVD1 to run the update.
Process runs smoothly until the step where the to be updated Root partition has to be chosen.
There no partition is shown at all. Checking "Show all partitions" the partitioner shows all partitions twice, as evms AND standard partitions like /dev/sda3 and /dev/evms/sda3 as well.

According to the OES documentation /dev/sda3 should be chosen, but that produces an errormessage that /dev/sdb1 (!) could not be mounted to /boot

Attention: At this point the installation must be aborted, otherwise the installer will break the system.
If that already happened, see below for instructions how to repair that.


Resolution

Abort the update at the partition screen and get a Driver Update Disk (DUD) that prevents this error.
The DUD can be downloaded at  https://you.novell.com/update/i386/update/SUSE-SLES/10/PTF/f2cf38b50ed714a8409693060195b235/20100215

Two small files need to be downloaded:
hwinfo-12.60-0.4.19.1049.0.PTF.574442.dud  # this is the driver update disk
hwinfo-12.60-0.4.19.1049.0.PTF.574442.i586.rpm # this one is the update for the INSTALLED system and needs to be applied after the update is finished.

Note: a valid SLES or OES2 subscription is necessary to download these files

The DUD file can be used as an emulated floppy disk with vmware, kvm, xen or whatever hypervisor is used.

Now restart the update by again booting from the SLES10SP3 DVD, at the splashscreen, where "Boot from Harddisk" or "Installation" can be chosen, there are also hotkeys for "language", "resolution" and"driver" available. Depending on the system the DUD may be recognized automatically, if not, press the "driver" hotkey, choose "installation" and follow the installer's suggestions.

Now the partitioner screen should show only /dev/sda3 (from the above example) as to be updated.
The update should finish smoothly now.

When the system is up and running again, apply the downloaded hwinfo rpm package either using YaST2 or manually:

rpm -Uhv hwinfo-12.60-0.4.19.1049.0.PTF.574442.i586.rpm


Now, what if it is already too late?


Given the system does not boot anymore, boot process stops
complaining devices like /dev/sdb1, sdb3, etc can not be found.

The update failed because of a bug in the hardware detection,
resulting in the installer translating sda to sdb. The system
now thinks the OS is installed on the second harddrive.

Reboot the system and start the "Rescue System" from the SLES10SP3 DVD1

Log in as root, no password necessary.

run "fdisk -l" to determine the available partitions

Example:

   Device Boot      Start         End      Blocks   Id  System
   /dev/sda1               1          15      120456   83  Linux
   /dev/sda2              16          81      530145   82  Linux swap / Solaris
   /dev/sda3              82       26000   208194367+  83  Linux
   /dev/sdb1               1       26109   209720511   65  Novell Netware 386

Here we have

sda1 as /boot
sda2 as swap
sda3 as /

sdb1 is of no concern here, the data on that disk won't be touched during the update.

mount the ROOT partition and remount necessary system directories:

mount /dev/sda3 /mnt
mount -o bind /dev /mnt/dev
mount -o bind /sys /mnt/sys
mount -o bind /proc /mnt/proc

Now chroot onto the old root partition

chroot /mnt

mount the BOOT partition

mount /dev/sda1 /boot

Edit /etc/fstab and change /boot, swap and / back to /dev/sdaX

/dev/sda3            /                    reiserfs   acl,user_xattr        1 1
/dev/sda2            swap                 swap       defaults              0 0
/dev/sda1            /boot                ext3       acl,user_xattr        1 1

Now edit /etc/grub.conf and change it to:

root (hd0,2)
install --stage2=/boot/grub/stage2 /boot/grub/stage1 (hd0) /boot/grub/stage2  (hd0,0)/grub/menu.lst
quit


Explanation:
hd0 = /dev/sda , hd0,0 = /dev/sda1, hd0,2 = /dev/sda3.
All these devices are only examples, this may look different depending on
the partitioning of the machine. It should give an idea how to solve this
situation, though

Now the kernel package needs to be reinstalled to do some final repairs:

Make sure the /boot partition is still mounted!
Determine the system's cdrom/dvd drive:

hwinfo --cdrom |grep Device

Now mount the SLES10SP3 DVD1 media:

mount /dev/hdc /mnt

and reinstall the kernel rpm:

rpm -Uhv --force /mnt/suse/i586/kernel-default-2.6.16.60-0.54.5.i586.rpm

The post-install script of the rpm package is executed automatically
and makes necessary updates to the bootloader configuration in /boot/grub/menu.lst
Note, there may be some udev errormessage, but these can be ignored.

As a last step execute:

grub-install /dev/sda

which will install the bootloader and point it to the new kernel image.
Now exit the chroot environment and reboot the system

exit
sync
shutdown -r now

After the reboot, the installer continues as if nothing had happened
and the update can be finished.

Additional Information

Software download at:

https://you.novell.com/update/i386/update/SUSE-SLES/10/PTF/f2cf38b50ed714a8409693060195b235/20100215

This directory contains a "mass-PTF", every customer with a valid subscription can download the PTF