Re: How to get postmaster shut down time in postgres? - Mailing list pgsql-general

From pavan95
Subject Re: How to get postmaster shut down time in postgres?
Date
Msg-id 1528182918174-0.post@n3.nabble.com
Whole thread Raw
In response to Re: How to get postmaster shut down time in postgres?  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
Hi Tom Lane,

I'm glad that I got a reply from you. And yes you are exactly correct. I am
looking for the time that shutdown begins. 

I fulfilled my requirement by adding a piece of code before the initiation
of shutdown in the postgresql service file located in /etc/init.d folder of
my ubuntu server. It works perfectly fine and the sample output is shown as
below:

          reported                     |    shutdown_time         |          
startup_time
---------------------------------+--------------------------+----------------------------------
 2018-06-05 12:15:00.63332 | /2018-06-05 12:15:00/  | 2018-06-05
12:09:57.625046+05:30
                                            |                                 
| 2018-06-05 12:15:05.28899+05:30

In my view this work meets my requirement. Kindly suggest if it appropriate
to do like this. 

Regards,
Pavan



--
Sent from: http://www.postgresql-archive.org/PostgreSQL-general-f1843780.html


pgsql-general by date:

Previous
From: pavan95
Date:
Subject: Re: How to get postmaster shut down time in postgres?
Next
From: pavan95
Date:
Subject: Re: How to get postmaster shut down time in postgres?