Skip to contentSkip to conversation

support LUKS2 labels on md raid arrays

PATCH New Andreas Klauer 1 participant 1 message Dec 7, 2021 MD RAID

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 support LUKS2 labels on md raid arrays

I noticed that with LUKS2 on mdadm arrays, the by-label symlinks would not show up at all, so here is a trivial change to make it work for md.

See also

* https://gitlab.com/cryptsetup/cryptsetup/-/issues/382
* https://github.com/systemd/systemd/commit/f2bd752215cba2f90697edd7e3ff5e859a6b9a4c

---
 udev-md-raid-arrays.rules | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
udev-md-raid-arrays.rules +1 -1
index 13c9076e..bd23abba 100644
@@ -32,7 +32,7 @@ OPTIONS+="link_priority=100"
 OPTIONS+="watch"
 ENV{ID_FS_USAGE}=="filesystem|other|crypto", ENV{ID_FS_UUID_ENC}=="?*", SYMLINK+="disk/by-uuid/$env{ID_FS_UUID_ENC}"
 ENV{ID_FS_USAGE}=="filesystem|other", ENV{ID_PART_ENTRY_UUID}=="?*", SYMLINK+="disk/by-partuuid/$env{ID_PART_ENTRY_UUID}"
-ENV{ID_FS_USAGE}=="filesystem|other", ENV{ID_FS_LABEL_ENC}=="?*", SYMLINK+="disk/by-label/$env{ID_FS_LABEL_ENC}"
+ENV{ID_FS_USAGE}=="filesystem|other|crypto", ENV{ID_FS_LABEL_ENC}=="?*", SYMLINK+="disk/by-label/$env{ID_FS_LABEL_ENC}"
 
 ENV{MD_LEVEL}=="raid[1-9]*", ENV{SYSTEMD_WANTS}+="mdmonitor.service"
 
Signature · 1 line
2.34.1