From cafd48d04e5f3611bd66f1ff4be3e0e109fc7496 Mon Sep 17 00:00:00 2001 From: Vasil Averyanau Date: Tue, 10 Dec 2024 17:19:00 +0100 Subject: [PATCH] chore(docs): how to avoid restore and backup/repair task interference (#4147) This documents how to prevent interference between restore and backup/repair tasks. Fixes: #3742 --- docs/source/restore/index.rst | 23 ++++++++++--------- .../source/sctool/partials/sctool_repair.yaml | 2 +- .../sctool/partials/sctool_repair_update.yaml | 2 +- 3 files changed, 14 insertions(+), 13 deletions(-) diff --git a/docs/source/restore/index.rst b/docs/source/restore/index.rst index 67948c894..7dee2588d 100644 --- a/docs/source/restore/index.rst +++ b/docs/source/restore/index.rst @@ -89,14 +89,15 @@ and :ref:`resume ` it. Interference with backup and repair tasks ========================================= -It is advisable to manually make sure that the restore task does not interfere with backup or repair tasks. - -#. Do not start backup or repair tasks when restore task is running. -#. If scheduled runs of backup or repair tasks can interfier with restore task, then disable them until restore is complete:: - - # check Next column to determine when next run of a task is scheduled - $ sctool tasks -a - - # disable repair/backup tasks if needed - $ sctool repair update -c CLUSTER-ID SCHEDULED-REPAIR-TASK-ID --enabled=false - $ sctool backup update -c CLUSTER-ID SCHEDULED-BACKUP-TASK-ID --enabled=false +The restore task will not start if backup or repair tasks are running in the cluster at that time, and vice versa, if a restore task is running, backup or repair tasks will not start. +You will see an error in the output of the ``sctool tasks`` command if there is a conflict between tasks. +Here is an example output of ``sctool progress -c ${cluster_name} {task_id}`` when there is an interference between tasks:: + + $ ./sctool.dev progress -c my-cluster backup/06cd5d90-6daa-4215-acd3-d19f6782b5b6 + Run: 351378ee-ab05-11ef-aa2d-0242c0a8c802 + Status: ERROR (initialising) + Cause: exclusive task (restore) is running: another task is running + Start time: 25 Nov 24 09:13:52 CET + End time: 25 Nov 24 09:13:52 CET + Duration: 0s + Progress: - diff --git a/docs/source/sctool/partials/sctool_repair.yaml b/docs/source/sctool/partials/sctool_repair.yaml index 4b0a7524c..5bbe5bd38 100644 --- a/docs/source/sctool/partials/sctool_repair.yaml +++ b/docs/source/sctool/partials/sctool_repair.yaml @@ -129,7 +129,7 @@ options: usage: | Prints table names together with keyspace, used in combination with --dry-run. - name: small-table-threshold - default_value: 1G + default_value: 1GiB usage: | Enables small table optimization for tables of size lower than given threshold, supported units [B, M, G, T]. - name: start-date diff --git a/docs/source/sctool/partials/sctool_repair_update.yaml b/docs/source/sctool/partials/sctool_repair_update.yaml index adf30acb8..82b9fc748 100644 --- a/docs/source/sctool/partials/sctool_repair_update.yaml +++ b/docs/source/sctool/partials/sctool_repair_update.yaml @@ -130,7 +130,7 @@ options: usage: | Prints table names together with keyspace, used in combination with --dry-run. - name: small-table-threshold - default_value: 1G + default_value: 1GiB usage: | Enables small table optimization for tables of size lower than given threshold, supported units [B, M, G, T]. - name: start-date