[DRBD-user] open OpenSSI-DRBD integration issues.

Lars Ellenberg Lars.Ellenberg at linbit.com
Thu Feb 12 13:52:23 CET 2004


> In OpenSSI, to failover file systems from one node to another, we use
> the UUID to determine which device refers to the failed file system. So,
> we have entries as:
> 
> UUID=d55a4892-d7be-455d-8509-cd24ab8b076b       /home   ext3
> defaults,chard,node=2:1 1       2
> 
> The UUID above is the UUID of /dev/nbd/0 which is being mirrored between
> node2 and node1.
> 
> Now, when I call "mount -a", instead of mounting /dev/nbd/0, it mounts
> the underlying device which is /dev/ida/c0d0p3, as reflected in the mtab
> 
>    /dev/2/ida/c0d0p3 on /home type ext3 (rw,chard)
> 
> mount uses /proc/partitions to determine which devices to read for the
> particular UUID. Since the drbd devices don't have entries in
> /proc/partitions, only the underlying devices get checked for UUID and
> so get mounted. The DRBD device will never get mounted if the UUID is
> specified.
> 

On kernel 2.4, we do not use gendisks at all, so we never show up
in /proc/partitions. But even if we _did_ show up there, it won't
be a _unique_ id anymore, since drbd is transparent, and the
superblock of /dev/nbd/0 looks exactly the same the one of
/dev/lower/device.

So only the first matching U-"U"-ID will be mounted, and 
I suppose the lower device typically is listed first.

We had a similar problem trying to get LVM on top of drbd running:
it just does not work. With LVM2, however, one can configure
patterns of device names to exclude / include in the search for PVs,
and it works.

(A)
So maybe you have to hack up mount, to have it look at /dev/nbX
first whenever you specify a UUID, regardless of whether they show
up in /proc/partitions or not (or add a /etc/partitions to be
read in first, to have this more flexible) ...

(B)
Or, we could hack up DRBD to nullify the first, say, 64K, and
remapping all blocks 64K up. Loosing transparency, gaining unique
superblocks. We'd still have to register our gendisks in linux 2.4...


	Lars Ellenberg



More information about the drbd-user mailing list