List:General Discussion« Previous MessageNext Message »
From:Maxim Wolf Date:December 7 2000 11:00am
Subject:Re: Too many connections?
View as plain text  
To increase the number of connections,
you must (for the first time)
set up the number of connections in your my.cnf:
[mysql]
port...
socket...
user...
set-variable ....
set-variable    = max_connections=300

usually the no of connections is limited to 100 (or smth. like this)
another important and userfull thing is to set the
number of queries to be queued to a higher no
(eg 64, deafult is 8, I think)

set-varaible   = back_log=64

...

Both might cause a higher use of memory and processor time!
(Yes, we made this experience).
You better check ALL your queries with
EXPLAIN (see mysql reference) to identify slow and
complex queries and to optimize them - this will give your
system much more power and speed than just increasing the
parameters! Out "slow queries" went down from >200 to 0!
(use "mysqladmin status" to monitor the status of your mysqlserver)

Regards,
MAx


================================
Maxim Wolf
World Careers Network
http://www.wcn.co.uk
Tel: 020 8946 9876
DDI: 020 8296 5912
Email: max@stripped
================================

----- Original Message -----
From: "Lee Smallbone" <lee@stripped>
To: <mysql@stripped>
Sent: Thursday, December 07, 2000 11:51 AM
Subject: Too many connections?


> Hello,
>
>  We've recently started getting problems on a high traffic website,
>  with similar errors to:
>
> Warning:  MySQL Connection Failed: Too many connections
> in /www/init.php3 on line 40
> Unable to select database
>
>  What can we do to resolve this?
>
> ver: mysql  Ver 9.16 Distrib 3.21.33b, for pc-linux-gnu (i586)
>
>  Thanks in advance,
>
> --
>
> Best regards / Hilsen / kær kvedja,
>
> Lee Smallbone
> Opera Software AS
>
>
>
> --
> ---------------------------------------------------------------------
> Please check "http://www.mysql.com/documentation/manual.php" before
> posting. To request this thread, e-mail mysql-thread58301@stripped
>
> To unsubscribe, send a message to:
>     <mysql-unsubscribe-max=wcn.co.uk@stripped>
>
> If you have a broken mail client that cannot send a message to
> the above address (Microsoft Outlook), you can use:
>     http://lists.mysql.com/php/unsubscribe.php
>

Thread
Too many connections?Lee Smallbone7 Dec
  • Re: Too many connections?Maxim Wolf7 Dec