Monday 16 July 2018

Solving Error “ERROR 1 (HY000): Can’t create/write to file ‘/tmp/#sql_9f3_0.MYI’ (Errcode: 17)”

Solving Error “ERROR 1 (HY000): Can’t create/write to file ‘/tmp/#sql_9f3_0.MYI’ (Errcode: 17)”

March 31st, 2015 - Posted by Steve Marks to MySQLPHPWeb Development.
Recently a site that we manage stopped working all of a sudden. The error being returned from the MySQL query was as follows:
  1. ERROR 1 (HY000): Can't create/write to file '/tmp/#sql_9f3_0.MYI' (Errcode: 17)  
The error states that a file in the ‘/tmp/’ folder can’t be written to, but why?
My initial thoughts were that it might be down to permissions on the folder. That would be odd however as it’s been fine for many years. Sure enough, the permissions on the folder were fine. So what else would cause an error like this?

THE SOLUTION

After much investigation, it turns out that the /tmp/ file on the server was full. Although there were only about 20 files in this folder, a couple of them were huge.
I’m not sure where these huge files originated from, however after removing them the site in question came instantly back to life.

0 comments:

Post a Comment