Skip to main content

ZFS Snapshot Replicator

Project description

Description

ZFS Replicate Utility

A small command line utility to handle remote replication of ZFS snapshots using SSH.

This project is directly based on the autorepl.py script used by FreeNAS.

I am providing code in the repository to you under an open source license. Because this is my personal repository, the license you receive to my code is from me and not my employer (Facebook).

Getting Started

Usage is pretty straight-forward and documented in the command’s help output. For more information on ZFS snapshots, see: Working With Oracle Solaris ZFS Snapshots and Clones

Remote Configuration

If you’re replicating using the root user’s credentials, you should really reconsider, but this script should just work.

Otherwise, you’ll not only need to ensure the user you’re using has SSH access to the remote host, but also can mount filesystems (if this is desirable) and has ZFS permissions configured correctly.

Allow user to mount (FreeBSD):

sysctl -w vfs.usermount=1

ZFS Permissions:

zfs allow backup create,destroy,snapshot,rollback,clone,promote,rename,mount,send,receive,quota,reservation,hold storage

More information about this configuration can be found at the following sources:

Compared to Other Tools

This tool is only for replication of snapshots. It assumes that another system is creating them on a regular basis. It also doesn’t require installation of any special tools (other than the standard shell scripts) on the remote host.

Other tools fill other niches:

sanoid

A full snapshot management system. Its companion application, syncoid, handles replication with many available options.

zfs-replicate (BASH)

A very similar project. The major differences are configuration style (our project uses parameters whereas this project uses a BASH script), and the system expectations (e.g., logging controls).

znapzend

Another scheduling and replicating system.

zrep

A SH script with several control commands for snapshot replication.

More information has been captured in this survey.

Reporting Issues

Any issues discovered should be recorded on Github. If you believe you’ve found an error or have a suggestion for a new feature, please ensure that it is reported.

If you would like to contribute a fix or new feature, please submit a pull request. This project follows git flow and utilizes travis to automatically check pull requests before a manual review.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

zfs-replicate-1.1.4.tar.gz (20.3 kB view details)

Uploaded Source

File details

Details for the file zfs-replicate-1.1.4.tar.gz.

File metadata

  • Download URL: zfs-replicate-1.1.4.tar.gz
  • Upload date:
  • Size: 20.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.0.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.3

File hashes

Hashes for zfs-replicate-1.1.4.tar.gz
Algorithm Hash digest
SHA256 7f5a9f5ea430fb969ce61cb61045cd9c3545c551c81d7b19c83e44cfe98dddb3
MD5 f5712780c2ba451d21f9c45c6dbca75e
BLAKE2b-256 4df1782ba1a54e102e1a8541b435be2afde7496b9160a3f412728d08d09dac14

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page