I'm doing all of this with Cloudformation. I've tried to enable logging for already working replication task, but I can't see the logs anywhere, it seems that a group should be created for the logs and there is no option like that in the documentation. I cannot find the parameter of the log group in the docs of Replication Task.[1] [2] [3]
Here's my replication task.
ReplicationTask:
Type: 'AWS::DMS::ReplicationTask'
Properties:
SourceEndpointArn: !Ref SourceEndpoint
TargetEndpointArn: !Ref TargetEndpoint
ReplicationInstanceArn: !Ref ReplicationInstance
MigrationType: 'full-load'
TableMappings: '
{
"rules": [
{
"rule-type": "selection",
"rule-id": "1",
"rule-name": "1",
"object-locator": {
"schema-name": "%",
"table-name": "%"
},
"rule-action": "include"
}
]
}'
ReplicationTaskSettings: '
{
"Logging": {
"EnableLogging": true,
"LogComponents": [{
"Id": "SOURCE_UNLOAD",
"Severity": "LOGGER_SEVERITY_DEFAULT"
},{
"Id": "SOURCE_CAPTURE",
"Severity": "LOGGER_SEVERITY_DEFAULT"
},{
"Id": "TARGET_LOAD",
"Severity": "LOGGER_SEVERITY_DEFAULT"
},{
"Id": "TARGET_APPLY",
"Severity": "LOGGER_SEVERITY_INFO"
},{
"Id": "TASK_MANAGER",
"Severity": "LOGGER_SEVERITY_DEBUG"
}]
},
}'
when I click on replication task, i see a link in the logs tab that takes me to cloud watch where I see an error Log group not found
References:
[1] http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-replicationtask.html
[2] http://docs.aws.amazon.com/dms/latest/userguide/CHAP_Tasks.CustomizingTasks.TaskSettings.html
[3] http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-logs-loggroup.html
You need to set it for the user. These documentation links give you more insight.
You need to create these roles in advance, or create in CloudFormation template.
Edit: It appears that sometimes the new AWS Console fails to create both of these IAM roles automatically. So you may need to create them manually.