[pkg-cryptsetup-devel] Bug#1125472: cryptdisks_start is case-sensitive to PARTUUID in /etc/crypttab entry
Graeme Hewson
debian at wormhole.me.uk
Wed Jan 14 11:53:53 GMT 2026
Package: cryptsetup
Version: 2:2.8.3-1
sfdisk displays the following for a swap partition:
------------------------------------------------------------
root at debian:/home/user# sfdisk --part-uuid /dev/sdb 9
AB20A9BE-D613-4F24-A7DA-FBCEC20FC644
------------------------------------------------------------
So this entry in /etc/crypttab should work:
------------------------------------------------------------
myswap PARTUUID=AB20A9BE-D613-4F24-A7DA-FBCEC20FC644 /dev/urandom swap,plain,cipher=aes-xts-plain64,size=256
------------------------------------------------------------
But it doesn't work:
------------------------------------------------------------
root at debian:/home/user# cryptdisks_start myswap
Starting crypto disk...myswap (skipped, device PARTUUID=AB20A9BE-D613-4F24-A7DA-FBCEC20FC644 does not exist)...failed
------------------------------------------------------------
Puzzlement ensues...
The answer is that cryptdisks_start is case-sensitive to PARTUUID, and hex
digits must be written in lower case.
This entry...
------------------------------------------------------------
myswap PARTUUID=ab20a9be-d613-4f24-a7da-fbcec20fc644 /dev/urandom swap,plain,cipher=aes-xts-plain64,size=256
-------------------------------------------------------------
... does work:
-------------------------------------------------------------
root at debian:/home/user# cryptdisks_start myswap
Starting crypto disk...myswap (starting)...myswap (started)...done.
-------------------------------------------------------------
I'm using a live boot of sid:
-------------------------------------------------------------
root at debian:/home/user# cat /etc/os-release
PRETTY_NAME="Debian GNU/Linux forky/sid"
NAME="Debian GNU/Linux"
VERSION_CODENAME=forky
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"
IMAGE_ID=live
BUILD_ID=20251229T080959Z
-------------------------------------------------------------
The problem also occurs with earlier releases of cryptsetup (I originally
encountered the problem on Kubuntu 25.04).
Incidentally, sgdisk (not available on the live boot) also outputs the
partition UUID with upper-case hex digits:
-------------------------------------------------------------
# sgdisk --info=9 /dev/sdh
Partition GUID code: 0657FD6D-A4AB-43C4-84E5-0933C84B4F4F (Linux swap)
Partition unique GUID: AB20A9BE-D613-4F24-A7DA-FBCEC20FC644
...
...
-------------------------------------------------------------
/dev/disk/by-partuuid lists lower-case digits, however.
More information about the pkg-cryptsetup-devel
mailing list