Merge ~ines-almeida/launchpad:change-appserver-log-rotate into launchpad:master

Proposed by Ines Almeida
Status: Needs review
Proposed branch: ~ines-almeida/launchpad:change-appserver-log-rotate
Merge into: launchpad:master
Diff against target: 16 lines (+3/-2)
1 file modified
charm/launchpad-appserver/templates/logrotate.conf.j2 (+3/-2)
Reviewer Review Type Date Requested Status
Simone Pelosi Approve
Review via email: mp+464017@code.launchpad.net

Commit message

charm: update appserver logrotate from daily to hourly

Currently log files for this service can get quite heavy (in the realm of 10 Gb) which makes it impossible to live view the latest logs of a unit. Taking into account that we run 4 appserver units, debuging an issue can lead to several minutes to download the daily log files, and the launchpad-bastion disk to get unnecessarily full.
In this change, we are rotating the logs hourly, while keeping the same amount of days worth of logs on disk. This will lead to lighter log files, and less space for logs used.

Description of the change

This is currently running in qastaging (changed manually) for testing

To post a comment you must log in.
Revision history for this message
Simone Pelosi (pelpsi) wrote :

LGTM!

review: Approve

Unmerged commits

5b7bfde... by Ines Almeida

charm: update appserver logrotate from daily to hourly

Currently log files for this service can get quite heavy (in the realm of 10 Gb) which makes it impossible to live view the latest logs of a unit. Taking into account that we run 4 appserver units, debuging an issue can lead to several minutes to download the daily log files, and the launchpad-bastion disk to get unnecessarily full.
In this change, we are rotating the logs hourly, while keeping the same amount of days worth of logs on disk. This will lead to lighter log files, and less space for logs used.

Succeeded
[SUCCEEDED] docs:0 (build)
[SUCCEEDED] lint:0 (build)
[SUCCEEDED] mypy:0 (build)
13 of 3 results

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/charm/launchpad-appserver/templates/logrotate.conf.j2 b/charm/launchpad-appserver/templates/logrotate.conf.j2
2index 494f246..2714525 100644
3--- a/charm/launchpad-appserver/templates/logrotate.conf.j2
4+++ b/charm/launchpad-appserver/templates/logrotate.conf.j2
5@@ -1,8 +1,9 @@
6 {{ logs_dir }}/launchpad.log
7 {
8- rotate 21
9- daily
10+ rotate 504
11+ hourly
12 dateext
13+ dateformat -%Y%m%d-%H
14 delaycompress
15 compress
16 notifempty

Subscribers

People subscribed via source and target branches

to status/vote changes: