On Sunday 09 June 2013 05:28 AM, Jonathan McDowell wrote: > I can't see anything on > http://packages.qa.debian.org/m/multipath-tools.html so I'm assuming > this isn't going to make the first point release next weekend? Attached are the 2 patches that need to be added. My build is failing for some other stupid reason. And I haven't been successful in fixing it. If you have the resources, verify and push these patches for Wheezy only. -- Ritesh Raj Sarraf RESEARCHUT - http://www.researchut.com "Necessity is the mother of invention."
From a3a6c1019879964ca64b1cdb06d0fd4f19b47fef Mon Sep 17 00:00:00 2001
From: Ritesh Raj Sarraf <rrs@debian.org>
Date: Thu, 28 Mar 2013 21:11:09 +0530
Subject: [PATCH 1/4] Call PREREQS before calling scripts/functions
Thanks: Guy Rossin, Michael Prokop
Closes: #704073
Signed-off-by: Ritesh Raj Sarraf <rrs@debian.org>
---
debian/initramfs/init-top | 11 +++++++++++
1 file changed, 11 insertions(+)
Index: multipath-tools/debian/initramfs/init-top
===================================================================
--- multipath-tools.orig/debian/initramfs/init-top 2013-06-09 16:00:49.413782464 +0530
+++ multipath-tools/debian/initramfs/init-top 2013-06-09 16:00:49.409782464 +0530
@@ -2,6 +2,17 @@
#
# multipath hardware handler
+PREREQ=" "
+
+prereqs() { echo "$PREREQ"; }
+
+case $1 in
+prereqs)
+ prereqs
+ exit 0
+ ;;
+esac
+
. /scripts/functions
verbose()
From 7572c53e289b11b65cd90e1f2b166ad7e17eef63 Mon Sep 17 00:00:00 2001
From: Ritesh Raj Sarraf <rrs@debian.org>
Date: Sat, 30 Mar 2013 01:27:26 +0530
Subject: [PATCH 3/4] Don't plain exit if root in on multipath device
And `exit 1` is a wrong decision. It breaks calling applications, in
most common case, the installer.
Closes: #704073
Thanks: Guy Rossin
Signed-off-by: Ritesh Raj Sarraf <rrs@debian.org>
---
debian/multipath-tools.init | 13 ++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)
Index: multipath-tools/debian/multipath-tools.init
===================================================================
--- multipath-tools.orig/debian/multipath-tools.init 2013-06-09 16:00:59.101782355 +0530
+++ multipath-tools/debian/multipath-tools.init 2013-06-09 16:00:59.097782355 +0530
@@ -36,7 +36,7 @@
tablename=$(dmsetup table --target multipath | sed -n "s/\(.*\): .* $dev .*/\1/p")
if ! [ -z $tablename ]; then
log_daemon_msg "Root is on a multipathed device, multipathd can not be stopped"
- exit 1
+ DONT_STOP_MPATHD=1
fi
else
local_slave=`readlink -f $slave`;
@@ -49,7 +49,7 @@
tablename=$(dmsetup table --target multipath | sed -n "s/\(.*\): .* $dev .*/\1/p")
if ! [ -z $tablename ]; then
log_daemon_msg "Root is on a multipathed device, multipathd can not be stopped"
- exit 1
+ DONT_STOP_MPATHD=1
fi
fi
}
@@ -62,6 +62,7 @@
log_end_msg $?
;;
stop)
+ DONT_STOP_MPATHD=0
root_dev=$(awk '{ if ($1 !~ /^[ \t]*#/ && $1 ~ /\// && $2 == "/") { print $1; }}' /etc/mtab)
dm_num=$(dmsetup info -c --noheadings -o minor $root_dev 2>/dev/null)
if [ $? -ne 0 ]; then
@@ -74,9 +75,11 @@
[ -d $syspath/$root_dm_device ] && teardown_slaves $syspath/$root_dm_device
fi
- log_daemon_msg "Stopping $DESC" "$NAME"
- start-stop-daemon --oknodo --stop --quiet --pidfile /var/run/$NAME.pid --exec $DAEMON
- log_end_msg $?
+ if [ x$DONT_STOP_MPATHD = x0 ]; then
+ log_daemon_msg "Stopping $DESC" "$NAME"
+ start-stop-daemon --oknodo --stop --quiet --pidfile /var/run/$NAME.pid --exec $DAEMON
+ log_end_msg $?
+ fi
;;
reload|force-reload)
log_daemon_msg "Reloading $DESC" "$NAME"
Attachment:
signature.asc
Description: OpenPGP digital signature