On Mon, May 08, 2006 at 02:27:05PM +0200, Patrick wrote:
> Hi there,
> 
> I've got a question, that i'm sure's been addressed somewhere, so
> sorry if i'm asking the same question twice, but here goes:
> 
> I've currently got two linux machines running drbd ( remote device
> mirror ) and it's working perfectly, but i'd love to use ZFS (* i
> <heart> ZFS *) but alas, i don't seem to see any information on remote
> mirroring other than a blog i've found about using NFS to export the
> device, the page :
> 
> http://blogs.sun.com/roller/page/chrisg?entry=zfs_remote_replication
> http://blogs.sun.com/roller/page/chrisg?entry=more_with_the_zfs_external
> 
> The page has an idea that seems somewhat fiddly, and i'd rather not
> trust it on a production-type enviroment, anyone have any more 'info'
> for me?

There are two basic methods of doing remote replication: remote
mirroring and asynchronous updates.  

Remote mirroring can be done through iSCSI/zvols, though the failover
case is a little awkward (you'll be doing ZFS on top of zvols for local
access).  It also implies synchronous operation for every write, which
would slow down local access.  The remote data is also not available
(even read-only) until you perform a failover, because mirroring occurs
at the block level and the upper layers cannot keep in sync.

Asynchronous remote replication can be done today with 'zfs send' and
zfs receive', though it needs some more work to be truly useful.  It has
the properties that it doesn't tax local activity, but your data will be
slightly out of sync (depending on how often you sync your data,
preferably a few minutes).  Among the things we're working on to make
this easier:

- recursive snapshots ('zfs snapshot -r')
- recursive send ('zfs send -r')
- ability to send properties ('zfs send -p')
- read-only receive on the remote end (currently the fs has to be
  unmounted)
- ability to receive into root dataset

Once these are are implemented, it should be fairly easy to construct
your own cron job to do regular remote replication using any transport
you'd like (probably SSH).  The tricky part comes when local churn
outpaces regular replication.  Do you want to guarantee your time delta
(by slowing down local access somehow), or hope that the remote end will
catch up (disabling more attempts in the process).

- Eric

--
Eric Schrock, Solaris Kernel Development       http://blogs.sun.com/eschrock
_______________________________________________
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss

Reply via email to