ca api gateway /var/log is filling and we are being alerted how can we clear space?
search cancel

ca api gateway /var/log is filling and we are being alerted how can we clear space?

book

Article ID: 277873

calendar_today

Updated On:

Products

CA API Gateway

Issue/Introduction

Monitoring is showing the /var/log partition filling its currently 80 percent and they are being alerted. They want to manually clear space.

# ls -alh /var/log shows the 3 biggest files as wtmp, secure, and messages

Environment

CA API Gateway 10.1

Resolution

The gateway has logrotate.d enabled by default but if you want to manually clear these files you can simply do the below action;

# echo > /var/log/messages

# echo > /var/log/secure

# echo > /var/log/wtmp

# ls -al /var/log (All should now have size of 1 bytes)

# reboot -n

After reboot you should note these files have grown in size and messages normally.