Skip to content

Commit 8170ec5

Browse files
widorohityadavcloud
authored andcommitted
kvm: Logrotate should not touch agent.log (apache#3597)
Logrotate should only touch security_group.log and resizevolume.log as the agent.log is already rotated by log4j inside the Agent. Having two systems trying to rotate agent.log leads to all kinds of issues like having binary (compressed) data in the middle of a plain-text log file. In addition we do not have to rotate the logs every day, only when they grow larger than 10M. On fairly idle hypervisors this should not cause those logs to rotate every day. Signed-off-by: Wido den Hollander <wido@widodh.nl>
1 parent 89053c7 commit 8170ec5

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

agent/conf/cloudstack-agent.logrotate.in

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,11 @@
1515
# specific language governing permissions and limitations
1616
# under the License.
1717

18-
@AGENTLOG@
19-
/var/log/cloudstack/agent/security_group.log
20-
{
18+
/var/log/cloudstack/agent/security_group.log /var/log/cloudstack/agent/resizevolume.log {
2119
copytruncate
2220
daily
2321
rotate 5
2422
compress
2523
missingok
24+
size 10M
2625
}

0 commit comments

Comments
 (0)