Welcome Guest ( Log In | Register )



 
Reply to this topicStart new topic
> Too Many Connections?, mysql_connect()
lonelym
post Aug 16 2007, 01:27 AM
Post #1


Member - Active Contributor
Group Icon

Group: Members
Posts: 91
Joined: 18-May 07
Member No.: 22,008



I uploaded my PHP game yesterday, and most of my friends tried it out. After a while, I tried to play as well but it said that mysql_connect() had too many connections already. Can anyone tell me how to increase the amount of connections or maybe the total amount of connections allowed?
Go to the top of the page
 
+Quote Post
TavoxPeru
post Aug 16 2007, 07:21 AM
Post #2


Super Member
Group Icon

Group: [HOSTED]
Posts: 802
Joined: 8-April 06
From: Lima - Peru
Member No.: 12,579
myCENTs:17.43



QUOTE(lonelym @ Aug 15 2007, 08:27 PM) *
I uploaded my PHP game yesterday, and most of my friends tried it out. After a while, I tried to play as well but it said that mysql_connect() had too many connections already. Can anyone tell me how to increase the amount of connections or maybe the total amount of connections allowed?

You need to change the mysql.max_links directive and set it to -1, you can set this directive in your php.ini configuration file or in your apache's httpd.conf file.

Also, check out the MySql max_connections system variable, this variable controls the number of connections allowed that by default is 100. so if you need more connections, you should restart mysqld with a larger value for this variable.

If you are using MySql 5 take a look to B.1.2.6. Too many connections.

Best regards,
Go to the top of the page
 
+Quote Post
lonelym
post Aug 16 2007, 12:53 PM
Post #3


Member - Active Contributor
Group Icon

Group: Members
Posts: 91
Joined: 18-May 07
Member No.: 22,008



I understand. The site is already uploaded to the internet. Can I change my host's max_connections? Or is it something that only they are allowed to set?
Go to the top of the page
 
+Quote Post
WeaponX
post Aug 17 2007, 01:39 AM
Post #4


Way Out Of Control - You need a life :)
Group Icon

Group: Members
Posts: 1,086
Joined: 21-June 05
From: New York
Member No.: 6,440
myCENTs:86.41



It depends. I've seen some hosts that will allow their users to edit this setting. I would contact the webhost to see what can be done. If anything, they will/can increase it for you.
Go to the top of the page
 
+Quote Post
lonelym
post Aug 17 2007, 01:46 AM
Post #5


Member - Active Contributor
Group Icon

Group: Members
Posts: 91
Joined: 18-May 07
Member No.: 22,008



Thanks. smile.gif
Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic

Collapse

> Similar Topics

Topics Topics
  1. MySQL & PHP coding(9)
  2. Displaying Data From Mysql?(2)
  3. Php/mysql Data Display(3)
  4. Need Help With A PHP - MySQL Registration Script(13)
  5. Need For PHP/MySQL Creator(1)
  6. Printing Out A Table(6)
  7. Need Some Help Using PHP & MySQL(4)
  8. [PHP + MySQL] Separating The Results By Pages(0)
  9. [PHP + MySQL] Encrypting Data(11)
  10. [php] Index.php?section=xx&pag=yy(6)
  11. How Do You Create A Secure Loging?(4)
  12. Important: Basics Of Using PHP And MySQL(10)
  13. Need Help With Php/mysql And Web Servers Such As Asta's.(4)
  14. Need MySQL Alternative To The Syntax "or die()"(8)
  15. Re-order MySQL Table(11)
  1. PHP & MySQL: Displaying Content From A Given ID(6)
  2. How To Show Serial Nums In PHP Table For Contents Of MySQL DB(4)
  3. Php Mysql Errors(2)
  4. Sql Injection Prevention (passing Numerical Data Across Pages).(9)
  5. Php/mysql And Manual Page Caching?(4)
  6. Extracting Mysql Maths Using Php(2)
  7. Anyone Know Of A Really Good Mysql Class?(4)
  8. Warning: Mysql_num_rows()(1)
  9. Warning: Mysql_result(): Supplied Argument Is Not A Valid Mysql Result Resource In ...(4)
  10. Making A Link = Mysql_query(8)
  11. Making Something In Mysql Happen Only Once(10)
  12. Mysql Question(inserting Number From A Textfield)(3)
  13. Letting Users Add Mysql Data With Php(1)


 



- Lo-Fi Version Time is now: 2nd December 2008 - 11:10 AM