Linux (kubuntu) 9.10 upgrade major fail.

I spent most of last night trying to upgrade my laptop OS from Kubuntu 9.04 to 9.10 (Karmic Koala), but something went very wrong along the way. I have already searched through ubuntuforums but I am not linux-savvy enough to tell whether the problems other people are having with the upgrade are similar to mine. I even posted a thread there but so many people are having trouble that mine seems to have sunk already. Thus, I come to the dope (where people are smarter anyway :)) I have always been able to solve my linux problems with a bit of googling, but this one I can’t handle on my own.

Whenever I boot I just end at a prompt saying:


(initramfs)_  

I figured out that I could boot from an older kernel (2.6.28-16 as opposed to the new 2.6.31) but now I have lost all wireless connections and all sound. Both of these problems seem to be relatively common in connection with this update and they should be solvable by booting from the new kernel. The thing is: I have no idea how to do that.

By the way: iwconfig gives me


lo no wireless extensions
 eth0 no wireless extensions

I have had wireless issues before, but never this one.

At least part of the problem can be seen here (I think - as I said I’m not particularly good at linux, but rummaging around I noticed this):


kasparhauser@Kalidasa:~$ apt-cache policy linux-image-generic
linux-image-generic:
  Installed: 2.6.31.14.27
  Candidate: 2.6.31.14.27
  Version table:
 *** 2.6.31.14.27 0
        500 http://dk.archive.ubuntu.com karmic/main Packages
        100 /var/lib/dpkg/status
kasparhauser@Kalidasa:~$ lsb_release -rd
Description:    Ubuntu 9.10
Release:        9.10
kasparhauser@Kalidasa:~$ apt-cache policy grub
grub:
  Installed: (none)
  Candidate: 0.97-29ubuntu59
  Version table:
     0.97-47lenny2 0
        100 /var/lib/dpkg/status
     0.97-29ubuntu59 0
        500 http://dk.archive.ubuntu.com karmic/main Packages

Does this mean I have no grub installed - and what does that mean exactly?

I have access to another machine + a usb pen so installing stuff should be possible if necessary.

Any help will be much appreciated. Thanks.

The most likely explanation is that your grub bootloader isn’t installed/configured correctly. I’m assuming that the kernel and modules for 2.6.31 are installed.

I would first try to re-install grub. That should I think also reconfigure it. If not, try dpkg-reconfigure grub. If that doesn’t work, check /boot/menu.lst for suspicious entries.

Make sure you back up /boot/menu.lst first.

PS: if you can connect the machine with a cable instead of wireless, it’s a lot easier to do upgrades than moving files back and forth with a usb stick.

Thanks. I tried upgrading to grub2, but no luck. I can still boot with 2.6.28 (typing from my laptop now - thanks for the tip on using a wire), but when I try 2.6.31 it just hangs for a very long time and falls back to the “initramfs_”-prompt.

Don’t know if this clarifies anything, but here is my /boot/grub/grub.cfg:


if [ -s /boot/grub/grubenv ]; then
  have_grubenv=true
  load_env
fi
set default="0"
if [ ${prev_saved_entry} ]; then
  saved_entry=${prev_saved_entry}
  save_env saved_entry
  prev_saved_entry=
  save_env prev_saved_entry
fi
insmod ext2
set root=(hd0,1)
search --no-floppy --fs-uuid --set cb6b8d4c-cce6-4fa8-82e6-e1156fe86ccf
if loadfont /usr/share/grub/unicode.pf2 ; then
  set gfxmode=640x480
  insmod gfxterm
  insmod vbe
  if terminal_output gfxterm ; then true ; else
    # For backward compatibility with versions of terminal.mod that don't
    # understand terminal_output
    terminal gfxterm
  fi
fi
if [ ${recordfail} = 1 ]; then
  set timeout=-1
else
  set timeout=3
fi
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/05_debian_theme ###
set menu_color_normal=white/black
set menu_color_highlight=black/white
### END /etc/grub.d/05_debian_theme ###

### BEGIN /etc/grub.d/10_linux ###
menuentry "Ubuntu, Linux 2.6.31-14-generic" {
        recordfail=1
        if [ -n ${have_grubenv} ]; then save_env recordfail; fi
	set quiet=1
	insmod ext2
	set root=(hd0,1)
	search --no-floppy --fs-uuid --set cb6b8d4c-cce6-4fa8-82e6-e1156fe86ccf
	linux	/boot/vmlinuz-2.6.31-14-generic root=UUID=cb6b8d4c-cce6-4fa8-82e6-e1156fe86ccf ro   quiet splash
	initrd	/boot/initrd.img-2.6.31-14-generic
}
menuentry "Ubuntu, Linux 2.6.31-14-generic (recovery mode)" {
        recordfail=1
        if [ -n ${have_grubenv} ]; then save_env recordfail; fi
	insmod ext2
	set root=(hd0,1)
	search --no-floppy --fs-uuid --set cb6b8d4c-cce6-4fa8-82e6-e1156fe86ccf
	linux	/boot/vmlinuz-2.6.31-14-generic root=UUID=cb6b8d4c-cce6-4fa8-82e6-e1156fe86ccf ro single 
	initrd	/boot/initrd.img-2.6.31-14-generic
}
menuentry "Ubuntu, Linux 2.6.28-16-generic" {
        recordfail=1
        if [ -n ${have_grubenv} ]; then save_env recordfail; fi
	set quiet=1
	insmod ext2
	set root=(hd0,1)
	search --no-floppy --fs-uuid --set cb6b8d4c-cce6-4fa8-82e6-e1156fe86ccf
	linux	/boot/vmlinuz-2.6.28-16-generic root=UUID=cb6b8d4c-cce6-4fa8-82e6-e1156fe86ccf ro   quiet splash
	initrd	/boot/initrd.img-2.6.28-16-generic
}

The entries for the two kernels look identical to me - so why can’t I boot the first one?

CAREFUL

Grub2 is installed already by default. Installing Grub won’t help matters, and might only make matters worse.

If you can boot into an older kernel, do so, and back up ALL of your important data at once.

An initramfs error is very low level - it might mean a problem with grub2 and your hardware. Did you try a Live CD, and did it work on your computer? What “problems” did you encounter during the upgrade?

It may be easiest to just re-format and start over. I keep my /home partition on a separate partition so that I can reformat my / partition (the system partition) willy nilly, and my documents are safe.

Thank you for the reply, Casserole. I realised after my grub->grub2 “upgrade” that grub2 is the default in Karmic.
Anyway - the thing that bugs me is that as far as I can see, everything should be working already. Trying to boot with the Karmic kernel gives me this error message:


 Gave up waiting for root device 
...
...
Alert! /dev/by-uuid/xxxx-xxx-etc. does not exist 

The problem is that the older kernel (which I am using now) uses the exact same UUID as the newer one is supposed to use i.e: the UUID exists and works. In my previous post you can see that the configurations (grub.cfg) for the two kernels are identical. I have absolutely no idea why one works and the other doesn’t.
I know that the easiest thing would probably be to do a fresh install of Karmic, but unlike Casserole I wasn’t clever enough to realise that not having my /home partition on a separate partition would pose a problem some day. Swiping the drive will be a last resort. (I am moving the most vital stuff now, though, in case of a fatal error later on).

Update - and a breakthrough (if anyone cares but me ;)). The UUID problem is so common, apparently, with this upgrade that an official workaround has been published. Basically I had to change the /etc/default/grub to not check for UUID. Easy.

Next issue: Booting results in either a black screen or a strange flickering reddish-white colour. This, apparently, is another “common issue” for users with intel graphics chips. The solution consists in adding the line “i915.modeset=0” to the same /default/grub file as above.

My os boots, and I have sound :). The only issue left is the missing wi-fi which I imagine is also a “common problem”:rolleyes:.

Yay!