[Drbd-dev] [PATCH 1/1] fix drbd.rules to avoid start drbd fail

Liuhua Wang lwang at suse.com
Fri Jun 27 11:16:08 CEST 2014


  fix drbd.rules by removing NAME and adding a SYMLINK to kernel node for
  the reason that when drbd configuration has a device name different from
  kernel node, device name will not be created since renaming a kernel node
  fails. So start drbd by pacemaker will fail.

Signed-off-by: Liuhua Wang <lwang at suse.com>
---
 scripts/drbd.rules | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/scripts/drbd.rules b/scripts/drbd.rules
index dbdfdba..3c967f0 100644
--- a/scripts/drbd.rules
+++ b/scripts/drbd.rules
@@ -12,4 +12,6 @@
 # having it as one single line avoids those problems.
 #
 # DO NOT WRAP THIS LINE
-SUBSYSTEM=="block", KERNEL=="drbd*", IMPORT{program}="/usr/sbin/drbdadm sh-udev minor-%m", NAME="$env{DEVICE}", SYMLINK="$env{SYMLINK}"
+SUBSYSTEM=="block", KERNEL=="drbd*", IMPORT{program}="/usr/sbin/drbdadm sh-udev minor-%m", SYMLINK="$env{SYMLINK}"
+TEST!="$env{DEVICE}", SYMLINK+="$env{DEVICE}"
+
-- 
1.9.0



More information about the drbd-dev mailing list