Reading move status
To follow a data movement job in a database cluster group for Aurora, read its row in dbclustergroup_data_movement.move_info.
Description
The table has one row for each job. The row shows the job's status and current phase, its source and target member cluster aliases, its replication lag, the rows copied against the estimated total, and the errors and warnings that it reported. For every column, see move_info.
Syntax
SELECT { * |column[, ...] } FROM dbclustergroup_data_movement.move_info [WHERE { job_id = 'job_id' | status = 'status' }];
Parameters and options
The statement takes the following parameters.
column-
A column of
move_info, such asjob_id,status,phase,progress_details,errors, orwarnings. Select columns by name, rather than relying on their order or count. - WHERE job_id = '
job_id' -
Optional. Returns the row of one job.
job_idis the job ID that the move statement returned. - WHERE status = '
status' -
Optional. Returns the jobs that have this status.
statusisRunning,Paused,Completed,Cancelled, orError.
You can give only one filter. Without a WHERE clause, the query returns every job in the group.
Where it runs and required privileges
Run the statement at the routing endpoint, in a session that isn't pinned. The table accepts a plain SELECT only.
Your router user needs the dbclustergroup_metadata_read_only privilege or the dbclustergroup_move_admin privilege to read move_info.
Usage notes
Keep the following in mind when you use the statement.
-
The
phasecolumn shows the job's current phase. A job moves through the phases in this order:Initializing,Precheck,Seeding,Cdc,CutoverInit, andCutoverFlip. -
Jobs publish progress periodically, so a read shows the last published state.
-
A job's row stays readable after the job ends, so you can confirm a success or read a failure reason.
-
The table refuses
ORDER BY. Sort and combine conditions in your client. For the filters that the system tables accept, see Filters the system tables accept.
The status column reads Running, Paused, Completed, Cancelled, or Error. Paused means that the service stopped the job for a time, for example while it replaces the data mover compute that runs the job. You can't pause or resume a job yourself.
Examples
The following query reads one job's status, phase, and progress.
SELECT job_id, status, phase, progress_details, errors, warnings FROM dbclustergroup_data_movement.move_info WHERE job_id = '4a6f1c2e-7d3b-4c1a-9e2f-5b8d0c6a1f30';
Errors
The statement can return the following error. For the error text and other refusals, see Routing and data mapping errors.
| Aurora MySQL | Meaning |
|---|---|
| 1235 (42000) | ORDER BY is not supported on this table: the query sorts. Use a plain SELECT and sort in your client. |
Related statements
For more information, see the following: