Skip to content

systemd-cryptsetup - Failed to deactivate error on shutdown with cryptsetup 2.0 #8472

@xabbu

Description

@xabbu

Submission type

  • Bug report

systemd version the issue has been seen with

237.0, 238.0

Used distribution

Manjaro / Arch Linux

In case of bug report: Expected behaviour you didn't see

clean shutdown of LUKS encrypted devices which are mounted thru crypttab.

In case of bug report: Unexpected behaviour you saw

When systemd is built with cryptsetup 2.0.2 (also with cryptsetup 2.0 and 2.0.1), on shutdown I see errors like this

systemd-cryptsetup[2521]: Failed to deactivate: Device or resource busy
systemd[1]: [email protected]: Control process exited, code=exited status=1
systemd[1]: [email protected]: Failed with result 'exit-code'.
systemd[1]: Stopped Cryptography Setup for Data.

Usually one for every mounted LUKS device, that I have in my crypttab.

The LUKS encrypted device is mounted with an entry in crypttab. The Options are "luks,timeout=180". This is not a LUKS2 device.

When I build systemd with cryptsetup 1.7.5, there are no such errors.

A more complete journal excerpt.

In case of bug report: Steps to reproduce the problem

build systemd with cryptsetup 2.0.2 and use /etc/crypttab to mount a luks encrypted device. Shutdown this system and check the journal after the next boot.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions