How do I turn on, access, or delete CloudWatch logs for AWS DMS?

3 minute read
0

I want to manage the Amazon CloudWatch logs for my AWS Database Migration Service (AWS DMS) task.

Resolution

Note: If you receive errors when running AWS Command Line Interface (AWS CLI) commands, make sure that you’re using the most recent AWS CLI version.

Turn on logging for a new DMS task

To turn on logging for a new AWS DMS task, choose Enable CloudWatch logs when you create a task.

Turn on logging for an existing DMS task

To turn on logging for an existing task:

  1. Open the AWS DMS console, and then choose Database migration tasks from the navigation pane.
  2. If the task is in the Failed or Stopped status, then select the task and choose Actions. Choose Modify, and then choose Enable CloudWatch logs.
  3. If the task is in the Running status, you can change the task setting for logging using the AWS CLI.
  4. Verify that the AWS Identity and Access Management (IAM) role dms-cloudwatch-logs-role exists on the AWS account running the task. If the role doesn't exist in the AWS account running the task, then follow the steps in Why can't I see CloudWatch Logs for an AWS DMS task?

After you turn on logging, you can manage the AWS DMS task logs.

View the logs of a DMS task

To view the logs of a task that has run, follow these steps:

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

Delete the logs of a DMS task

To delete logs, follow these steps:

  1. Open the AWS DMS console, and then choose Replication instances from the navigation pane.
  2. Choose the name of the replication instance that hosts your task.
  3. From the Log management section, select the logs you want to delete.
  4. Choose Delete.
  5. Confirm that you want to delete the logs permanently by choosing Delete.

You can also delete AWS DMS logs from the CloudWatch console by following these steps:

  1. Open the CloudWatch console, and then choose Logs from the navigation pane.
  2. Use the Filter field for search for your log files. The log group has the prefix dms.
  3. Choose the log group, and then choose Actions.
  4. Choose Delete log group.
  5. Confirm that you want to delete the logs permanently by choosing Delete.

Related information

Migrate an on-premises Oracle database to Amazon RDS for PostgreSQL using an Oracle bystander and AWS DMS

AWS OFFICIAL
AWS OFFICIALUpdated 2 years ago