Copy zfs volume onto another server using ssh

Copy ZFS Volume onto another Server using SSH

Copy ZFS Volume onto another Server using SSH
This snippet describes how to Copy ZFS Volume onto another Server using SSH. The steps to realize that are very easily and can be done by doing following:


Let’s assume you want to transfer a zfs volume named "rpool/storage" onto another Server you own.

First you have to take a snapshot from your source volume.

On your source host by enter following commands:

zfs snapshot -r rpool/storage@1
zfs send rpool/storage@1 | ssh root@yourTARGETHOSTIP zfs receive rpool/storage@1

After SSH transfer login to your target host and set your new mountpoint for the new volume:

zfs set mountpoint=/storage rpool/storage

Thats it!

See also Oracle ZFS Administration Handbook for detailed infos about ZFS: Oracle ZFS

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Human Verification: In order to verify that you are a human and not a spam bot, please enter the answer into the following box below based on the instructions contained in the graphic.