WebFaction
Community site: login faq

I got the error "OperationalError: (1040, 'Too many connections')" several times recently.

I've read that it could be caused by high load on the database. The high load could be caused by my own app, or someone sharing the database it connects to.

How can I know which is the case?

asked 21 Apr '13, 09:47

wuerg
323
accept rate: 0%


The number of connections are limited to 30 per user on the shared MySQL server. You can check your actual processes on the Shared MySQL server by running "show_processlist;" while logged into the MySQL server via command line.

The caveat is that if you have exhausted your connections you will not be able to log in.

permanent link

answered 21 Apr '13, 11:40

aaront ♦♦
7604
accept rate: 28%

@aaront - How to cleanup this connections? I am also getting this error.

(22 Jul '13, 14:05) jpatel3

@jpatel3 - there was a temporary spike in system load on your server which caused connections to pile up. It should be resolved now, but if you're still seeing a problem then please open a support ticket and we'll look into it.

(22 Jul '13, 15:40) seanf

@aaront What is the limit for number of connection on a Cloud Server? We had an issue this morning "Too many connections" persisted for a couple of hours and I had to open a ticket to get MYSQL server restarted. All seem to work now, but looking at "show_processlist" I only see 1 connection at all times. I'm just worried it is going to happen again . FYI: we're using 4GB cloud package.

(18 Jun, 14:13) ptgm

We don't limit the number of connections on cloud plans. You may read /etc/my.cnf and look at the max_user_connections directive. If it does not exist as it should not for cloud plans, it will default to unlimited. Submit a support ticket and we can investigate.

(18 Jun, 21:09) johns ♦♦
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×168

question asked: 21 Apr '13, 09:47

question was seen: 5,943 times

last updated: 18 Jun, 21:09

WEBFACTION
REACH US
SUPPORT
AFFILIATE PROGRAM
LEGAL
© COPYRIGHT 2003-2016 SWARMA LIMITED - WEBFACTION IS A SERVICE OF SWARMA LIMITED
REGISTERED IN ENGLAND AND WALES 5729350 - VAT REGISTRATION NUMBER 877397162
5TH FLOOR, THE OLD VINYL FACTORY, HAYES, UB3 1HA, UNITED KINGDOM