I'm trying to launch an Amazon Relational Database Service (Amazon RDS) DB instance in an Amazon Virtual Private Cloud (Amazon VPC) but I received an error message.
Resolution
To launch an Amazon RDS DB instance in a specific Amazon VPC, be sure to set up the Amazon VPC and the DB instance according to these requirements:
- Use an Amazon VPC that has at least two subnets in the AWS Region where you want to deploy your DB instance. If an Amazon VPC doesn't have at least two subnets, you receive the following error message: "VPC must have a minimum of 2 subnets in order to create a DB Subnet Group. Go to the VPC Management Console to add subnets."
- Create a DB subnet group and include only the subnets you want Amazon RDS to launch DB instances into. If a DB subnet group isn't created, then Amazon RDS creates a DB subnet group including all subnets for the Amazon VPC. Each DB subnet group must have subnets in at least two Availability Zones in an AWS Region. If your subnet group doesn't include subnets from at least two Availability Zones, you receive following error message: "DB Subnet Group doesn't meet availability zone coverage requirement. Please add subnets to cover at least 2 availability zones."
- Use one of the approved Amazon Elastic Compute Cloud (Amazon EC2) dedicated instance types, if you want your DB instance to be in a dedicated Amazon VPC that has an instance tenancy attribute that is set to Dedicated. If you use an instance type that isn’t supported for dedicated Amazon VPC, then the Amazon VPC is not listed.
Note: If the DNS hostnames and DNS resolution attributes of the Amazon VPC aren't enabled, the Amazon VPC is listed when you choose Launch RDS Instance. However, if you try to launch an instance that is Publicly Accessible, you receive the following error message: "Cannot create a publicly accessible DB Instance. The specified VPC does not support DNS resolution, DNS hostnames, or both. Update the VPC and then try again."
Related information
Creating a DB instance in a VPC
Working with a DB instance in a VPC
How do I change the VPC for an RDS DB instance?
DNS support in your VPC
Working with DB subnet groups