Bug #23883 max_connections default should be raised to 150+x
Submitted: 2 Nov 2006 11:13 Modified: 11 Dec 2006 9:25
Reporter: Hartmut Holzgraefe Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server Severity:S4 (Feature request)
Version:* OS:Any (*)
Assigned to: Hartmut Holzgraefe
Triage: D5 (Feature request)

[2 Nov 2006 11:13] Hartmut Holzgraefe
Description:
to avoid the typical error message on an overloaded LAMP site running with default settings:

  *Warning*: mysql_connect(): Can't connect to local MySQL server through socket
   '/var/lib/mysql/mysql.sock' (2) in */path/to/script.php* on line *42*
  Could not connect to database. 

This is due to apaches default of 150 max_childs(?) so that in the worst case 150 apache processes are running PHP scripts competing for only 100 mysql connections.

How to repeat:
see above

Suggested fix:
raise max_connections to at least 151
[2 Nov 2006 11:27] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/14736

ChangeSet@1.2321, 2006-11-02 12:26:36+01:00, hartmut@mysql.com +1 -0
  raise max_connections default to avoid conflicts with apache max_childs settings (Bug #23883)
[27 Nov 2006 22:01] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/15897

ChangeSet@1.2396, 2006-11-27 15:01:14-07:00, tsmith@siva.hindu.god +1 -0
  raise max_connections default to avoid conflicts with apache max_childs settings (Bug #23883)
[27 Nov 2006 23:45] Timothy Smith
Patch queued to 5.1 -maint tree.
[11 Dec 2006 7:19] Jon Stephens
Thank you for your bug report. This issue has been committed to our source repository of that product and will be incorporated into the next release.

If necessary, you can access the source repository and build the latest available version, including the bug fix. More information about accessing the source trees is available at

    http://dev.mysql.com/doc/en/installing-source.html

Documented fix in 5.1.15 changelog.