Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
59 changes: 56 additions & 3 deletions docs/commands/backup.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,11 @@ Usage information can be obtained using `mas backup --help`
usage: mas backup [-i MAS_INSTANCE_ID] [--backup-version BACKUP_VERSION] [--backup-storage-size BACKUP_STORAGE_SIZE]
[--clean-backup] [--no-clean-backup] [--upload-backup] [--aws-access-key-id AWS_ACCESS_KEY_ID]
[--aws-secret-access-key AWS_SECRET_ACCESS_KEY] [--s3-bucket-name S3_BUCKET_NAME] [--s3-region S3_REGION]
[--artifactory-url ARTIFACTORY_URL] [--artifactory-repository ARTIFACTORY_REPOSITORY] [--include-sls]
[--exclude-sls] [--mongodb-namespace MONGODB_NAMESPACE] [--mongodb-instance-name MONGODB_INSTANCE_NAME]
[--artifactory-url ARTIFACTORY_URL] [--artifactory-repository ARTIFACTORY_REPOSITORY]
[--backup-manage-app] [--manage-workspace-id MANAGE_WORKSPACE_ID] [--backup-manage-db]
[--manage-db2-namespace MANAGE_DB2_NAMESPACE] [--manage-db2-instance-name MANAGE_DB2_INSTANCE_NAME]
[--manage-db2-backup-type {offline,online}] [--include-sls] [--exclude-sls]
[--mongodb-namespace MONGODB_NAMESPACE] [--mongodb-instance-name MONGODB_INSTANCE_NAME]
[--mongodb-provider {community}] [--sls-namespace SLS_NAMESPACE] [--cert-manager-provider {redhat,ibm}]
[--artifactory-username ARTIFACTORY_USERNAME] [--artifactory-token ARTIFACTORY_TOKEN] [--dev-mode] [--no-confirm]
[--skip-pre-check] [-h]
Expand Down Expand Up @@ -48,6 +51,18 @@ Upload Configuration:
--artifactory-repository ARTIFACTORY_REPOSITORY
Artifactory repository for backup upload (dev-mode only)

Manage Application Backup:
--backup-manage-app Backup the Manage application
--manage-workspace-id MANAGE_WORKSPACE_ID
Manage workspace ID
--backup-manage-db Backup the Manage application database (Db2)
--manage-db2-namespace MANAGE_DB2_NAMESPACE
Manage Db2 namespace (default: db2u)
--manage-db2-instance-name MANAGE_DB2_INSTANCE_NAME
Manage Db2 instance name
--manage-db2-backup-type {offline,online}
Manage Db2 backup type: offline (database unavailable) or online (database remains available)

Components:
--include-sls Include SLS in backup (default: true)
--exclude-sls Exclude SLS from backup (use if SLS is external)
Expand Down Expand Up @@ -189,6 +204,32 @@ mas backup \
--no-confirm
```

### Backup with Manage Application
Backup MAS instance including the Manage application and its database:

```bash
mas backup \
--instance-id inst1 \
--backup-manage-app \
--manage-workspace-id masdev \
--backup-manage-db \
--manage-db2-namespace db2u \
--manage-db2-instance-name mas-inst1-masdev-manage \
--manage-db2-backup-type offline \
--no-confirm
```

### Backup with Manage Application Only (No Database)
Backup the Manage application without backing up its database:

```bash
mas backup \
--instance-id inst1 \
--backup-manage-app \
--manage-workspace-id masdev \
--no-confirm
```

Notes
-------------------------------------------------------------------------------

Expand Down Expand Up @@ -229,6 +270,17 @@ Two upload destinations are supported:
- **S3**: Standard AWS S3 bucket upload (available in all modes)
- **Artifactory**: Artifactory repository upload (requires `--dev-mode`)

### Manage Application Backup
The backup command can optionally include the Manage application and its Db2 database:

- **Manage Application**: Backs up the Manage namespace resources and persistent volume data
- **Manage Database**: Backs up the Db2 database associated with the Manage workspace
- **Offline backup**: Database is unavailable during backup (required for circular logging)
- **Online backup**: Database remains available during backup (requires archive logging)

!!! note
If your Db2 instance uses circular logging (default), you must use offline backup type.

### Interactive Mode
When running without `--instance-id`, the command enters interactive mode and will prompt for:

Expand All @@ -237,7 +289,8 @@ When running without `--instance-id`, the command enters interactive mode and wi
3. Backup storage size
4. Backup version (or auto-generate)
5. Workspace cleanup preference
6. Upload configuration (optional)
6. Manage application backup configuration (optional)
7. Upload configuration (optional)

#### Example Interactive Mode Output

Expand Down
30 changes: 15 additions & 15 deletions docs/commands/restore.md
Original file line number Diff line number Diff line change
Expand Up @@ -122,14 +122,14 @@ mas restore
Restore a specific MAS instance from a backup with default settings:

```bash
mas restore --instance-id inst1 --restore-version 20260117-191701 --no-confirm
mas restore --instance-id inst1 --restore-version 2020260117-191701 --no-confirm
```

### Restore with Custom Storage Size
Specify a custom storage size for the restore PVC:

```bash
mas restore --instance-id inst1 --restore-version 20260117-191701 --backup-storage-size 50Gi --no-confirm
mas restore --instance-id inst1 --restore-version 2020260117-191701 --backup-storage-size 50Gi --no-confirm
```

### Restore with Changed MAS Domain
Expand All @@ -138,7 +138,7 @@ Restore a backup and change the MAS domain in the Suite CR:
```bash
mas restore \
--instance-id inst1 \
--restore-version 20260117-191701 \
--restore-version 2020260117-191701 \
--mas-domain-restore new.domain.com \
--no-confirm
```
Expand All @@ -149,7 +149,7 @@ Download a backup from S3 and restore it:
```bash
mas restore \
--instance-id inst1 \
--restore-version 20260117-191701 \
--restore-version 2020260117-191701 \
--download-backup \
--aws-access-key-id AKIAIOSFODNN7EXAMPLE \ #pragma: allowlist secret
--aws-secret-access-key wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY \ #pragma: allowlist secret
Expand All @@ -164,7 +164,7 @@ Download and restore a backup with a custom archive name:
```bash
mas restore \
--instance-id inst1 \
--restore-version 20260117-191701 \
--restore-version 2020260117-191701 \
--download-backup \
--custom-backup-archive-name custom-backup-name.tar.gz \
--aws-access-key-id AKIAIOSFODNN7EXAMPLE \ #pragma: allowlist secret
Expand All @@ -180,7 +180,7 @@ Restore a backup without including Suite License Service (useful when using exte
```bash
mas restore \
--instance-id inst1 \
--restore-version 20260117-191701 \
--restore-version 2020260117-191701 \
--exclude-sls \
--no-confirm
```
Expand All @@ -191,7 +191,7 @@ Restore using a custom SLS configuration file instead of the one from backup:
```bash
mas restore \
--instance-id inst1 \
--restore-version 20260117-191701 \
--restore-version 2020260117-191701 \
--exclude-slscfg-from-backup \
--sls-cfg-file /path/to/sls-config.yaml \
--no-confirm
Expand All @@ -203,7 +203,7 @@ Restore SLS configuration from backup but change the SLS URL:
```bash
mas restore \
--instance-id inst1 \
--restore-version 20260117-191701 \
--restore-version 2020260117-191701 \
--include-slscfg-from-backup \
--sls-url-restore https://new-sls-url.com \
--no-confirm
Expand All @@ -215,7 +215,7 @@ Restore using a custom DRO/BAS configuration file instead of the one from backup
```bash
mas restore \
--instance-id inst1 \
--restore-version 20260117-191701 \
--restore-version 2020260117-191701 \
--exclude-drocfg-from-backup \
--dro-cfg-file /path/to/dro-config.yaml \
--no-confirm
Expand All @@ -227,7 +227,7 @@ Restore and install a new DRO instance:
```bash
mas restore \
--instance-id inst1 \
--restore-version 20260117-191701 \
--restore-version 2020260117-191701 \
--include-dro \
--ibm-entitlement-key YOUR_ENTITLEMENT_KEY \ #pragma: allowlist secret
--contact-email admin@example.com \
Expand All @@ -243,7 +243,7 @@ Restore SLS instance with a custom domain:
```bash
mas restore \
--instance-id inst1 \
--restore-version 20260117-191701 \
--restore-version 2020260117-191701 \
--include-sls \
--sls-domain custom-sls.domain.com \
--no-confirm
Expand All @@ -255,7 +255,7 @@ Restore without installing Grafana:
```bash
mas restore \
--instance-id inst1 \
--restore-version 20260117-191701 \
--restore-version 2020260117-191701 \
--exclude-grafana \
--no-confirm
```
Expand All @@ -264,14 +264,14 @@ mas restore \
Skip the pre-restore validation check (use with caution):

```bash
mas restore --instance-id inst1 --restore-version 20260117-191701 --skip-pre-check --no-confirm
mas restore --instance-id inst1 --restore-version 2020260117-191701 --skip-pre-check --no-confirm
```

### Restore Without Workspace Cleanup
Keep backup and config workspace contents after completion (useful for troubleshooting):

```bash
mas restore --instance-id inst1 --restore-version 20260117-191701 --no-clean-backup --no-confirm
mas restore --instance-id inst1 --restore-version 2020260117-191701 --no-clean-backup --no-confirm
```

!!! note
Expand All @@ -283,7 +283,7 @@ A comprehensive example with all major options configured:
```bash
mas restore \
--instance-id inst1 \
--restore-version 20260117-191701 \
--restore-version 2020260117-191701 \
--backup-storage-size 100Gi \
--mas-domain-restore new.domain.com \
--include-sls \
Expand Down
Loading