User login

Too many connections in lock_may_be_available() on Drupal 7 site

Encountered this error:

The website encountered an unexpected error. Please try again later.
Error messagePDOException: SQLSTATE[08004] [1040] Too many connections in lock_may_be_available() (line 165 of /var/local/drupal/dgd7/drupal/includes/lock.inc)

The website encountered an unexpected error. Please try again later PDOException Too many connections in lock_may_be_available() lock.inc

Visited other sites on the server, they were OK. Hit reload in Chrome, and still got the error. Visited update.php and then the administration pages and back to the home page and all was well again.

So either something really weird was going on and going to update.php or admin jogged it back to functioning, or more likely it was a temporary error and Chrome cached it.

Update: This was probably due to server overload, probably stemming from anonymous comments DOS attack

Searched words: 
The website encountered an unexpected error. Please try again later PDOException Too many connections in lock_may_be_available() lock.inc

Comments

PDOException: SQLSTATE[08004]

PDOException: SQLSTATE[08004] [1040] Too many connections in lock_may_be_available() (line 165 of /var/www/includes/lock.inc).

This error encounter have you any solution for it.

drupal 7 error

PDOException: SQLSTATE[42000]: Syntax error or access violation: 1226 User 'u967967217_rem' has exceeded the 'max_questions' resource (current value: 20000) in lock_may_be_available() (line 167 of /home/u967967217/public_html/includes/lock.inc).

Too many connections in lock_may_be_available() on drupal7/mysql

hi there,

I'm using drupal 7 for some few years and I just got this same problem as above for the first time! : "PDOException: SQLSTATE[08004] [1040] Too many connections in lock_may_be_available() (line 167 of /var/www/site1/includes/lock.inc)" which supposed to be happening offten!
but this is the first time I got problem would like to know whether I could get an solution on this platform and will be greatly appreciated for it.

Hello to others running into this

First, as should be evident, it is not solely a Drupal problem but with your environment as a whole while your site is under heavy load— checking that MySQL is running and starting it or restarting it will probably fix this.

For further fix / diagnostic, look at https://drupal.org/comment/8165481#comment-8165481 (and everything above and what will come below it, if you have a lot of time..)

Post new comment

The content of this field is kept private and will not be shown publicly.
  • You may post code using <code>...</code> (generic) or <?php ... ?> (highlighted PHP) tags.
  • You can use Markdown syntax to format and style the text. Also see Markdown Extra for tables, footnotes, and more.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd> <img> <blockquote> <small> <h2> <h3> <h4> <h5> <h6> <sub> <sup> <p> <br> <strike> <table> <tr> <td> <thead> <th> <tbody> <tt> <output>
  • Lines and paragraphs break automatically.

More information about formatting options

By submitting this form, you accept the Mollom privacy policy.