3.1.26 Ensure 'log_timezone' is set correctly

Information

The log_timezone setting specifies the time zone to use in timestamps within log messages. This value is cluster-wide, so that all sessions will report timestamps consistently. Unless directed otherwise by your organization's logging policy, set this to either GMT or UTC.

Rationale:

Log entry timestamps should be configured for an appropriate time zone as defined by your organization's logging policy to ensure a lack of confusion around when a logged event occurred.

Note that this setting affects only the timestamps present in the logs. It does not affect the time zone in use by the database itself (for example, select now()), nor does it affect the host's time zone.

Solution

Execute the following SQL statement(s) to remediate this setting:

postgres=# alter system set log_timezone = 'GMT';
ALTER SYSTEM
postgres=# select pg_reload_conf();
pg_reload_conf
----------------
t
(1 row)

Default Value:

By default, the PGDG packages will set this to match the server's timezone in the Operating System.

See Also

https://workbench.cisecurity.org/benchmarks/17004

Item Details

Category: AUDIT AND ACCOUNTABILITY

References: 800-53|AU-3, 800-53|AU-3(1), 800-53|AU-7, 800-53|AU-12, CSCv7|6.3

Plugin: PostgreSQLDB

Control ID: 43858cf9be430a5c64c31722f4b7867fdd1a204f39951523434721762a3a01d1