Configure and run workflows
This section describes how to configure, pilot, and run a migration after you deploy Migration Assistant on Amazon EKS. The day-to-day operator interface is the Workflow CLI, which runs in the Migration Console pod (migration-console-0) on Amazon EKS. The supporting console CLI provides component-level inspection and ad-hoc operations during validation and troubleshooting.
Getting started with the Workflow CLI
This sequence is the shortest safe path to your first migration to Amazon OpenSearch Service or Amazon OpenSearch Serverless NextGen: load the right schema for your version, prove connectivity, run a small pilot, and only then run the full workflow.
Before you start
Make sure all of the following are true:
-
Migration Assistant is deployed on Amazon EKS. See Deploy the solution.
-
The source cluster and the Amazon OpenSearch Service domain or Amazon OpenSearch Serverless NextGen collection are reachable from the Amazon EKS cluster.
-
Snapshot storage is ready in Amazon S3 if you plan to run backfill.
-
Any HTTP Basic credentials you need can be created as managed Kubernetes Secrets in the
manamespace.
Step 1: Access the Migration Console
kubectl exec -it migration-console-0 -n ma -- /bin/bash
If you are accessing Amazon EKS from a new shell, refresh your kubeconfig first:
aws eks update-kubeconfig --region <REGION> --name migration-eks-cluster-<STAGE>-<REGION>
Step 2: Confirm the installed version
console --version
This matters because the workflow schema can change by release.
Step 3: Load the version-matched sample
workflow configure sample --load
This gives you the safest starting point for your installed release.
Step 4: Edit the workflow configuration
workflow configure edit
Fill in the fields that describe your migration:
-
Source endpoint, version, and authentication.
-
Target endpoint and authentication. For Amazon OpenSearch Serverless NextGen, set
service: aossin the SigV4authConfig. For Amazon OpenSearch Service, setservice: es. -
Snapshot repository details if you are running backfill.
-
The migration pattern: backfill only, capture and replay only, or both.
Use source version strings in <ENGINE> <VERSION> format. The workflow schema accepts ES for Elasticsearch 1.x, 2.x, and 5.x through 8.x; OS for OpenSearch 1.x through 3.x; and SOLR for Apache Solr 6.x through 9.x. Examples include ES 7.10.2, OS 3.5.0, and SOLR 9.7.0.
The keys under sourceClusters and targetClusters are workflow labels. Use a distinct label for every source and target; the same name cannot appear in both maps. snapshotMigrationConfigs[].fromSource, snapshotMigrationConfigs[].toTarget, traffic.proxies.<name>.source, and traffic.replayers.<name>.toTarget all reference those labels. In perSnapshotConfig, each key must match a snapshot declared under sourceClusters.<source>.snapshotInfo.snapshots, and optional migration label values must be unique within that snapshot group.
Note
Do not start by editing every possible field. Start with the minimum required fields for your path.
Target configuration for Amazon OpenSearch Serverless NextGen
When the target is an Amazon OpenSearch Serverless NextGen collection, set the target cluster like this:
{ "targetClusters": { "target": { "endpoint": "https://<collection-id>.<region>.aoss.amazonaws.com", "authConfig": { "sigv4": { "region": "<region>", "service": "aoss" } } } } }
The migration IAM role created by the Amazon EKS deployment must also be added as a principal in your collection’s data access policy. The IAM role is named <eks-cluster-name>-migrations-role. Add it to the collection’s data access policy with both collection-level and index-level permissions before running the workflow.
Target configuration for Amazon OpenSearch Service
When the target is an Amazon OpenSearch Service domain:
{ "targetClusters": { "target": { "endpoint": "https://<domain-endpoint>", "authConfig": { "sigv4": { "region": "<region>", "service": "es" } } } } }
If your domain has fine-grained access control (FGAC) enabled, map the migration IAM role to a security role on the domain (typically all_access during migration, then scoped down). See Troubleshooting.
Step 5: Create credentials if you use basic authentication
workflow configure credentials create source-credentials workflow configure credentials create target-credentials
Reference those credential names in authConfig.basic.secretName in your workflow configuration. When you save configuration with workflow configure edit, the CLI detects missing HTTP Basic secrets and can prompt you to create them. Non-interactive submissions fail fast if a referenced secret is missing, so create or update credentials before you run workflow submit.
Step 6: Verify connectivity before submitting a workflow
console clusters connection-check
The check runs against both source and target by default. To narrow it to one side:
console clusters connection-check --cluster source console clusters connection-check --cluster target
For a direct API check:
console clusters curl source / console clusters curl target /
If these checks fail, stop and fix connectivity or authentication first. Do not start a workflow yet.
Step 7: Verify AWS identity if you use SigV4
If your source or target uses Amazon OpenSearch Service or Amazon OpenSearch Serverless NextGen, verify pod identity is working from the Migration Console pod:
aws sts get-caller-identity
If console clusters connection-check works in the Migration Console but the workflow later fails with HTTP 401 or 403, verify that the Argo workflow executor pods are using the argo-workflow-executor service account with its EKS Pod Identity association. On Amazon EKS, both the Migration Console pod and the workflow executor pods get Pod Identity-backed AWS credentials automatically through the bootstrap script.
Step 8: Run a pilot migration first
Use a small allowlist or a representative subset before you attempt the full migration. This is the easiest way to catch mapping issues, authentication issues, and throughput problems early.
workflow submit workflow manage
Use workflow manage to watch the run and approve any gated steps.
Step 9: Validate the pilot
Check counts and basic behavior on the Amazon OpenSearch Service domain or Amazon OpenSearch Serverless NextGen collection before you expand scope:
console clusters cat-indices console clusters curl target /<index>/_count console clusters curl target /<index>/_search?size=5&pretty
If you are migrating applications with live traffic, also validate representative queries against the target.
Step 10: Run the real migration
After the pilot succeeds, widen the configuration to the full index set and submit again:
workflow configure edit workflow submit workflow manage
Step 11: Use logs if anything fails
workflow status workflow log all workflow log all -f workflow log resource --list workflow log resource snapshotmigration.<NAME> -- --tail=100
workflow submit automatically stops and replaces an existing workflow with the same name, so you do not need to manually clean up between runs. If a previous run left orphaned migration custom resources, use workflow reset instead of deleting Argo workflows directly:
workflow reset # lists migration custom resources workflow reset --list # lists migration custom resources and exits workflow reset migration-foo # delete a specific resource by name workflow reset --all # delete everything (capture proxies are protected) workflow reset --all --include-proxies --delete-storage # also remove capture proxies and Apache Kafka PVCs
Core commands
The workflow CLI orchestrates a full migration; the console CLI inspects or manually drives a single component during validation and troubleshooting.
Workflow commands
| Command | Why you use it |
|---|---|
|
|
Shows the sample schema for your installed version |
|
|
Loads that sample as your starting point |
|
|
Opens the workflow config in your editor ( |
|
|
Prints the current config |
|
|
Clears the current config and lets you start over. Use |
|
|
Starts the migration workflow (auto-stops and replaces an existing one with the same name) |
|
|
Submits and blocks until the workflow completes or the timeout is reached |
|
|
Primary day-to-day interface for monitoring, approvals, and logs (interactive TUI) |
|
|
Shows the current workflow tree in a non-interactive form |
|
|
Shows running and completed workflows |
|
|
Shows migration resources grouped by role instead of only the current Argo workflow step tree |
|
|
Shows logs across workflow pods |
|
|
Streams logs live |
|
|
Shows logs for one migration resource, such as |
|
|
Lists pod label selectors available for filtered logs |
|
|
Lists migration resources that have managed output artifacts, such as metadata evaluation and migration reports |
|
|
Prints the latest metadata evaluation report for a snapshot migration. Use |
|
|
Prints the latest managed output artifacts for all current migration resources |
|
|
Approves pending step gates that match exact names or globs |
|
|
Lists available approval gates across step, change, and retry categories |
|
|
Lists migration custom resources; pass a resource name or |
Workflow command flags
The tables below cover the workflow subcommands and the advanced flags that matter for migration operations and automation. Global flags (-v/--verbose) can be placed before any subcommand to increase logging.
workflow configure
| Command or flag | Purpose |
|---|---|
|
|
Print the current workflow configuration |
|
|
Open the current configuration in |
|
|
Read configuration from stdin, save it, and report validation errors without launching an editor |
|
|
Print the installed version’s sample configuration |
|
|
Load the installed version’s sample configuration into the current session |
|
|
Clear the current workflow configuration after a confirmation prompt |
|
|
Clear the current workflow configuration without prompting |
|
|
List managed HTTP Basic credential secrets |
|
|
Create managed HTTP Basic credentials, prompting for username and password |
|
|
List configured HTTP Basic credential names that have not been created yet |
|
|
Read one |
|
|
Disable terminal echo while reading credentials from stdin |
|
|
Update an existing managed HTTP Basic credential secret |
|
|
List managed HTTP Basic credential secrets |
|
|
Read one |
|
|
Disable terminal echo while reading credentials from stdin |
|
|
Delete a managed HTTP Basic credential secret after a confirmation prompt |
|
|
List managed HTTP Basic credential secrets |
|
|
Delete a managed HTTP Basic credential secret without prompting |
workflow submit
| Flag | Purpose |
|---|---|
|
|
Block until the workflow completes or times out (default: return immediately) |
|
|
Timeout when using |
|
|
Polling interval between status checks when using |
|
|
Configuration session name to load parameters from (default: |
|
|
Name of the workflow to replace if one already exists (default: |
|
|
Advanced: override the generated run nonce that is passed to downstream resources and names such as snapshots (default: current timestamp) |
|
|
Kubernetes namespace (default: |
workflow status
| Flag | Purpose |
|---|---|
|
|
Show all workflows including completed ones (default: only running) |
|
|
Show status for all workflows regardless of name (mutually exclusive with |
|
|
Show status for a specific workflow (default: |
|
|
Run or skip current status checks for each snapshot and backfill still in progress (default: |
|
|
Show the resource-centric view or the current Argo Workflow step tree (default: |
|
|
Argo Server URL (default: auto-detected from environment) |
|
|
Kubernetes namespace (default: |
|
|
Skip TLS certificate verification (default: true) |
|
|
Bearer token for Argo Server authentication |
workflow log
| Flag | Purpose |
|---|---|
|
|
Stream logs live using |
|
|
Include RFC 3339 timestamps in log output |
|
|
Show logs for pods associated with one migration resource. Use typed names such as |
|
|
List migration resources that can be used with |
|
|
List available label selectors for |
|
|
Show output for all workflows (mutually exclusive with |
|
|
Filter logs to a specific workflow (default: |
|
|
Filter pods by the corresponding migration label (available on |
|
|
Additional raw label selector to filter pods, repeatable (e.g. |
|
|
Label prefix for unqualified filter keys (default: |
|
|
Forward extra arguments to |
|
|
Kubernetes namespace (default: |
|
|
Argo Server URL |
|
|
Skip TLS certificate verification (default: true) |
|
|
Bearer token for authentication |
workflow show
| Flag | Purpose |
|---|---|
|
|
Show the latest managed output artifact for a resource and optional task, such as |
|
|
Show latest output for a managed task across matching resources. Supported tasks are |
|
|
Show metadata output using the approval-gate style name; the command maps it to the matching |
|
|
List resources and tasks that have managed output artifacts |
|
|
Show the latest managed output artifacts for all current resources |
|
|
List retained output artifacts for the selected resource UID instead of printing the latest output |
|
|
Show one retained artifact selected from |
|
|
Print only the artifact content, without section headers |
|
|
Kubernetes namespace (default: |
workflow manage
| Flag | Purpose |
|---|---|
|
|
Workflow to manage (default: |
|
|
Argo Server URL (default: auto-detected from environment) |
|
|
Kubernetes namespace (default: |
|
|
Skip TLS certificate verification (default: true) |
|
|
Bearer token for authentication |
|
|
Open the resource-centric view or the current Argo Workflow step tree (default: |
workflow reset
| Flag | Purpose |
|---|---|
|
|
One or more resource names or glob patterns to delete (e.g. |
|
|
List migration resources and exit without deleting anything |
|
|
Delete all migration custom resources |
|
|
Also delete resources that depend on the targeted resource |
|
|
Include capture proxies in deletion (they are protected by default) |
|
|
Delete Kafka PVCs and orphaned PVs during reset |
|
|
Keep retained workflow output artifacts and print their S3 prefix instead of deleting the artifact prefix with the resource |
|
|
Kubernetes namespace (default: |
workflow approve
| Flag | Purpose |
|---|---|
|
|
Exact names or glob patterns of pending approval gates to approve (e.g. |
|
|
List gates instead of approving them. Use |
|
|
Approve every matching gate for the selected subcommand. For retry gates, the command blocks approval until required reset prerequisites are complete. |
|
|
For |
|
|
Workflow containing the gates (default: |
|
|
Argo Server URL (default: auto-detected from environment) |
|
|
Kubernetes namespace (default: |
|
|
Skip TLS certificate verification (default: true) |
|
|
Bearer token for authentication |
Console commands
The console CLI groups operations by component:
| Command | Why you use it |
|---|---|
|
|
Confirms which schema and behavior your Migration Console is running |
|
|
Verifies the Migration Console can reach and authenticate to source and target |
|
|
Lists indexes on one or both clusters |
|
|
Issues a direct API request against the named cluster |
|
|
Destructive — deletes all indexes on the named cluster |
|
|
Legacy/direct snapshot operations. In workflow-managed runs, snapshots are created and monitored by the workflow |
|
|
Run or preview metadata migration outside the workflow |
|
|
Legacy/direct RFS backfill control. In workflow-managed runs, configure |
|
|
Legacy/direct component control for Traffic Replayer. In workflow-managed runs, use |
|
|
Inspect Migration Assistant metrics |
|
|
Inspect Strimzi-managed Apache Kafka used by capture and replay |
|
|
Inspect captured request/response tuples for replay validation |
Note
The workflow path drives metadata, backfill, and replay automatically. Reach for an equivalent console command only when the command is wired for the resource you are inspecting or when you are working around a specific direct-component failure. For workflow-managed runs, prefer workflow manage, workflow status --resource-view, workflow log resource, and workflow show.
Approval gates
Not every migration step should run without human review. Approval gates let the workflow stop at meaningful checkpoints — typically transitions after metadata work, backfill milestones, and cutover-sensitive steps — so you can validate before continuing.
workflow manage workflow approve step <STEP_NAME>
Approval behavior can also be controlled in the workflow configuration:
-
skipApprovals- top-level flag that skips all manual approval gates in the workflow. -
metadataMigrationConfig.skipEvaluateApproval- skips the gate after metadata evaluation. -
metadataMigrationConfig.skipMigrateApproval- skips the gate after metadata migration applies changes. -
documentBackfillConfig.skipApproval- skips the gate after document backfill completes.
Use these flags only when validation, alerting, and rollback decisions are already automated. For first runs and pilots, leave approvals enabled so you can inspect metadata evaluation output, backfill status, and cutover-sensitive steps before continuing.
When a metadata gate is waiting, inspect the managed output before approving it. In workflow manage, select the metadata output step and use Show Output. For a non-interactive view, run workflow show --list to find the snapshotmigration.<NAME> resource, then run workflow show snapshotmigration.<NAME> evaluatemetadata or workflow show snapshotmigration.<NAME> migratemetadata. The workflow records the output artifact location on the SnapshotMigration resource, so workflow show --history can list retained reports for that resource.
Status symbols
| Symbol | Meaning |
|---|---|
|
|
Succeeded |
|
|
Running |
|
|
Pending |
|
|
Failed |
|
|
Waiting for approval |
Migration scenarios
Migration Assistant supports three migration patterns. Pick the one that matches your downtime tolerance.
Scenario 1: Backfill only
Best when you can tolerate a brief write freeze, or when writes can be paused and replayed from an external queue.
Snapshot source → Migrate metadata → Backfill documents → Verify → Switch traffic
Scenario 2: Capture and Replay only
Best when the data is small enough that live replay alone can synchronize the target on Amazon OpenSearch Service or Amazon OpenSearch Serverless NextGen, or when you want to replay traffic against multiple targets to compare results.
Reroute traffic to capture proxy → Migrate metadata → Replay traffic → Verify → Switch traffic to target
Scenario 3: Backfill + Capture and Replay (zero-downtime)
The most comprehensive approach. Capture begins first so no writes are lost, then backfill brings over historical data, then replay catches the target up to real-time.
Reroute traffic to capture proxy → Snapshot source → Migrate metadata → Backfill documents → Replay captured traffic → Verify → Switch traffic to target
Assessment and breaking changes
Before running a migration, review breaking changes between your source and target versions. Breaking changes may require modifications to your client applications after the migration completes.
Understanding breaking changes
Between major versions of Elasticsearch and OpenSearch, features may be deprecated or removed. Common breaking changes include:
-
Removal of mapping types (Elasticsearch 6.x to 7.x and later)
-
Changes to field types (for example,
stringreplaced bytextandkeyword) -
Query DSL syntax changes
-
REST API endpoint changes
-
Plugin compatibility differences
For a complete list of breaking changes for your migration path, see the Migration Assistant documentation.
Impact of data transformations
Any time you apply a transformation to your data — such as changing index names, modifying field mappings, or splitting indexes with type mappings — these changes may need to be reflected in your client configurations. Run production-like queries against the Amazon OpenSearch Service domain or Amazon OpenSearch Serverless NextGen collection before switching over actual production traffic. This verifies that clients can communicate with the target, locate the necessary indexes and fields, and retrieve expected results.
For complex migrations involving multiple transformations, perform a trial migration with representative non-production data to fully test client compatibility.