[DRBD-user] DRBD and LVM2

Johan Karlsson jokka75 at gmail.com
Wed Jan 12 19:33:45 CET 2005

Note: "permalinks" may not be as permanent as we would like,
direct links of old sources may well be a few messages off.


On Tue, 11 Jan 2005 14:40:38 +0100, Laurent Simonneau <liste at alixen.fr> wrote:
> After a successfull drbd synchro, I try to run
> mke2fs -j /dev/drbd0 ... and drbd crash ! The connexion
> with secondary node is broken.

This happened to me with drbd 0.7.7 and kernel 2.4.2[678].
> It seems to work with protocol A, but I don't really understand why ...

Did not try that - but I dont want to run protocol A anyhow :-)

> But is it really interesting to use DRBD over LVM ? I use LVM for
> snapshots to have more consistant backup. I saw on mailing list,
> FAQ, ... a lot of contradictory informations about DRBD and LVM
> snapshot.
> Does it works or not ?

I have working drbd-over-lvm2 setups on a production servers, working perfectly
with protocol C. I'm running linux 2.6.9, drbd 0.7.7 and also
experimental vserver patches.

The question of using LVM underneath is a bit philosophical - I like
the flexilibity it gives me, especially since the standby machine is
linked with four other machines.
To add another one machine, I'd just lvcreate a new logical volume,
and configure drbd on top of this. Hopefully not all primarys will
fail at the same time, or the standby will get a lot to do =).

One server is scrapped? No problem, remove drbd and lvremove it - the
space can then efficiently be used for another server.

Just the other day, I needed more space for one vserver. Stop the
drbd, lvresize the logical volume on both nodes, drbdadm resize, start
drbd, resize2fs /dev/drbd0, mount and start the vserver. It would be
_a lot_ more work if regular partitions had been used.

But I guess it all depends on your needs and the setup.


More information about the drbd-user mailing list