diff --git a/templates/patroni.yml.j2 b/templates/patroni.yml.j2 index 5759ef3d18..1d7929722c 100644 --- a/templates/patroni.yml.j2 +++ b/templates/patroni.yml.j2 @@ -13,6 +13,10 @@ name: {{ member_name }} log: dir: {{ log_path }} + dateformat: "%Y-%m-%d %H:%M:%S %Z" + format: "%(asctime)s [%(process)d]: %(levelname)s: %(message)s " + file_num: 10080 + file_size: 600 restapi: listen: '{{ self_ip }}:8008' @@ -80,7 +84,7 @@ bootstrap: log_statement_sample_rate: 1 log_statement_stats: 'off' log_temp_files: 1 - log_timezone: 'GMT' + log_timezone: 'UTC' log_truncate_on_rotation: 'on' logging_collector: 'on' wal_level: logical diff --git a/tests/integration/ha_tests/helpers.py b/tests/integration/ha_tests/helpers.py index 8caeebac1c..e4b4010309 100644 --- a/tests/integration/ha_tests/helpers.py +++ b/tests/integration/ha_tests/helpers.py @@ -778,7 +778,7 @@ async def reused_replica_storage(ops_test: OpsTest, unit_name) -> bool: ops_test, unit_name, "grep 'Database cluster state: in archive recovery' " - "/var/snap/charmed-postgresql/common/var/log/patroni/patroni.log", + "/var/snap/charmed-postgresql/common/var/log/patroni/patroni.log*", ) return True @@ -792,6 +792,6 @@ async def reused_full_cluster_recovery_storage(ops_test: OpsTest, unit_name) -> ops_test, unit_name, "grep -E 'Database cluster state: in archive recovery|Database cluster state: shut down' " - "/var/snap/charmed-postgresql/common/var/log/patroni/patroni.log", + "/var/snap/charmed-postgresql/common/var/log/patroni/patroni.log*", ) return True