Wednesday, 6 May 2015

No space left on device...

Today I ran into something curious, that I saw a few weeks ago on a training that I gave: the root filesystem  ran full (Oracle Linux 6). At first I did not find anything that caused the problem, but the command 'df -k' indeed suggested a full root filesystem. Using 'du -sh /home/oracle' we found that that folder consumed an unreasonable amount of space. In my case today I found the same. It turns out that there are 2 hidden files that were the problem:

[oracle@darlin-vce-soa ~]$ ls -al
-rw-------.  1 oracle oinstall 4488290304 May  6 16:09 .xsession-errors
-rw-------.  1 oracle oinstall      19752 May  4 16:47 .xsession-errors.old
[oracle@darlin-vce-soa ~]$ rm -rf .xsession-errors
[oracle@darlin-vce-soa ~]$ rm -rf .xsession-errors.old 
As you can see the .xsession-errors file is terribly large, in the training we found that it was the .old file. Actually it turns out that these files are rolling errors-logs of the output of applications that use a graphical interface. In this case it logs amongst others the output of JDeveloper, and my grow very large due to java-exceptions. So in case of a regular exception raised by JDeveloper, you might want to keep these files 'in the eye'.

You can savely remove those files, to save up space. But if they have grown that big, you might want to tail those to see what causes the problems.

Another tip might be to remove old kernels: when upgrading to a new kernel, Oracle Linux keeps the old kernel files. You can find a description to remove those here.

No comments :