On Tue, Jan 27, 2009 at 09:06:56PM +1100, [email protected] wrote:

umm - can't see it. I checked the bug as well. Could you resend please?
The 65d108f.diff patch does not apply cleanly.
Attached now.

Thanks. I got it to apply after one small hiccup.
See attached log file.
Did you resolve the conflict by hand?. Otherwise kpartx won't work. I
can send a patch against 0.4.8-7 instead of 0.4.8-13 if that's easier
for you. But since you only need kpartx I recommend to apply the patch I
send against 0.4.8-13 (see below).

We next tried applying your patch to 0.4.8-13.
It applies cleanly and the packages build ok.

We copied the new kpartx binary to /sbin/kpartx.new and tested as before:
 # /etc/init.d/multipath-tools stop
 # multipath -F
 # ls /dev/mapper/mp*
 /bin/ls: /dev/mapper/mp*: No such file or directory
 # multipath -v2 -l
 # ls /dev/mapper/mp*
 /dev/mapper/mpath0
 # /sbin/kpartx.new -a
 # ls /dev/mapper/mp*
 /dev/mapper/mpath0    /dev/mapper/mpath0p1
 # mount /dev/mapper/mpath0p1 /mnt
 # df /mnt
 /dev/mapper/mpath0p1 10253771740       544 10253771196   1% /mnt
 # multipath -l
 mpath0 (222a60001559596f8) dm-7 Promise,VTrak E610f
 [size=9.5T][features=1 queue_if_no_path][hwhandler=0]
 \_ round-robin 0 [prio=0][active]
  \_ 2:0:2:0 sdd 8:48  [active][undef]
  \_ 2:0:3:0 sde 8:64  [active][undef]
  \_ 2:0:4:0 sdf 8:80  [active][undef]
  \_ 2:0:5:0 sdg 8:96  [active][undef]


To get everything to work across reboots, we had to make a couple
of modifications to the system.

1. move multipath-tools down the order in rcS.d
   ls /etc/rcS.d/*multipath-tools-boot*
   /etc/rcS.d/S28multipath-tools-boot

   see #445825. we moved it even later than suggested there (S04).
   I am not entirely sure why so late.

   For the record, rcS.d looks like this now -
   #ls /etc/rcS.d/
README               S18ifupdown-clean         S40networking
S01glibc.sh          S20module-init-tools      S43portmap
S02hostname.sh       S22scsitools.sh           S45mountnfs.sh
S02mountkernfs.sh    S25libdevmapper1.02       S46mountnfs-bootclean.sh
S03udev              S26lvm                    S47lm-sensors
S04dmraid            S28multipath-tools-boot   S48console-screen.sh
S04mountdevsubfs.sh  S29multipath-kpartx       S55bootmisc.sh
S05bootlogd          S30checkfs.sh             S55urandom
S05keymap.sh         S30procps.sh              S70screen-cleanup
S09scsitools-pre.sh  S35mountall.sh            S70x11-common
S10checkroot.sh      S36mountall-bootclean.sh  S75sudo
S11hwclock.sh        S36udev-mtab              S99stop-bootlogd-single
S12mtab.sh           S39ifupdown


2. modify /etc/udev/rules.d/multipath.rules

- ACTION=="add", SUBSYSTEM=="block", KERNEL=="dm-*", \
+ ACTION=="change", SUBSYSTEM=="block", KERNEL=="dm-*", \
  PROGRAM="/sbin/dmsetup -j %M -m %m --noopencount --noheadings -c -o name 
info", \
-        RUN+="/sbin/kpartx -a /dev/mapper/%c"
+        RUN+="/sbin/kpartx.new -a /dev/mapper/%c"


   this step may not be necessary.
   The new kpartx does not seem to help with this step,
   ie no mpath0p1 device gets created.
   We think this is because mpath0 has not been set up yet.

   In the boot log we get
device-mapper: multipath round-robin: version 1.0.0 loaded
Starting multipatherror calling out /sbin/scsi_id -g -u -s /block/sdg

(sdg is the last of the multipathed devices)

3. add another boot-time script
   /etc/rcS.d/S29multipath-kpartx

   This contains -
   #!/bin/sh
   # NB: assumes you have 'user_friendly_names yes' in multipath.conf
   #
   . /lib/lsb/init-functions
   set -x
   set -v
   for m in /dev/mapper/mpath?
   do
       log_action_begin_msg "Fixing multipath device $m"
       echo "$0 fixing multipath device $m"
       /sbin/kpartx.new -a $m
       log_action_end_msg $?
   done

   This does create /dev/mapper/mpath0p1 correctly.

From the boot log, when this script runs, we get:
.
+ set -v

for m in /dev/mapper/mpath?
do
    log_action_begin_msg "Fixing multipath device $m"
    echo "$0 fixing multipath device $m"
    /local/sbin/kpartx -a $m
    log_action_end_msg $?
done
+ for m in '/dev/mapper/mpath?'
+ log_action_begin_msg 'Fixing multipath device /dev/mapper/mpath0'
+ echo -n 'Fixing multipath device /dev/mapper/mpath0...'
Fixing multipath device/dev/mapper/mpath0...
+ echo '/etc/rcS.d/S29multipath-kpartx fixing multipath device 
/dev/mapper/mpath0'
/etc/rcS.d/S29multipath-kpartx fixing multipath device /dev/mapper/mpath0
+ /sbin/kpartx.new -a /dev/mapper/mpath0
+ log_action_end_msg 0
+ '[' -z '' ']'
+ end=.
+ '[' 0 -eq 0 ']'
+ echo done.
done.


Thanks for your help with this problem.

I don't know when we will get time to look at the problem on 'lenny',
this issue has put our work schedule back quite a bit.
It might be best to close this bug and create a clone for 0.4.8-13
in case other folks can step up and test as well.

Kind regards
Vince




--
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]

Reply via email to