Re: postgres uptime - Mailing list pgsql-hackers

From Gaetano Mendola
Subject Re: postgres uptime
Date
Msg-id 412719D1.3030204@bigfoot.com
Whole thread Raw
In response to Re: postgres uptime  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Tom Lane wrote:
| Gaetano Mendola <mendola@bigfoot.com> writes:
|
|>>I think we should just call gettimeofday() at postmaster start and store
|>>it somewhere.
|
|
|>Isn't the shared memory a good place ?
|
|
| Depends.  Do you want to reset it during a backend-crash-recovery cycle?
| You'll have to, if it's only stored in shared memory.  Depending on what
| your definition of "uptime" is, that could be a reasonable thing to do,
| or not.
|
| There's been a remarkable lack of discussion about exactly what this
| number would mean, anyway.  Does "postmaster start" mean postmaster
| process start?  Or when we are first ready to receive a connection?
| There could be a *very* large difference, in the case of a hot-standby
| postmaster.

Speaking of my needs I wish to have the time when the server was able to
accept connections and if the backend do a crash-recovery cicle we can have
a GUC, similar to statistics reset, in order to have an uptime reset
or not.


Regards
Gaetano Mendola


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (MingW32)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFBJxnQ7UpzwH2SGd4RAoi6AJ4sm64TNT8SCGvkoaEaN9f82RFS4wCgiq0L
MrCYrpKNA7AKT1k+jRoypgQ=
=ezvn
-----END PGP SIGNATURE-----



pgsql-hackers by date:

Previous
From: "Andrew Dunstan"
Date:
Subject: Re: pg_hba.conf and Solaris
Next
From: Joe Conway
Date:
Subject: Re: repeatable system index corruption on 7.4.2 (SOLVED)