MySQL stopped working - full disk

Maybe it is because I am lacking in free disk space, take a look:

Filesystem            Size  Used Avail Use% Mounted on
/dev/sda2             1.9G  208M  1.6G  12% /
none                  998M  192K  998M   1% /dev
none                 1002M     0 1002M   0% /dev/shm
none                 1002M   56K 1002M   1% /var/run
none                 1002M     0 1002M   0% /var/lock
none                 1002M     0 1002M   0% /lib/init/rw
/dev/sda1              92M   24M   63M  28% /boot
/dev/sda8             434G  199M  412G   1% /home
/dev/sda6             9.2G  495M  8.3G   6% /usr
/dev/sda7             9.2G  8.8G     0 100% /var

/var is at 100% utilization.

Perhaps this is the reason?


Yes, it could be the reason if mysql's data is on /var/ (which is usually true).

It seems you have enough on /home/. Why don't copy data files there and try?


According to MySQL 5.0 Certification Study Guide, page 409, Chapter 29, section 29.2 "The MyISAM Engine", bullet point 11 specifically states:

If you run out of disk space while adding rows to a MyISAM table, no error occurs. The server suspends the operation until space becomes available, and then completes the operation.

Over and over again, whenever I see this occur, I delete a couple of old binary logs, and voilà, MySQL starts moving again. I then quickly shutdown MySQL, erase the remaining binary logs and the binary log index, start MySQL up, and everything is just fine. Works every time for me!

If binary logs are not enabled, then you have to use kill -9 on mysqld, move the /var/lib/mysql folder to a bigger disk. Symlink /var/lib/mysql to the new location, and start MySQL back up.