chiark / gitweb /
rsync-backup.in, rsync-backup.8: Ensure the store filesystem is mounted.
[rsync-backup] / rsync-backup.in
index 5c9a54cefff2570bd87ba48b8cebb010202e2390..705696d2b8cb4f73461c9f8aa288177d48c84d8c 100644 (file)
@@ -606,6 +606,15 @@ backup () {
   ## Back up the filesystems on the currently selected host using the
   ## currently selected snapshot type.
 
+  ## Make sure that there's a store volume.  We must do this here rather than
+  ## in the main body of the script, since the configuration file needs a
+  ## chance to override STOREDIR.
+  if ! [ -r $STOREDIR/.rsync-backup-store ]; then
+    echo >&2 "$quis: no backup volume mounted"
+    exit 15
+  fi
+
+  ## Back up each requested file system in turn.
   for fs in "$@"; do
 
     ## Parse the argument.