20

Currently, the value for the max_connections parameter in a MySQL RDS t1.micro server model is {DBInstanceClassMemory/12582880} is 32.

Since my server does not allowing any more connections after 32, what is the Maximum safe value for max_connections I can use for a micro instance ?

1

3 Answers 3

33

About 2 years ago, I was tasked with evaluating Amazon RDS for MySQL. I wrote some posts in the DBA StackExchange about my findings and observations:

In short, there are three options you cannot alter

Here is the Chart I made telling you those per-Server Model limits

MODEL      max_connections innodb_buffer_pool_size
---------  --------------- -----------------------
t1.micro   34                326107136 (  311M)
m1-small   125              1179648000 ( 1125M,  1.097G)
m1-large   623              5882511360 ( 5610M,  5.479G)
m1-xlarge  1263            11922309120 (11370M, 11.103G)
m2-xlarge  1441            13605273600 (12975M, 12.671G)
m2-2xlarge 2900            27367833600 (26100M, 25.488G)
m2-4xlarge 5816            54892953600 (52350M, 51.123G)

As for your actual question, t1.micro has 34 as a max_connections setting. If you cannot surpass 32, that is quite understandable. Amazon AWS must be able to connect to and monitor things for the RDS Instance as a SUPER user. Not being able to go beyond 32 is reasonable for a t1.micro instance. In light of this, you will have no choice but to trust the management scheme administered by Amazon for apportioning max_connections and other options among all MySQL Instances in the AWS Cloud.

5
  • Nice answer. but I thought I can change it in custom Parameter group. So there is no other way than increasing Instance size? May 29, 2014 at 13:30
  • Only those 3 options are immutable for the sake of the fair distribution CPU cycles, Memory, and Overall Performance to all running MySQL RDS instances. May 29, 2014 at 13:33
  • All the links are helpful. you saved a day for me May 29, 2014 at 13:36
  • 1
    To check your max_connections, try this command: select @@max_connections; Apr 9, 2016 at 23:43
  • 1
    See my answer below serverfault.com/a/740138/104677
    – advncd
    Jan 16, 2017 at 19:52
15

Here's what you can do to change max_connections or any other parameter in an AWS RDS (mysql) instance:

  • From RDS console go to Parameter Groups
  • Create a new parameter group based on the default group and name it my-param-group
  • Modify max_connections or other parameters in my-param-group
  • Go back to instance main page and click Modify in Instance Action button to modify the instance
  • Choose my-param-group as the DB Parameter Group
  • Reboot your instance
  • Done!
1
  • 1
    I think this should be the accepted answer now
    – lucaConfa
    Oct 25, 2017 at 4:51
9

It appears that things have changed since the accepted answer. After seeing this thread I ran a test on a db.m3.medium RDS MySQL instance with max_connection manually set to 2000 using DB Parameter Groups. I was able to create 2000 connections and only then got the expected error of Too Many Connections.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .