- Neueste
- Die meisten Stimmen
- Die meisten Kommentare
Hello There,
I understand that you are looking for right sizing of your CIDR block as you don’t know how many IPs are usually required for Aurora RDS and you also would like to know how many IPs are needed in case of using some feature like RDS Proxy.
To begin with, In Amazon RDS Aurora “1 instance” uses “1 IP address” for an Aurora cluster irrespective of your cluster being provisioned or serverless. For example: For a cluster with 1 writer and 2 reader instances, 3 IP addresses will be required.
To make it simple, Considering you have 10 Production DB instances with 1 writer and 1 reader instance then minimum number of IPs you would be requiring would be:
Min. number of IPs = Number of Aurora DB instances (including both writer and total number of readers) = 20 IPs
However, as I can see you have already went the doc which says “The CIDR blocks in each of your subnets must be large enough to accommodate spare IP addresses for Amazon Aurora to use during maintenance activities, including failover and compute scaling”.
Here, please note that while only 1 IP per instance is required, it is essential to have spare IPs in the subnets to allow proper functioning of Aurora clusters and hence when you are creating the subnets please provision extra IP addresses in the CIDR as well because you will be requiring those IPs in case the underlying host needs to be replaced or DB Start/Stop or DB instance class change etc.
[+] Working with a DB instance in a VPC: https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_VPC.WorkingWithRDSInstanceinaVPC.html#Overview.RDSVPC.Create
That being said, In any generic networking configuration also consider that 5 IP Addresses are reserved on the subnet for networking purposes.
Coming to your query related to RDS Proxy, I would highly recommend you to go through the below documentation which gives idea about Planning for IP address capacity in case of using the RDS Proxy feature.
Following are the recommended minimum number of IP addresses to leave free in your subnets for your proxy based on DB instance class sizes.
db.*.xlarge or smaller 10
db.*.2xlarge 15
db.*.4xlarge 25
db.*.8xlarge 45
db.*.12xlarge 60
db.*.16xlarge 75
db.*.24xlarge 110
[+] Refer “Planning for IP address capacity” section - https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/rds-proxy-setup.html#rds-proxy-network-prereqs.plan-ip-address
And coming to your concern, Is it different if we place all databases in the same subnet or separated?
Firstly, as you might be aware your VPC must have at least two subnets. These subnets must be in two different Availability Zones in the AWS Region where you want to deploy your DB cluster.
You can place all the Database instances in these two subnets. However, it also depends upon your requirements, use-case and architecture to choose and create more than 2 subnets for your production database instances that you can use to group DB instances based on your security and operational needs.
I hope that the above information was quite helpful. Have a great day ahead!
Relevanter Inhalt
- AWS OFFICIALAktualisiert vor 3 Jahren
- AWS OFFICIALAktualisiert vor einem Jahr
- AWS OFFICIALAktualisiert vor 2 Jahren
- AWS OFFICIALAktualisiert vor 2 Jahren
Thank you, so it's only one IP per instance and "some" IPs to have room for failover and maintenance. Could you give an idea on what "some" IPs are? I'm supossing one in the event of failover or another for maintenance, but just for limited time. Am I right? If this is the case, putting more than one database in the same subnets (that was what I was referring to in the last question) can help reducing the number of extra IPs, as they share the "risk". I assume that having 1/3 or 1/4 is more than enough. In this case, for 20 instances, having 25-27 IPs, so /27 is enough (32-5=28 IPs).
Just for reference, the first link is "pure" RDS, this is for Aurora (but says the same regarding IPs): https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/USER_VPC.WorkingWithRDSInstanceinaVPC.html#USER_VPC.Subnets
About RDS proxy I already saw it, I was asking if it also depends on DB size, which I understand not as it's 1 IP per instance.