No space left on device - I can't start apache, mysql or install anything.

May 11, 2016 1.4k views
Linux Commands DigitalOcean

How to fix this problem?

If I use

df -i

I receive:

Filesystem                 Inodes   IUsed  IFree IUse% Mounted on
udev                       218483     402 218081    1% /dev
tmpfs                      220126     340 219786    1% /run
/dev/disk/by-label/DOROOT 2621440 2621440      0  100% /
none                       220126       1 220125    1% /sys/fs/cgroup
none                       220126       1 220125    1% /run/lock
none                       220126       1 220125    1% /run/shm
none                       220126       1 220125    1% /run/user

If I use

df -h

Seems to be good

Filesystem                 Size  Used Avail Use% Mounted on
udev                      1005M  4.0K 1005M   1% /dev
tmpfs                      202M  340K  202M   1% /run
/dev/disk/by-label/DOROOT   40G   20G   18G  53% /
none                       4.0K     0  4.0K   0% /sys/fs/cgroup
none                       5.0M     0  5.0M   0% /run/lock
none                      1008M     0 1008M   0% /run/shm
none                       100M     0  100M   0% /run/user

How to solve "IUse - 100%" ?
Thank you!

1 Answer

df -i checks for inode usage. Inodes only represent sort of structures or objects which are written on your device, basically a metadata or pointers. Being full on Inodes usually means that you have too many files (in terms of amount, not size) written on your disk.

Perhaps you're using some application which writes too many small log files or stores the sessions data for each visitor and doesn't clean-up.

More on this issue and how to solve it/find the files can be found here - http://unix.stackexchange.com/questions/117093/find-where-inodes-are-being-used

Have another answer? Share your knowledge.