rhordern
Jul 15 2002, 04:07 AM
Hi, I'm running plesk 2.5.3 on linux 7.1 on a duron 1Ghz with 512Ram, using about 50Gb bandwith per month and have about 300 sites including subdomains. For the last few days I've had complaints from my customers saying that mysql keeps stopping. I can not understand this. The server load seems correct (0.1- 0.4) and anyway I would think that the sever load would just slow down mysql and when mysql stopps working html files shouldn't show up either ...
Does anyone know why mysql could just stop working and/or how to fix it,
Thanks in advance,
Richard
Jonathan
Jul 15 2002, 05:04 AM
When mysql stopps what message do your php/cgi pages produce when they try to connect to mysql??
rhordern
Jul 15 2002, 05:18 AM
I've not actually been on it yet when it happens as it only started yesterday and only lasts for about 15 minutes at a time. A customer said that it says "Unable to connect to database" and that phpmyadmin + the plesk CP say something similar...
I was thinking, coud it be a problem like too many people trying to access the database at the same time, is there a way to increase the amout of simultanious connections allowed ?
Thanks
Richard
Jonathan
Jul 15 2002, 07:45 AM
I immediately thought of the max connections variable if your clients were reporting the error to you. By default mysql sets this variable to 100. I'm assuming your running Plesk v2.5.x Standard version and NOT the RPM version.
Create the file my.cnf under /usr/local/psa/mysql/var/ and put in it
QUOTE
[mysqld]
set-variable = max_connections=200
Then restart either just mysql or the whole of plesk. You should also make sure that none of your clients are using persistant connections in php. You could also disable persistant connections in the php.ini file as well.
frostie
Jul 19 2002, 06:53 PM
Wicked, thank you very much.
I took a look at php.ini and it showed that mysql.allow_persistant was set to 'On'. I have set this to 'Off' to see how it goes.
mysql.max_persistant was set to '-1' (unlimited) . I was just wondering if setting this to '200' would be the same as doing this as you suggested above:
[mysqld]
set-variable = max_connections=200
Let me know. Any tips and tricks for maximising the way the server performs would be greatly appreciated.
James
rhordern
Jul 20 2002, 02:17 AM
No it's not the same, the max connections is the amount of connections allowed at the same time with all the databases on the whole server. the mysql.max_persistant I think limits how many times the same database can connect to mysql at the same time. I don't like the idea of turning this off, what woud be a good setting instead of having this unlimited ?
Thanks,
Richard
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please
click here.