This page contains a few quick notes on how to cleanup old log files on a vCenter Server.

First, we have identified that the Log disk is full by logging on the vCenter Server VAMI
(https://FQDN-of-vcenter:5480) as shown in the following figure.

Hard disk 5 (log) is 96,8% full on the vCenter Server

You can also check the disk space via SSH by typing the following command:

df -h

When you are SSH connected to the vCenter Server, type the following commands to remove old log files:

cd /storage/log/vmware/sso/tomcat/
ls -lha localhost_access*
rm localhost_access*

cd /storage/log/vmware/eam/web/
ls -lha localhost_access*
rm localhost_access*

cd /storage/log/vmware/lookupsvc/tomcat/
ls -lha localhost_access*
rm localhost_access*

cd /var/log/vmware/vmware-sps
ls -lha sps-access*log
rm sps-access*log

Navigate back to the vCenter Server VAMI and verify that your Log disk has sufficient capacity now.
If this did not solve your problem you can try to use the following commands to identify the largest capacity consumers:

# Check the 20 largest files in /storage/log
du -a /storage/log/ | sort -n -r | head -n 20

# Find all files larger than 100 MB
find ./ -type f -size +100M |less

Usefull links

Loading

By Marc Roeleveld

VCDX-DCV #299 | Cloud Architect | Owner at Roeleveld Cloud Services

Leave a Reply

Your email address will not be published. Required fields are marked *