MySQL Forums
Forum List  »  Perl

Can't connect to MySQL server on 'dbserver' (4)
Posted by: Fred McIntyre
Date: May 05, 2009 12:42PM

After posting this I saw that I was in the wrong forum. My apologies. I'm reposting in the Newbies.

I have a perl script running on a Linux server which forks off many processes rather rapidly. Each process makes its own connection to a remote MySQL server. As soon as it is finished with its work, the process closes the connection. The remote server has max_connections=1000, connection_timeout=30, and log_warnings=2 (among other things). I'd be glad to show the values of any other relevant variables.

The problem is that after between 200 and 240 connections (the number varies) in rapid succession (some simultaneously) I get the error "Can't connect to MySQL server on 'dbserver' (4)"

When that happens there is nothing in the MySQL server error log, and the Aborted_clients and Aborted_connects counts do not increase. Status shows "Max_used_connections 57" Therefore, I'm inclined to think the connection request isn't reaching the remote MySQL server - at least not MySQL itself.

Can anyone help me know what to look at to determine what is blocking the connection. If strace or similar is suggested, please be very specific about exactly what I need to type on the command line, and what to look for, as I am not a Linux expert.

Of course, if any other configuration would be helpful, just let me know what.

Thanks,
Fred



Edited 1 time(s). Last edit at 05/05/2009 07:26PM by Fred McIntyre.

Options: ReplyQuote


Subject
Written By
Posted
Can't connect to MySQL server on 'dbserver' (4)
May 05, 2009 12:42PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.