Page 1 of 1

Disk Full

Posted: Sun Sep 12, 2021 9:26 pm
by Aldo Lanfranconi
Hello, I have an old version of NagiosXI runnin on centos 6.8

I have a disk full,

Code: Select all

[root@nagiosxi ~]# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/VolGroup-lv_root
                       57G   54G     0 100% /
tmpfs                 498M     0  498M   0% /dev/shm
/dev/sda1             477M   69M  384M  16% /boot
[root@nagiosxi ~]# df -i
Filesystem            Inodes IUsed   IFree IUse% Mounted on
/dev/mapper/VolGroup-lv_root
                     3739632 94550 3645082    3% /
tmpfs                 127380     1  127379    1% /dev/shm
/dev/sda1             128016    50  127966    1% /boot
[root@nagiosxi ~]#
I have faced this problem in the past, and I follow the same instuctions:
https://support.nagios.com/forum/viewto ... 16&t=61503

but after restarting

Code: Select all

Your root / partition and filesystem have been resized
Your disk size is now 80GB,
And your / filesystem is 57GB
The results of all commands are in /var/log/vm_resize.log
It is OK, I have extended from 60gb to 80 Gb, but running again df-h still shows as full, /dev/mapper/VolGroup-lv_root have not been extended.

Please help

Re: Disk Full

Posted: Mon Sep 13, 2021 11:32 am
by tgriep
If you rebooted the server after increasing the space, let's run the commands manually to resize the drive. Post any errors if you see any. Run all of the commands in a root ssh session.

Code: Select all

pvresize /dev/sda2
lvresize /dev/mapper/VolGroup-lv_root /dev/sda2
resize2fs /dev/mapper/VolGroup-lv_root
Then check to see if the drive is resized.

Code: Select all

df -h
In not, can you run the following commands as root and post the output here?

Code: Select all

fdisk -l
vgdisplay
Below are some commands to find the largest files and directories, run them and post the output to the ticket.

Find largest 10 directories by size command:

Code: Select all

find / -regextype posix-extended -regex "/(sys|srv|proc)" -prune -o -type d -print0 | xargs -0 du | sort -n | tail -10 | cut -f2 | xargs -I{} du -sh {}
Find the largest 10 files by size command:

Code: Select all

find / -regextype posix-extended -regex "/(sys|srv|proc)" -prune -o -type f -print0 | xargs -0 du | sort -n | tail -10 | cut -f2 | xargs -I{} du -sh {}
Thank you.

Re: Disk Full

Posted: Mon Sep 20, 2021 12:48 pm
by Aldo Lanfranconi
I did retry and it works!

Re: Disk Full

Posted: Mon Sep 20, 2021 12:56 pm
by benjaminsmith
I did retry and it works!
Wonderful, glad that's working now. Did you need anything else or shall we go ahead and close this post out?