Migrating table structures and data

0

I'm working on a DynamoDB solution that will need to be migrated to a customer's AWS instance at some point. I have a table that I would like to script out so I can use that to create the table on the customer's instance using AWS CLI. I can use describe-table to create a script, so surely there's a way to use it to create the table, but create-table doesn't take a file as a parameter?

Likewise, with the data, you can create a json file of all records, but it's in a different format to the file you specify in the --request-items parameter of batch-write-item. So, how do you migrate data from one instance of a table to another?

Nick
asked a year ago224 views
1 Answer
0

Migrate the DynamoDB table data by exporting the table to an Amazon S3 bucket in the target account (https://aws.amazon.com/pt/premiumsupport/knowledge-center/back-up-dynamodb-s3/) . Be sure that DynamoDB has s3:ListBucket permissions to this S3 bucket. Be sure that the S3 bucket doesn't have any access control lists that deny access to the exported data.

After the export is completed, import the data from the S3 bucket into a new table in the target account. https://aws.amazon.com/pt/blogs/database/amazon-dynamodb-can-now-import-amazon-s3-data-into-a-new-table/

profile pictureAWS
answered a year ago
  • thanks, will try that

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