Dear all,
All our webpage are run in PHP and mysql database server. We find that when check our linux server by using "ps -auxwx", there are many processes still running as following scripts.
When the number of processes exceed twenty something, the webpage cannot connect the mysql database.
Remark that I have add the mysql_close($db) at the end of each webpage after calling mysql database.
Please give us what the problems are and the solution, thanks
Sincerely yours,
Simon
Display in the webpage when the no of mysql process exceed the limit
Warning: MySQL Connection Failed: Too many connections in /home/htdocs/kindergarten/ccwkk/php/news/headnews.php on line 21
Warning: Supplied argument is not a valid MySQL-Link resource in /home/htdocs/kindergarten/ccwkk/php/news/headnews.php on line 22
Display in the linux server when entering "ps -auxw"
root 587 0.0 4.9 17232 3076 ? S 09:08 0:00 /usr/local/mysql/bin/mysqld --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data --user=root --
root 589 0.0 4.9 17232 3076 ? S 09:08 0:00 /usr/local/mysql/bin/mysqld --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data --user=root --
root 590 0.0 4.9 17232 3076 ? S 09:08 0:00 /usr/local/mysql/bin/mysqld --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data --user=root --
root 1354 0.0 0.6 2436 384 ? S 11:17 0:00