HomeFreeBSD

dracut: Fix race condition between load-key and import

Description

dracut: Fix race condition between load-key and import

zfs-load-key.sh is called by the dracut-pre-mount.service unit which has
no explicit 'After' dependency on zfs-import.target. That way it can be
that the pool has not yet been imported and the zfs-load-key.sh finishes
without ever seeing the relevant pool.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Lorenz Hüdepohl <dev@stellardeath.org>
Closes #11500

Details

Provenance
Lorenz Hüdepohl <dev@stellardeath.org>Authored on Jan 26 2021, 8:14 PM
GitHub <noreply@github.com>Committed on Jan 26 2021, 8:14 PM
Parents
rGf4f50a70488e: spa_export_common: refactor common exit points
Branches
Unknown
Tags
Unknown

Event Timeline

GitHub <noreply@github.com> committed rGcaedada66e1c: dracut: Fix race condition between load-key and import (authored by Lorenz Hüdepohl <dev@stellardeath.org>).Jan 26 2021, 8:14 PM