[DRBD-user] Drbd + LVM snapshots?

Iustin Pop iustin at google.com
Thu Mar 12 15:17:46 CET 2009

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


On Thu, Mar 12, 2009 at 02:07:56PM +0000, Hari Sekhon wrote:
> Stefan Seifert wrote:
> > On Thursday 12 March 2009 14:34:03 Hari Sekhon wrote:
> >   
> >> Has anyone used Drbd with LVM snapshots?
> >>
> >> I have lvm on top of drbd so that I can try snapshotting the contents of
> >> the main storage on the primary node while it has it mounted.
> >>
> >> I really want to both replicate (which is working well) and also to take
> >> snapshots of the main area some how.
> >> Can anyone tell me if what I am trying to do is completely off or if
> >> this can be done in another way?
> >>     
> >
> > I have it the other way round: my drbd device is on top of an lv. Makes 
> > resizing trivial and allows me to make snapshots for backups. Works like a 
> > charm.
> >
> > Regards,
> > Stefan
> 
> Your snapshots are local and not replicated then?
> 
> Have you actually mounted a snapshot of a drbd device, is the filesystem 
> operational?
> 
> As far as I can tell, this is the one stumbling block, actually getting 
> the snapshot of this drbd data volume to be mountable/usable... since 
> the filesystem itself is still sitting on drbd which I am sure does some 
> block fiddling (perhaps incidentally rather than intentionally) to 
> prevent mounting, the same sort of thing as when you try to mount the 
> underlying block device by mistake...

Block fiddling? There's such thing (AFAIK). Yes, it works with
snapshotting the underlying LVM volume.

The 'prevent mounting' thing you refer to is just open in exclusive
mode.

regards,
iustin



More information about the drbd-user mailing list