Management scripts
IBM® Optim Archive Enterprise Edition for z/OS® includes management scripts for deployment lifecycle operations: environment setup, service deployment, backup and restore, and cleanup.
setup-optim-s390x.sh
The setup-optim-s390x.sh script performs initial environment setup and
configuration.
The script completes the following tasks:
- Validates prerequisites and platform (must run on s390x)
- Presents product license agreements
- Creates Docker secrets for passwords and encryption keys
- Generates SSL certificates and keystores
- Creates Docker volumes for persistent storage
- Copies configuration files to volumes
- Updates the .env file with generated values:
- Usage
- To run the
setup-optim-s390x.shscript in interactive mode:./scripts/setup-optim-s390x.sh - Parameters
- The
setup-optim-s390x.shscript takes the following parameters:Parameter Description Required --product-name Product to install (TDM, Archive, Data Privacy) Yes --license-type License type (enterprise or solution) Yes --accept-license Auto-accept license agreements No --initial-setup Auto-select first installation option No --metadb_password PostgreSQL password No --keycloak_password Keycloak admin password No --truststore_password Certificate truststore password No --reconfigure-secrets Reconfigure secrets and certificates only No --add-product Add product to existing installation No
optim-deployservices-s390x.sh
The optim-deployservices-s390x.sh script deploys all IBM Optim services as Docker Swarm
services.
The script completes the following tasks:
- Creates Docker overlay network (
optim-net) - Deploys services in correct dependency order
- Waits for each service to be running and healthy
- Configures service parameters and environment variables
- Provides real-time deployment status
- Usage
- To run the
optim-deployservices-s390x.shscript:./scripts/optim-deployservices-s390x.sh \ --postgres-admin-password="${POSTGRES_PASSWORD}" \ --metadb-password="${METADB_PASSWORD}" \ --keycloak-db-password="${KEYCLOAK_DB_PASSWORD}" \ --keycloak-admin-password="${KEYCLOAK_ADMIN_PASSWORD}" \ --truststore-password="${TRUSTSTORE_PASSWORD}" \ --hostname="${HOSTNAME}" \ --memory-profile medium - Required parameters
- The
optim-deployservices-s390x.shscript requires the following parameters:Parameter Description --postgres-admin-password PostgreSQL admin password --metadb-password Optim metadata database password --keycloak-db-password Keycloak database password --keycloak-admin-password Keycloak admin password --truststore-password Certificate truststore password --hostname Runtime hostname (FQDN) - Optional parameters
- The
optim-deployservices-s390x.shscript accepts the following optional parameters:Parameter Description Default --memory-profile Memory profile (small/medium/large) medium --debug Enable debug mode for Runtime and Spark false --image-registry Image registry URL localhost/ibm-optim - Memory profiles
- The
optim-deployservices-s390x.shscript can use the following memory profiles:Profile Driver memory Executor memory Recommended for small 512 MB 2 GB 32 GB RAM systems medium 1024 MB 4 GB 64 GB RAM systems (default) large 2048 MB 8 GB 128 GB or higher RAM systems
optim-backup-restore-s390x.sh
The optim-backup-restore-s390x.sh script creates backups and restores IBM Optim databases.
The script completes the following tasks:
- Creates compressed backups of PostgreSQL databases (optim and keycloak)
- Captures Keycloak base URL for restoration on different hosts
- Optionally includes encryption keys for cross-host restoration
- Restores databases from backup files
- Updates Keycloak URLs when restoring to different host
- Usage for backup
-
Usage for backup:
# Basic backup ./scripts/optim-backup-restore-s390x.sh backup --path /opt/optim/backups # Backup with encryption key ./scripts/optim-backup-restore-s390x.sh backup \ --path /opt/optim/backups \ --encryption-key
- Usage for restore
-
Usage for restore:
# Basic restore ./scripts/optim-backup-restore-s390x.sh restore \ --backup-file /opt/optim/backups/optim_20260315_120000.tar # Restore with encryption key ./scripts/optim-backup-restore-s390x.sh restore \ --backup-file /opt/optim/backups/optim_20260315_120000.tar \ --encryption-key - Parameters
- The
setup-optim-s390x.shscript takes the following parameters:Parameter Description Required backup Create backup Yes (command) restore Restore from backup Yes (command) --path Directory for backup Yes (for backup) --backup-file Full path to backup tar file Yes (for restore) --container Container or service name No --encryption-key Include or restore encryption key No
optim-cleanup-s390x.sh
The optim-backup-restore-s390x.sh script performs complete cleanup of IBM Optim Docker resources.
The script completes the following tasks:
- Removes all IBM Optim Docker services
- Removes all IBM Optim Docker volumes
- Removes all IBM Optim Docker secrets
- Removes IBM Optim Docker networks
- Removes IBM Optim Docker images
- Removes SSL certificate directory
- Usage
- To run the
optim-cleanup-s390x.shscript:./scripts/optim-cleanup-s390x.shWarning: Back up your data before running this script. This script performs a complete cleanup and deletes all IBM Optim data, configurations, and certificates.