How can I enable monitoring for an AWS DMS task?

Last updated: 2019-12-26

How can I enable monitoring for an AWS Database Migration Service (AWS DMS) task?

Short Description

You can use Amazon CloudWatch logs to monitor the progress of your DMS task, the resources used, and the network activity used. You can monitor an AWS DMS task by using the AWS DMS console, the AWS Command Line Interface (AWS CLI), or the AWS DMS API.

Resolution

Enable task logging

To modify a DMS task, the task must be in a stopped or failed state.

  1. Open the AWS DMS console, and then choose Database migration tasks from the navigation pane.
  2. Select your task, choose Actions, and then choose Modify.
  3. From the Task Settings pane, choose Enable CloudWatch logs.
  4. Choose Save.

Check the task's progress

  1. Open the AWS DMS console, and then choose Database migration tasks from the navigation pane.
  2. Choose the name of the task that you want to monitor.
  3. From the Table Statistics section, review the values in the columns for Tables loaded, Tables loading, Tables queued, and Tables errored.

For more information about the status of your task, see Task Status.

View the Amazon CloudWatch logs

  1. Open the AWS DMS console, and then choose Database migration tasks from the navigation pane.
  2. Choose the name of the task that you want to review.
  3. From the Overview details section, choose View logs.

View the Amazon CloudWatch metrics

  1. Open AWS DMS console, and then choose Database migration tasks from the navigation pane.
  2. Choose the name of the task you want to monitor.
  3. From Migration task metrics, view the metrics for your task.
  4. Check the metrics for CDCLatencySource and CDCLatencyTarget during the CDC phase of the task to identify potential latency in the source or target. For more information, see Monitoring Replication Tasks Using Amazon CloudWatch.

Check task configuration and settings

  1. Open the AWS DMS console, and then choose Database migration tasks from the navigation pane.
  2. Choose the name of the task that you want to review.
  3. From the Overview details section, you can see the Basic configuration and Task settings for your task.

View the metrics for a replication instance

  1. Open the AWS DMS console, and then choose Replication instances from the navigation pane.
  2. Choose the name of the replication instance in use.
  3. From the CloudWatch metrics tab, review the metrics for CPU utilization, freeable memory, free storage space, and SWAP usage.

Use advanced settings

  1. Open the AWS DMS console, and then choose Database migration tasks from the navigation pane.
  2. Select your task, choose Actions, and then choose Modify.
  3. Expand Advanced task settings.
  4. In the Create control table in target using schema field, enter the name of your schema on the target database where AWS DMS can create its control tables.
  5. In the History timeslot (minutes), enter the amount of time you want each history record to stay in the replication history table.
  6. In the Enable control table section, for Apply Exceptions, awsdms_apply_exceptions is always enabled. Optionally, you can add the following control tables to monitor additional details about the task:
    Replication Status - awsdms_status
    Suspended Tables - awsdms_suspended_tables
    Replication History - awsdms_history
    Note: These control tables are created in the target instance, and they can be viewed only by using a SELECT query in the target control schema in the target database instance.