postgrespro.git / summary / log / commit / refs

commit    689d15e95e3509554fbc1afd231b41f4a1fee669
Author:   Peter Eisentraut <peter@eisentraut.org>
Date:     Wed Jan 30 22:26:10 2019 +0000

    Log PostgreSQL version number on startup
    
    Logging the PostgreSQL version on startup is useful for two reasons:
    There is a clear marker in the log file that a new postmaster is
    beginning, and it's useful for tracking the server version across
    startup while upgrading.
    
    Author: Christoph Berg <christoph.berg@credativ.de>
    Discussion: https://www.postgresql.org/message-id/flat/20181121144611.GJ15795@msg.credativ.de/


src/backend/postmaster/postmaster.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/backend/postmaster/postmaster.c b/src/backend/postmaster/postmaster.c index 119c01d745..40a0222220 100644 --- a/src/backend/postmaster/postmaster.c +++ b/src/backend/postmaster/postmaster.c @@ -1052,6 +1052,10 @@ PostmasterMain(int argc, char *argv[]) whereToSendOutput = DestNone; + /* Report server startup in log */ + ereport(LOG, + (errmsg("starting %s", PG_VERSION_STR))); + /* * Establish input sockets. * [parent: 57431a911d3a]