Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

systemd-cryptsetup v220 breaks non-LUKS devices with unspecified type #442

Open
kevinoid opened this Issue Jul 1, 2015 · 4 comments

Comments

4 participants
@kevinoid
Copy link

kevinoid commented Jul 1, 2015

On a system running the Debian testing distribution, I recently upgraded the systemd package from 215-18 to 220-7. The system now fails to open the swap device (/dev/sda7) on boot with the following message:

systemd-cryptsetup[23252]: crypt_load() failed on device /dev/sda7.
systemd-cryptsetup[23252]: Failed to activate: Invalid argument

The device is configured as a plain (non-LUKS) device using a keyfile with the following line in /etc/cryptsetup:

sda7_crypt /dev/sda7 /sda7_crypt.keyfile discard,hash=ripemd160

I tracked the issue down to a change in commit 7376e83528 at line 408 which now causes systemd-cryptsetup to fail rather than retry as plain for devices of unspecified type. Since there is no mention of this change in Bug 66396, I assume the change was inadvertent. If the change was intentional, I would highly suggest documenting it as a breaking change for system administrators in the upgrade notes.

Thanks,
Kevin

@kevinoid kevinoid changed the title v220 breaks non-LUKS devices with unspecified type systemd-cryptsetup v220 breaks non-LUKS devices with unspecified type Jul 1, 2015

@poettering

This comment has been minimized.

Copy link
Member

poettering commented Jul 11, 2015

Yeah. That change was not intended afaics. would be happy to take a patch that restores old behaviour on this one.

@sledges

This comment has been minimized.

Copy link

sledges commented Aug 15, 2015

Seeing exactly the same behaviour, I wonder how come only two of us affected (not a common setup?), and google hasn't indexed "crypt_load() failed on device" to point to this issue, so spent whole evening yesterday trying to bring my laptop back up :) (by downgrading systemd for now :/) ArchLinux here

@sledges

This comment has been minimized.

Copy link

sledges commented Aug 15, 2015

adding "plain," before "cipher=" to crypttab solves the problem, so this issue is only for backwards compatibility to avoid nasty surprises :)

@daryltucker

This comment has been minimized.

Copy link

daryltucker commented Oct 6, 2015

The Archlinux Wiki mentions a workaround for this issue, for those looking.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.