From fa9362f14760c32e49fea6b71e6e3198dfb5c6c3 Mon Sep 17 00:00:00 2001 From: Forza Date: Fri, 24 Nov 2023 08:33:29 +0100 Subject: [PATCH] Upload files to "udev" udev rule to mask the filesystem UUID of the origin device. --- udev/90-dmcache.rules | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 udev/90-dmcache.rules diff --git a/udev/90-dmcache.rules b/udev/90-dmcache.rules new file mode 100644 index 0000000..cf19b21 --- /dev/null +++ b/udev/90-dmcache.rules @@ -0,0 +1,7 @@ +# /etc/udev/rules.d/90-dmcache.rules +# udev rule for dm-cache to remove origin device FS UUID device link. +# +# `blkid` can be used to find the filesystem uuid: +# /dev/sdj1: LABEL="usb-backup" UUID="df68a30d-d26e-4b9c-9606-a130e66ce63d" + +ENV{ID_FS_UUID_ENC}=="df68a30d-d26e-4b9c-9606-a130e66ce63d", KERNEL=="sd*", SUBSYSTEM=="block", ACTION=="add|change", SYMLINK-="disk/by-uuid/$env{ID_FS_UUID_ENC}"