Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
59 commits
Select commit Hold shift + click to select a range
5b643c8
[minor] Add mas backup option
whitfiea Jan 28, 2026
d48ec67
Add in function call
whitfiea Jan 28, 2026
1b4d500
fix tekton issues
whitfiea Jan 28, 2026
627da84
Fix storageclass issue
whitfiea Jan 29, 2026
1068f4d
fix imnport err
whitfiea Jan 29, 2026
5b90b65
add upload task
whitfiea Jan 29, 2026
5bd0864
set backup action
whitfiea Jan 29, 2026
afed0cf
fix mongodb
whitfiea Jan 29, 2026
ab66023
Correct the s3 key names
whitfiea Jan 29, 2026
33022ce
update ibm_catalogs_version
whitfiea Jan 30, 2026
7f10c49
prompt for backup version
whitfiea Jan 30, 2026
03f3bbe
ad new prompter for instaneid
whitfiea Jan 30, 2026
b6e9e17
remove ? mark
whitfiea Jan 30, 2026
e8f47cb
Re order backup tasks
whitfiea Jan 30, 2026
029189f
Pass throught skip_pre_check
whitfiea Jan 30, 2026
16f392f
Update cli docs and add in cleanup workspaces task (#2033)
whitfiea Feb 4, 2026
348b8e8
Suite restore pipeline (#2034)
sanjayprab Feb 4, 2026
a845cc2
update docs
whitfiea Feb 4, 2026
f4cfac4
[patch] fix upload_backup condition in backup
Feb 4, 2026
f1bac7e
Suite restore commands and docs update (#2035)
sanjayprab Feb 5, 2026
9c35a3d
Backup for manage and db2 dev (#2043)
whitfiea Feb 6, 2026
f431358
add sls and mongo options to backup interactive mode (#2046)
sanjayprab Feb 6, 2026
54ab21c
Merge branch 'master' into backuprestore-dev
Feb 6, 2026
1646f1a
Add Manage Db2 and Application to MAS restore pipelines (#2061)
sanjayprab Feb 12, 2026
2ac93e2
fix YYYY
Feb 12, 2026
494afec
Merge branch 'master' into backuprestore-dev
Feb 12, 2026
124b596
Merge branch 'master' into backuprestore-dev
Feb 13, 2026
d77edc0
some tweaks to restore and update docs & guides (#2068)
sanjayprab Feb 13, 2026
c644f82
Update README.md
Feb 18, 2026
13f1842
Merge branch 'master' into backuprestore-dev
Feb 19, 2026
19df800
Merge branch 'master' into backuprestore-dev
Feb 23, 2026
74b7061
add s3 endpoint url to backup and restore pipelines (#2081)
sanjayprab Feb 23, 2026
83a9815
Merge branch 'master' into backuprestore-dev
Feb 25, 2026
5e974fd
changes for storage class and archive download selection (#2084)
sanjayprab Feb 26, 2026
9cef22d
update docs
Feb 26, 2026
e8a4aed
Update README.md
Feb 26, 2026
378a48f
Revert "Update README.md"
Feb 26, 2026
286204d
Merge branch 'master' into backuprestore-dev
Feb 26, 2026
42a67b8
Update backup-restore.md
Mar 2, 2026
a9ba69d
Merge branch 'master' into backuprestore-dev
Mar 2, 2026
bed5a1c
Update backup-restore.md
Mar 2, 2026
b0b089c
docs tweaks
Mar 2, 2026
a545fa3
Update README.md
Mar 3, 2026
8291845
rebuild
Mar 3, 2026
f188169
local tars
Mar 3, 2026
dff5e23
Update backup-restore.md
Mar 3, 2026
ceb3dec
rebuild
Mar 3, 2026
5c3157e
Merge branch 'master' into backuprestore-dev
Mar 3, 2026
ee93416
Update backup-restore.md
Mar 3, 2026
e627fae
remove tars
Mar 3, 2026
d834c43
use tars
Mar 3, 2026
f92fcbd
Revert "use tars"
Mar 9, 2026
f3013a0
Merge branch 'master' into backuprestore-dev
Mar 10, 2026
b728c6c
remove config-pvc from backup and restore pipelines and other tweaks …
sanjayprab Mar 11, 2026
b2e8f3c
Merge branch 'master' into backuprestore-dev
Mar 13, 2026
0369e55
Some documentation tweaks (#2111)
sanjayprab Mar 13, 2026
420db06
Merge branch 'master' into backuprestore-dev
sanjayprab Mar 13, 2026
b2b36b9
add restore commands docs to mkdocs
Mar 13, 2026
1a0808d
Update backup-restore.md
Mar 13, 2026
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
301 changes: 301 additions & 0 deletions docs/commands/backup.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,301 @@
Backup
===============================================================================

Usage
-------------------------------------------------------------------------------
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]
[--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]

IBM Maximo Application Suite Admin CLI v18.10.0
Backup a MAS instance by configuring and launching the MAS Backup Tekton Pipeline.

Interactive Mode:
Omitting the --instance-id option will trigger an interactive prompt

MAS Instance:
-i, --instance-id MAS_INSTANCE_ID
MAS Instance ID to backup

Backup Configuration:
--backup-version BACKUP_VERSION
Version/timestamp for the backup (auto-generated if not provided)
--backup-storage-size BACKUP_STORAGE_SIZE
Size of the backup PVC storage (default: 20Gi)
--clean-backup Clean backup and config workspaces after completion (default: true)
--no-clean-backup Do not clean backup and config workspaces after completion

Upload Configuration:
--upload-backup Upload the backup archive after completion
--aws-access-key-id AWS_ACCESS_KEY_ID
AWS Access Key ID for S3 upload
--aws-secret-access-key AWS_SECRET_ACCESS_KEY
AWS Secret Access Key for S3 upload
--s3-bucket-name S3_BUCKET_NAME
S3 bucket name for backup upload
--s3-region S3_REGION
AWS region for S3 bucket
--artifactory-url ARTIFACTORY_URL
Artifactory URL for backup upload (dev-mode only)
--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)

Dependencies Configuration:
--mongodb-namespace MONGODB_NAMESPACE
MongoDB namespace (default: mongoce)
--mongodb-instance-name MONGODB_INSTANCE_NAME
MongoDB instance name to backup (default: mas-mongo-ce)
--mongodb-provider {community}
MongoDB provider (only community is supported for backup)
--sls-namespace SLS_NAMESPACE
SLS namespace (default: ibm-sls)
--cert-manager-provider {redhat}
Certificate manager provider (default: redhat)

More:
--artifactory-username ARTIFACTORY_USERNAME
Username for access to development builds on Artifactory (dev-mode only)
--artifactory-token ARTIFACTORY_TOKEN
API Token for access to development builds on Artifactory (dev-mode only)
--dev-mode Configure backup for development mode
--no-confirm Launch the backup without prompting for confirmation
--skip-pre-check Skips the 'pre-backup-check' task in the backup pipeline
-h, --help Show this help message and exit
```

Examples
-------------------------------------------------------------------------------

### Interactive Backup
Launch an interactive backup session that will prompt you for all required configuration:

```bash
mas backup
```

### Non-Interactive Backup with Minimal Configuration
Backup a specific MAS instance with default settings:

```bash
mas backup --instance-id inst1 --no-confirm
```

### Backup with Custom Storage Size
Specify a custom storage size for the backup PVC:

```bash
mas backup --instance-id inst1 --backup-storage-size 50Gi --no-confirm
```

### Backup with Custom Version
Set a custom backup version identifier:

```bash
mas backup --instance-id inst1 --backup-version 1.0.0 --no-confirm
```

### Backup with S3 Upload
Create a backup and automatically upload it to an S3 bucket:

```bash
mas backup \
--instance-id inst1 \
--upload-backup \
--aws-access-key-id AKIAIOSFODNN7EXAMPLE \ #pragma: allowlist secret
--aws-secret-access-key wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY \ #pragma: allowlist secret
--s3-bucket-name my-mas-backups \
--s3-region us-east-1 \
--no-confirm
```

### Backup Excluding SLS
Create a backup without including Suite License Service (useful when SLS is external):

```bash
mas backup --instance-id inst1 --exclude-sls --no-confirm
```

### Backup with Custom MongoDB Configuration
Specify custom MongoDB settings:

```bash
mas backup \
--instance-id inst1 \
--mongodb-namespace my-mongo \
--mongodb-instance-name my-mongo-instance \
--mongodb-provider community \
--no-confirm
```

### Backup with Custom SLS Configuration
Specify a custom SLS namespace:

```bash
mas backup \
--instance-id inst1 \
--sls-namespace my-sls \
--no-confirm
```


### Backup Skipping Pre-Check
Skip the pre-backup validation check (use with caution):

```bash
mas backup --instance-id inst1 --skip-pre-check --no-confirm
```

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

```bash
mas backup --instance-id inst1 --no-clean-backup --no-confirm
```

!!! note
By default, workspaces are cleaned after backup completion to free up storage. Use `--no-clean-backup` only when you need to inspect the workspace contents for troubleshooting purposes.

### Complete Non-Interactive Backup Example
A comprehensive example with all major options configured:

```bash
mas backup \
--instance-id inst1 \
--backup-version 20240315-prod \
--backup-storage-size 100Gi \
--include-sls \
--mongodb-namespace mongoce \
--mongodb-instance-name mas-mongo-ce \
--mongodb-provider community \
--sls-namespace ibm-sls \
--cert-manager-provider redhat \
--upload-backup \
--aws-access-key-id AKIAIOSFODNN7EXAMPLE \ #pragma: allowlist secret
--aws-secret-access-key wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY \ #pragma: allowlist secret
--s3-bucket-name my-mas-backups \
--s3-region us-east-1 \
--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
-------------------------------------------------------------------------------

### Backup Process
The backup command performs the following operations:

1. **Validates the target cluster** - Ensures OpenShift cluster connectivity and checks for MAS instances
2. **Prepares the pipeline namespace** - Creates or updates the `mas-{instance-id}-pipelines` namespace
3. **Installs OpenShift Pipelines** - Validates or installs the OpenShift Pipelines Operator
4. **Creates backup PVC** - Provisions persistent storage for the backup data
5. **Launches the backup pipeline** - Submits a Tekton PipelineRun to perform the backup
6. **Optionally uploads the backup** - If configured, uploads the backup archive to S3 or Artifactory

### Default Values
If not specified, the following defaults are used:

- **Backup Storage Size**: `20Gi`
- **Backup Version**: Auto-generated timestamp in format `YYYYMMDD-HHMMSS`
- **Clean Workspaces**: `true` (workspaces are cleaned after completion)
- **MongoDB Namespace**: `mongoce`
- **MongoDB Instance Name**: `mas-mongo-ce`
- **MongoDB Provider**: `community`
- **SLS Namespace**: `ibm-sls`
- **Certificate Manager Provider**: `redhat`
- **Include SLS**: `true`

### Storage Requirements
Ensure sufficient storage is available for the backup PVC. The required size depends on:

- Size of MAS configuration data
- Size of MongoDB database
- Size of SLS data (if included)
- Any additional application data

### Upload Destinations
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:

1. Target OpenShift cluster connection
2. MAS instance selection (if multiple instances exist)
3. Backup storage size
4. Backup version (or auto-generate)
5. Workspace cleanup preference
6. Manage application backup configuration (optional)
7. Upload configuration (optional)

#### Example Interactive Mode Output

![backup-cmd](../img/backup-cmd.png)


### Pipeline Monitoring
After launching the backup, a URL to the Tekton PipelineRun will be displayed. Use this URL to monitor the backup progress in the OpenShift Console.
Loading
Loading