EBS snapshot backups from a FreeBSD zfs file system: zpool freeze?

Charles Sprickman spork at bway.net
Thu Jul 4 00:28:52 UTC 2013


On Jul 3, 2013, at 8:13 PM, Steven Hartland wrote:

> ----- Original Message ----- From: "Berend de Boer" <berend at pobox.com>
>> Hi All,
>> I'm experimenting with building a FreeBSD NFS server on Amazon AWS
>> EC2. I've created a zpool with 5 disks in a raidz2 configuration.
>> 
>> How can I make a consistent backup of this using EBS?
>> On Linux' file systems I can freeze a file system, start the backup of
>> all disks, and unfreeze. This freeze usually only takes 100ms or so.
>> ZFS on FreeBSD does not appear to have such an option. I.e. what I'm
>> looking for is basically a hardware based snapshot. ZFS should simply
>> be suspended at a recoverable point for a few hundred ms.
>> A similar question from 2010 is here:
>> http://thr3ads.net/zfs-discuss/2010/11/580781-how-to-quiesce-and-unquiesc-zfs-and-zpool-for-array-hardware-snapshots
>> Absent a "zfs freeze" it seems using FreeBSD/zfs on AWS with EBS is
>> going to be impossible. Unfortunately that means back to Linux sigh.
> 
> Not been following the thread really so excuse if this has already
> been mentioned ;-)
> 
> There is a zpool freeze <pool> which stops spa_sync() from doing
> anything, so that the only way to record changes is on the ZIL.

I don't use EC2 or any of the other Amazon "cloud" stuff, but I'd assume
you could even have another chunk of block storage as a dedicated ZIL
and you could pass on snapshotting that.  What effect would that have
on the pool while it's "frozen"?  Are all writes, sync or not, sent
to ZIL while frozen?

I do have an interest in this as I do run some ESXi hosts, and in
addition to file-level backups, I do take snapshots with vmware.
Knowing that the "quiesce writes" option is actually doing something 
and is not just a no-op when running the FreeBSD guest tools would be
nice.

Any arguments that claim "people don't do this" I think are a bit dated,
not only are the Amazon services widely used, but host-your-own 
virtualization, be it VMware, Xen, VirtualBox, or Hyper-V is extremely common.

> The comment in the zpool_main is: "'freeze' is a vile debugging
> abomination" so it's evil but might be what you want if you're up to
> writing some code.

Anything going on with this on the Illumos or ZFS on Linux side?

Charles

> 
> For more info have a look at ztest.
> 
>   Regards
>   Steve
> 
> ================================================
> This e.mail is private and confidential between Multiplay (UK) Ltd. and the person or entity to whom it is addressed. In the event of misdirection, the recipient is prohibited from using, copying, printing or otherwise disseminating it or any information contained in it. 
> In the event of misdirection, illegible or incomplete transmission please telephone +44 845 868 1337
> or return the E.mail to postmaster at multiplay.co.uk.
> 
> _______________________________________________
> freebsd-fs at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-fs
> To unsubscribe, send any mail to "freebsd-fs-unsubscribe at freebsd.org"



More information about the freebsd-fs mailing list