File 0002-udev-optionally-disable-the-generation-of-the-partla.patch of Package systemd.24274
From da553accaab79707358b9bc32abfbf79fe0da4ac Mon Sep 17 00:00:00 2001
From: Franck Bui <fbui@suse.com>
Date: Tue, 21 Aug 2018 16:21:53 +0200
Subject: [PATCH 2/2] udev: optionally disable the generation of the
'partlabel' symlinks
We already addressed bsc#1089761 to prevent the generation of
"primary" or "logical".
But it wasn't enough: some users could also have used their own
name other than "primary" and "logical" of course...
For them, we introduce "udev.no-partlabel-links" kernel command-line
option to prevent the generation of all by-partlabel symlinks
regardless of the name which was choosen.
This option should be *only* used to address performance issue related
to bsc#1089761 because it will be removed as soon as the udev
performance issue will be addressed.
[fbui: fixes bsc#1089761]
---
rules/60-persistent-storage.rules | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/rules/60-persistent-storage.rules b/rules/60-persistent-storage.rules
index babb3d784..7a8e00b55 100644
--- a/rules/60-persistent-storage.rules
+++ b/rules/60-persistent-storage.rules
@@ -86,7 +86,9 @@ ENV{DEVTYPE}=="partition", ENV{ID_WWN_WITH_EXTENSION}=="?*", SYMLINK+="disk/by-i
# by-partlabel/by-partuuid links (partition metadata)
ENV{ID_PART_ENTRY_UUID}=="?*", SYMLINK+="disk/by-partuuid/$env{ID_PART_ENTRY_UUID}"
-ENV{ID_PART_ENTRY_SCHEME}=="gpt", ENV{ID_PART_ENTRY_NAME}=="?*", ENV{ID_PART_ENTRY_NAME}!="primary|logical", SYMLINK+="disk/by-partlabel/$env{ID_PART_ENTRY_NAME}"
+
+IMPORT{cmdline}="udev.no-partlabel-links"
+ENV{ID_PART_ENTRY_SCHEME}=="gpt", ENV{ID_PART_ENTRY_NAME}=="?*", ENV{ID_PART_ENTRY_NAME}!="primary|logical", ENV{udev.no-partlabel-links}!="?*", SYMLINK+="disk/by-partlabel/$env{ID_PART_ENTRY_NAME}"
# add symlink to GPT root disk
ENV{ID_PART_ENTRY_SCHEME}=="gpt", ENV{ID_PART_GPT_AUTO_ROOT}=="1", SYMLINK+="gpt-auto-root"
--
2.18.0