Karmic update doesn't recognize encrypted hard disk

Asked by David Brownlee

Upgraded 64bit Desktop from Jaunty to Karmic Beta using "update-manager -d". The upgrade completed successfully but, on reboot, it is unable to find the encrypted harddrive. This is on a laptop which was initially installed using the Jaunty alternate iso image so that the entire harddisk could be encrypted. At present, it prints a message about not finding the disk and drops me out to a Busybox "(initrdfs)" prompt.

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Solved by:
David Brownlee
Solved:
Last query:
Last reply:
Revision history for this message
David Brownlee (david-m-brownlee) said :
#1

Confirmed on another, older laptop that the same problem exists for upgrades on 32bit systems.

Revision history for this message
David Brownlee (david-m-brownlee) said :
#2

Hmm, this may be bug #430496. I will dig further tonight and link to the bug if it turns out to be the same.

Revision history for this message
David Brownlee (david-m-brownlee) said :
#3

OK, this doesn't look like the same bug. I changed "splash" to "nosplash" on the kernel arguments in grub and all I see on boot is:

  Boot from (hd0,4) ext2 9df54a9f-bee2-48cd-ae71-863098345c65
  Starting up ...

The cursor sits there blinking under the 'B' and then it appears that some timeout it reached and it writes to the screen without first clearing it leaving me with:

  Boot froCheck cryptopts=source= bootarg cat /proc/cmdline5c65
  Startingor missing modules. devices: cat /proc/modules ls /dev
  -r ALERT! /dev/disk/by-uuid/927c495b-179f-439a-9580-6cb6057b92ea does not exist.
   Dropping to a shell!

  BusyBox v1.13.3 (Ubuntu 1:1.13.3-1ubuntu7)
  Enter 'help' for a list of built-in command

  (initramfs) _

Revision history for this message
David Brownlee (david-m-brownlee) said :
#4

OK, I've linked a bug. In addition to changing "splash" to "nosplash", I also had to remove "quiet" (didn't see that before) from the kernel boot arguments. Doing that allowed me to see it was hanging on "Waiting for encrypted source device..."

While I'm waiting for a fix, I'll make sure to back up the files on the encrypted harddrive. In case anyone else is in the same situation and is stuck, here is how I can get to my files:

1. Boot from a Ubuntu LiveCD (I'm using Karmic Beta)
2. Open a terminal window and switch to the root user with "sudo su -"
3. Unlock the encrypted disk with "cryptsetup luksOpen /dev/sda1 somelabel" (try "fdisk -l" if you don't know your device)
4. Install LVM2 with "apt-get install lvm2" (this assumes your network is working)
5. Find the name of the volume group with "vgscan" (my volume group is called "lenovo" as shown next)
6. Activate the volume group with "vgchange -v -a y lenovo"
7. Use "vgdisplay -v" (or just look in /dev/lenovo) to find the logical volume you want to mount (mine was called "/dev/lenovo/root")
8. Mount the partition with "mount /dev/lenovo/root /mnt"

Your encrypted root file system is now under /mnt and you can start backing up to USB or across the network.

Revision history for this message
David Brownlee (david-m-brownlee) said :
#5

Bug is 446591

Revision history for this message
Gunni (fgunni) said :
#6

Just as additional info:
For me booting with the old jaunty kernel in recovery mode does work, so no need of livecd, if that works for you, too.

Revision history for this message
Gunni (fgunni) said :
#7

Found a workaround to get your system running again:

http://ubuntuforums.org/showpost.php?p=7159100&postcount=4

Revision history for this message
David Brownlee (david-m-brownlee) said :
#8

Unfortunately, I discarded the old kernel during the upgrade.

Also, building a new initrd as in the forum link doesn't work for me either. I followed what he was doing making adjustments for my different partitions (and not copying the original initrd image into the new image which, if I read his instructions right, is what he did and resulted in an initrd image significantly bigger than the original). However, his setup is slightly different than mine. In my case, I have the unencrypted boot partition and only one encrypted partition partition containing a PV for LVM which is the sole PV of a volume group that is then split into two LVs, one for the root partition and the other for swap. It does not appear that the example in the link was using LVM within an encrypted partition.

It also appears that this is not new to Karmic. I found this expired post as well:
https://answers.launchpad.net/ubuntu/+question/68158

Gunni, thanks for looking at the problem.

Revision history for this message
David Brownlee (david-m-brownlee) said :
#9

OK, since one other person commented that this worked for them, I thought I would look at it again. The initrd in the forum link is 2.6.28-11. I only have 2.6.31-11 and 2.6.28-15 on my system and I initially only tried 2.6.31-11 as it was the most recent. I did leave the lvm options the first time and I checked to see if I had any other typos and it looks good but does not work. However, I made the same changes with the initrd for 2.6.28-15 and that *does* boot now so possibly there is a second problem introduced after 2.6.28.

This still seems pretty broken though and booting this way has introduced some new problems that I did not have with the Karmic Beta LiveCD or 9.04 (touchpad no longer recognized and, after plugging in a usb mouse and usb external harddrive, both of which work, lsusb just returns the prompt). At this point, I've backed up my data so a clean install of Karmic Beta is looking pretty good. I already did that with my other laptop and it has been working fine.

Revision history for this message
wesley fitzgerald (wood45log) said :
#10

please forward me the answer at <email address hidden> as this is artist X im using and i dos,ent have encrypt my desktop only if i sign in which contradicts it self but i like the pro gramme so im out in the cold there so how can you ypou get a system that doesn't account for hackers and the like thank you Wes