Question

I am experiencing some strange behaviour with MySQL. I have a table, not large, about 20k rows, with one column that is VARCHAR(512). Performing a SELECT query on this table (that involves joins etc) works, but if I change the schema to VARCHAR(1024) or TEXT I get the error: #2013 Lost connection to MySQL server during query.

My error.log shows the following:

121014 16:24:49 [Note] Plugin 'FEDERATED' is disabled.
121014 16:24:49  InnoDB: Initializing buffer pool, size = 8.0M
121014 16:24:49  InnoDB: Completed initialization of buffer pool
121014 16:24:49  InnoDB: Started; log sequence number 0 52320007
121014 16:24:49 [Note] Recovering after a crash using /var/log/mysql/mysql-bin
121014 16:24:49 [Note] Starting crash recovery...
121014 16:24:49 [Note] Crash recovery finished.
121014 16:24:49 [Note] Event Scheduler: Loaded 0 events
121014 16:24:49 [Note] /usr/sbin/mysqld: ready for connections.
Version: '5.1.58-1ubuntu1-log'  socket: '/var/run/mysqld/mysqld.sock'  port: 3306  (Ubuntu)

I have dumped the database and loaded it on a different machine and it works fine no matter the schema. Does anyone know how I might debug this issue or what might be causing it?

Extra note: The machine at issue is a Rackspace cloud server, I have resized the server, which means that it has more resources and also that the hardware it was running on likely changed, but the problem persists.

Clarification: I can do most queries on this table no matter the schema, it is just particular queries (involving a number of joins) that seem to cause the failure. A SELECT * works fine.

Was it helpful?

Solution

I have no idea what was causing this issue, but upgrading to MySQL 5.5 made it disappear. Thanks to all those that tried to help.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top