Re: [HACKERS] syslog_line_prefix

2009-09-28 Thread Andrew Dunstan
Tom Lane wrote: Andrew Dunstan writes: Alvaro Herrera wrote: syslog uses a nonblocking file descriptor without a retry loop to implement their logic. I see no reason we couldn't do that ourselves. Mixing it with regular blocking code could turn out to be nontrivial, but I don't thin

Re: [HACKERS] syslog_line_prefix

2009-09-28 Thread Tom Lane
Andrew Dunstan writes: > Alvaro Herrera wrote: >> syslog uses a nonblocking file descriptor without a retry loop to >> implement their logic. I see no reason we couldn't do that ourselves. >> Mixing it with regular blocking code could turn out to be nontrivial, >> but I don't think it's impossibl

Re: [HACKERS] syslog_line_prefix

2009-09-28 Thread Andrew Dunstan
Alvaro Herrera wrote: Tom Lane escribió: Alvaro Herrera writes: Tom Lane escribió: This is the same issue already raised with respect to syslog versus syslogger, ie, some people would rather lose log data than have the backends block waiting for it to be written. Th

Re: [HACKERS] syslog_line_prefix

2009-09-28 Thread Alvaro Herrera
Tom Lane escribió: > Alvaro Herrera writes: > > Tom Lane escribió: > >> This is the same issue already raised with respect to syslog versus > >> syslogger, ie, some people would rather lose log data than have the > >> backends block waiting for it to be written. > > > That could be made configura

Re: [HACKERS] syslog_line_prefix

2009-09-28 Thread Robert Haas
On Mon, Sep 28, 2009 at 2:13 PM, Alvaro Herrera wrote: > Robert Haas escribió: >> On Mon, Sep 28, 2009 at 1:07 PM, Alvaro Herrera >> wrote: >> > Tom Lane escribió: >> >> [ please trim the quoted material a bit, folks ] >> >> >> >> Magnus Hagander writes: >> >> > 2009/9/28 Robert Haas : >> >> >>

Re: [HACKERS] syslog_line_prefix

2009-09-28 Thread Alvaro Herrera
Robert Haas escribió: > On Mon, Sep 28, 2009 at 1:07 PM, Alvaro Herrera > wrote: > > Tom Lane escribió: > >> [ please trim the quoted material a bit, folks ] > >> > >> Magnus Hagander writes: > >> > 2009/9/28 Robert Haas : > >> >> The problem with having the syslogger send the data directly to an

Re: [HACKERS] syslog_line_prefix

2009-09-28 Thread Tom Lane
Alvaro Herrera writes: > Tom Lane escribió: >> This is the same issue already raised with respect to syslog versus >> syslogger, ie, some people would rather lose log data than have the >> backends block waiting for it to be written. > That could be made configurable; i.e. let the user choose wh

Re: [HACKERS] syslog_line_prefix

2009-09-28 Thread Robert Haas
On Mon, Sep 28, 2009 at 1:07 PM, Alvaro Herrera wrote: > Tom Lane escribió: >> [ please trim the quoted material a bit, folks ] >> >> Magnus Hagander writes: >> > 2009/9/28 Robert Haas : >> >> The problem with having the syslogger send the data directly to an >> >> external process is that the ex

Re: [HACKERS] syslog_line_prefix

2009-09-28 Thread Alvaro Herrera
Tom Lane escribió: > [ please trim the quoted material a bit, folks ] > > Magnus Hagander writes: > > 2009/9/28 Robert Haas : > >> The problem with having the syslogger send the data directly to an > >> external process is that the external process might be unable to > >> process the data as fast

Re: [HACKERS] syslog_line_prefix

2009-09-28 Thread Tom Lane
[ please trim the quoted material a bit, folks ] Magnus Hagander writes: > 2009/9/28 Robert Haas : >> The problem with having the syslogger send the data directly to an >> external process is that the external process might be unable to >> process the data as fast as syslogger is sending it.  I'm

Re: [HACKERS] syslog_line_prefix

2009-09-28 Thread Robert Haas
On Mon, Sep 28, 2009 at 6:51 AM, Magnus Hagander wrote: >> I think it's better to spool the log messages to files, and then let >> the external utility read the files.  The external utility can still >> fall behind, but even if it does the cluster will continue running. > > The difficulty there is

Re: [HACKERS] syslog_line_prefix

2009-09-28 Thread Magnus Hagander
2009/9/28 Robert Haas : > On Mon, Sep 28, 2009 at 5:22 AM, Magnus Hagander wrote: >> On Sun, Sep 27, 2009 at 23:03, Robert Haas wrote: >>> On Sun, Sep 27, 2009 at 4:54 PM, Peter Eisentraut wrote: On Sun, 2009-09-27 at 16:15 -0400, Tom Lane wrote: > Peter Eisentraut writes: > > Then

Re: [HACKERS] syslog_line_prefix

2009-09-28 Thread Robert Haas
On Mon, Sep 28, 2009 at 5:22 AM, Magnus Hagander wrote: > On Sun, Sep 27, 2009 at 23:03, Robert Haas wrote: >> On Sun, Sep 27, 2009 at 4:54 PM, Peter Eisentraut wrote: >>> On Sun, 2009-09-27 at 16:15 -0400, Tom Lane wrote: Peter Eisentraut writes: > Then why not send everything to sys

Re: [HACKERS] syslog_line_prefix

2009-09-28 Thread Magnus Hagander
On Sun, Sep 27, 2009 at 23:03, Robert Haas wrote: > On Sun, Sep 27, 2009 at 4:54 PM, Peter Eisentraut wrote: >> On Sun, 2009-09-27 at 16:15 -0400, Tom Lane wrote: >>> Peter Eisentraut writes: >>> > Then why not send everything to syslog and have syslog filter it to the >>> > places you want to?

Re: [HACKERS] syslog_line_prefix

2009-09-27 Thread Robert Haas
On Sun, Sep 27, 2009 at 4:54 PM, Peter Eisentraut wrote: > On Sun, 2009-09-27 at 16:15 -0400, Tom Lane wrote: >> Peter Eisentraut writes: >> > Then why not send everything to syslog and have syslog filter it to the >> > places you want to?  That is what syslog is for, after all. >> >> We send all

Re: [HACKERS] syslog_line_prefix

2009-09-27 Thread Peter Eisentraut
On Sun, 2009-09-27 at 16:15 -0400, Tom Lane wrote: > Peter Eisentraut writes: > > Then why not send everything to syslog and have syslog filter it to the > > places you want to? That is what syslog is for, after all. > > We send all syslog output with the same identifier/priority/facility, > so

Re: [HACKERS] syslog_line_prefix

2009-09-27 Thread Tom Lane
Peter Eisentraut writes: > On Fri, 2009-09-25 at 14:58 -0600, Joshua Tolley wrote: >> Actually the thing I want is to be able to send some stuff to syslog, >> and some to a file, and other stuff to another file. This patch >> doesn't do all that, but lays the necessary groundwork. > Then why not

Re: [HACKERS] syslog_line_prefix

2009-09-27 Thread Peter Eisentraut
On Fri, 2009-09-25 at 14:58 -0600, Joshua Tolley wrote: > Actually the thing I want is to be able to send some stuff to syslog, > and some > to a file, and other stuff to another file. This patch doesn't do all > that, > but lays the necessary groundwork. Then why not send everything to syslog and

Re: [HACKERS] syslog_line_prefix

2009-09-26 Thread Tom Lane
Robert Haas writes: > I also agree with Tom's comments that we don't have consensus on where > this should go. I think it would help a lot if someone put together a > design document (perhaps on the wiki) and tried to enumerate at a high > level the logging requirements that aren't being satisfie

Re: [HACKERS] syslog_line_prefix

2009-09-26 Thread Robert Haas
On Fri, Sep 25, 2009 at 6:12 PM, Andrew Dunstan wrote: > Tom Lane wrote: >> Joshua Tolley writes: >>> Having just sent two messages to the discussion about the wrong patch, >>> I'll >>> apologize, and shut up now :) >> >> No need to apologize --- this really is, and should be, all one >> conversa

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Andrew Dunstan
Tom Lane wrote: Joshua Tolley writes: Having just sent two messages to the discussion about the wrong patch, I'll apologize, and shut up now :) No need to apologize --- this really is, and should be, all one conversation. I think the main problem I've got with applying either patch

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Tom Lane
Joshua Tolley writes: > Having just sent two messages to the discussion about the wrong patch, I'll > apologize, and shut up now :) No need to apologize --- this really is, and should be, all one conversation. I think the main problem I've got with applying either patch is that I don't believe w

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Joshua Tolley
On Fri, Sep 25, 2009 at 05:04:45PM -0400, Robert Haas wrote: > On Fri, Sep 25, 2009 at 4:58 PM, Joshua Tolley wrote: > > On Fri, Sep 25, 2009 at 03:19:36PM -0400, Tom Lane wrote: > >> However, I don't think I actually believe the premise of this patch, > >> which is that sending log information to

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Robert Haas
On Fri, Sep 25, 2009 at 5:27 PM, Joshua Tolley wrote: > On Fri, Sep 25, 2009 at 04:18:08PM -0400, Robert Haas wrote: >> > I would even more like to have some things send to CSV and some things >> > sent to text. >> >> This patch won't help, then. > > No, it won't, but as said before, it lays the g

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Joshua Tolley
On Fri, Sep 25, 2009 at 05:04:45PM -0400, Robert Haas wrote: > On Fri, Sep 25, 2009 at 4:58 PM, Joshua Tolley wrote: > > On Fri, Sep 25, 2009 at 03:19:36PM -0400, Tom Lane wrote: > >> However, I don't think I actually believe the premise of this patch, > >> which is that sending log information to

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Robert Haas
On Fri, Sep 25, 2009 at 5:01 PM, Magnus Hagander wrote: > On Fri, Sep 25, 2009 at 22:57, Andrew Dunstan wrote: >> >> Magnus Hagander wrote: >>> >>> On Fri, Sep 25, 2009 at 22:17, Andrew Dunstan wrote: >>> Magnus Hagander wrote: > > I definitely want both text and CSV outpu

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Joshua Tolley
On Fri, Sep 25, 2009 at 04:18:08PM -0400, Robert Haas wrote: > > I would even more like to have some things send to CSV and some things > > sent to text. > > This patch won't help, then. No, it won't, but as said before, it lays the groundwork, namely letting the syslogger know things about the l

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Magnus Hagander
On Fri, Sep 25, 2009 at 22:57, Andrew Dunstan wrote: > > Magnus Hagander wrote: >> >> On Fri, Sep 25, 2009 at 22:17, Andrew Dunstan wrote: >> >>> >>> Magnus Hagander wrote: >>> I definitely want both text and CSV output - which I can't have today. >>> >>> Sure you can. What makes y

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Robert Haas
On Fri, Sep 25, 2009 at 4:58 PM, Joshua Tolley wrote: > On Fri, Sep 25, 2009 at 03:19:36PM -0400, Tom Lane wrote: >> However, I don't think I actually believe the premise of this patch, >> which is that sending log information to both stderr and syslog is >> a useful thing to do > > Actually the t

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Robert Haas
On Fri, Sep 25, 2009 at 4:33 PM, Magnus Hagander wrote: > On Fri, Sep 25, 2009 at 22:18, Robert Haas wrote: >> On Fri, Sep 25, 2009 at 4:06 PM, Magnus Hagander wrote: >>> Other than if you're logging all your queries (or over time, where >>> is very small), I've never seen a system with perfor

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Joshua Tolley
On Fri, Sep 25, 2009 at 03:19:36PM -0400, Tom Lane wrote: > However, I don't think I actually believe the premise of this patch, > which is that sending log information to both stderr and syslog is > a useful thing to do Actually the thing I want is to be able to send some stuff to syslog, and som

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Andrew Dunstan
Magnus Hagander wrote: On Fri, Sep 25, 2009 at 22:17, Andrew Dunstan wrote: Magnus Hagander wrote: I definitely want both text and CSV output - which I can't have today. Sure you can. What makes you think you can't? How do i do that? When I enable csv logging, it cha

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Magnus Hagander
On Fri, Sep 25, 2009 at 22:18, Robert Haas wrote: > On Fri, Sep 25, 2009 at 4:06 PM, Magnus Hagander wrote: >> Other than if you're logging all your queries (or over time, where >> is very small), I've never seen a system with performance issues >> from logging. I'm sure others may have, but no

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Magnus Hagander
On Fri, Sep 25, 2009 at 22:17, Andrew Dunstan wrote: > > > Magnus Hagander wrote: >> >> I definitely want both text and CSV output - which I can't have today. >> >> > > Sure you can. What makes you think you can't? How do i do that? When I enable csv logging, it changes the log format to csv, and

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Robert Haas
On Fri, Sep 25, 2009 at 4:06 PM, Magnus Hagander wrote: > On Fri, Sep 25, 2009 at 21:19, Tom Lane wrote: >> "Joshua D. Drake" writes: >>> On Mon, 2009-09-14 at 09:43 +0900, Itagaki Takahiro wrote: We have a tip that log_line_prefix is not required for syslog in the documentation, but w

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Andrew Dunstan
Magnus Hagander wrote: I definitely want both text and CSV output - which I can't have today. Sure you can. What makes you think you can't? cheers andrew -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.or

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Magnus Hagander
On Fri, Sep 25, 2009 at 21:19, Tom Lane wrote: > "Joshua D. Drake" writes: >> On Mon, 2009-09-14 at 09:43 +0900, Itagaki Takahiro wrote: >>> We have a tip that log_line_prefix is not required for syslog >>> in the documentation, but we'd better to have independent setttings >>> if we set log_dest

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Tom Lane
"Joshua D. Drake" writes: > On Mon, 2009-09-14 at 09:43 +0900, Itagaki Takahiro wrote: >> We have a tip that log_line_prefix is not required for syslog >> in the documentation, but we'd better to have independent setttings >> if we set log_destination to 'stderr, syslog'. > IMO we should just mak

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Joshua D. Drake
On Mon, 2009-09-14 at 09:43 +0900, Itagaki Takahiro wrote: > Here is a patch to add a GUC parameter "syslog_line_prefix". > It adds prefixes to syslog and eventlog. We still have > "log_line_prefix", that will be used only for stderr logs. > > We have a tip that log_line_prefix is not required for

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Robert Haas
On Fri, Sep 25, 2009 at 12:13 PM, Alvaro Herrera wrote: > Robert Haas escribió: > >> On the other hand, I don't think this is the right way to do it.  The >> patch proposes the following mapping of logging destinations to GUCs: >> >> stderr -> log_line_prefix (same as now) >> csvlog -> not applica

Re: [HACKERS] syslog_line_prefix

2009-09-25 Thread Alvaro Herrera
Robert Haas escribió: > On the other hand, I don't think this is the right way to do it. The > patch proposes the following mapping of logging destinations to GUCs: > > stderr -> log_line_prefix (same as now) > csvlog -> not applicable (same as now) > syslog -> syslog_line_prefix > eventlog -> s

Re: [HACKERS] syslog_line_prefix

2009-09-24 Thread Robert Haas
On Tue, Sep 15, 2009 at 2:18 PM, Alvaro Herrera wrote: > Magnus Hagander wrote: > >> I'm not sure I like this as a GUC. We're going to end up with a lot of >> different GUCs, and everytime we add a new log destination (admittedly >> not often, of course), that increases even further. And GUCs real

Re: [HACKERS] syslog_line_prefix

2009-09-15 Thread Alvaro Herrera
Magnus Hagander wrote: > I'm not sure I like this as a GUC. We're going to end up with a lot of > different GUCs, and everytime we add a new log destination (admittedly > not often, of course), that increases even further. And GUCs really > don't provide the level of flexibility you'd really like

Re: [HACKERS] syslog_line_prefix

2009-09-14 Thread Magnus Hagander
On Mon, Sep 14, 2009 at 02:43, Itagaki Takahiro wrote: > Here is a patch to add a GUC parameter "syslog_line_prefix". > It adds prefixes to syslog and eventlog. We still have > "log_line_prefix", that will be used only for stderr logs. > > We have a tip that log_line_prefix is not required for sys

[HACKERS] syslog_line_prefix

2009-09-13 Thread Itagaki Takahiro
Here is a patch to add a GUC parameter "syslog_line_prefix". It adds prefixes to syslog and eventlog. We still have "log_line_prefix", that will be used only for stderr logs. We have a tip that log_line_prefix is not required for syslog in the documentation, but we'd better to have independent set