Skip to content

Categories:

mysql iis asp and the crazies

It’s been a long time coming.
Here are the error messages of the last two months on Windows IIS6 using ASP 3.0:
The ominous asp error -2147467259:
[MySQL][ODBC 3.51 Driver]Can’t create TCP/IP socket (10038)
[MySQL][ODBC 5.1 Driver]Can’t create TCP/IP socket (10038)
[MySQL][ODBC 3.51 Driver][mysqld-5.0.44-log]MySQL server has gone away

Searching for this error on google and mysql.com would yield results that ranged from other helpless users asking the same question, to mysql admins posting that this is not actually a bug and there’s nothing they can do.

This error would occur sporadically, usually under heavy load and would return relentlessly. Nothing would help!
We tried all the suggestions from various sources (too many to list now), including debugging iis, windows, cleaning up after all connections to the database, mdac updates, tcp/ip ephemeral port range of windows increase, tweaking the registry, etc…

Feeling there’s nothing we could do on the web server platform, we moved on to the db servers (mysql servers 5.x running on debian).
Here we got errors like the following:

Aborted connection 887 to db: ‘abc’ user:
‘abc’ host: ’123.456.789.123′ (Got an error reading communication
packets)

We tried all the fitting suggestion on http://dev.mysql.com/doc/refman/5.1/en/
communication-errors.html
without a proper result.
The error returned again and again.
After tweaking several mysql config variables we finally came upon a little noticed post on:
http://themattreid.com/wordpress/?p=15

Thank you matt reid!
Increasing the max_allowed_packet from 8MB to 64 MB did the trick.
Time to celebrate.

Share and Enjoy:
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google Bookmarks

Posted in code. Tagged with , , , .

0 Responses

Stay in touch with the conversation, subscribe to the RSS feed for comments on this post.

Some HTML is OK

(required)

(required, but never shared)

or, reply to this post via trackback.