Skip to content

Archiver service fails on standby if they had a failed archive before #430

Description

@blogh

The archiver service fails on standby if they had a failed archive before
because pg_walfile_name() cannot run on a standby and returns :

ERROR:  recovery is in progress                             
HINT:  pg_walfile_name() cannot be executed during recovery.

The service could be usefull when archive mode is always but it's not designed to
do so because we use this test:

[[local]:5433 (17.10)] benoit@benoit=# SELECT current_setting('archive_mode')::bool IS TRUE;
ERROR:  invalid input syntax for type boolean: "always" 

Therefore, I propose to fail if we are in recovery.

The query: https://github.com/OPMDG/check_pgactivity/blob/master/check_pgactivity#L2108

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions