Thanks Jason, I think I'm going to start with a bash script which SSH's into the machine to check if the process has finished writing and then calls the fsfreeze as I've got time constraints to getting this working. But I will definitely revisit this and see if there is something I can create which will do as you have described, as it would be a much neater solution. Nick > -----Original Message----- > From: ceph-users [mailto:ceph-users-bounces@xxxxxxxxxxxxxx] On Behalf Of Jason Dillaman > Sent: 08 July 2016 04:02 > To: nick@xxxxxxxxxx > Cc: ceph-users <ceph-users@xxxxxxxxxxxxxx> > Subject: Re: RBD Watch Notify for snapshots > > librbd pseudo-automatically handles this by flushing the cache to the snapshot when a new snapshot is created, but I don't think krbd > does the same. If it doesn't, it would probably be a nice addition to the block driver to support the general case. > > Baring that (or if you want to involve something like fsfreeze), I think the answer depends on how much you are willing to write some > custom C/C++ code (I don't think the rados python library exposes watch/notify APIs). A daemon could register a watch on a custom > per-host/image/etc object which would sync the disk when a notification is received. Prior to creating a snapshot, you would need to > send a notification to this object to alert the daemon to sync/fsfreeze/etc. > > On Thu, Jul 7, 2016 at 12:33 PM, Nick Fisk <mailto:nick@xxxxxxxxxx> wrote: > Hi All, > > I have a RBD mounted to a machine via the kernel client and I wish to be able to take a snapshot and mount it to another machine > where it can be backed up. > > The big issue is that I need to make sure that the process writing on the source machine is finished and the FS is sync'd before > taking the snapshot. > > My question. Is there something I can do with Watch/Notify to trigger this checking/sync process on the source machine before the > snapshot is actually taken? > > Thanks, > Nick > > _______________________________________________ > ceph-users mailing list > mailto:ceph-users@xxxxxxxxxxxxxx > http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com > > > > > -- > Jason _______________________________________________ ceph-users mailing list ceph-users@xxxxxxxxxxxxxx http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com