|
|
ecd2a9 |
---
|
|
|
ecd2a9 |
multipath/multipath.rules | 6 +++++-
|
|
|
ecd2a9 |
1 file changed, 5 insertions(+), 1 deletion(-)
|
|
|
ecd2a9 |
|
|
|
ecd2a9 |
Index: multipath-tools-130222/multipath/multipath.rules
|
|
|
ecd2a9 |
===================================================================
|
|
|
ecd2a9 |
--- multipath-tools-130222.orig/multipath/multipath.rules
|
|
|
ecd2a9 |
+++ multipath-tools-130222/multipath/multipath.rules
|
|
|
ecd2a9 |
@@ -21,6 +21,7 @@ ACTION!="change", GOTO="update_timestamp
|
|
|
ecd2a9 |
IMPORT{db}="DM_MULTIPATH_TIMESTAMP"
|
|
|
ecd2a9 |
IMPORT{db}="DM_MULTIPATH_DEVICE_PATH"
|
|
|
ecd2a9 |
IMPORT{db}="DM_MULTIPATH_WIPE_PARTS"
|
|
|
ecd2a9 |
+IMPORT{db}="DM_MULTIPATH_NEED_KPARTX"
|
|
|
ecd2a9 |
# Check if the device is part of a multipath device. the -T option just keeps
|
|
|
ecd2a9 |
# the old result if the timestamp hasn't changed.
|
|
|
ecd2a9 |
PROGRAM=="$env{MPATH_SBIN_PATH}/multipath -T $env{DM_MULTIPATH_TIMESTAMP}:$env{DM_MULTIPATH_DEVICE_PATH} -c $env{DEVNAME}", \
|
|
|
ecd2a9 |
@@ -43,7 +44,10 @@ KERNEL!="dm-*", GOTO="end_mpath"
|
|
|
ecd2a9 |
ENV{DM_UUID}=="mpath-?*|part[0-9]*-mpath-?*", OPTIONS+="link_priority=10"
|
|
|
ecd2a9 |
ACTION!="change", GOTO="end_mpath"
|
|
|
ecd2a9 |
ENV{DM_UUID}!="mpath-?*", GOTO="end_mpath"
|
|
|
ecd2a9 |
+ENV{DM_ACTIVATION}=="1", ENV{DM_MULTIPATH_NEED_KPARTX}="1"
|
|
|
ecd2a9 |
ENV{DM_SUSPENDED}=="1", GOTO="end_mpath"
|
|
|
ecd2a9 |
ENV{DM_ACTION}=="PATH_FAILED", GOTO="end_mpath"
|
|
|
ecd2a9 |
-ENV{DM_ACTIVATION}=="1", RUN+="$env{MPATH_SBIN_PATH}/kpartx -u $tempnode"
|
|
|
ecd2a9 |
+ENV{DM_ACTIVATION}!="1", ENV{DM_MULTIPATH_NEED_KPARTX}!="1", GOTO="end_mpath"
|
|
|
ecd2a9 |
+RUN+="$env{MPATH_SBIN_PATH}/kpartx -a $tempnode", \
|
|
|
ecd2a9 |
+ ENV{DM_MULTIPATH_NEED_KPARTX}=""
|
|
|
ecd2a9 |
LABEL="end_mpath"
|