Hi there,
I have this problem for a long time, but nowadays it is getting worse. I tried to find a solution but I could not find one till now. When I search for "is not a valid MySQL result resource in" in google, I end up with 107,000 results and 99 percent of them are errors on pages.
Under normal conditions, all scripts are working fine. But time to time, especially under heavy load, I am getting errors of "... is not a valid MySQL result resource in ..." in my logs. I have no other errors or problems.
I am using persistent connections. I know they are little bit tricky to use but I had 300 queries/min on mysql and I wanted to use persistent connections for performance.
On php manual there is a warning saying:
"Using persistent connections can require a bit of tuning of your Apache and MySQL configurations to ensure that you do not exceed the number of connections allowed by MySQL. " But there is no other explanation about that. I tried to increase MySql max_connections to 400 but it did not solved the problem. (I had usually about 20 connections on mysql monitor).
Is anyone knows any helpful hints about this issue?
Thanks for your help in advance.
Yours,
Tolga Orhon