Problems with cryptsetup during update

If you are not using enCRYPTED volumes or swap, then you don't need cryptsetup, just uninstall it and reboot using the following commands:

sudo apt-get remove cryptsetup
# it's better to update and reinstall GRUB before rebooting
sudo update-grub
sudo grub-install /dev/<your_device_id>
sudo reboot

To find your device id, run:

lsblk

and locate the disk which contains a partition mounted at /boot/*. Note that you should use the device id (e.g. /dev/sda), not the partition id (e.g. /dev/sda1)

To make sure you are not using crypted filesystems please check /etc/fstab, if you see the option 'crypt' anywhere, then you require cryptsetup and what you need is to configure it properly.


This warning appeared inexplicably after I mounted two previously inactive disks as RAID 1, assigned a UUID to it, and later there was a kernel update.

To fix the warning, the first thing to do is

$ lsblk -f

to obtain the UUID value from the line "/".

This UUID is then entered in two files. In the file etc/fstab in the line containing the root "/", e.g: "/dev/sda3 / ext4 defaults 0 0". The part "dev/sda3" is replaced by "UUID=value":

UUID=cb2f354f-9e7a-44f8-8a01-2ef1e0b66c31 / ext4 defaults 0 0

In the file /etc/initramfs-tools/conf.d/resume the UUID is entered in this form:

RESUME=UUID=cb2f354f-9e7a-44f8-8a01-2ef1e0b66c31

Then the following command:

$ update-initramfs -u -k all

The warning should have disappeared and a reboot should be running.


Pre-information: I am using btrfs within LUKS with an unencrypted boot partition. For LVM or other setups the solution may differ!

If you actually are using cryptsetup and encounter this error, the fix for me was to:

  1. Make sure the /etc/crypttab file is set up correctly. There should be at least one entry named "root", this is the root / entry. This was crucial for me - and nobody mentioned it so far!
  2. This entry should be referred to in the /etc/fstab with /dev/mapper/root. Check that the UUIDs are correctly set up
  3. Now run update-initramfs -u which udpates only your most recent kernel. If a cryptsetup warning pops up, you failed on the previous steps. Review all files and try figure out the problem
  4. Run update-grub to fix any remaining grub issues
  5. Now check the /boot/grub/grub.cfg. Go search for the first menuentry which is the one that will be booted. The search part should contain the UUID of the boot partition (unencrypted!). The linux part should have something saying that root=/dev/mapper/root or pointing to the UUID of the unencrypted volume (in my setup the btrfs volume)

Good luck!