Saturday, November 19, 2011

Solaris: ZFS snapshot between two hosts

Send the initial snapshot and create the filesystem on the remote host

  1. make sure that the receiving host is running Solaris updated after October 2008
  2. make sure the filesystem you are replicating does not exist already on the receving host
  3. zfs snapshot export/upload@zrep-00001 on the origin host
  4. zfs send -i export/upload@zrep-00001 | ssh otherservername "cat > /export/save/upload@zrep-00001"
  5. wait several days depending on the size of the dataset
  6. cat /export/save/upload@rzrepl-00001 | zfs recv export/upload


Statistics: able to complete a transfer of 6.1T in 10 days. (From ms1 (Sun Fire X4500) to ms5 (Sun Fire X4540), both hosts in the same rack.)

Send incremental covering the days that the first step took

  1. zfs snapshot export/upload@zrep-00002 on the origin host
  2. zfs send -i export/upload@zrep-00001 export/upload@zrep-00002 | ssh otherservername "cat > /export/save/upload@zrep-00002"
  3. cat /export/save/upload@rzrepl-00002 | zfs recv export/upload

No comments:

UNIX: How to print column nicely using printf

[user@hostfwnms1-oam tmp]# cat b.sh printf "%-26s %-19s %-8s %-8s %-s %-s\n" HOSTNAME IP PING SNMPWALK 0-ok 1-fail for i in `cat n...