]> git.ipfire.org Git - thirdparty/dracut.git/commitdiff
udev-rules: do not run blkid on temporary device mapper devices
authorHarald Hoyer <harald@redhat.com>
Thu, 5 Nov 2009 12:32:47 +0000 (13:32 +0100)
committerHarald Hoyer <harald@redhat.com>
Thu, 5 Nov 2009 16:06:26 +0000 (17:06 +0100)
modules.d/95udev-rules/59-persistent-storage.rules

index 41e24aec64f9694e5a9a6fe59581d751fc45e82b..299a71dec913bbb815c7cd5c5bac1a6c23bdb271 100644 (file)
@@ -1,7 +1,18 @@
 SUBSYSTEM!="block", GOTO="ps_end"
 ACTION!="add|change", GOTO="ps_end"
-ACTION=="change", KERNEL=="dm-[0-9]*", IMPORT{program}="/sbin/blkid -o udev -p $tempnode"
+
 KERNEL=="cciss[0-9]*", IMPORT{program}="/sbin/blkid -o udev -p $tempnode"
 KERNEL=="nbd[0-9]*", IMPORT{program}="/sbin/blkid -o udev -p $tempnode"
 KERNEL=="md[0-9]*|md_d[0-9]*|md/*", IMPORT{program}="/sbin/blkid -o udev -p $tempnode"
-LABEL="ps_end"
\ No newline at end of file
+
+
+KERNEL!="dm-[0-9]*", GOTO="ps_end"
+ACTION=="add", GOTO="ps_end"
+IMPORT{program}="/sbin/dmsetup info -c --nameprefixes --unquoted --rows --noheadings -o name,uuid,suspended,readonly,major,minor,open,tables_loaded,names_using_dev -j%M -m%m"
+ENV{DM_NAME}!="?*", GOTO="ps_end"
+ENV{DM_UUID}=="CRYPT-TEMP-?*", GOTO="ps_end"
+ENV{DM_UUID}!="?*", ENV{DM_NAME}=="temporary-cryptsetup-?*", GOTO="ps_end"
+IMPORT{program}="/sbin/blkid -o udev -p $tempnode"
+
+
+LABEL="ps_end"