[PATCH] Added description on possible workflow for ZFS snapshotting

offlineimap at 927589452.de offlineimap at 927589452.de
Wed Feb 15 10:05:52 GMT 2017


From: J <github at 927589452.de>

Signed-off-by: J <github at 927589452.de>
---
 _doc/backups.md | 24 +++++++++++++++++++++++-
 1 file changed, 23 insertions(+), 1 deletion(-)

diff --git a/_doc/backups.md b/_doc/backups.md
index f867911..d782a4e 100644
--- a/_doc/backups.md
+++ b/_doc/backups.md
@@ -88,7 +88,29 @@ The idea is just about having an history available in case of damage. It's then
 
 #### ZFS
 
-*TODO*
+  Optional:
+  Generate a *zfs* mountpoint dedicated to your Mails:
+  {% highlight bash %}
+  $ zfs create zroot/usr/home/$USER/Mail 
+  {% endhighligt %}
+
+  To create a snapshot (with a date as the seed) you can run:
+  {% highlight bash %}
+  $ zfs snapshot zroot/usr/home/$USER/Mail@$(date +%Y%m%d%H%M%S)offlineimap
+  {% endhighligt %}
+
+  Of course you need to point your 'localfolders' to a subdirectory of the zfs mountpoint you are generating a snapshot of. 
+
+  Now you can easily wrap your offlineimap command with a failsafe like that:
+  {% highlight bash %}
+  #!/bin/sh
+  zfs snapshot zroot/usr/home/$USER/Mail@$(date +%Y%m%d%H%M%S)offlineimap
+  # append your commandline options as needed to the script
+  offlineimap $\*
+  {% endhighligt %}
+
+*TODO*:
+ Implement as offlineimap hook
 
 ### Content trackers
 
-- 
2.11.1





More information about the OfflineIMAP-project mailing list