Had a customer issue come through right before I left for the day. Hadn’t seen this happen before and google was not too helpful.
Problem: We had the tmp-dir set as /var/tmp which was on it’s own partition of 5GB. This is a relatively small database of about 15GB. Customer has some replication slaves setup and was running a LOAD DATA INFILE on the master. File was about 12GB, so the slave creates a SQL-DATA-1024-512.data file in the tmp directory to buffer that INFILE command coming from the master. Well, eventually that filled up the /var/tmp partition.
Solution: stop the server, change the tmp-dir=/bigger-partition, move the file to the new tmp location, restart cluster, all good.
Prevention: Make sure your tmp-dir setting is on a large enough partition to hold your temporary files, and make sure if you’re going to load a data file on the master that’s bigger than your slave tmp-dir that it will halt the Slave_SQL_thread once the partition fills up and you’ll have a headache on your hands.






