Note: "permalinks" may not be as permanent as we would like,
direct links of old sources may well be a few messages off.
Lars Ellenberg wrote: > you could have set it up as LVM2 on top of DRBD instead. > Oh, really? Thought I've read somewhere don't do this. Very good to know. Why LVM2 or is LVM1 also acceptable? > Basically the problem is that you won't get a "clean" but only a > "consistent" snapshot if you have LVM below DRBD, because LVM expects to > be the topmost layer right below the file system, and if DRBD (or any > other stacking block device driver, for that matter) is in between, LVM > is not able to contact the filesystem and tell it to flush its journals > and metadata stuff, > Yes, that makes sense. > > "stop drbd on primary without making the peer primary" > is > "take down that device, and all services depending on the data on it". > > this is the easy way, and of course will give you a clean and consistent > view of the data, because the data won't be used by anyone but the > backup now... Not so good, i believe ... > so what should work is backup/snapshot during downtime: > > node-A: Primary; node-B: Secondary > node-A# stop_all_services && umount /dev/nb0 && drbd stop > node-A: Secondary; node-B: Secondary > either node# lvmcreate {snapshot} > either node# drbd start ; mount_that_device && start_all_services > > then do anything you want to do with the snapshot, and delete the > snapshot after you are done with it. you should be able to access the > drbd device as usual while accessing the snapshot. > > the difficult thing is: doing a clean and consistent snapshot while drbd > is online. Mhm, i see ... stop_all_services won't be a good solution, cause these services should be high available, it's a HA cluster ;-) The snapshot should be created _while_ all services are running. > The failover/failback thing, and "just inbetween" doing the snapshot, > as you outline above, won't be such a good idea, because you probably > will get a consistent, but not a *clean* snapshot. What exactly means *clean*? Is that the problem you above-mentioned, i.e. making a snapshot while drbd is online? Thanks for help, possible these questions should go on a "drbd-newbie" list. -- Best regards, Andreas Semt