summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Lehman <dlehman@redhat.com>2009-10-21 08:18:38 -0500
committerDavid Lehman <dlehman@redhat.com>2009-10-22 13:46:09 -0500
commitd04d7f33f58bc8d1f21db4f48958166f0f46bf27 (patch)
treecdc17e58ccdd02918d67a9d0e4883c92318ef587
parente7fd45bb9fda8a9dbd05a49005ada7ae2ccac36c (diff)
downloadanaconda-d04d7f33f58bc8d1f21db4f48958166f0f46bf27.tar.gz
anaconda-d04d7f33f58bc8d1f21db4f48958166f0f46bf27.tar.xz
anaconda-d04d7f33f58bc8d1f21db4f48958166f0f46bf27.zip
More udev fixups for device-mapper and cryptsetup temp devices. (#526699)
-rw-r--r--70-anaconda.rules9
1 files changed, 7 insertions, 2 deletions
diff --git a/70-anaconda.rules b/70-anaconda.rules
index bad99ddd4..720d65f94 100644
--- a/70-anaconda.rules
+++ b/70-anaconda.rules
@@ -1,17 +1,22 @@
ACTION!="add|change", GOTO="anaconda_end"
SUBSYSTEM!="block", GOTO="anaconda_end"
+# for device-mapper device we are supposed to only operate on "change" events
+KERNEL=="dm-*", ACTION=="add", GOTO="anaconda_end"
+
ENV{ANACBIN}="/sbin"
TEST!="$env{ANACBIN}/dmsetup", ENV{ANACBIN}="/usr/sbin"
-IMPORT{program}="$env{ANACBIN}/blkid -o udev -p $tempnode"
-
+# device-mapper devices are special. we can't run blkid on them until we
+# know they aren't cryptsetup temporary devices.
+KERNEL!="dm-*", IMPORT{program}="$env{ANACBIN}/blkid -o udev -p $tempnode"
KERNEL!="dm-*", GOTO="anaconda_mdraid"
IMPORT{program}="$env{ANACBIN}/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="anaconda_end"
ENV{DM_UUID}=="CRYPT-TEMP-?*", GOTO="anaconda_end"
ENV{DM_UUID}!="?*", ENV{DM_NAME}=="temporary-cryptsetup-?*", GOTO="anaconda_end"
+IMPORT{program}="$env{ANACBIN}/blkid -o udev -p $tempnode"
SYMLINK+="disk/by-id/dm-name-$env{DM_NAME}"
ENV{DM_UUID}=="?*", SYMLINK+="disk/by-id/dm-uuid-$env{DM_UUID}"