generated from canonical/template-operator
-
Notifications
You must be signed in to change notification settings - Fork 18
[DPE-7242] Add multi-cluster refresh docs #690
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 10 commits
Commits
Show all changes
19 commits
Select commit
Hold shift + click to select a range
78036d3
update naming scheme for upgrade docs
a-velasco 0276fbd
minor edits to Juju upgrades
a-velasco 26df5ee
add empty multi-cluster upgrade doc and update references
a-velasco 603da41
update content in single and multi-cluster upgrade docs
a-velasco 69ed924
update 'upgrade' terminology to 'refresh'
a-velasco bd528f0
update cross-regional async replication terminology
a-velasco bceb87e
add table of supported refreshes
a-velasco 461483b
small edits
a-velasco e103829
update sample refresh commands to match juju status
a-velasco 47dd09b
minor edits
a-velasco 194de2c
Apply suggestion from @sinclert-canonical
a-velasco e13588c
Apply review suggestions
a-velasco 7bd79dc
Update docs/how-to/refresh/index.md
a-velasco 11d0186
split single and multi-cluster instructions into folders
a-velasco 378efc0
remove terraform domain from linkcheck
a-velasco a4fba7c
fix broken references
a-velasco a0fc1c1
fix broken juju link
a-velasco 62e56ab
fix 24.04 mention
a-velasco 78d3dda
fix broken reference
a-velasco File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,30 @@ | ||
| # Cluster-cluster replication | ||
|
|
||
| Cluster-cluster asynchronous replication focuses on disaster recovery by distributing data across different servers. | ||
|
|
||
| For increased safety, it is recommended to distribute data across different geographical regions as well. | ||
|
|
||
| ## Substrate dependencies | ||
|
|
||
| The following table shows the source and target controller/model combinations that are currently supported: | ||
|
|
||
| | | AWS | GCP | Azure | | ||
| |-------|------------|:----------:|:----------:| | ||
| | AWS | ![ check ] | | | | ||
| | GCP | | ![ check ] | | | ||
| | Azure | | | ![ check ] | | ||
|
|
||
| ## Guides | ||
|
|
||
| ```{toctree} | ||
| :titlesonly: | ||
| :maxdepth: 2 | ||
|
|
||
| Deploy <deploy> | ||
| Clients <clients> | ||
| Switchover/failover <switchover-failover> | ||
| Recovery <recovery> | ||
| Removal <removal> | ||
| ``` | ||
|
|
||
| [check]: https://img.shields.io/badge/%E2%9C%93-brightgreen | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,65 @@ | ||
| # Refresh (upgrade) | ||
|
|
||
| This charm supports in-place upgrades to higher versions via Juju's [`refresh`](https://documentation.ubuntu.com/juju/3.6/reference/juju-cli/list-of-juju-cli-commands/refresh/#details) command. | ||
|
|
||
| ## Supported refreshes | ||
|
|
||
| ```{eval-rst} | ||
| +------------+------------+----------+------------+ | ||
| | From | To | | ||
| +------------+------------+----------+------------+ | ||
| | Charm | MySQL | Charm | MySQL | | ||
| | revision | Version | revision | Version | | ||
| +============+============+==========+============+ | ||
| | 366, 367 | ``8.0.41`` | | | | ||
| +------------+------------+----------+------------+ | ||
| | 312, 313 | ``8.0.39`` | 366, 367 | ``8.0.41`` | | ||
| +------------+------------+----------+------------+ | ||
| | 240 | ``8.0.36`` | 366, 367 | ``8.0.41`` | | ||
| | | +----------+------------+ | ||
| | | | 312, 313 | ``8.0.39`` | | ||
| +------------+------------+----------+------------+ | ||
| | 196 | ``8.0.34`` | None | | | ||
| +------------+------------+----------+------------+ | ||
| | 151 | ``8.0.32`` | 240 | ``8.0.36`` | | ||
| | | +----------+------------+ | ||
| | | | 196 | ``8.0.34`` | | ||
| +------------+------------+----------+------------+ | ||
| ``` | ||
|
|
||
| Due to an upstream issue with MySQL Server version `8.0.35`, Charmed MySQL versions below [Revision 240](https://github.com/canonical/mysql-operator/releases/tag/rev240) **cannot** be refreshed beyond [Revision 196](https://github.com/canonical/mysql-operator/releases/tag/rev196). | ||
a-velasco marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| To upgrade from older versions to Revision 240 or higher, the data must be migrated manually. See: [](/how-to/development/migrate-data-via-backup-restore). | ||
|
|
||
| ### Juju version upgrade | ||
|
|
||
| Before refreshing the charm, make sure to check the [](/reference/releases) page to see if there any requirements for the new revision, such as a Juju version upgrade. | ||
|
|
||
| * [](/how-to/refresh/upgrade-juju) | ||
|
|
||
| ## Refresh guides | ||
|
|
||
| To refresh a **single cluster**, see: | ||
sinclert-canonical marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
|
||
| * [](/how-to/refresh/refresh-single-cluster) | ||
| * [](/how-to/refresh/roll-back-single-cluster) | ||
|
|
||
| To refresh a **multi-cluster** deployment, see | ||
|
|
||
| * [](/how-to/refresh/refresh-multi-cluster) | ||
|
|
||
| ```{toctree} | ||
| :titlesonly: | ||
| :maxdepth: 2 | ||
| :hidden: | ||
|
|
||
| Refresh a cluster <refresh-single-cluster> | ||
| Roll back a cluster <roll-back-single-cluster> | ||
| Refresh a multi-cluster deployment <refresh-multi-cluster> | ||
| Upgrade Juju <upgrade-juju> | ||
| ``` | ||
|
|
||
| <!--Links--> | ||
|
|
||
| [cross]: https://img.icons8.com/?size=16&id=CKkTANal1fTY&format=png&color=D00303 | ||
| [check]: https://img.icons8.com/color/20/checkmark--v1.png | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,38 @@ | ||
| # How to refresh a multi-cluster deployment | ||
|
|
||
| A MySQL multi-cluster deployment (also known as a multi-node cluster or cluster set) can be upgraded by performing a refresh of each cluster individually. | ||
a-velasco marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| This guide goes over the steps and important considerations before refreshing multiple MySQL clusters. | ||
|
|
||
| ## Determine cluster order | ||
|
|
||
| To upgrade a multi-cluster deployment, each cluster must be refreshed one by one - starting with the standby clusters. | ||
|
|
||
| **The primary cluster must be the last one to get refreshed.** | ||
|
|
||
| When a primary cluster gets refreshed, it triggers a potentially costly re-election process. To minimise this cost, all standby clusters should be refreshed before the primary. | ||
a-velasco marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| <!--TODO: Mention how to identify primary cluster--> | ||
a-velasco marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| ## Refresh each cluster | ||
|
|
||
| For each cluster, follow the instructions in [](/how-to/refresh/refresh-single-cluster). | ||
|
|
||
| **Perform a health check before proceeding to the next cluster.** | ||
|
|
||
| Use the [`get-cluster-status`](https://charmhub.io/mysql/actions#get-cluster-status) Juju action to check that everything is healthy after refreshing a cluster. | ||
|
|
||
| <!---TODO: example of running get-cluster-status (and making sure the cluster-set param is True?) | ||
a-velasco marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| ```shell | ||
| juju run <?> get-cluster-status | ||
| ``` | ||
| --> | ||
|
|
||
| ## Roll back | ||
|
|
||
| If something goes wrong, roll back the cluster. See: [](/how-to/refresh/roll-back-single-cluster) | ||
|
|
||
| <!--TODO: clarify what to do if you've already refreshed one or more clusters, another one fails, and you need to roll back everything - including the clusters that are fully upgraded --> | ||
|
|
||
|
|
||
|
|
||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.