Go Back   Armenian Knowledge Base > Technical sections > Webmaster Zone > Web Development

Reply
 
Thread Tools

Too many connections
Old 12.05.2004, 13:11   #1
Web developer
 
Aram Ghazanchyan's Avatar
 
Join Date: 09 2002
Location: Yerevan
Age: 44
Posts: 896
Rep Power: 0
Default Too many connections

Warning: mysql_pconnect(): Too many connections in /home/xxx/public_html/conn.inc.php on line 2

Chto delat'?

Old 12.05.2004, 15:24   #2
Moderator
 
acid's Avatar
 
Join Date: 09 2001
Location: South Korea, Gumi
Posts: 7,699
Blog Entries: 16
Rep Power: 7
Default

There are two ways out:

1. You may want to change mysql_pconnect() to mysql_connect(), because first one won't close connection when script is ended. Documentation says:

Quote:
the connection to the SQL server will not be closed when the execution of the script ends. Instead, the link will remain open for future use (mysql_close() will not close links established by mysql_pconnect()).
2. You may increase your max_connections variable in your my.cnf.

Up to you to decide which way is the best for your case.

Cheers.

Old 12.05.2004, 16:18   #3
Главный Лысый
 
Pascal's Avatar
 
Join Date: 10 2001
Location: AM
Age: 47
Posts: 2,829
Rep Power: 5
Default

Perhaps it's a hoster limitation.
Review max m,ysql connections in your contract.

Regards
__________________
Ruben Muradyan
Technical Director
PanARMENIAN Network: Armenian News

----------------------------------------------------
Лысина - это полянка, вытоптанная мыслями.
----------------------------------------------------

Old 13.05.2004, 06:50   #4
Web developer
 
Aram Ghazanchyan's Avatar
 
Join Date: 09 2002
Location: Yerevan
Age: 44
Posts: 896
Rep Power: 0
Default

Thanks a lot
Reply




Реклама:
реклама
Buy text link .

All times are GMT. The time now is 10:10.
Top

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.