cs44
cs44

Reputation: 1310

Amazon RDS (postgres) connection limit?

I've searched the web and browsed the RDS docs, yet I can't seem to find an open connection limit.

For what it's worth, I'm planning on using the new Postgres flavor of RDS, but I suppose an answer from the mySQL side of the house would be acceptable as well.

Thanks!

Upvotes: 97

Views: 121582

Answers (5)

Kunal Patil
Kunal Patil

Reputation: 775

May be it's too late for answering, but you could find the Amazon Aurora RDS Postgresql connection limit here:

https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/AuroraPostgreSQL.Managing.html#AuroraPostgreSQL.Managing.MaxConnections

Upvotes: 3

David Dehghan
David Dehghan

Reputation: 24775

You can change the max_connections. Make a clone of the default parameters. Then change the value and save and set the instance group to the new options group and finally reboot your instance to make the setting take effect.

enter image description here

Upvotes: 15

astgtciv
astgtciv

Reputation: 770

Afaik the 'max_connections' returned above is actually the current value of max_connections as set in the ParameterGroup. I wanted to know how to dynamically figure out the max possible connections of a given Postgres instance in AWS, but for some reason could not even find an info sheet from AWS. However, I noticed that AWS console RDS section shows you a progress bar of your current connections vs total possible:

Snapshot from AWS console

Examining this in Google Chrome Tools, I have established that the blue part is 4 pixels wide, while the total width of the progress bar is 50 pixels, which means that my current 121 connections constitute roughly 8% of total, which gives an approximation of max possible connections for my db.r3.large instance at 1512.

Upvotes: 13

Fernando Á.
Fernando Á.

Reputation: 7725

Simply with show max_connections;

You can modify this value on the Parameter Groups on the RDS console. The value of max_connections in the default postgres9.3 Parameter Group is {DBInstanceClassMemory/12582880}. In version 9.4 the default value is {DBInstanceClassMemory/31457280}.

Upvotes: 91

sskates
sskates

Reputation: 1628

If you setup a PostgreSQL RDS instance you can query for max_connections:

select * from pg_settings where name='max_connections';

max_connections is set to 5696.

Upvotes: 133

Related Questions