ozbuyucusu.com why not ?

9Sep/090

MySQL : Net packets out of order

A couple of weeks ago I come across an error which was very frustrating. I got this error when I try to connect a database with Toad or via Sphinx. I googled around alot to find an answer but the only answer I found out was in mysql forums which only declared that this is a "network problem". I even reinstalled mysql to find a fix for it. It didnt work.

So I rechecked every possible step that would cause a problem, and found out the problem started when I use mysql-dump output to load my data. I got the mysql-dump again and retired from my production server. It didnt work aswell. Then I tried yesterdays backups from production which worked fine. So what happened between yesterday and today that I get a net packets out of order error ?

I created a "view" !

Views, stored procedures, triggers are created with mysql users id and even though it can be recreated via backup its problematic if the user unique id doesnt match between servers.

So if you get a "net packets out of order" error, and if you got the error after a restore drop and recreate your views, stored procedures, triggers not to get an error in some programs (while others working perfectly well).

I saw the same error comes up in .NET aswell (while I am searching in google ), but I didnt really check if its caused by this error.

Filed under: Coding No Comments
26Aug/092

Php Error: Allowed memory size of 262144 bytes exhausted

Today I come across a php error I havent seen in ages.

"Allowed memory size of 262144 bytes exhausted"

I rechecked everything in php.ini / .htaccess / code on server. I saw nothing wrong at start. memory limit was set to 4gb and there was no lines in code which modifies this variable. So what was the problem ?

Then I thought what if php cannot allocate 4gb of memory ? Then set memory limit to 1gb and it worked. The problem was simple, if php cannot allocate the memory limit you set it goes to its default value while phpinfo is still showing 4gb.

Tagged as: , 2 Comments

Pages

Categories

Blogroll

Archive

Meta