Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: Bug#545032: Bug#545032: Bug#545032: Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-11-05 Thread Michael Biebl
Bastian Blank wrote:
 On Tue, Nov 03, 2009 at 09:41:24PM +0100, Michael Biebl wrote:
 Discussing with upstream, 95-devkit-disks.rules was changed to only act on
 change events (and not add|change)
 
 The rules may still be called with the device suspended and then block
 udev to handle further rules and events, including the callback to the
 devmapper tools. This is a classic race condition and I have no recipe
 for this yet.

Should I add a check for DM_SUSPENDED==1 then, just like DM_HIDE?

 Hopefully this addresses your remaining complaints in a sufficient manner so 
 the
  conflicts in dmsetup can be removed again.
 
 I accept that for now. But if it starts to break things I'll come back.

Fair enough. Admittedly, the interaction between udev,
device-mapper/lvm2/crypsetup/mdadm and dk-disks is not ideal yet.
So constructive input how to improve that in the future, is very much 
appreciated.
I also strongly believe, that we should closely work with upstream on such
matters, so not every disto is doing their own thing and ideally we have a
common set of core udev rules where 3rd party apps can rely on.

Which leads me to a bit unrelated question: Your dm/lvm2 udev rules look quite
well written, but they also look significantly different from what upstream lvm2
is shipping.
Have you considered to push your changes upstream?
What about --enable-udev_sync, is this something we want in Debian?

Cheers,
Michael

P.S: dk-disks 009-1 has been uploaded today, so I would appreciate of dmsetup   
at
your earliest convenience

-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?



signature.asc
Description: OpenPGP digital signature


Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-11-04 Thread Raphael Hertzog
On Sun, 18 Oct 2009, Bastian Blank wrote:
 On Fri, Oct 16, 2009 at 11:55:55PM +0200, Bastian Blank wrote:
  On Fri, Oct 16, 2009 at 11:43:52PM +0200, Bastian Blank wrote:
   Okay. What about point 1 of my list? This still probes device-mapper
   devices.
 
 | - Probe for partitions, aka open, on all block devices with a (small)
 |   blacklist. This can be only allowed with a whitelist, as several
 |   device types may not be queried from add events or not at all, like
 |   several dm subtypes.
 
  This patch should use an apropriate whitelist.
 
 Actually it lacks some safe device types.
 
[ snip patch ]

 And while you are at it, add dasd*|cciss* to the presentation list.

I prepared an NMU with the two above changes, Bastian can you confirm that
those are the last changes that you require to drop the Conflicts?

Michael or Martin, can you integrate those 2 patches and upload?

Cheers,
-- 
Raphaël Hertzog
diff -u devicekit-disks-008/debian/changelog 
devicekit-disks-008/debian/changelog
--- devicekit-disks-008/debian/changelog
+++ devicekit-disks-008/debian/changelog
@@ -1,3 +1,10 @@
+devicekit-disks (008-1.1) unstable; urgency=low
+
+  * Non-maintainer upload.
+  * Fix udev rules to not mess with the lvm ones. Closes: #545032
+
+ -- Raphaël Hertzog hert...@debian.org  Wed, 04 Nov 2009 08:47:10 +0100
+
 devicekit-disks (008-1) unstable; urgency=low
 
   * New upstream release.
diff -u devicekit-disks-008/debian/patches/series 
devicekit-disks-008/debian/patches/series
--- devicekit-disks-008/debian/patches/series
+++ devicekit-disks-008/debian/patches/series
@@ -4,0 +5,2 @@
+09-whitelist-for-parttable-probing
+10-extend-presentation-list
only in patch2:
unchanged:
--- devicekit-disks-008.orig/debian/patches/10-extend-presentation-list
+++ devicekit-disks-008/debian/patches/10-extend-presentation-list
@@ -0,0 +1,18 @@
+Subject: extend list of devices that can be mounted
+
+dasd* and cciss* devices are real disks that can be mounted. Add them to
+the whitelist of devices that can be automounted.
+
+Origin: vendor, http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=545032#143
+
+--- a/data/95-devkit-disks.rules
 b/data/95-devkit-disks.rules
+@@ -130,7 +130,7 @@ ENV{ID_FS_TYPE}==ntfs|vfat, \
+ #
+ 
+ ENV{DKD_PRESENTATION_NOPOLICY}=1
+-KERNEL==sd*|hd*|sr*|mmcblk*|mspblk*, ENV{DKD_PRESENTATION_NOPOLICY}=0
++KERNEL==sd*|hd*|sr*|mmcblk*|mspblk*|dasd*|cciss*, 
ENV{DKD_PRESENTATION_NOPOLICY}=0
+ 
+ 
##
+ 
only in patch2:
unchanged:
--- devicekit-disks-008.orig/debian/patches/09-whitelist-for-parttable-probing
+++ devicekit-disks-008/debian/patches/09-whitelist-for-parttable-probing
@@ -0,0 +1,20 @@
+From: Bastian Blank wa...@debian.org
+Subject: use whitelist for devices with partition table that can be probed
+
+With a blacklist, it can break as soon as a new block device is added
+if it can't be blindly opened at the time this rule is executed.
+
+Origin: vendor, http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=545032#143
+--- a/data/95-devkit-disks.rules
 b/data/95-devkit-disks.rules
+@@ -11,8 +11,8 @@ KERNEL==loop*|ram*, GOTO=devkit_disks
+ # Probe for partition tables; this really should be part of udev
+ #
+ 
+-# skip rules for inappropriate block devices
+-KERNEL==fd*|mtd*|nbd*|gnbd*|btibm*, GOTO=probe_parttable_end
++# scan parttable only for block devices that support it
++KERNEL!=hd*|sd*|sr*|cciss*|dasd*|mmcblk*|mspblk*, GOTO=probe_parttable_end
+ 
+ # never access non-cdrom removable ide devices, the drivers are causing event 
loops on open()
+ KERNEL==hd*[!0-9], ATTR{removable}==1, SUBSYSTEMS==ide, 
ATTRS{media}==disk|floppy, GOTO=probe_parttable_end


Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: Bug#545032: Bug#545032: Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-11-04 Thread Bastian Blank
On Tue, Nov 03, 2009 at 09:41:24PM +0100, Michael Biebl wrote:
 Discussing with upstream, 95-devkit-disks.rules was changed to only act on
 change events (and not add|change)

The rules may still be called with the device suspended and then block
udev to handle further rules and events, including the callback to the
devmapper tools. This is a classic race condition and I have no recipe
for this yet.

 Hopefully this addresses your remaining complaints in a sufficient manner so 
 the
  conflicts in dmsetup can be removed again.

I accept that for now. But if it starts to break things I'll come back.

Bastian

-- 
War is never imperative.
-- McCoy, Balance of Terror, stardate 1709.2



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-11-04 Thread Michael Biebl
Raphael Hertzog wrote:
 On Sun, 18 Oct 2009, Bastian Blank wrote:
 On Fri, Oct 16, 2009 at 11:55:55PM +0200, Bastian Blank wrote:
 On Fri, Oct 16, 2009 at 11:43:52PM +0200, Bastian Blank wrote:
 Okay. What about point 1 of my list? This still probes device-mapper
 devices.
 | - Probe for partitions, aka open, on all block devices with a (small)
 |   blacklist. This can be only allowed with a whitelist, as several
 |   device types may not be queried from add events or not at all, like
 |   several dm subtypes.

 This patch should use an apropriate whitelist.
 Actually it lacks some safe device types.

 [ snip patch ]
 And while you are at it, add dasd*|cciss* to the presentation list.
 
 I prepared an NMU with the two above changes, Bastian can you confirm that
 those are the last changes that you require to drop the Conflicts?
 
 Michael or Martin, can you integrate those 2 patches and upload?

Raphael, please see my last email why those changes were not uploaded yet and
how it has been approached differently.
Please do *not* NMU with this patch.

Michael


-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?



signature.asc
Description: OpenPGP digital signature


Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-11-04 Thread Raphael Hertzog
On Wed, 04 Nov 2009, Michael Biebl wrote:
  Michael or Martin, can you integrate those 2 patches and upload?
 
 Raphael, please see my last email why those changes were not uploaded yet and
 how it has been approached differently.

Oh I missed that mail, thanks for the update. I'm not subscribed to the
bug, just annoyed by the conflict and wanted to help resolve the issue
(I did not intend to upload any NMU, it just's a practical way to provide
something ready for the maintainer).

Cheers,
-- 
Raphaël Hertzog



--
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: Bug#545032: Bug#545032: Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-11-03 Thread Michael Biebl
Bastian Blank wrote:
 On Fri, Oct 16, 2009 at 11:55:55PM +0200, Bastian Blank wrote:
 On Fri, Oct 16, 2009 at 11:43:52PM +0200, Bastian Blank wrote:
 Okay. What about point 1 of my list? This still probes device-mapper
 devices.
 
 | - Probe for partitions, aka open, on all block devices with a (small)
 |   blacklist. This can be only allowed with a whitelist, as several
 |   device types may not be queried from add events or not at all, like
 |   several dm subtypes.
 
 This patch should use an apropriate whitelist.

So, here is a status update on this issue:
What happened so far is, that I removed the blkid call for dm devices.
I also dropped the devkit-disks-dm-export prober altogether and instead rely on
the information setup by dmsetup/cryptsetup.

The last bit is the devkit-disks-part-id prober.

Unfortunately I can't just drop this prober completely for all dm/md devices, as
you might have partitioning information on such a device.

Discussing with upstream, 95-devkit-disks.rules was changed to only act on
change events (and not add|change) and I additionally added a rule to skip
devices where DM_HIDE==1 is set.

The latest state is at
http://git.debian.org/?p=pkg-utopia/devicekit-disks.git;a=summary

and I plan to upload that soonish as 009-1.

Hopefully this addresses your remaining complaints in a sufficient manner so the
 conflicts in dmsetup can be removed again.

Michael

-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?



signature.asc
Description: OpenPGP digital signature


Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-10-21 Thread martin f krafft
also sprach Michael Biebl bi...@debian.org [2009.10.15.1444 +0200]:
 P.S: I have to retract my statement wrt to mdadm. I double checked the Debian
 mdadm udev rules files, and it uses the upstream udev rules file that calls
 mdadm --detail, whereas the dk-disks udev rule calls mdadm --examine. The
 former seems to operate on the actual md device only, the latter on the
 underlying physical device.
 So I don't think it's safe to remove the mdadm section from
 95-devkit-disks.rules just yet without further investigation.
 I CCed the mdadm maintainers for their input. Maybe we could enable that 
 mdadm
 --examine in mdadm itself?

I have no idea what you are talking about. What could be enabled in
mdadm itself?

A new bug report would be appreciated.

-- 
 .''`.   martin f. krafft madd...@d.o  Related projects:
: :'  :  proud Debian developer   http://debiansystem.info
`. `'`   http://people.debian.org/~madduckhttp://vcs-pkg.org
  `-  Debian - when you have better things to do than fixing systems
 
men always want to be a woman's first love.
 women have a more subtle instinct:
 what they like is to be a man's last romance.
-- oscar wilde


digital_signature_gpg.asc
Description: Digital signature (see http://martin-krafft.net/gpg/)


Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: Bug#545032: Bug#545032: Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-10-18 Thread Bastian Blank
found 545032 008-1
thanks

On Sat, Oct 17, 2009 at 12:02:19AM +0200, Michael Biebl wrote:
 Bastian Blank wrote:
  On Fri, Oct 16, 2009 at 10:45:25PM +0200, Michael Biebl wrote:
  I adressed the issues you mentioned [1] and just uploaded 007-3 to 
  unstable.
  Okay. What about point 1 of my list? This still probes device-mapper
  devices.
 What? Where?

| KERNEL==fd*|mtd*|nbd*|gnbd*|btibm*, GOTO=probe_parttable_end
| IMPORT{program}=devkit-disks-part-id $tempnode
| LABEL=probe_parttable_end

devkit-disks-part-id opens the temporary device node to read data from
it.

Bastian

-- 
You!  What PLANET is this!
-- McCoy, The City on the Edge of Forever, stardate 3134.0



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-10-18 Thread Bastian Blank
On Fri, Oct 16, 2009 at 06:20:48PM -0400, David Zeuthen wrote:
 Yeah, I'd like to know exactly how much of this can be expected to be in
 other distros.

All of them.

 FWIW, I've been telling the LVM/device-mapper guys for a
 long time to include udev rules etc. in the stock upstream release. I
 know they are planning to do that but I'm not sure it's there yet. If
 there is, please point me to it.

Can you please explain why you don't check that yourself against an
uptodate rawhide system? If seen LVM2 2.02.52, the first version
shipping the rules, in the package list several weeks ago.

 Anyway, that's the reason why I have my own prober, udev rules and
 name-spaced properties. This will have to stay in the upstream
 distribution of DKD until there's an upstream release of
 LVM/device-mapper with what I need.

Well, your turn to break device-mapper.

Bastian

-- 
Spock: We suffered 23 casualties in that attack, Captain.



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: Bug#545032: Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-10-18 Thread Bastian Blank
On Fri, Oct 16, 2009 at 11:55:55PM +0200, Bastian Blank wrote:
 On Fri, Oct 16, 2009 at 11:43:52PM +0200, Bastian Blank wrote:
  Okay. What about point 1 of my list? This still probes device-mapper
  devices.

| - Probe for partitions, aka open, on all block devices with a (small)
|   blacklist. This can be only allowed with a whitelist, as several
|   device types may not be queried from add events or not at all, like
|   several dm subtypes.

 This patch should use an apropriate whitelist.

Actually it lacks some safe device types.

--- a/data/95-devkit-disks.rules
+++ b/data/95-devkit-disks.rules
@@ -12,7 +12,7 @@
 #
 
 # skip rules for inappropriate block devices
-KERNEL==fd*|mtd*|nbd*|gnbd*|btibm*, GOTO=probe_parttable_end
+KERNEL!=hd*|sd*|sr*|cciss*|dasd*|mmcblk*|mspblk*, GOTO=probe_parttable_end
 
 # never access non-cdrom removable ide devices, the drivers are causing event 
loops on open()
 KERNEL==hd*[!0-9], ATTR{removable}==1, SUBSYSTEMS==ide, 
ATTRS{media}==disk|floppy, GOTO=probe_parttable_end

And while you are at it, add dasd*|cciss* to the presentation list.

Bastian

-- 
You!  What PLANET is this!
-- McCoy, The City on the Edge of Forever, stardate 3134.0



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-10-16 Thread Bastian Blank
On Fri, Oct 16, 2009 at 04:37:53AM +0200, Michael Biebl wrote:
 +(g_str_has_prefix (dm_uuid, CRYPT-LUKS1) ||
CRYPT-LUKS1-, maybe there will be a CRYPT-LUKS10 someday.

 + g_regex_match_simple (^CRYPT-[a-f0-9-]+$, dm_uuid, 0, 0)) 
^CRYPT-[0-9a-f], no need to have an anchor at the end.

 -if (g_str_has_prefix (dkd_dm_name, temporary-cryptsetup-)) 
 {
 +/* Debian already hides temporary cryptsetup devices, so 
 this check could probably be removed? */
 +if (g_str_has_prefix (dm_name, temporary-cryptsetup-)) {
This check can go. This temporary devices either have no uuid
(cryptsetup  1.1) or start with CRYPT-TEMP- (cryptsetup = 1.1).

Bastian

-- 
Sometimes a feeling is all we humans have to go on.
-- Kirk, A Taste of Armageddon, stardate 3193.9



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: Bug#545032: Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-10-16 Thread Michael Biebl
I adressed the issues you mentioned [1] and just uploaded 007-3 to unstable.

Michael

[1] http://git.debian.org/?p=pkg-utopia/devicekit-disks.git;a=summary
-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?



signature.asc
Description: OpenPGP digital signature


Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: Bug#545032: Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-10-16 Thread Bastian Blank
On Fri, Oct 16, 2009 at 10:45:25PM +0200, Michael Biebl wrote:
 I adressed the issues you mentioned [1] and just uploaded 007-3 to unstable.

Okay. What about point 1 of my list? This still probes device-mapper
devices.

Bastian

-- 
Lots of people drink from the wrong bottle sometimes.
-- Edith Keeler, The City on the Edge of Forever,
   stardate unknown



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: Bug#545032: Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-10-16 Thread Bastian Blank
On Fri, Oct 16, 2009 at 11:43:52PM +0200, Bastian Blank wrote:
 On Fri, Oct 16, 2009 at 10:45:25PM +0200, Michael Biebl wrote:
  I adressed the issues you mentioned [1] and just uploaded 007-3 to unstable.
 Okay. What about point 1 of my list? This still probes device-mapper
 devices.

This patch should use an apropriate whitelist.

--- a/data/95-devkit-disks.rules
+++ b/data/95-devkit-disks.rules
@@ -12,7 +12,7 @@
 #
 
 # skip rules for inappropriate block devices
-KERNEL==fd*|mtd*|nbd*|gnbd*|btibm*, GOTO=probe_parttable_end
+KERNEL!=hd*|sd*|sr*|cciss*|dasd*, GOTO=probe_parttable_end
 
 # never access non-cdrom removable ide devices, the drivers are causing event 
loops on open()
 KERNEL==hd*[!0-9], ATTR{removable}==1, SUBSYSTEMS==ide, 
ATTRS{media}==disk|floppy, GOTO=probe_parttable_end

Bastian

-- 
Is truth not truth for all?
-- Natira, For the World is Hollow and I have Touched
   the Sky, stardate 5476.4.



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: Bug#545032: Bug#545032: Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-10-16 Thread Michael Biebl
Bastian Blank wrote:
 On Fri, Oct 16, 2009 at 10:45:25PM +0200, Michael Biebl wrote:
 I adressed the issues you mentioned [1] and just uploaded 007-3 to unstable.
 
 Okay. What about point 1 of my list? This still probes device-mapper
 devices.

What? Where?


-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?



signature.asc
Description: OpenPGP digital signature


Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-10-16 Thread David Zeuthen
On Thu, 2009-10-15 at 14:44 +0200, Michael Biebl wrote:
 Bastian Blank wrote:
  On Tue, Oct 13, 2009 at 05:45:27PM +0200, Michael Biebl wrote:
  What we can not remove currently, is the call to devkit-disks-dm-export,
  as it makes additional information available like (DKM_)DM_TARGET_TYPES,
  which is used inside the dk-disks code.
  
  Please explain which highlevel information you need.
  
  DM_TARGET_TYPES is only used to find the string crypt in it and I
  already explained several times that DM_UUID==CRYPT-* is a quite better
  indicator, completely functional in the near future with cryptsetup 1.1.
 
 Finally some useful information, thanks.
 
 Attached is a patch which makes use of DM_UUID making it possible to 
 completely
 remove devkit-disks-dm-export, and it seems to work nicely.
 
 Is the DM_UUID=CRYPT-* naming scheme documented somewhere? I'd like to send 
 this
 patch upstream and would need to know if it is a Debian specific feature.
 If not, since what version of cryptsetup/dmsetup is this naming interface 
 stable?

Yeah, I'd like to know exactly how much of this can be expected to be in
other distros.  FWIW, I've been telling the LVM/device-mapper guys for a
long time to include udev rules etc. in the stock upstream release. I
know they are planning to do that but I'm not sure it's there yet. If
there is, please point me to it.

Anyway, that's the reason why I have my own prober, udev rules and
name-spaced properties. This will have to stay in the upstream
distribution of DKD until there's an upstream release of
LVM/device-mapper with what I need.

Thanks,
David





-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-10-15 Thread Michael Biebl
Bastian Blank wrote:
 On Tue, Oct 13, 2009 at 05:45:27PM +0200, Michael Biebl wrote:
 What we can not remove currently, is the call to devkit-disks-dm-export,
 as it makes additional information available like (DKM_)DM_TARGET_TYPES,
 which is used inside the dk-disks code.
 
 Please explain which highlevel information you need.
 
 DM_TARGET_TYPES is only used to find the string crypt in it and I
 already explained several times that DM_UUID==CRYPT-* is a quite better
 indicator, completely functional in the near future with cryptsetup 1.1.

Finally some useful information, thanks.

Attached is a patch which makes use of DM_UUID making it possible to completely
remove devkit-disks-dm-export, and it seems to work nicely.

Is the DM_UUID=CRYPT-* naming scheme documented somewhere? I'd like to send this
patch upstream and would need to know if it is a Debian specific feature.
If not, since what version of cryptsetup/dmsetup is this naming interface 
stable?


Thanks,
Michael

P.S: I have to retract my statement wrt to mdadm. I double checked the Debian
mdadm udev rules files, and it uses the upstream udev rules file that calls
mdadm --detail, whereas the dk-disks udev rule calls mdadm --examine. The
former seems to operate on the actual md device only, the latter on the
underlying physical device.
So I don't think it's safe to remove the mdadm section from
95-devkit-disks.rules just yet without further investigation.
I CCed the mdadm maintainers for their input. Maybe we could enable that mdadm
--examine in mdadm itself?

Anyways, this should probably be handled in a separate bug report as this one is
about dm devices. I just mentioned it, as you brought up the mdadm issue.

-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?
From 9aca432753e8e4fbaacf09b47bdf374765397232 Mon Sep 17 00:00:00 2001
From: Michael Biebl bi...@debian.org
Date: Thu, 15 Oct 2009 14:26:17 +0200
Subject: [PATCH 1/2] Stop probing device-mapper devices

Use DM_NAME and DM_UUID which are already setup by the dmsetup udev
rules.
See http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=545032
---
 data/95-devkit-disks.rules |   21 -
 src/devkit-disks-device.c  |   17 +
 2 files changed, 9 insertions(+), 29 deletions(-)

diff --git a/data/95-devkit-disks.rules b/data/95-devkit-disks.rules
index fbb85a0..f8fad85 100644
--- a/data/95-devkit-disks.rules
+++ b/data/95-devkit-disks.rules
@@ -29,27 +29,6 @@ LABEL=probe_parttable_end
 
 ##
 
-# pick up device-mapper data; this REALLY should be done by rules installed
-# by the device-mapper package
-#
-KERNEL!=dm-*, GOTO=device_mapper_end
-ACTION!=add|change, GOTO=device_mapper_end
-
-IMPORT{program}=devkit-disks-dm-export %M %m
-ENV{DKD_DM_NAME}!=?*, GOTO=device_mapper_end
-
-ENV{DKD_DM_STATE}==SUSPENDED, GOTO=device_mapper_end
-ENV{DKD_DM_TARGET_TYPES}==|*error*, GOTO=device_mapper_end
-
-# avoid probing if it has already been done earlier
-#
-ENV{ID_FS_USAGE}!=, GOTO=device_mapper_end
-IMPORT{program}=/sbin/blkid -o udev -p $tempnode
-
-LABEL=device_mapper_end
-
-##
-
 # pick up data from MD components; this REALLY should be done by rules installed
 # by mdadm or the kernel package
 #
diff --git a/src/devkit-disks-device.c b/src/devkit-disks-device.c
index 5af03ce..58de2fd 100644
--- a/src/devkit-disks-device.c
+++ b/src/devkit-disks-device.c
@@ -2200,21 +2200,22 @@ static gboolean
 update_info_luks_cleartext (DevkitDisksDevice *device)
 {
 uid_t unlocked_by_uid;
-const gchar *dkd_dm_name;
-const gchar *dkd_dm_target_types;
+const gchar *dm_name;
+const gchar *dm_uuid;
 gboolean ret;
 
 ret = FALSE;
 
-dkd_dm_name = g_udev_device_get_property (device-priv-d, DKD_DM_NAME);
-dkd_dm_target_types = g_udev_device_get_property (device-priv-d, DKD_DM_TARGET_TYPES);
-if (dkd_dm_name != NULL  g_strcmp0 (dkd_dm_target_types, crypt) == 0 
+dm_name = g_udev_device_get_property (device-priv-d, DM_NAME);
+dm_uuid = g_udev_device_get_property (device-priv-d, DM_UUID);
+if (dm_name != NULL  g_str_has_prefix (dm_uuid, CRYPT-) 
 device-priv-slaves_objpath-len == 1) {
 
 /* TODO: might be racing with setting is_drive earlier */
 devkit_disks_device_set_device_is_drive (device, FALSE);
 
-if (g_str_has_prefix (dkd_dm_name, temporary-cryptsetup-)) {
+/* Debian already hides temporary cryptsetup devices, so this check could probably be removed? */
+if (g_str_has_prefix (dm_name, temporary-cryptsetup-)) {
 /* ignore temporary devices created by /sbin/cryptsetup */
 goto out;
  

Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-10-15 Thread Bastian Blank
[ Triming mdadm maintainers from CC. ]

On Thu, Oct 15, 2009 at 02:44:23PM +0200, Michael Biebl wrote:
 Is the DM_UUID=CRYPT-* naming scheme documented somewhere? I'd like to send 
 this
 patch upstream and would need to know if it is a Debian specific feature.

I forgot to cite the information I got from the cryptsetup maintainer.
The current state is documented in #548988.

 If not, since what version of cryptsetup/dmsetup is this naming interface 
 stable?

1.0.7 have CRYPT-$UUID for luks devices. 1.1, which is supposed to be
released shortly, will have CRYPT-PLAIN-* and CRYPT-LUKS-*.

I'm still not fully aware what you are really trying to detect. The code 
is so full of comments in the relevant section, this makes it not easier  
to give comments.

I see three possibilities:
- Destinguish between uncrypted and crypted devices (the luks
  description would be wrong then).
- Destinguish between plain crypted and luks crypted devices.
- Destinguish between luks crypted and anything else.

The last looks like the correct one according to the names and checks.
The correct check for this one would be:
CRYPT-[0-9a-f]* || CRYPT-LUKS-*
The check for temporary-cryptsetup-* can go then. This will catch
anything from cryptsetup 1.0.7 up.

It makes no sense to comment on the actual check if I don't know what it
should do.

Bastian

-- 
There is an order of things in this universe.
-- Apollo, Who Mourns for Adonais? stardate 3468.1



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-10-15 Thread Bastian Blank
On Thu, Oct 15, 2009 at 08:15:22PM +0200, Bastian Blank wrote:
 On Thu, Oct 15, 2009 at 02:44:23PM +0200, Michael Biebl wrote:
  If not, since what version of cryptsetup/dmsetup is this naming interface 
  stable?
  1.1, which is supposed to be
 released shortly, will have CRYPT-PLAIN-* and CRYPT-LUKS-*.

cryptsetup 1.1(~rc2) reached unstable today. Also it is CRYPT-LUKS1-*
(note the 1).

 - Destinguish between luks crypted and anything else.

Some additional looks only allow this variant to stay and the original
check is not able to do that.

Bastian

-- 
Suffocating together ... would create heroic camaraderie.
-- Khan Noonian Singh, Space Seed, stardate 3142.8



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-10-15 Thread Michael Biebl
Bastian Blank wrote:
 [ Triming mdadm maintainers from CC. ]

 
 The last looks like the correct one according to the names and checks.
 The correct check for this one would be:
 CRYPT-[0-9a-f]* || CRYPT-LUKS-*
 The check for temporary-cryptsetup-* can go then. This will catch
 anything from cryptsetup 1.0.7 up.

Assuming we want to distinguish luks devices, I updated the patch based on your
suggestions

-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?
From 9aca432753e8e4fbaacf09b47bdf374765397232 Mon Sep 17 00:00:00 2001
From: Michael Biebl bi...@debian.org
Date: Thu, 15 Oct 2009 14:26:17 +0200
Subject: [PATCH 1/2] Stop probing device-mapper devices

Use DM_NAME and DM_UUID which are already setup by the dmsetup udev
rules.
See http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=545032
---
 data/95-devkit-disks.rules |   21 -
 src/devkit-disks-device.c  |   17 +
 2 files changed, 9 insertions(+), 29 deletions(-)

Index: devicekit-disks/data/95-devkit-disks.rules
===
--- devicekit-disks.orig/data/95-devkit-disks.rules	2009-10-16 04:11:03.0 +0200
+++ devicekit-disks/data/95-devkit-disks.rules	2009-10-16 04:11:03.0 +0200
@@ -29,27 +29,6 @@
 
 ##
 
-# pick up device-mapper data; this REALLY should be done by rules installed
-# by the device-mapper package
-#
-KERNEL!=dm-*, GOTO=device_mapper_end
-ACTION!=add|change, GOTO=device_mapper_end
-
-IMPORT{program}=devkit-disks-dm-export %M %m
-ENV{DKD_DM_NAME}!=?*, GOTO=device_mapper_end
-
-ENV{DKD_DM_STATE}==SUSPENDED, GOTO=device_mapper_end
-ENV{DKD_DM_TARGET_TYPES}==|*error*, GOTO=device_mapper_end
-
-# avoid probing if it has already been done earlier
-#
-ENV{ID_FS_USAGE}!=, GOTO=device_mapper_end
-IMPORT{program}=/sbin/blkid -o udev -p $tempnode
-
-LABEL=device_mapper_end
-
-##
-
 # pick up data from MD components; this REALLY should be done by rules installed
 # by mdadm or the kernel package
 #
Index: devicekit-disks/src/devkit-disks-device.c
===
--- devicekit-disks.orig/src/devkit-disks-device.c	2009-10-16 04:11:03.0 +0200
+++ devicekit-disks/src/devkit-disks-device.c	2009-10-16 04:14:30.0 +0200
@@ -2200,21 +2200,24 @@
 update_info_luks_cleartext (DevkitDisksDevice *device)
 {
 uid_t unlocked_by_uid;
-const gchar *dkd_dm_name;
-const gchar *dkd_dm_target_types;
+const gchar *dm_name;
+const gchar *dm_uuid;
 gboolean ret;
 
 ret = FALSE;
 
-dkd_dm_name = g_udev_device_get_property (device-priv-d, DKD_DM_NAME);
-dkd_dm_target_types = g_udev_device_get_property (device-priv-d, DKD_DM_TARGET_TYPES);
-if (dkd_dm_name != NULL  g_strcmp0 (dkd_dm_target_types, crypt) == 0 
+dm_name = g_udev_device_get_property (device-priv-d, DM_NAME);
+dm_uuid = g_udev_device_get_property (device-priv-d, DM_UUID);
+if (dm_name != NULL  dm_uuid != NULL 
+(g_str_has_prefix (dm_uuid, CRYPT-LUKS1) ||
+ g_regex_match_simple (^CRYPT-[a-f0-9-]+$, dm_uuid, 0, 0)) 
 device-priv-slaves_objpath-len == 1) {
 
 /* TODO: might be racing with setting is_drive earlier */
 devkit_disks_device_set_device_is_drive (device, FALSE);
 
-if (g_str_has_prefix (dkd_dm_name, temporary-cryptsetup-)) {
+/* Debian already hides temporary cryptsetup devices, so this check could probably be removed? */
+if (g_str_has_prefix (dm_name, temporary-cryptsetup-)) {
 /* ignore temporary devices created by /sbin/cryptsetup */
 goto out;
 }
@@ -2223,12 +2226,12 @@
 
 devkit_disks_device_set_luks_cleartext_slave (device, ((gchar **) device-priv-slaves_objpath-pdata)[0]);
 
-if (luks_get_uid_from_dm_name (dkd_dm_name, unlocked_by_uid)) {
+if (luks_get_uid_from_dm_name (dm_name, unlocked_by_uid)) {
 devkit_disks_device_set_luks_cleartext_unlocked_by_uid (device, unlocked_by_uid);
 }
 
 /* TODO: export this at some point */
-devkit_disks_device_set_dm_name (device, dkd_dm_name);
+devkit_disks_device_set_dm_name (device, dm_name);
 } else {
 devkit_disks_device_set_device_is_luks_cleartext (device, FALSE);
 devkit_disks_device_set_luks_cleartext_slave (device, NULL);


signature.asc
Description: OpenPGP digital signature


Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-10-13 Thread Michael Biebl
Bastian Blank schrieb:
 On Sun, Oct 11, 2009 at 09:04:09PM +0200, Andreas Barth wrote:
 As what I read from the bug report, Bastian prefers to have all udev
 rules in dmsetup.
 
 Not in dmsetup, but in the package that controls that sort of device. So
 dmsetup for the core rules, lvm2 for the lvm specific rules, cryptsetup
 for their rules (if necessary, I don't know). Because they control there
 own devices, they may also break it.
 
 Bastian, same questions to you: Is there any reason why we can't at
 all have a working set of udev rules in devicekit-disks? (I'm not
 necessarily speaking about the current rules, but why it is impossible
 to have any udev rules in the package at all.)
 
 As long as the rules only change the behaviour of the tools in this
 package, but not just copy other rules and also follow the other rules
 about introspection, I don't see a general problem.
 
 However, the current rules file does the following.
 - Probe for partitions, aka open, on all block devices with a (small)
   blacklist. This can be only allowed with a whitelist, as several
   device types may not be queried from add events or not at all, like
   several dm subtypes.
 - Try to get informations about dm devices from add events.
 - Use blkid on dm devices even if this are hidden devices that must not
   show up via filesystem infos. Also done from add events, something
   that can never be allowed.
 - Examine linux raid devices with mdadm. This is the sole responsibility
   of the mdadm package.
 - Examine SMART state, only set informations.
 - Tag devices without known prefix and with an undocumented list of
   devices.
 
 The first point needs to be changed to a whitelist. The second only
 provides information used by them but it is undetermined if it will
 work and newer kernels change the way to actually get the information in
 this state. The third one needs to go. The forth is not my problem but I don't
 like it. The fifth is okay. The informations set in the sixth should get
 a known prefix.
 

We can safely remove the call to /sbin/mdadm --examine --export
$tempnode in the mdadm section of 95-devkit-disks.rules (actually the
complete mdadm section) as the mdadm udev rules handle that for us.

We can also safely remove the call to /sbin/blkid -o udev -p $tempnode
in the device-mapper section, as the dmsetup udev rules will do that for us.
What we can not remove currently, is the call to devkit-disks-dm-export,
as it makes additional information available like (DKM_)DM_TARGET_TYPES,
which is used inside the dk-disks code.

So, before we can remove the call to devkit-disks-dm-export, dmsetup
needs to be fixed to export that information. It seems you just removed
this kind of information in commit r730.

If you readd the dmsetup-export.patch, I could patch the dk-disks code
to use DM_TARGET_TYPES and DM_NAME instead of DKD_DM_TARGET_TYPES and
DKD_DM_NAME.

Does that sound like a plan to you?


-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?



signature.asc
Description: OpenPGP digital signature


Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-10-13 Thread Bastian Blank
On Tue, Oct 13, 2009 at 05:45:27PM +0200, Michael Biebl wrote:
 What we can not remove currently, is the call to devkit-disks-dm-export,
 as it makes additional information available like (DKM_)DM_TARGET_TYPES,
 which is used inside the dk-disks code.

Please explain which highlevel information you need.

DM_TARGET_TYPES is only used to find the string crypt in it and I
already explained several times that DM_UUID==CRYPT-* is a quite better
indicator, completely functional in the near future with cryptsetup 1.1.

Bastian

-- 
Four thousand throats may be cut in one night by a running man.
-- Klingon Soldier, Day of the Dove, stardate unknown



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-10-11 Thread Andreas Barth
* Michael Biebl (bi...@debian.org) [091011 18:58]:
 Where exactly in the rules does it overwrite data setup by device mapper?
 Which part exactly in the rules file does break other apps?
 What do you suggest instead?

I think this are the core questions, and we should try to get to an
at least working configuration soon.


As what I read from the bug report, Bastian prefers to have all udev
rules in dmsetup. Would that work for you? If not, why not? Or: What
do you need from udev what is not in dmsetup?

Bastian, same questions to you: Is there any reason why we can't at
all have a working set of udev rules in devicekit-disks? (I'm not
necessarily speaking about the current rules, but why it is impossible
to have any udev rules in the package at all.)

I'd like to push towards an resolution of this issue that works, and
makes our users happy. I don't have an strict opinion how the
resolutions looks otherwise, and would like to make a decision
together how we can reach that best.


Cheers,
Andi



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-10-11 Thread Bastian Blank
On Sun, Oct 11, 2009 at 09:04:09PM +0200, Andreas Barth wrote:
 As what I read from the bug report, Bastian prefers to have all udev
 rules in dmsetup.

Not in dmsetup, but in the package that controls that sort of device. So
dmsetup for the core rules, lvm2 for the lvm specific rules, cryptsetup
for their rules (if necessary, I don't know). Because they control there
own devices, they may also break it.

 Bastian, same questions to you: Is there any reason why we can't at
 all have a working set of udev rules in devicekit-disks? (I'm not
 necessarily speaking about the current rules, but why it is impossible
 to have any udev rules in the package at all.)

As long as the rules only change the behaviour of the tools in this
package, but not just copy other rules and also follow the other rules
about introspection, I don't see a general problem.

However, the current rules file does the following.
- Probe for partitions, aka open, on all block devices with a (small)
  blacklist. This can be only allowed with a whitelist, as several
  device types may not be queried from add events or not at all, like
  several dm subtypes.
- Try to get informations about dm devices from add events.
- Use blkid on dm devices even if this are hidden devices that must not
  show up via filesystem infos. Also done from add events, something
  that can never be allowed.
- Examine linux raid devices with mdadm. This is the sole responsibility
  of the mdadm package.
- Examine SMART state, only set informations.
- Tag devices without known prefix and with an undocumented list of
  devices.

The first point needs to be changed to a whitelist. The second only
provides information used by them but it is undetermined if it will
work and newer kernels change the way to actually get the information in
this state. The third one needs to go. The forth is not my problem but I don't
like it. The fifth is okay. The informations set in the sixth should get
a known prefix.

Bastian

-- 
Power is danger.
-- The Centurion, Balance of Terror, stardate 1709.2



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-10-09 Thread Bastian Blank
On Wed, Sep 23, 2009 at 04:36:54PM +0200, Michael Biebl wrote:
  But anyway, the duplication of the rules already warants this bug.
 Right, but not with this severity. So downgrading to important.

The rules are set by the kernel and userspace part of device-mapper to
make several of its users work. So the next step is to enforce them from
the kernel.

The rules provided by dmsetup provide the information you need in
DM_NAME, DM_UUID and maybe DM_SUSPENDED.

Bastian

-- 
Lots of people drink from the wrong bottle sometimes.
-- Edith Keeler, The City on the Edge of Forever,
   stardate unknown



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-09-24 Thread Bastian Blank
On Wed, Sep 23, 2009 at 05:06:00PM +0200, Michael Biebl wrote:
 Bastian Blank wrote:
  On Wed, Sep 23, 2009 at 04:36:54PM +0200, Michael Biebl wrote:
  Right, but not with this severity. So downgrading to important.
  Sure with this. You break dmsetup. Anyway, will add a conflict.
 Adding a conflict is certainly not the way I want it to go, as dk-disks is 
 meant
 to work with dm devices.

As long as it doesn't follow the rules, a conflict is correct.

 What do you suggest instead?

Remove it. dmsetup does the complete setup in favour of lvm and the
other devmapper using tools.

Bastian

-- 
Where there's no emotion, there's no motive for violence.
-- Spock, Dagger of the Mind, stardate 2715.1



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-09-23 Thread Michael Biebl
severity 545032 important
thanks

Bastian Blank wrote:
 On Fri, Sep 04, 2009 at 05:16:29PM +0200, Michael Biebl wrote:
 Bastian Blank wrote:
 devicekit-disks adds its own udev rules that likes to handle add actions
 of device-mapper devices. This will break arbitrary usage, for example
 cryptsetup. So this is not allowed for anything except the device mapper
 core with special precaution. Also it overwrites data already setup by
 device mapper.
 could you elaborate how exactly it will break other applications, like 
 cryptsetup.
 
 #543983
 
 But anyway, the duplication of the rules already warants this bug.

Right, but not with this severity. So downgrading to important.


Michael


-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?



signature.asc
Description: OpenPGP digital signature


Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-09-23 Thread Bastian Blank
On Wed, Sep 23, 2009 at 04:36:54PM +0200, Michael Biebl wrote:
 Right, but not with this severity. So downgrading to important.

Sure with this. You break dmsetup. Anyway, will add a conflict.

Bastian

-- 
No one may kill a man.  Not for any purpose.  It cannot be condoned.
-- Kirk, Spock's Brain, stardate 5431.6



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#545032: [Pkg-utopia-maintainers] Bug#545032: Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-09-23 Thread Michael Biebl
Bastian Blank wrote:
 On Wed, Sep 23, 2009 at 04:36:54PM +0200, Michael Biebl wrote:
 Right, but not with this severity. So downgrading to important.
 
 Sure with this. You break dmsetup. Anyway, will add a conflict.

Adding a conflict is certainly not the way I want it to go, as dk-disks is meant
to work with dm devices.

Where exactly in the rules does it overwrite data setup by device mapper?
Which part exactly in the rules file does break other apps?
What do you suggest instead?

FWIW, this is the relevant part of the current (devicekit-disk 004-1) rules 
file:

##

# pick up device-mapper data; this really should be done by rules installed
# by the device-mapper package
#

KERNEL!=dm-*, GOTO=device_mapper_end
ACTION!=add|change, GOTO=device_mapper_end

IMPORT{program}=devkit-disks-dm-export %M %m
ENV{DKD_DM_NAME}!=?*, GOTO=device_mapper_end

SYMLINK+=disk/by-id/dm-name-$env{DKD_DM_NAME}
ENV{DKD_DM_UUID}==?*, SYMLINK+=disk/by-id/dm-uuid-$env{DKD_DM_UUID}

ENV{DKD_DM_STATE}==SUSPENDED, GOTO=device_mapper_end
ENV{DKD_DM_TARGET_TYPES}==|*error*, GOTO=device_mapper_end

IMPORT{program}=vol_id --export $tempnode
OPTIONS=link_priority=-100
ENV{DKD_DM_TARGET_TYPES}==*snapshot-origin*, OPTIONS=link_priority=-90
ENV{ID_FS_USAGE}==filesystem|other|crypto, ENV{ID_FS_UUID_ENC}==?*,
SYMLINK+=disk/by-uuid/$env{ID_FS_UUID_ENC}
ENV{ID_FS_USAGE}==filesystem|other, ENV{ID_FS_LABEL_ENC}==?*,
SYMLINK+=disk/by-label/$env{ID_FS_LABEL_ENC}

LABEL=device_mapper_end

##


The next upload of dk-disks (devicekit-disk 007-1) will contain

##

# pick up device-mapper data; this REALLY should be done by rules installed
# by the device-mapper package
#
KERNEL!=dm-*, GOTO=device_mapper_end
ACTION!=add|change, GOTO=device_mapper_end

IMPORT{program}=devkit-disks-dm-export %M %m
ENV{DKD_DM_NAME}!=?*, GOTO=device_mapper_end

ENV{DKD_DM_STATE}==SUSPENDED, GOTO=device_mapper_end
ENV{DKD_DM_TARGET_TYPES}==|*error*, GOTO=device_mapper_end

# avoid probing if it has already been done earlier
#
ENV{ID_FS_USAGE}!=, GOTO=device_mapper_end
IMPORT{program}=/sbin/blkid -o udev -p $tempnode

LABEL=device_mapper_end

##


-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?



signature.asc
Description: OpenPGP digital signature


Bug#545032: [Pkg-utopia-maintainers] Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-09-04 Thread Michael Biebl
Bastian Blank wrote:
 Package: devicekit-disks
 Severity: critical
 
 devicekit-disks adds its own udev rules that likes to handle add actions
 of device-mapper devices. This will break arbitrary usage, for example
 cryptsetup. So this is not allowed for anything except the device mapper
 core with special precaution. Also it overwrites data already setup by
 device mapper.

Hi Bastian,

could you elaborate how exactly it will break other applications, like 
cryptsetup.

Michael
-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?



signature.asc
Description: OpenPGP digital signature


Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-09-04 Thread Bastian Blank
Package: devicekit-disks
Severity: critical

devicekit-disks adds its own udev rules that likes to handle add actions
of device-mapper devices. This will break arbitrary usage, for example
cryptsetup. So this is not allowed for anything except the device mapper
core with special precaution. Also it overwrites data already setup by
device mapper.

Bastian

-- 
Humans do claim a great deal for that particular emotion (love).
-- Spock, The Lights of Zetar, stardate 5725.6



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#545032: [Pkg-utopia-maintainers] Bug#545032: devicekit-disks - Handles add actions of dm devices

2009-09-04 Thread Bastian Blank
On Fri, Sep 04, 2009 at 05:16:29PM +0200, Michael Biebl wrote:
 Bastian Blank wrote:
  devicekit-disks adds its own udev rules that likes to handle add actions
  of device-mapper devices. This will break arbitrary usage, for example
  cryptsetup. So this is not allowed for anything except the device mapper
  core with special precaution. Also it overwrites data already setup by
  device mapper.
 could you elaborate how exactly it will break other applications, like 
 cryptsetup.

#543983

But anyway, the duplication of the rules already warants this bug.

Bastian

-- 
Our way is peace.
-- Septimus, the Son Worshiper, Bread and Circuses,
   stardate 4040.7.



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org