zfsnap - Simple sh script to make zfs rolling snaphosts with cron

Property Value
Distribution FreeBSD 12
Repository FreeBSD Ports Quarterly i386
Package filename zfsnap-1.11.1_1.txz
Package name zfsnap
Package version 1.11.1
Package release 1
Package architecture i386
Package type txz
Category sysutils
Homepage https://github.com/graudeejs/zfSnap/
Maintainer yamagi@yamagi.org
Download size 6.61 KB
Installed size 25.02 KB
zfSnap is a simple sh script for creating ZFS snapshots. When called from
cron rolling snapshots can be created and deleted automatically. The main
advantage of zfSnap is that it is written in 100%25 pure /bin/sh, does not
require any additional software to run, and is simple to use.
zfSnap keeps all information about snapshot in snapshot name. zfs snapshot
names are in form: Timestamp--TTL where timestamp is date and time of
snapshot creation and TTL is Time To Live in human readable form.
WWW: https://github.com/graudeejs/zfSnap/
To run zfSnap periodically you can add these options to your
xPERIODICx_zfsnap_enable	- Enable xPERIODICx snapshots
(values: YES | NO)
xPERIODICx_zfsnap_fs		- Space separated zfs filesystems
to create non-recursive snapshots
xPERIODICx_zfsnap_recursive_fs	- Space separated zfs filesystems
to create recursive snapshots
xPERIODICx_zfsnap_ttl		- Set Time To Live
xPERIODICx_zfsnap_verbose	- Verbose output (values: YES | NO)
xPERIODICx_zfsnap_flags		- zfSnap generic flags
(except -v and -d)
xPERIODICx_zfsnap_enable_prefix - Create snapshots with prefix
(Default = YES)
xPERIODICx_zfsnap_prefix	- Set prefix to use for new snapshots
(Default = "xPERIODICx-")
(where xPERIODICx is any of hourly, daily, weekly, monthly, reboot)
xPERIODICx_zfsnap_delete_enable    - Delete old snapshots periodically
(values: YES | NO)
xPERIODICx_zfsnap_delete_flags	   - zfSnap generic flags
(except -v and -d)
xPERIODICx_zfsnap_delete_verbose   - Verbose output (values: YES | NO)
xPERIODICx_zfsnap_delete_prefixes  - Space separated list of prefixes
of old zfSnap snapshots to delete
'hourly-', 'daily-', 'weekly-',
'monthly-' and 'reboot-' prefixes
are hard-coded
(where xPERIODICx is any of daily, weekly, monthly)
Add these lines to your /etc/crontab
4	*	*	*	*	root	periodic hourly
@reboot					root	periodic reboot
NOTE: it is not recommended to delete zfSnap snapshots every hour.
Deleting zfs snapshots takes more time than creating them.
There for it's better to delete snapshots once per day...
Periodic scripts provide very limited feature set. If you want to use
more advanced setup, you need to call zfSnap from crontab directly.
This way you can combine all sort of parameter combinations.
Don't forget to check https://github.com/graudeejs/zfSnap/wiki for more
Feedback welcomed: graudeejs@gmail.com


Package Version Architecture Repository
zfsnap-1.11.1_1.txz 1.11.1 amd64 FreeBSD Ports Quarterly
zfsnap-1.11.1_1.txz 1.11.1 amd64 FreeBSD Ports Latest
zfsnap-1.11.1_1.txz 1.11.1 i386 FreeBSD Ports Latest
zfsnap - - -


Type URL
Mirror pkg.freebsd.org
Binary Package zfsnap-1.11.1_1.txz
Source Package sysutils/zfsnap

Install Howto

Install zfsnap txz package:

# pkg install zfsnap

See Also

Package Description
zfsnap2-2.0.0.b3_1.txz Portable performant script to make rolling ZFS snapshots easy
zfstools-0.3.6_1.txz OpenSolaris-compatible auto snapshotting for ZFS
zgv-5.9_9.txz Graphics viewer for SVGAlib
zh-CJKUnifonts-0.2.20080216.1_4.txz CJKUnifonts TrueType Font is a combine of Arphic Ming and Kai fonts
zh-CNS11643-font-98.1_6.txz Combine of Kai and Sung with CNS11643 TrueType Fonts
zh-FreeWnn-lib-1.1.1.a021_13.txz Japanese/Chinese/Korean input method (Chinese client libraries)
zh-FreeWnn-server-1.1.1.a021_14.txz Japanese/Chinese/Korean input method (Chinese server)
zh-arphicttf-2.11_6.txz Four Chinese Big5/GB TrueType fonts made by Arphic Technology
zh-aterm-1.0.1.txz Color vt102 terminal emulator with transparency support
zh-auto-cn-l10n-1.1_3.txz The automatic localization for Simplified Chinese zh_CN.eucCN locale
zh-auto-tw-l10n-1.16.txz Automatic localization for Traditional Chinese locale
zh-autoconvert-0.3.16_5.txz Intelligent Chinese encoding converter
zh-bg5pdf-1.0.0_8.txz Convert Chinese-Big5 encoded files to PDF, using PDFlib
zh-bitchx-1.2.1_2,1.txz Feature-rich scriptable IRC client
zh-brise-0.35.txz Rime Schema Repository