Package: lvm2
Version: 2.02.111-2.1
Severity: important
Tags: patch
Add missing information about the expected device path.
May I suggest the attached patch which attempts so solve that.
-- System Information:
Debian Release: 8.0
APT prefers testing
APT policy: (500, 'testing'), (99, 'unstable'), (59, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386
Kernel: Linux 3.16.0-4-amd64 (SMP w/8 CPU cores)
Locale: LANG=, LC_CTYPE= (charmap=ANSI_X3.4-1968)
Shell: /bin/sh linked to /bin/dash
Init: sysvinit (via /sbin/init)
Versions of packages lvm2 depends on:
ii dmeventd 2:1.02.90-2.1
ii dmsetup 2:1.02.90-2.1
ii init-system-helpers 1.21
ii initscripts 2.88dsf-58
ii libc6 2.19-15
ii libdevmapper-event1.02.1 2:1.02.90-2.1
ii libdevmapper1.02.1 2:1.02.90-2.1
ii libreadline5 5.2+dfsg-2
ii libudev1 215-12
ii lsb-base 4.1+Debian13+nmu1
lvm2 recommends no packages.
Versions of packages lvm2 suggests:
pn thin-provisioning-tools <none>
-- no debconf information
Cheers,
--
Cristian
--- debian/initramfs-tools/lvm2/scripts/local-block/lvm2.orig 2015-01-17 23:35:47.000000000 +0100
+++ debian/initramfs-tools/lvm2/scripts/local-block/lvm2 2015-03-14 11:56:10.000000000 +0100
@@ -22,9 +22,11 @@
dev="$1"
# Make sure that we have a d-m path
-dev="${dev#/dev/mapper/}"
+dev_path=/dev/mapper
+dev="${dev#$dev_path/}"
if [ "$dev" = "$1" ]; then
- return 1
+ echo "Dev path $dev_path expected in $1" >&2
+ exit 0
fi
eval $(dmsetup splitname --nameprefixes --noheadings --rows "$dev")
@@ -33,7 +35,7 @@
lvm lvchange -aly --ignorelockingfailure "$DM_VG_NAME/$DM_LV_NAME"
rc=$?
if [ $rc = 5 ]; then
- echo "Unable to find LVM volume $DM_VG_NAME/$DM_LV_NAME"
+ echo "Unable to find LVM volume $DM_VG_NAME/$DM_LV_NAME" >&2
fi
fi
--- debian/initramfs-tools/lvm2/scripts/local-top/lvm2.orig 2015-01-17 18:13:22.000000000 +0100
+++ debian/initramfs-tools/lvm2/scripts/local-top/lvm2 2015-03-14 11:58:57.000000000 +0100
@@ -21,6 +21,7 @@
# Make sure that we have a non-empty argument
if [ -z "$dev" ]; then
+ # FIXME: the caller does not handle exit status failure
return 1
fi