new install not booting

I have just installed OpenSuSE 11.3 from DVD but on booting there is an error about not finding the swap partition
and the same for the root partition

when I tell it not to try again I get a $ prompt.

ls /dev/disk/by-id includes:

I think of the swap partition as /dev/sda1 and the root partition as /dev/sda2 (there is also /home on /dev/sdb1 from a previous installation of OpenSuSE 11.2

How do I get the machine to boot using partition identifiers which work?


These are not the same pathes:


Can you post your /etc/fstab and /etc/grub/menu.lst ??

Sorry I didn’t explain clearly - the swap and formatted / partitions are not mounted. I guess all I can see is the contents of the initrd

The message is:
Waiting for device /dev/disk/by-id/ata-Integrated_Technology_Express_Inc______#0__-part2 to appear…could not find device /dev/disk/by-id/ata-Integrated_Technology_Express_Inc______#0__-part2
do you want me to fall back to /dev/disk/by-id/ata-Integrated_Technology_Express_Inc______#0__-part2 (Y/n)

Y gets the same message again after a time-out
N gets:
not found exiting to /bin/sh
and a $ prompt

at this stage /etc does not contain /fstab or /grub/

mount /dev/sda2 /tmp
/bin/cat /tmp/etc/fstab
/dev/disk/by-id/ata-Integrated_Technology_Express_Inc______#0__-part1 swap swap defaults 0 0
/dev/disk/by-id/ata-Integrated_Technology_Express_Inc______#0__-part2 / ext4 acl,user,xatr 1 1
/dev/sdb1 /home /ext4 acl,user,xattr 1 2
proc /proc proc defaults 0 0
sysfs /sys sysfs noauto 0 0
debugfs /sys/kernel/debug debugfs noauto 0 0
usbfs /proc/bus/usb usbfs noauto 0 0
devpts /dev/pts devpts mode=0620,gid=5 0 0

/tmp/etc/grub/ directory does not exist

Yes, I realise the 2 paths are different - I had to type them into the post. So does the system because it cannot find the ones it is looking for.
How do I tell it to look for the ones which do exist instead of the ones which don’t?

there should be a /etc/fstab

the problem appears that #O has replaced Q in the fstab, as pointed out earlier.
so either change the first two fstab entries accordingly. Or, simple substitute it with /dev/sda1 as swap, and /dev/sda2 as root. rest of the entries in the fstab appear fine.

the correct path to the grub is /boot/grub/menu.lst but i dont think you require tinkering there.

I edited the fstab I could get to after manually mounting /dev/sda2 and rebooted. The same message came up demonstrating that the partition where fstab resides has not been mounted yet and the file hasn’t been read.

I looked in menu.lst when I eventually found it and realise that the boot loader has the unrecognised device paths for the swap and root partitions. Thank you Fruchtratte for pointing me to the correct file (and reo_sam for the correct path to that file).

My next step will be to Escape from the graphical boot menu to the text version and edit the command line so that it mounts /dev/sda2 on boot. This is the step I needed reminding about.

Once in a running system I shall edit /etc/fstab and /boot/grub/menu.lst to have usable parameters then mkinitrd. Will this be enough?

I had seen (observed) the same problem of install (SLES 10 sp3 in that case) putting one device ID into intrd but the device having a different id after the reboot. With auto-yast a chroot script was generated to fix the files before mkinitrd is run.

It will probably be late tomorrow before I can do any more with this box. I will post an update when I have further questions or a solution to report.

You might use the halinfo script with the syntax **halinfo -hV **or halinfo -uV to display UUIDs and diskIDs of all your partitions and use UUIDs or labels (if you made some) rather than /dev/disk/by-id (which are symbolic links generated at boot time) in /etc/fstab. Never use device names (sdaX, sdbX) in /etc/fstab or you will run into problems if those device names change (they occasionally do). You can also use the command blkid to display UUIDS, but halinfo can display both.
Displaying partitions infos from hal daemon

While installing openSUSE in expert mode, you can choose to mount the partition by UUIDs by clicking on the button labeled “Fstab Options…” after selecting the mountpoint for each partition as well as the swap partition. UUIDs don’t change until you reformat the partition. DiskIds don’t change even if you reformat the partition - since they are based on the hard disk serial number - … however symlinks might point to the wrong partition as they rely on the udev daemon. (although it is not supposed to happen but mounting by UUIDs is safer an easier IMO - unless you intend to clone hard disks and mount the original and the copy at the same time).

/etc/fstab syntax while mounting by UUIDs (example):

UUID=1cb99824-88d5-4801-828f-787564db749d /home ext3 acl,user_xattr 0 2

Thanks for the interest and suggestions.

The initial problem was that the bootloader held references to the swap and root partitions which were not valid on reboot. In order to boot a fully working system I escaped the graphical boot menu, edited the commands for the normal boot option to reference /dev/sda1 and /dev/sda2 - this enabled the system to boot.

Next I downloaded the halinfo script recommended by please_try_again and ran it to find the UUIDs of each partition.

The I edited /etc/fstab to mount partitions by UUID and ran /etc/sysconfig/bootloader to update the bootloader.

The working system now boots every time.