No Space Left on the Device Warning
PreviousPostgreSQL Database not Starting due to Replication Checkpoint ErrorNextRKE2 Kubernetes Cluster not Starting due to ETCD Quorum Loss
Last updated
Was this helpful?
This guide is to resolve Storage Issues caused by the NFS server on a node.
You can configure logrotate to handle log rotation on an hourly basis to manage storage issues caused by excessive log files.
Below are the step-by-step instructions for modifying the logrotate configuration.
Open the rsyslog logrotate configuration file in a text editor.
sudo vim /etc/logrotate.d/rsyslogModify the configuration to set up hourly rotation.
Change the rotate directive to 6.
rotate 6
Change the weekly directive to hourly.
hourly
Add the maxsize directive if it is not already present.
maxsize 0
Test the configuration to ensure there are no syntax errors.
sudo logrotate -d /etc/logrotate.confOpen the logrotate timer configuration file in a text editor.
sudo nano /lib/systemd/system/logrotate.timerModify the timer to trigger log rotation hourly.
Change OnCalendar=daily to OnCalendar=hourly
Restart the logrotate.timer to apply the changes.
sudo systemctl daemon-reload
sudo systemctl restart logrotate.timerIf needed, clear other log files using the following commands to free up more storage.
sudo rm -f /var/log/*.gz /var/log/*.1 /var/log/*.oldLast updated
Was this helpful?
Was this helpful?