Restoring RDS Snapshot with CloudFormation

0

I am trying to recreate an RDS Aurora database from a snapshot using CloudFormation and I am running into a problem. During the stack creation, I am getting this error 'Only DB Snapshot Identifiers can be used with the filter DB_SNAPSHOT_ID'

Here is a snippet of my CF template:

Parameters:
  DBSnapshot: 
     Type : "String"
     Default: "arn:aws:rds:us-west-2:893352710245:cluster-snapshot:snapshot"

Resources:
  RDSDatabase:
     Type: "AWS::RDS::DBInstance"
     Properties:
       DBInstanceClass: 'db.t2.micro'
       DBSnapshotIdentifier: !Ref DBSnapshot
1 Answer
0
Accepted Answer

Think I found the issue:

  DBSnapshot:
     Type : "String"
     Default: "arn:aws:rds:eu-west-1:300688157164:cluster-snapshot:snapshot"

Resources:
  MyDB:
    Type: "AWS::RDS::DBCluster"
    Properties:
      SnapshotIdentifier: !Ref DBSnapshot
      Engine: "aurora"

You are restoring a cluster so need to use AWS::RDS::DBCluster and SnapshotIdentifier and not the AWS::RDS::DBInstance.

AWS
answered 6 years ago
profile picture
EXPERT
reviewed 17 days 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