From 81f1eee55257ca4c0d1b094db7585e8bbb4bd50d Mon Sep 17 00:00:00 2001
From: Eric Frias <efrias@syncad.com>
Date: Sat, 5 Apr 2025 18:09:51 +0000
Subject: [PATCH] Prevent snapshotting after hive sync from failing when
 copying shared_memory.bin on slow hardware, fixes #26

---
 assisted_startup.sh | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/assisted_startup.sh b/assisted_startup.sh
index 2b83814..4220c31 100755
--- a/assisted_startup.sh
+++ b/assisted_startup.sh
@@ -440,7 +440,10 @@ else
     fi
 
     # Create a snapshot of the ZFS pool
-    ./snapshot_zfs_datasets.sh $SNAPSHOT_NAME
+    # (specify --force to prevent snapshot_zfs_datasets from erroring out
+    # if the blockchain and shared_memory write times are too far apart,
+    # something that can easily happen when copying the shared memory file)
+    ./snapshot_zfs_datasets.sh --force $SNAPSHOT_NAME
 
     # Restart Docker Compose
     docker compose up -d
-- 
GitLab