MySQL Settings
Show status of InnoDB:
mysql -u root
show innodb status;
See what MySQL is doing (e.g. expensive query):
show processlist;
Check the current structure of a table, including foreign key constraints. This can be helpful in resolving issues caused by db mode 'update', which only adds columns but will not change an existing column:
show create table _Alias;
We use the following settings for MySQL on our production server (NixOS/Linux):
[mysqld]
key_buffer_size = 256M
max_allowed_packet = 64M
sort_buffer_size = 2M
read_buffer_size = 2M
myisam_sort_buffer_size = 64M
query_cache_size = 128M
max_connections = 250
[mysqldump]
max_allowed_packet = 16M
[isamchk]
key_buffer = 256M
sort_buffer_size = 256M
[myisamchk]
key_buffer = 256M
sort_buffer_size = 256M
