I'm curious as well.  I'm trying to set up a near-line backup using two 
ZFS-based machines, and am a bit confused on how to set it up properly.

First time around, create a snapshot and send it to remote:
zfs snapshot master/[EMAIL PROTECTED]
zfs send master/[EMAIL PROTECTED] | ssh mirror zfs recv backup/mirrorfs

Once that's done, [EMAIL PROTECTED], correct?  So if I wanted to start an 
incremental backup, I'd have to start creating mirror1, mirror2, etc?
zfs snapshot master/[EMAIL PROTECTED]
zfs send -i mirror master/[EMAIL PROTECTED] | ssh mirror zfs recv 
backup/mirrorfs
(make changes)
zfs snapshot master/[EMAIL PROTECTED]
zfs send -i mirror1 master/[EMAIL PROTECTED] | ssh mirror zfs recv 
backup/mirrorfs
etc.

So now [EMAIL PROTECTED]  So I could probably create a script that does a 
rename, snapshot, and send.  But let's say it was running from cron and some 
failed (for whatever reason).  So now I'm running the script manually and it's 
complaining that the incremental source doesn't match, and apparently no way to 
tell which [EMAIL PROTECTED] is the source short of trial-and-error even if I 
kept all my incremental mirrors?  Is there a clean way around this?

I guess a better scenario would be that I accidentally destroyed the last 
[EMAIL PROTECTED] (so no source snapshot to -i).  Would my only recourse it to 
bite the bullet and do a zfs send [EMAIL PROTECTED] (aka full)?

Another question is if I wanted to send a snapshot as a snapshot, I can do:
zfs snapshot master/[EMAIL PROTECTED]
zfs send master/[EMAIL PROTECTED] | ssh mirror zfs recv backup/[EMAIL PROTECTED]

And now [EMAIL PROTECTED]@savesnap, right?  But that would involve sending the 
whole stream, which is however much data the filesystem was consuming at that 
point in time?  How would mirrorfs handle the difference between it and [EMAIL 
PROTECTED]  Would it take as much space as the [EMAIL PROTECTED] to [EMAIL 
PROTECTED], or more?

Sorry for all these questions (and sort of derailing the thread) but I'd really 
like to set this up the right way the first time around.  I'd love to be able 
to say zfs mirror master/[EMAIL PROTECTED] [EMAIL PROTECTED]/mirrorfs and have 
it sync a fs, either the current fs or a snapshot, but right now it seems as 
though the only way to do it is with snapshots, send/recv, and fiddling with 
incremental scripting...

Thanks,
-- Starfox
 
 
This message posted from opensolaris.org
_______________________________________________
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss

Reply via email to