Last active 6 months ago

此 Bash 腳本用於強制執行 Logrotate,立即處理系統日誌檔案的輪替,保持日誌管理的有效性。

timmy revised this gist 6 months ago. Go to revision

No changes

timmy revised this gist 6 months ago. Go to revision

1 file changed, 3 insertions

force_logrotate.sh(file created)

@@ -0,0 +1,3 @@
1 + #!/bin/bash
2 + # sudo logrotate -d /etc/logrotate.conf # 只測試,不真的動手
3 + sudo logrotate -f /etc/logrotate.conf # 強制馬上執行一次
Newer Older