CentOS partition reporting out of space

Posted on

CentOS partition reporting out of space – Managing your servers can streamline the performance of your team by allowing them to complete complex tasks faster. Plus, it can enable them to detect problems early on before they get out of hand and compromise your business. As a result, the risk of experiencing operational setbacks is drastically lower.

But the only way to make the most of your server management is to perform it correctly. And to help you do so, this article will share nine tips on improving your server management and fix some problem about linux, centos, lvm, partition, .

I have CentOS server with 7 partitions and 2 of them are LVM partitions one is divided as 2 LVM partitions. While working with the production software the disk suddenly gets full in a folder that is stored in one of the LVM partitions that are together in one of the 7 normal partitions. My / partition is only 40G while the /somedir LVM partition is 250G of space, why is the system reporting disk full when the files in the LVM partition grow near the size of the / partition??

the df -h command throws:

/dev/sda2              39G  6,9G   30G  19% /
tmpfs                 3,9G  1,4M  3,9G   1% /dev/shm
                      247G  172G   63G  74% /backups
/dev/sda1             485M  310M  151M  68% /boot
                      386G  3,4G  363G   1% /home
/dev/sda5              14G   36M   13G   1% /tmp
                      247G   30G  205G  13% /usr1   2,0T  249G  1,8T  13% /mnt/SATANAS
                      233G   57G  177G  25% /mnt/Fiscaldir
                       96G   44G   53G  46% /media/Catalogos
                       98G   42G   51G  46% /mnt/Reportes
/dev/sdb1             3,7T   31G  3,7T   1% /media/Seagate Backup Plus Drive

sorry it was not formatted before

Solution :

  • First try to figure out if there is any error in the partition using “dmesg” command. If you find any error, and if you are not much familiar to fix the issue, a simple reboot may fix the issue.

  • If it is truly a inode related issue, you may reduce your reserved space. It will give some space and also inode as well. (though it is not recommended for production environment. As soon as possible revert it back to 2% or 3%).

    tune2fs -m 0 /dev/sda1
    tune2fs 1.41.12 (17-May-2010)
    Setting reserved blocks percentage to 0% (0 blocks)
  • Find zero sized or unused files using find command and remove it after analyzing the files.

  • If possible take backup of the entire file system and create filesystem again using the command,

    mkfs.ext4 -i </dev/destination>

to specify the number of inodes and then restore the original contents into this.

I believe you’ve run out of inodes on the partition.
If you do df -i you will probably find the inode usage is 100%.

Leave a Reply

Your email address will not be published.