Okay, I think I somehow just lost all of my data.

I installed Ubuntu 20.04 on one disk. In the installer (using the "other"-option for manual installation), I used one partition for /boot, and another one as encrypted device, where / is mounted. So far so good. I have another disk, which I also tried to mount (but not change) during installation. For that I also selected "use as logical volume for encryption" (or somesuch) and entered a passphrase. Then I used that volume as ext4. However, in the list, the tickbox for "format drive" was ticked, and greyed out, which I didn't like at all. So I went back a step, and repeated the same steps, upon which an error popup appeared which shows a big "x" and says: an error occurred while configuring encrypted volumes - the configuration has been aborted. Upon seeing that, I canceled the installation, rebooted and tried again.

This time, I used them as encrypted volume, but selected "don't use" instead of "ext4". This time, the tickbox indicated that the drive will not be formatted, and I pressed continue. A popup told me that the partition table of that drive would be modified (as well as that the \boot and \ partitions will be formatted, no problem there). I did not want that, so I canceled again.

After another reboot, I simply installed, without touching the additional drive (same as I did for another drive, with windows partitions on it).

Now after installation, It seems the data on the LUKS encrypted drive is gone. I can luksOpen it okay, but cannot mount it.

When using the GUI "Disks" utility that comes with ubuntu, it just says "unknown" after unlocking it (instead of for example "filesystem ext4") If using luksOpen and mount, I get an error of the type wrong fs type, bad option, bad superblock on /dev/mapper/mydrive, missing codepage or helper program, or other error.

Did I overwrite my LUKS volume with an empty one during installation (even though I am 100% certain that I never agreed to write changes to disk? (As far as I know, in older ubuntu versions, changes are only ever made after proceeding to the next step). If I did overwrite my LUKS volume, that would explain why I can open it (same password as before), but not mount it (I did not create any new partition inside). Did this strange error popup during my earlier tries erase everything?

What kind of further data could I provide to help diagnose this?

How would I go about finding more about that error

edit: I repeated my steps, to try to reproduce the error (I added the verbatim text above). I used the newly installed \ drive to reproduce the error (which indeed appears after going back, and trying again, as mentioned above). I then canceled the isntallation, and now the old LUKS-encrypted \ device can no longer be found during boot.

So either the error causes something to be written to disk, or even without the error, the installer creates new (empty) LUKS volume before one ever presses "continue".

The question now becomes: Are my old LUKS headers gone, or can I somehow get the drive to work again?

these may be related bugs? https://bugs.launchpad.net/ubuntu-mate/+bug/1894013 https://bugs.launchpad.net/ubuntu/+source/systemsettings/+bug/1761681

  • What exact commands are you using, vgscan, vgchange, lvs, etc. before you try the mount, and what is the exact mount command? See cyberciti.biz/faq/linux-mount-an-lvm-volume-partition-command
    – ubfan1
    Jan 1, 2021 at 17:43
  • I simply use "sudo cryptsetup luksOpen /dev/sda1 mydrive", "sudo mkdir /mnt/mydir" and "sudo mount /dev/mapper/mydrive /mnt/mydir".
    – Bernhard
    Jan 1, 2021 at 19:08
  • @ubfan1 Also: I am not using any fancy LVM features. The drive in question (sda) contains a single encrypted volume, which in turn contains a single ext4 partition.
    – Bernhard
    Jan 1, 2021 at 19:55


You must log in to answer this question.

Browse other questions tagged .