Ok, so to fix this problem follow these steps (assuming you are using
Ubuntu 11.04):

1. Modify this line in /lib/udev/rules.d/95-kpartx.rules

       ENV{DM_STATE}=="ACTIVE", ENV{DM_UUID}=="dmraid-*", \
        RUN+="/sbin/kpartx -p -part -a /dev/$kernel"

    by changing "dmraid-*" to "DMRAID-*" and remove the '-p -part'
switch so that you get

       ENV{DM_STATE}=="ACTIVE", ENV{DM_UUID}=="DMRAID-*", \
        RUN+="/sbin/kpartx -a /dev/$kernel"

   As mentioned in the bug report, the switch to uppercase is required
since id's for dmraid mapped devices follow that convention.  The
removal of the -p switch is meant to allow kpartx use its default
partition map naming scheme rather than a distro specific one.  Not sure
if Debian ever changed this.

2. Modify this line in the script /sbin/dmraid-activate

       dmraid -i -ay -Z "$1"

    by inserting the -p switch as suggested John in comment #14 so you
obtain

       dmraid -i -ay -p -Z "$1"

    Now dmraid will not map partitions, leaving that job to kpartx when
it is called in its respective udev rule.

3. Done!

I am not sure how to convert my changes into an uploadable patch via
Launchpad.  Could someone please direct me to a tutorial or give a brief
example?

It would be nice if kpartx was integrated into dmraid itself or else at
least replace the partition mapping portion of dmraid with calls to
kpartx and bundle the two together (as suggested in the dmraid TODO
file).  I assume such changes must be made upstream. If so, where should
I go to make / suggest the changes?

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/737027

Title:
  kpartx udev rule is broken

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/dmraid/+bug/737027/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to