Automate a Data Migration Service (DMS) Task

0

I have a DMS task set up to copy a AWS RDS Oracle schema to target s3 bucket.

Is there an option to automate the task, I have to run this DMS task everyday at 6 AM and I have to run it manually. Does AWS give the option to automate the DMS Task

raja
asked a year ago1319 views
5 Answers
0

Hi Raja,

You can leverage the Amazon EventBridge Scheduler to schedule that DMS task to run everyday at 6 AM for your timezone. You can set the target as the StartReplicationTask under AWS Database Migration Service shown in the screenshot below: Enter image description here

Note that this requires an IAM role that grants the EventBridge service permissions to start this task. The wizard for creating this schedule will provide options for choosing an existing IAM role or link to create a new one.

Let me know if you have any other questions

Loc, Data Architect, AWS ProServe

AWS
Loc
answered a year ago
  • Hi I do not get the option to choose StartReplicationTask under AWS Database Migration Service,

0

Enter image description here

raja
answered a year ago
  • Hi Raja,

    It looks like you are creating an EventBridge rule. Please try creating an EventBridge schedule - you'll see the option on the left side menu

    Loc

0
profile pictureAWS
EXPERT
kentrad
answered a year ago
0

Enter image description here

raja
answered a year ago
0

if you want to create a eventbridge that resume the task (because you need start the first time manually) you need to create a eventbridge schedule for a lambda, that create a iam role automatically (because dms:StartReplicationTask dosnt). After that, you can edit the rule and add the "dms:StartReplicationTask" action into the role created, like this:

{ "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Action": [ "lambda:InvokeFunction", "dms:StartReplicationTask" ], "Resource": "*" } ] } (can delete the lambda action if you want)

when you have this, now you can change the target service to DMS StartReplicationTask, whith the arn for your dms task and "StartReplicationTaskType": "resume-processing" (important resume-processing)

Cheers

answered a month ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions