Use clone source for btrfs send.
This commit is contained in:
@@ -139,8 +139,9 @@ in
|
|||||||
echo "Incremental send completed successfully"
|
echo "Incremental send completed successfully"
|
||||||
REPLICATION_SUCCESS=1
|
REPLICATION_SUCCESS=1
|
||||||
else
|
else
|
||||||
echo "Incremental send failed (likely missing parent on receiver), falling back to full send"
|
echo "Incremental send failed (likely missing parent on receiver), falling back to full send with clone source"
|
||||||
btrfs send "$SNAPSHOT_PATH" | \
|
# Use -c to specify clone source, maintaining parent relationship even in full send
|
||||||
|
btrfs send -c "$PREV_LOCAL" "$SNAPSHOT_PATH" | \
|
||||||
ssh -i "$SSH_KEY" -o StrictHostKeyChecking=accept-new root@${standby} \
|
ssh -i "$SSH_KEY" -o StrictHostKeyChecking=accept-new root@${standby} \
|
||||||
"btrfs receive /persist/services-standby"
|
"btrfs receive /persist/services-standby"
|
||||||
REPLICATION_SUCCESS=1
|
REPLICATION_SUCCESS=1
|
||||||
|
|||||||
Reference in New Issue
Block a user