1

I run a fairly busy website that creates lots of session files in the /tmp folder. Recently I started getting this mySQL error:

MySQL said: Can't create/write to file '/tmp/MLX3o6NG' (Errcode: 28 - No space left on device)

So I checked with df -i and found:

/usr/tmpDSK 262144 262143 1 100% /tmp

It looks like the inodes are full. What is the best thing I could do?

Move the PHP session files to another directory? If so, how? The / partition for example has 179691356 free inodes.

user1227914
  • 3,446
  • 10
  • 42
  • 76

1 Answers1

4

As you have stated in your Post the /tmp directory is full. However, you can redirect where your temp directory is writing to.

Go into your my.cnf file and look for something like this line:

tmpdir = /tmp/

If it is not there then add:

tmpdir = /whatevr/dir/you/want

Just be sure to have space in that directory and that Mysql has write permission for the new temp directory. Then restart your Mysql server for the changes to your my.cnf file to take affect...

BK435
  • 3,076
  • 3
  • 19
  • 27