Im using PHP MySQLi to connect to MySQL and sometimes doing query i get error:
"Permission denied" error code: 2002.
The strange thing is that it happens for different query's and totally unpredictable. For example it might happen on third query after first two executed correctly.
I know it is not problem with MySQL because i moved it from one server to another and problem still persists. Most likely problem with PHP or interconnection between PHP and MySQL servers (they're on different machines)
Anyone got ideas?
EDIT:
query what gets "Permission denied" works if i restart script - its not permissions problem
ERROR:
[23-Apr-2011 19:00:02] PHP Warning: mysqli::mysqli() [mysqli.mysqli]: [2002] Permission denied (trying to connect via tcp://xxx.xxx.xxx.xxx:3306) in /home/.../DB.php on line 19
[23-Apr-2011 19:00:02] PHP Warning: mysqli::mysqli() [mysqli.mysqli]: (HY000/2002): Permission denied in /home/.../DB.php on line 19