Connecting to MySQL when working with a large table

If you receive R0018 and Remote File Incorrect errors, then it is possible that the connection to MySQL is timing out. The default timeout value is 30 seconds.

This can be increased by adding an additional line to the my.cnf file.

The net_read_timeout line was added and set to 90 seconds in the example below:

[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
# Default to using old password format for compatibility with mysql 3.x
# clients (those using the mysqlclient10 compatibility package).
old_passwords=1

net_read_timeout=90
[mysql.server]
user=mysql
basedir=/var/lib

[mysqld_safe]
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid