Wes was kind enough to
point out that the zenity-based GUI in the last release of the ZFS Automatic Snapshots SMF Service didn’t work under earlier versions of JDS. After a bit of digging, we discovered that this was because some zenity features I was relying on weren’t in the older GNOME 2.6-based zenity.
So, rather sooner than I expected, I’ve got another version of the software for you to try – zfs-auto-snapshot-0.4.tar.gz (link now deleted, see Update at the bottom of this post).
We now detect which version of zenity is on the system, and do the right thing. I’ve included a README to make things easier for the first-time user.
I also cleaned up some of the logic that creates the name of the SMF instance for each snapshot schedule. In the earlier code, if you had two ZFS filesystems
tank/foo/bar with separate snapshot schedules (not strictly required, since you could have one schedule for
tank, and use the “snapshot all child datasets” option), SMF would have failed to import the 2nd instance – we can’t use ‘/’ in SMF instance names, so I was escaping them with ‘-‘ characters, hence the namespace clash. This is fixed now, so all feedback is welcome!
They say the best backups are the ones you don’t have to worry about, and while I realise that ZFS snapshots are only the first step in a “proper” backup solution, in my day to day work testing ZFS, this stuff has already saved me from going off looking for tapes…
Perhaps the next step, is to extend the current functionality to provide an option to use zfs send/receive, so along with taking snapshots on a schedule, we would also store the snapshots incrementally to a remote machine (and perhaps a do a bit of email notification! – Zawinski’s Law ? Bring it on!).
However, today, it’s a gorgeous day in Dublin, which is quite a rarity, so I’m going outside to play :-) Have a nice weekend folks!
Update June 30th: Joe pointed out a bug where the recursive snapshotting wasn’t respecting the retention limit properly: this was because I was using the same variable name in a shell function as I was in the function that called it (I thought ksh used local-scoping for variable names). You can get the fixed bits in zfs-auto-snapshot-0.5.tar.gz.
Thanks again for the bug report Joe!
Update September 6th: More here.
Update November 27th: More here.