Menu
Amazon Relational Database Service
User Guide (API Version 2014-10-31)

Working with Amazon Resource Names (ARNs) in Amazon RDS

Resources created in Amazon Web Services are each uniquely identified with an Amazon Resource Name (ARN). For certain Amazon RDS operations, you must uniquely identify an Amazon RDS resource by specifying its ARN. For example, when you create an RDS DB instance Read Replica, you must supply the ARN for the source DB instance.

Constructing an ARN for Amazon RDS

Resources created in Amazon Web Services are each uniquely identified with an Amazon Resource Name (ARN). You can construct an ARN for an Amazon RDS resource using the following syntax.

arn:aws:rds:<region>:<account number>:<resourcetype>:<name>

Region Name Endpoint
US West (Oregon) Region us-west-2 https://rds.us-west-2.amazonaws.com
US West (N. California) Region us-west-1 https://rds.us-west-1.amazonaws.com
US East (Ohio) Region us-east-2 https://rds.us-east-2.amazonaws.com
US East (N. Virginia) Region us-east-1 https://rds.us-east-1.amazonaws.com
Asia Pacific (Mumbai) Region ap-south-1 https://rds.ap-south-1.amazonaws.com
Asia Pacific (Seoul) Region ap-northeast-2 https://rds.ap-northeast-2.amazonaws.com
Asia Pacific (Singapore) Region ap-southeast-1 https://rds.ap-southeast-1.amazonaws.com
Asia Pacific (Sydney) Region ap-southeast-2 https://rds.ap-southeast-2.amazonaws.com
Asia Pacific (Tokyo) Region ap-northeast-1 https://rds.ap-northeast-1.amazonaws.com
Canada (Central) Region ca-central-1 https://rds.ca-central-1.amazonaws.com
China (Beijing) Region cn-north-1 https://rds.cn-north-1.amazonaws.com.cn
EU (Frankfurt) Region eu-central-1 https://rds.eu-central-1.amazonaws.com
EU (Ireland) Region eu-west-1 https://rds.eu-west-1.amazonaws.com
EU (London) Region eu-west-2 https://rds.eu-west-2.amazonaws.com
South America (São Paulo) Region sa-east-1 https://rds.sa-east-1.amazonaws.com
AWS GovCloud (US) us-gov-west-1 https://rds.us-gov-west-1.amazonaws.com

The following table shows the format that you should use when constructing an ARN for a particular Amazon RDS resource type.

Resource Type ARN Format
DB instance

arn:aws:rds:<region>:<account>:db:<name>

For example:

Copy
arn:aws:rds:us-east-2:123456789012:db:my-mysql-instance-1

DB cluster

arn:aws:rds:<region>:<account>:cluster:<name>

For example:

Copy
arn:aws:rds:us-east-2:123456789012:cluster:my-aurora-cluster-1
Event subscription

arn:aws:rds:<region>:<account>:es:<name>

For example:

Copy
arn:aws:rds:us-east-2:123456789012:es:my-subscription
DB option group

arn:aws:rds:<region>:<account>:og:<name>

For example:

Copy
arn:aws:rds:us-east-2:123456789012:og:my-og-oracle-tde
DB parameter group

arn:aws:rds:<region>:<account>:pg:<name>

For example:

Copy
arn:aws:rds:us-east-2:123456789012:pg:my-param-enable-logs
DB cluster parameter group

arn:aws:rds:<region>:<account>:cluster-pg:<name>

For example:

Copy
arn:aws:rds:us-east-2:123456789012:cluster-pg:my-cluster-param-timezone
Reserved DB instance

arn:aws:rds:<region>:<account>:ri:<name>

For example:

Copy
arn:aws:rds:us-east-2:123456789012:ri:my-reserved-postgresql
DB security group

arn:aws:rds:<region>:<account>:secgrp:<name>

For example:

Copy
arn:aws:rds:us-east-2:123456789012:secgrp:my-public
DB snapshot

arn:aws:rds:<region>:<account>:snapshot:<name>

For example:

Copy
arn:aws:rds:us-east-2:123456789012:snapshot:my-mysql-snap-20130507
DB cluster snapshot

arn:aws:rds:<region>:<account>:cluster-snapshot:<name>

For example:

Copy
arn:aws:rds:us-east-2:123456789012:cluster-snapshot:my-aurora-snap-20160809
DB subnet group

arn:aws:rds:<region>:<account>:subgrp:<name>

For example:

Copy
arn:aws:rds:us-east-2:123456789012:subgrp:my-subnet-10

Getting an Existing ARN

You can get the ARN of an RDS resource by using the AWS Management Console, AWS Command Line Interface (AWS CLI), or RDS API.

AWS Management Console

To get an ARN from the AWS Management Console, navigate to the resource you want an ARN for, and choose See Details for that resource. For example, you can get the ARN for a DB instance from the Configuration Details page as shown following.


    				DB instance ARN

AWS CLI

To get an ARN from the AWS CLI for a particular RDS resource, you use the describe command for that resource. The following table shows each RDS CLI command, and the ARN property used with the command to get an ARN.

RDS CLI Command ARN Property
describe-event-subscriptions EventSubscriptionArn
describe-certificates CertificateArn
describe-db-parameter-groups DBParameterGroupArn
describe-db-cluster-parameter-groups DBClusterParameterGroupArn
describe-db-instances DBInstanceArn
describe-db-security-groups DBSecurityGroupArn
describe-db-snapshots DBSnapshotArn
describe-events SourceArn
describe-reserved-db-instances ReservedDBInstanceArn
describe-db-subnet-groups DBSubnetGroupArn
describe-option-groups OptionGroupArn
describe-db-clusters DBClusterArn
describe-db-cluster-snapshots DBClusterSnapshotArn

For example, the following AWS CLI command gets the ARN for a DB instance.

Example

For Linux, OS X, or Unix:

Copy
aws rds describe-db-instances \ --db-instance-identifier DBInstanceIdentifier \ --region us-west-2

For Windows:

Copy
aws rds describe-db-instances ^ --db-instance-identifier DBInstanceIdentifier ^ --region us-west-2

API

To get an ARN for a particular RDS resource, you can call the following RDS API actions and use the ARN properties shown following.

RDS CLI Command ARN Property
DescribeEventSubscriptions EventSubscriptionArn
DescribeCertificates CertificateArn
DescribeDBParameterGroups DBParameterGroupArn
DescribeDBClusterParameterGroups DBClusterParameterGroupArn
DescribeDBInstances DBInstanceArn
DescribeDBSecurityGroups DBSecurityGroupArn
DescribeDBSnapshots DBSnapshotArn
DescribeEvents SourceArn
DescribeReservedDBInstances ReservedDBInstanceArn
DescribeDBSubnetGroups DBSubnetGroupArn
DescribeOptionGroups OptionGroupArn
DescribeDBClusters DBClusterArn
DescribeDBClusterSnapshots DBClusterSnapshotArn

Related Topics