-
Notifications
You must be signed in to change notification settings - Fork 136
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'Release-3-0-0-GA' of https://github.com/percona/pmm int…
…o Release-3-0-0-GA
- Loading branch information
Showing
4 changed files
with
104 additions
and
51 deletions.
There are no files selected for viewing
101 changes: 68 additions & 33 deletions
101
...ation/docs/install-pmm/install-pmm-server/baremetal/docker/restore_container.md
This file contains 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 |
---|---|---|
@@ -1,49 +1,84 @@ | ||
# Restore container | ||
# Restore Docker container | ||
You can restore PMM Server either from a manual backup or from an automated backup volume that was created during migration to PMM v3. | ||
|
||
!!! caution alert alert-warning "Important" | ||
You must have a [backup](backup_container.md) to restore from. | ||
Before proceeding with restoration, ensure you have either a [manual backup](backup_container.md) or an [automated backup volume](../../../../pmm-upgrade/migrating_from_pmm_2.md#step-2-migrate-pmm-2-server-to-pmm-3) to restore from. | ||
|
||
To restore the container: | ||
{.power-number} | ||
=== "Restore from manual backup" | ||
To restore the container from a manual backup: | ||
{.power-number} | ||
|
||
1. Stop the container. | ||
1. Stop the container: | ||
|
||
```sh | ||
docker stop pmm-server | ||
``` | ||
```sh | ||
docker stop pmm-server | ||
``` | ||
|
||
2. Remove the container. | ||
2. Remove the container: | ||
|
||
```sh | ||
docker rm pmm-server | ||
``` | ||
```sh | ||
docker rm pmm-server | ||
``` | ||
|
||
3. Revert to the saved image. | ||
3. Revert to the saved image: | ||
|
||
```sh | ||
docker rename pmm-server-backup pmm-server | ||
``` | ||
```sh | ||
docker rename pmm-server-backup pmm-server | ||
``` | ||
|
||
4. Change directory to the backup directory (e.g. `pmm-data-backup`). | ||
4. Change directory to the backup directory (e.g. `pmm-data-backup`): | ||
|
||
```sh | ||
cd pmm-data-backup | ||
``` | ||
```shc | ||
cd pmm-data-backup | ||
``` | ||
|
||
5. Copy the data. | ||
5. Copy the data: | ||
|
||
```sh | ||
docker run --rm -v $(pwd)/srv:/backup -v pmm-data:/srv -t percona/pmm-server:3 cp -r /backup/* /srv | ||
``` | ||
```sh | ||
docker run --rm -v $(pwd)/srv:/backup -v pmm-data:/srv -t percona/pmm-server:3 cp -r /backup/* /srv | ||
``` | ||
|
||
6. Restore permissions. | ||
6. Restore permissions: | ||
|
||
```sh | ||
docker run --rm -v pmm-data:/srv -t percona/pmm-server:3 chown -R pmm:pmm /srv | ||
``` | ||
```sh | ||
docker run --rm -v pmm-data:/srv -t percona/pmm-server:3 chown -R pmm:pmm /srv | ||
``` | ||
|
||
7. Start the image. | ||
7. Start the image: | ||
|
||
```sh | ||
docker start pmm-server | ||
``` | ||
```sh | ||
docker start pmm-server | ||
``` | ||
|
||
=== "Restore from automated migration backup" | ||
|
||
To restore from an automated backup volume created during [migration to PMM v3](../../../../pmm-upgrade/migrating_from_pmm_2.md#step-2-migrate-pmm-2-server-to-pmm-3): | ||
{.power-number} | ||
|
||
1. Stop the current PMM v3 container: | ||
```sh | ||
docker stop pmm-server | ||
``` | ||
2. Remove the container (optional): | ||
```sh | ||
docker rm pmm-server | ||
``` | ||
3. Start a PMM v2 container using your backup volume, replacing `<backup-volume-name>` with your PMM v2 backup volume name (e.g., `pmm-data-2025-01-16-165135`): | ||
|
||
```sh | ||
docker run -d \ | ||
-p 443:443 \ | ||
--volume <backup-volume-name>:/srv \ | ||
--name pmm-server \ | ||
--restart always \ | ||
percona/pmm-server:2.44.0 | ||
``` | ||
|
||
4. Verify that your PMM v2 instance is running correctly and all your data is accessible. | ||
|
||
!!! note alert alert-primary "Finding your backup volume name" | ||
- Your backup volume name was displayed during the [automated upgrade process](../../../../pmm-upgrade/migrating_from_pmm_2.md#step-2-migrate-pmm-2-server-to-pmm-3). | ||
- To list all available Docker volumes, use the following command, and look for volumes with names like `pmm-data-YYYY-MM-DD-HHMMSS`: | ||
|
||
```sh | ||
docker volume ls | ||
``` |
This file contains 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 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 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 |
---|---|---|
@@ -1,4 +1,4 @@ | ||
# Upgrade PMM Server using Podman | ||
# Manual upgrade: Upgrade PMM Server using Podman | ||
|
||
## Before you begin | ||
|
||
|