<div dir="ltr"><div><div><div>I see dmraid has two options -p (no_partitions) and -Z (rm_partitions).  I see that rm_partitions does just that, but it's not clear to me what the no_partitions option does.  Can somebody explain please?<br>
<br></div>How do utilities detect that a device is in use by DM?  I would like to be able to prevent creation of partitions on any disks my mapping target is using.  Are there ways to do that?  It would seem that DM solutions like raid, multipath, etc. would require this capability.<br>
<br></div>Thanks,<br></div>-john<br><div><div><div><div><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, Aug 2, 2013 at 6:07 AM, Zdenek Kabelac <span dir="ltr"><<a href="mailto:zkabelac@redhat.com" target="_blank">zkabelac@redhat.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Dne 1.8.2013 19:04, John Strange napsal(a):<div><div class="h5"><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
two questions:<br>
<br>
1. I'd like to use DM with a new target type.  I'm porting our virtualized<br>
storage solution from Windows.  I've been able to register my target and get<br>
callbacks working, but in looking at the dm-raid code, I'm concerned with how<br>
tightly coupled it is with the routines in md.c (multiple devices<br>
implementation).  Is there an expectation that a DM target use the md_xxxx<br>
routines?<br>
<br>
2. I used dmsetup to create a mapping for a device that my target controls.<br>
Is there a way to make the underlying device (e.g. /dev/sdb) not visible to<br>
the system?  I'm paranoid about external accesses to a LUN that I'm using.<br>
</blockquote>
<br></div></div>
In lvm2 it's solved in a way - that we use special flags for udev to avoid<br>
some scanning/watchrules - however all device are always available through /dev/mapper but  user visible devices are accessible via   /dev/vg/lv name which is the only suggested and supported way to use LVs.<br>
<br>
Obviously we often get reports where users are directly playing with /dev/dm-XXX devices or /dev/mapper/vg-lv  in their scripts and configs...<br>
<br>
But you can't hide existing devices in  system from userland visibility.<span class="HOEnZb"><font color="#888888"><br>
<br>
<br>
Zdenek<br>
<br>
</font></span></blockquote></div><br></div></div></div></div></div></div>