How to copy RDS database from Account A to Account B

0

Perimeter is RDS for Oracle or Postgres, but the question can be intended with a wider scope, considering all RDS engines.

Example: customer needs to copy a database from Prod account to Test account.

The procedure is:

  1. create a manual snapshot of prod database in prod account
  2. share the snapshot with the test account
  3. restore the snapshot in the test account but there are limitations as explained here:

Share manual Amazon RDS DB snapshots with another AWS account

https://aws.amazon.com/it/premiumsupport/knowledge-center/rds-snapshots-share-account/

In particular this limitation:

"You can't share manual snapshots of DB instances that use custom option groups with persistent or permanent options, such as Transparent Data Encryption (TDE) and time zone"

Customer uses "custom option groups" with specific timezone different from default. Given that source database and target database will need the same timezone, is it possible to bypass the current limitation in a "cross-account snapshot share" context? this is really a severe limitation for the customer at moment. Any experience to share?

Thanks

asked 8 months ago45 views
1 Answer
0

Dear Customer - Thanks for reaching out to us via AWS re:Post. First of all, allow me the opportunity to apologize for the delay in response to this post. I checked it just now and started working on it. I see that you wanted advice on copying database from one account to another when there is option group with persistent or permanent options attached - As a workaround you can create new instance without TDE option and copy data using EXPDP/IMPDP and then take snapshot of new instance and share it in different AWS account.

Below are the high level steps required for this workaround .

  • Create a new RDS instance with similar configuration but without any persistent/permanent options
  • Take a export backup using datapump and copy the dump files to S3 using S3 integration
  • Download the dump files in newly created instance and perform import using datapump.
  • Now take snapshot of new instance having data imported
  • Share this snapshot with any AWS account (as per your requirement)

Kindly refer below document [B] for S3 integration, [C] for importing data in RDS Oracle. Stay safe and have a nice day ahead !

References:

[A] Limitation on TDE Snapshots. https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_Tutorials.RestoringFromSnapshot.html https://aws.amazon.com/premiumsupport/knowledge-center/rds-snapshots-share-account/

[B] S3 Integration. https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/oracle-s3-integration.html

[C] Expdp/Impdp https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Oracle.Procedural.Importing.html#Oracle.Procedural.Importing.DataPump.S3

[D] Import data from the dump created. https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Oracle.Procedural.Importing.html#Oracle.Procedural.Importing.DataPump.DBLink

answered 5 months ago
profile picture
EXPERT
kentrad
reviewed 4 months 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