[DRBD-user] drbd+lvm no bueno

Eric Robinson eric.robinson at psmnv.com
Sat Jul 28 16:38:54 CEST 2018


> > > Lars,
> > >
> > > I put MySQL databases on the drbd volume. To back them up, I pause
> > > them and do LVM snapshots (then rsync the snapshots to an archive
> > > server). How could I do that with LVM below drbd, since what I want
> > > is a snapshot of the filesystem where MySQL lives?
> >
> > You just snapshot below DRBD, after "quiescen" the mysql db.
> >
> > DRBD is transparent, the "garbage" (to the filesystem) of the
> > "trailing drbd meta data" is of no concern.
> > You may have to "mount -t ext4" (or xfs or whatever), if your mount
> > and libblkid decide that this was a "drbd" type and could not be
> > mounted. They are just trying to help, really.
> > which is good. but in that case they get it wrong.
> 
> Okay, just so I understand....
> 
> Suppose I turn md4 into a PV and create one volume group 'vg_under_drbd0',
> and logical volume 'lv_under_drbd0' that takes 95% of the space, leaving 5%
> for snapshots.
> 
> Then I create my ext4 filesystem directly on drbd0.
> 
> At backup time, I quiesce the MySQL instances and create a snapshot of the
> drbd disk.
> 
> I can then mount the drbd snapshot as a filesystem?
> 

Disregard question. I tested it. Works fine. Mind blown.

-Eric




More information about the drbd-user mailing list