Blame SOURCES/0034-RHBZ-851416-mpathconf-display.patch

38852f
---
38852f
 multipath/mpathconf |   21 +++++++++++++++------
38852f
 1 file changed, 15 insertions(+), 6 deletions(-)
38852f
38852f
Index: multipath-tools-130222/multipath/mpathconf
38852f
===================================================================
38852f
--- multipath-tools-130222.orig/multipath/mpathconf
38852f
+++ multipath-tools-130222/multipath/mpathconf
38852f
@@ -159,7 +159,7 @@ if [ -z "$MODULE" -o "$MODULE" = "y" ];
38852f
 fi
38852f
 
38852f
 if [ "$MULTIPATHD" = "y" ]; then
38852f
-	if service multipathd status > /dev/null ; then
38852f
+	if /bin/systemctl status multipathd.service > /dev/null 2>&1 ; then
38852f
 		HAVE_MULTIPATHD=1
38852f
 	else
38852f
 		HAVE_MULTIPATHD=0
38852f
@@ -210,8 +210,17 @@ if [ -n "$SHOW_STATUS" ]; then
38852f
 			echo "dm_multipath module is not loaded"
38852f
 		fi
38852f
 	fi
38852f
-	if [ -n "$HAVE_MULTIPATHD" ]; then
38852f
-		service multipathd status
38852f
+	if [ -z "$HAVE_MULTIPATHD" ]; then
38852f
+		if /bin/systemctl status multipathd.service > /dev/null 2>&1 ; then
38852f
+			HAVE_MULTIPATHD=1
38852f
+		else
38852f
+			HAVE_MULTIPATHD=0
38852f
+		fi
38852f
+	fi
38852f
+	if [ "$HAVE_MULTIPATHD" = 1 ]; then
38852f
+		echo "multipathd is running"
38852f
+	else
38852f
+		echo "multipathd is not running"
38852f
 	fi
38852f
 	exit 0
38852f
 fi
38852f
@@ -301,12 +310,12 @@ if [ "$ENABLE" = 1 ]; then
38852f
 		modprobe dm_multipath
38852f
 	fi
38852f
 	if [ "$HAVE_MULTIPATHD" = 0 ]; then
38852f
-		service multipathd start
38852f
+		systemctl start multipathd.service
38852f
 	fi
38852f
 elif [ "$ENABLE" = 0 ]; then
38852f
 	if [ "$HAVE_MULTIPATHD" = 1 ]; then
38852f
-		service multipathd stop
38852f
+		systemctl stop multipathd.service
38852f
 	fi
38852f
 elif [ -n "$CHANGED_CONFIG" -a "$HAVE_MULTIPATHD" = 1 ]; then
38852f
-	service multipathd reload
38852f
+	systemctl reload multipathd.service
38852f
 fi