Error case - Maximum concurrent MySQL user connections

If you ever encounter a database error on your website in regards to too many concurrent connections, you should be made aware that our limit is set to 10 MySQL concurrent user connections. Therefore, if loading a specific script which requires a mysql connection is called 11 times, 10 of these will go through but 1 will fail and give you a connection error. 

Possible solutions

  • If connections are made from different sources, you should create different usernames for each script that will make an independent connection to the database.
  • You should verify if your script does 'pconnect' type connections to the database. Persistent connections could be the source of the issue. On the other hand, if you are executing multiple queries from the same software, using a this type of connection could be a path to follow.
  • When the problem stems from long database queries that lock the requested table, you could look into using the InnoDB engine instead.
Have more questions? Submit a request

0 Comments

Please sign in to leave a comment.