try increasing mysql max_connections property
It's set to 100 by default, so probably you need more connections at the same time
Main Topics
Browse All TopicsI have an MFC application that uses libmySQL.lib to access a remote database. Within this application there is a thread that runs queries to produce live updates and there is also a facility to produce ad-hoc reports, so potentially there could be two queries being sent with two different connection handlers.
There is also a C++ application that runs on the remote database, writing insert queries to it on behalf of about 20 other machines at distance; i.e. these 20 machines do not talk to MySQL directly.
This system used to work fine until recently when my MFC application suddently said that it could not connect to the database. I then used the lower-level MySQL command prompt to access the database and the following error message was displayed:
ERROR 1129: Host 'host81-136-213-32.in-addr
We arranged for this command to be executed on the remote server and it fixed the problem, but now we are finding it is happening with alarming regularity. There are two possible reasons for this we can think of;
1. It has been gradually happening more frequently as more machines are added (i.e. the ones that do not communicate with the database directly, but via the server application).
2. We think, although we can't be sure, that the problems only started occuring after a Norton Firewall was installed on the remote server.
We have also noticed that the above connection error occurs on some PC's, while others in our building can still access the remote server without any problems at all (pointing to a client fault?)
We have not been using MySQL for very long and therefore don't know much about it's internal mechanisms. Any pointers as to what could be causing this problem, and/or possible solutions would be greatly appreciated.
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
Thanks for your comments, I think we have found the problem although only time will tell. What we think was happening, and this wasn't something that I posted in the original question, was that the computers that reported the fault were all on our internal network and used a shared broadband internet connection, so when more than one application was being run by us, it would be coming from the same IP address. We spotted this because we have several standalone PC's in our building that do not use the shared resources and go out using their own ISDN connection and have their own unique IP address. drobnett, I have awarded you the points because I found your answer the most helpful and you told me about the max_connect_errors which I knew nothing about that I will probably now implement if it improves the problem.
Business Accounts
Answer for Membership
by: drobnettPosted on 2003-09-29 at 09:45:23ID: 9452739
The problem you are having is that hosts are having problems connecting to your MySql database...kind of obvious from the error message. By default MySql will block connections from a host after a set number of connection attempt errors, the default is 10. The only way to allow the host the chance to reconnect is by issuing the "flush-hosts" command. The problem is either with your application or the firewall. I would try turning off the firewall and see if this makes the problem go away. You may want to try to connect from a remote host using the mysql client and see if it returns any error messages which are being generated during the connection attempt.
ng greater than 10. However, this will not fix whatever the underlying problem is that you are having.
Another option is to increase the max_connect_errors parameter above the default of 10. The way to do this is by setting the option when the mysqld is started. i.e. myslqd -O max_connect_errors=somethi