Is there a setting to limit the number of access to the MySQL database in PHP?
-
I got a report from my user that on his shared host, my PHP program does not work as expected. It works fine locally and on most other servers. Since the program is hardcoded and uses external libraries, I cannot test it easily to find out the cause. The user has let me login to his web site and as I view the result, it looks like the sever sets a limitation to access the MySQL server per page load. It doesn't throw the fatal error though. The un-working part of the program is that when it fetches external web contents (feed) and tries to display them, it returns empty data. Some requests works and some don't. The urls are all have the same domain. That's the strange part. So the requests to external web sites is not entirely blocked. During the process of generating the web contents, there are lots of interactions with the MySQL detabase. So I'm wondering if there is a way to detect if the server has special settings to limit the access to the database.
-
Answer:
Yes. You could use max_connections setting in mysql, I think. Or "m... You must be signed in to read this answer.Connected to GoogleConnected to FacebookBy continuing you indicate that you have read and agree to the . Loading account...Complete Your ProfileFull NameChecking...EmailChecking...PasswordChecking...By creating an account you indicate that you have read and agree to the .
Amal Murali at Quora Visit the source
Other answers
There are several restrictions can be applied to a MySQL user i.e. maximum simultaneous connections, maximum connections per hour, maximum queries per hour, maximum update per hour. More on this can be found at MySQL Manual (http://dev.mysql.com/doc/refman/5.1/en/user-resources.html). In your case, there might be another reason the external host is denying or delaying the response to your requests.
Muhammad Wasif
Related Q & A:
- How to parse .log file and insert into database in PHP?Best solution by unix.com
- where is the index physically located in MySQL database?Best solution by Database Administrators
- How to manage MySQL database in Azure?Best solution by stackoverflow.com
- How to do a local mysql database replication on an online server?Best solution by howtoforge.com
- How to Display an Image in PDF, which is retrieved from MySql Database :JSP and iText?Best solution by Stack Overflow
Just Added Q & A:
- How many active mobile subscribers are there in China?Best solution by Quora
- How to find the right vacation?Best solution by bookit.com
- How To Make Your Own Primer?Best solution by thekrazycouponlady.com
- How do you get the domain & range?Best solution by ChaCha
- How do you open pop up blockers?Best solution by Yahoo! Answers
For every problem there is a solution! Proved by Solucija.
-
Got an issue and looking for advice?
-
Ask Solucija to search every corner of the Web for help.
-
Get workable solutions and helpful tips in a moment.
Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.