You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/how-to/back-up-and-restore/create-a-backup.md
+11-2Lines changed: 11 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -15,9 +15,18 @@ Once `juju status` shows Charmed MySQL as `active` and `idle`, you can create yo
15
15
juju run mysql/leader create-backup
16
16
```
17
17
18
-
If you have a cluster of one unit, you can run the `create-backup` action on `mysql-k8s/leader` (which will also be the primary unit).
18
+
If you have a cluster of one unit, you can run the `create-backup` action on the leader (which will also be the primary unit).
19
+
Otherwise, you must run the `create-backup` action on a non-primary unit. To find the primary, see `juju status` or
20
+
run `juju run mysql/leader get-cluster-status` to find the primary unit.
19
21
20
-
Otherwise, you must run the `create-backup` action on a non-primary unit. To find the primary, see `juju status` or run `juju run mysql-k8s/leader get-cluster-status` to find the primary unit).
22
+
The `create-backup` action validates that the unit in charge of the backup is healthy, by:
23
+
- Checking that the MySQL cluster is in a valid state (`OK` or `OK_PARTIAL` from the InnoDB [cluster status](https://dev.mysql.com/doc/mysql-shell/8.0/en/monitoring-innodb-cluster.html))
24
+
- Checking that the MySQL instance is in a valid state (`ONLINE` from Replication [member states](https://dev.mysql.com/doc/refman/8.0/en/group-replication-server-states.html).
25
+
26
+
In order to override these precautions, use the `force` flag:
27
+
```shell
28
+
juju run mysql/leader create-backup force=True
29
+
```
21
30
22
31
## List backups
23
32
You can list your available, failed, and in progress backups by running the `list-backups` command:
0 commit comments