Re: Feature request -- Log Database Name

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Robert Treat <xzilla(at)users(dot)sourceforge(dot)net>
Cc: ohp(at)pyrenet(dot)fr, Larry Rosenman <ler(at)lerctr(dot)org>, Josh Berkus <josh(at)agliodbs(dot)com>, pgsql-hackers list <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Feature request -- Log Database Name
Date: 2003-07-29 01:39:23
Message-ID: 17252.1059442763@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Robert Treat <xzilla(at)users(dot)sourceforge(dot)net> writes:
> I think better would be a GUC "log_to_table" which wrote all standard
> out/err to a pg_log table. of course, I doubt you could make this
> foolproof (how to log startup errors in this table?) but it could be a
> start.

How would a failed transaction make any entries in such a table? How
would you handle maintenance operations on the table that require
exclusive lock? (vacuum full, reindex, etc)

It seems possible that you could make this work if you piped stderr to a
buffering process that was itself a database client, and issued INSERTs
to put the rows into the table, and could buffer pending data whenever
someone else had the table locked (eg for vacuum). I'd not care to try
to get backends to do it locally.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Shridhar Daithankar 2003-07-29 08:57:44 Re: Doubt w.r.t vacuum
Previous Message Bruce Momjian 2003-07-29 00:57:02 Re: Regression test failure date.