Linux Running Out Of Space Quote Disk Full

even if you might have enough disk space on linux you might get this error message
when you run out of inodes. inodes store information about files and on some systems like VPS they are limited. you will have to delete the files taking up inode space.

to check free inodes use

df -ih

here is a very good link explaining how to do that:

http://www.ivankuznetsov.com/2010/02/no-space-left-on-device-running-out-of-inodes.html

here how to clean php sessions

http://pim.famnit.upr.si/blog/index.php?/archives/172-Running-out-of-inodes,-no-space-left-on-device,-php-not-cleaning-sessions.html

if you are saving sessions somewhere make a cron with this:

 cd /path/to/sessions; find -cmin +24 | xargs rm

my code that i added with “crontab -e”

0 */1 * * * root  find /var/lib/php/session/ -atime +2 | xargs rm

another not so immediately obvious problem causing this is that in your PHP script you define the session timeouts too long at the start of the script and that way PHP doesnt purge those sessions automatically



This entry was posted in everyday tips. Bookmark the permalink.