From 63bffe53a18ca57fd20adada247111fde9df3e35 Mon Sep 17 00:00:00 2001 From: Evan Broder Date: Mon, 5 May 2008 03:37:35 -0400 Subject: [PATCH] Fix multipath-tools' broken udev rule svn path=/trunk/packages/sipb-xen-clvm-config/; revision=503 --- debian/changelog | 7 +++++++ debian/control | 2 +- debian/control.in | 2 +- debian/rules | 5 +++-- files/etc/udev/multipath.rules.sipb-xen | 12 ++++++++++++ 5 files changed, 24 insertions(+), 4 deletions(-) create mode 100644 files/etc/udev/multipath.rules.sipb-xen diff --git a/debian/changelog b/debian/changelog index a0bdd5b..46111f3 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +sipb-xen-clvm-config (2.0) unstable; urgency=low + + * Depend on multipath-tools because we're going to want it + * Fix multipath-tools' udev script because it's horribly broken + + -- Evan Broder Mon, 5 May 2008 03:35:00 -0400 + sipb-xen-clvm-config (1.2) unstable; urgency=low * I remain an idiot, unfortunately, and didn't notice this last time diff --git a/debian/control b/debian/control index f79340c..caed174 100644 --- a/debian/control +++ b/debian/control @@ -7,7 +7,7 @@ Standards-Version: 3.7.2 Package: sipb-xen-clvm-config Architecture: any -Depends: ${shlibs:Depends}, ${misc:Depends}, clvm, cman, ccs +Depends: ${shlibs:Depends}, ${misc:Depends}, clvm, cman, ccs, multipath-tools Provides: ${diverted-files} Conflicts: ${diverted-files} Description: Configure clustering LVM diff --git a/debian/control.in b/debian/control.in index 9ffea2d..88ea37b 100644 --- a/debian/control.in +++ b/debian/control.in @@ -7,7 +7,7 @@ Standards-Version: 3.7.2 Package: sipb-xen-clvm-config Architecture: any -Depends: ${shlibs:Depends}, ${misc:Depends}, clvm, cman, ccs +Depends: ${shlibs:Depends}, ${misc:Depends}, clvm, cman, ccs, multipath-tools Provides: ${diverted-files} Conflicts: ${diverted-files} Description: Configure clustering LVM diff --git a/debian/rules b/debian/rules index b2583dd..6a092e6 100755 --- a/debian/rules +++ b/debian/rules @@ -3,7 +3,8 @@ DEB_AUTO_UPDATE_DEBIAN_CONTROL = 1 DEB_DIVERT_EXTENSION = .sipb-xen DEB_DIVERT_FILES_sipb-xen-clvm-config += \ - /etc/lvm/lvm.conf.sipb-xen + /etc/lvm/lvm.conf.sipb-xen \ + /etc/udev/multipath.rules.sipb-xen include /usr/share/cdbs/1/rules/debhelper.mk -include /usr/share/cdbs/1/rules/config-package.mk \ No newline at end of file +include /usr/share/cdbs/1/rules/config-package.mk diff --git a/files/etc/udev/multipath.rules.sipb-xen b/files/etc/udev/multipath.rules.sipb-xen new file mode 100644 index 0000000..3f3642f --- /dev/null +++ b/files/etc/udev/multipath.rules.sipb-xen @@ -0,0 +1,12 @@ +# +# multipath and multipath partitions nodes are created in /dev/mapper/ +# this file should be installed in /etc/udev/rules.d +# + +# take care of devmap partitioning +ACTION=="add", SUBSYSTEM=="block", KERNEL=="dm-*", \ + PROGRAM="/sbin/dmsetup -j %M -m %m status", \ + RESULT=="*multipath*", \ + PROGRAM="/sbin/dmsetup -j %M -m %m --noopencount --noheadings -c -o name info", \ + RUN+="/sbin/kpartx -a /dev/mapper/%c" + -- 1.7.9.5