Setting up swap fails when setting lvm+encryption

Bug #539324 reported by Steve Beattie on 2010-03-15
This bug affects 19 people
Affects Status Importance Assigned to Milestone
partman-base (Ubuntu)
Colin Watson
Colin Watson

Bug Description

Binary package hint: debian-installer

ISO: ubuntu alternate amd64 from 20100315

Selecting guided partitioning using lvm+encryption, the partitioning stage generates an error after creating the partitions "The attempt to mount a file system with type swap in LVM VG lucid-amd64, LV_swap1 at none failed. You may want to resume partitioning from the partitioning menu."

Repeating the setup fails again in the same way.

Steve Beattie (sbeattie) wrote :
Steve Beattie (sbeattie) wrote :
tags: added: iso-testing
Paul Hummer (rockstar) wrote :

This basically blocks my real ability to test Lucid. My current install is not encrypted now, and so I don't have any desire to do anything of value on my system. I figure I'll have to re-install when this is fixed.

Can we please make this bug critical?

Steve Langasek (vorlon) on 2010-03-16
Changed in debian-installer (Ubuntu Lucid):
importance: Undecided → High
Charlie Kravetz (charlie-tca) wrote :

This is also failing on Xubuntu using the lucid-alternate-i386.iso dated 2010-03-16.1. I can confirm the bug report using Hardware test; 400 MHz P2; 384MB RAM; NVidia/SGS Thomsom Riva 128 w/4MB memory

Changed in debian-installer (Ubuntu Lucid):
status: New → Confirmed
C de-Avillez (hggdh2) wrote :

Also failing on standard server install. Error in syslog: Unable to find swap-space signature.

Colin Watson (cjwatson) wrote :

I think what's happening is that nothing ever commits the partitioning before we try to swapon. I haven't quite figured out exactly where the commit ought to go yet, though.

Colin Watson (cjwatson) wrote :

Actually, that isn't right - I can see the CREATE_FILE_SYSTEM command happening. Something stranger is afoot.

Paul Hummer (rockstar) wrote :

The installer's log claims that it successfully mounts the root filesystem, so it's partitioning fine. It's on the mount of swap that it has on error.

Colin Watson (cjwatson) wrote :

When I strace this, it goes away, so I think it must be a race. Argh.

gmoore777 (guy-moore) wrote :

This is happening to my install with today's 3/17/2010 LucidLynx 64 bit build.
On a Dell Latitude E6400, Intel Core 2 Duo@2.534 GHz, 4 GB Memory, and 80.0 GB ATA Hitachi HTS72328 hard drive.
(Encrypting with HardyHeron worked on Monday September 29th, 2009)
(This same operation worked on a different Dell E6400 using LucidLynx Alternate CD burned on or about Feb 22, 2010. It had a different set of problems, but not this particular problem.)
Anxiously waiting for a fix or work around.

starslights (starslights) wrote :

Same for me on x86 64 in VM with same message error

Jeff Lane (bladernr) wrote :

Also seen on Ubuntu 32bit Alternate install...

gmoore777 (guy-moore) wrote :

Via the menus, I am able to successfully, manually partition the disk and do all the steps.

This is a bit long, and credit goes to other postings in the past, but here is what I did, to
create a non-encrypted /boot partition and an encrypted / (root) partition.
I've attached it as a Microsoft Word Document (sorry).
Hopefully you can follow my formatting and arrows.

Also seen on Ubuntu Studio Alternate i386 (20100317)

Colin Watson (cjwatson) wrote :

Thanks for all your comments. I can reproduce this bug myself, so there is no need to post further comments about how it can be reproduced or listing other affected images.

I managed to work around this bug by letting the installer set up full-disk encryption as usual. When the error message came, I chose "Yes" to display the partitioning scheme already created by the installer. Here I changed the type of the swap partition from "swap" to "do not use". The installation completed successfully after that.

Then, right after first booting into the new system, I manually turned the unused partition (named /dev/<hostname>/swap_1) into a proper swap partition by following these instructions:

Entering two commands (mkswap, swapon) at the terminal, adding the swap partition to /etc/fstab and testing the whole thing by rebooting the computer took just a couple of minutes.

Joel Ebel (jbebel) on 2010-03-23
tags: added: glucid
linux4me (ta2008) wrote :

Another workaround similar to Sebasitan's is to choose "Yes" when you get the error message to go back to the summary screen. Select the swap partition, hit Enter to modify it, choose "swap" as the type and hit Enter again. Then scroll down and select "Finish" to complete the installation. It seems to complete successfully after that without the necessity of manually setting up the swap partition after the first boot. The swap partition does appear in /etc/fstab.

yurx cherio (cherio) wrote :

I was trying to set up LVM on RAID0 without encryption and it didn't work either. It was failing with the same "Unable to find swap-space signature" error.
I had to set up 3 RAID0 devices instead in order to not to use LVM.

Colin Watson (cjwatson) on 2010-03-24
Changed in debian-installer (Ubuntu Lucid):
milestone: none → ubuntu-10.04-beta-2
Colin Watson (cjwatson) on 2010-03-24
Changed in debian-installer (Ubuntu Lucid):
assignee: nobody → Colin Watson (cjwatson)
Colin Watson (cjwatson) on 2010-03-29
affects: debian-installer (Ubuntu Lucid) → partman-base (Ubuntu Lucid)
Changed in partman-base (Ubuntu Lucid):
status: Confirmed → Triaged
James Neave (roboj1m) wrote :


I've been trying to install Lucid Server 64bit Beta 1 with the following config:

8Gb usb flash --> ext4 on /boot

3 x 500gb SATA --> RAID5 --> lvm --> ext4 on / & 8G swap.

The install would lock the machine completely after finishing creating the ext4 filesystem on vg_main, lv_root.

I can confirm that not assigning the swap and leaving it as "do not use" works and the machine goes on to continue the install procedure.



Launchpad Janitor (janitor) wrote :

This bug was fixed in the package partman-base - 139ubuntu3

partman-base (139ubuntu3) lucid; urgency=low

  * parted 2.1 changed the semantics of ped_disk_clobber: it now zeroes out
    the first few and last few sectors of the disk, regardless of whether
    there appears to be a valid partition table on it. Unfortunately, this
    means that creating a filesystem on a whole disk device and then calling
    ped_disk_commit_to_dev zeroes the filesystem header we just created. To
    avoid this, call ped_disk_commit_to_dev only if the partition doesn't
    start at sector zero (LP: #539324, #549260).
 -- Colin Watson <email address hidden> Mon, 29 Mar 2010 21:55:02 +0100

Changed in partman-base (Ubuntu Lucid):
status: Triaged → Fix Released
Colin Watson (cjwatson) wrote :

James, your description doesn't really match the original description of this bug, so it may not be the same thing. However, of course it's possible that my fix will cover your problem as well. I'd encourage you to test beta-2 once released, and if you're still having problems please file a new bug with as much detail as you can rather than following up to any existing bug. Thanks.

RJARRRPCGP (rjarrrpcgp) wrote :

I got the same type of error.

"The attempt to mount a file system with type swap in /dev/sda3 at none failed." (or similar)

RJARRRPCGP (rjarrrpcgp) wrote :

Then it freezes after it offers me to go back to the partitioning options screen.

Thanks, but I only need continued reports of this problem if they're
occurring on a daily build that postdates my fix, in which case details
of which build and log files are necessary.

I'm encountering this same issue with the 10.10 Alternate installer (amd64). In my case, I'm trying to install to existing encrypted lvms on an existing RAID5. The installer can't seem to handle the RAID either ( I have to assemble myself from the shell). It also fails to unlock ( I have to do it via cryptsetup from the shell). However, I can install via the no-swap workaround described above just no issues with the RAID or crypt once I unlock them manually....just something about mounting that swap apparently....

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers