I have a rather embarrassing problem. While debugging a web app, I suddenly found I was not retrieving items from the database. I went to the command line to log into MySQL and got back "Error 1040: Too many connections." This was when I realized I'd forgotten to include a call to mysqli::close() in my PHP script. This has never been a problem before -- PHP is supposed to close the DB connection at the end of the script, if I'm not mistaken.

In any case, it's fixed now, but in the meantime I can't connect to my DB. Is there any way for me to close my lingering old connections?

7 Years
Discussion Span
Last Post by EvolutionFallen

Thanks for the advice! They must have timed out after while, so I managed to get back in. But I left the thread open 'cause I wanted to know what to do should I ever encounter that problem again. Thanks again =)

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.