Re: postgres uptime

From: Gaetano Mendola <mendola(at)bigfoot(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: postgres uptime
Date: 2004-08-21 09:45:53
Message-ID: 412719D1.3030204@bigfoot.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Tom Lane wrote:
| Gaetano Mendola <mendola(at)bigfoot(dot)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-----

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Joe Conway 2004-08-21 11:32:09 Re: repeatable system index corruption on 7.4.2 (SOLVED)
Previous Message Andrew Dunstan 2004-08-21 08:23:19 Re: pg_hba.conf and Solaris