[ADMIN] Logging

2000-11-20 Thread Anders R. Sveen
Hey, I've set my pg_options file to write log messages, but it only logs to /var/log/messages instead of /var/log/postgresql wich remains empty. Why is that and how can i change it? Maybe it's a sylog question, but beeing new to it and all i can't really figure things out. I've installed the 7

[ADMIN] logging

2004-09-30 Thread Theo Galanakis
Title: logging I'm currently logging postgres dubugging to syslogs and wanted to know if it is possible to log which database each log entry is refering to? At the moment it looks something like this : Sep 30 02:49:59 tickle postgres[31285]: [31-1] LOG:  statement: select * from content_objec

[ADMIN] logging

2002-09-25 Thread Devinder K Rajput
Hi all, I am trying to setup logging. I have updated the postgresql.conf by making the following changes: #debug_level = 0 # range 0-16 debug_level = 2 # range 0-16 #debug_print_query = false debug_print_query = true ... # Syslog # #ifdef ENABLE_SYSLOG #syslog = 0 # range 0-2 syslog = 2

[ADMIN] logging

2008-10-03 Thread Marc Fromm
We would like to log sql activity from our web pages that use postgresql databases. I read the documentation for 8.1 at postgresql.org. The postgresql.conf file under the -Where to log- section has #log_destination = 'stderr' Is stderr the default or do I need to remove the comment symbol to actu

[ADMIN] logging

2011-05-06 Thread Campbell, Lance
I currently use PostgreSQL 8.4.x. Below is a message I see in my logs. How can I display the values for $1, $2, etc. within the logs? ERROR: duplicate key value violates unique constraint "table_name_pkey" STATEMENT: insert into schema_name.table_name(field1, field2, field3, field4, f

[ADMIN] Logging access

1999-10-03 Thread Tim Holloway
I've been trying to use PostgreSQL with the Enhydra Java Servlet-based applications server. The system throws an SQL Exception stating: java.sql.SQLException: User authentication failed at postgresql.Connection.(Connection.java:229) at postgresql.Driver.connect(Driver.java:87)

Re: [ADMIN] Logging

2000-11-20 Thread Lamar Owen
"Anders R. Sveen" wrote: > I've set my pg_options file to write log messages, but it only logs to > /var/log/messages instead of /var/log/postgresql wich remains empty. > Why is that and how can i change it? Maybe it's a sylog question, but > beeing new to it and all i can't really figure things

Re: [ADMIN] logging

2004-10-01 Thread Gaetano Mendola
Theo Galanakis wrote: I'm currently logging postgres dubugging to syslogs and wanted to know if it is possible to log which database each log entry is refering to? At the moment it looks something like this : Sep 30 02:49:59 tickle postgres[31285]: [31-1] LOG: statement: select * from content_

[ADMIN] Logging question

2005-03-30 Thread Steven Erickson
Because of customer requirements, I need to log all database modifying SQL, including the data itself, to a text file. This file will be protected to prevent all but a small, select number of users from viewing because of the secure nature of the data. They also want postgres status messages (sta

[ADMIN] logging queries

2002-09-23 Thread Nick Fankhauser
Hi- I'd like to set the logging or debug level so that the text of the queries that are executed show up in the log file. It seems to me that I recall this being discussed before, but I can't find any specific references in the runtime-config portion of the docs. Can someone tell me if this is p

Re: [ADMIN] logging

2002-09-25 Thread Andrew Sullivan
On Wed, Sep 25, 2002 at 09:14:36AM -0500, Devinder K Rajput wrote: > > # Syslog > # > #ifdef ENABLE_SYSLOG > #syslog = 0 # range 0-2 > syslog = 2 # range 0-2 You've sent the logs to syslog, although some messages go to STDERR anyway. If your syslog is not configured to do something with t

Re: [ADMIN] logging

2008-10-06 Thread IJS/System - Joko
yes, remove the comment character. And further more, find my email post with subject "log_statement at postgres.conf" Regards, Joko [IT/EDP] PT. Indra Jaya Swastika Phone: +62 31 7481388 Ext 201 http://www.ijs.co.id Marc Fromm wrote: We would like to log sql activity from our web pages t

[ADMIN] Logging autovacuum

2008-12-01 Thread Kevin Kempter
Hi All; I wonder is there a way to force autovacuum events to be logged to the postgres log ? Thanks in advance -- Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-admin

[ADMIN] Logging parameters

2010-05-11 Thread Maria L. Wilson
Trying to do some modifications to the amount of logging that our postgres database server (8.4 on linux) does on our production servers and had a few questions that I hope someone would clear up. Basically - in production, it would be nice to limit some of the logging and let the dev/test dat

[ADMIN] Logging questions

2010-12-10 Thread Wells Oliver
Hello- a quick question about logging. I'm trying to set logging to the most minimal level possible. e.g. I really don't want to see the following kind of thing: 2010-12-10 09:59:40 PST FATAL: database "woliver" does not exist Because... so what? Some guy forgot to supply the DB name. I've looke

Re: [ADMIN] logging

2011-05-06 Thread Tom Lane
"Campbell, Lance" writes: > I currently use PostgreSQL 8.4.x. > Below is a message I see in my logs. How can I display the values for > $1, $2, etc. within the logs? > ERROR: duplicate key value violates unique constraint "table_name_pkey" Update to 9.0.x. There's no capability for this befo

[ADMIN] Logging issue

2011-06-15 Thread Campbell, Lance
I just upgraded to PostgreSQL 9.0.2. I was told there was a change made to logging in this version such that when a prepared statement is executed and there is an error instead of seeing $# in the SQL logs you would see the actual values. I am still seeing the $# not the values. Is there some

[ADMIN] logging issue

2012-03-06 Thread Campbell, Lance
PostgreSQL 9.1.3 I just moved our test database from PostgreSQL 9.0 to 9.1. I also changed my log settings. I am seeing every single SQL statement that PostgreSQL performs by my Java applications. Is there some way to only display the details when there is an error? I would assume yes. Bu

[ADMIN] Logging autovacuum activity

2007-06-20 Thread Ireneusz Pluta
Hello, How can I make sure that autovacuum is running, beyond believing that all autovacuum_ settings in postgresql.conf are set correctly? In the 8.1 I could see: LOG: autovacuum: processing database "test" in the log. But I can't find it in the 8.2.4. I could see some developers discussio

[ADMIN] Logging - events supported

1999-10-24 Thread Tim Holloway
Following is an updated list of the messages to be channeled by the proposed logging system. THESE AND *ONLY* THESE are slated for implementation. If you have items you want included, PLEASE LET ME KNOW! As it stands, this is a pretty minimal set. Bear in mind that the logger is NOT a debugger.

[ADMIN] Logging in postgres

2002-01-26 Thread Antony Stace
Hi Folks I want to log all of the inserts and delete that occur in a postgres database. Whats the easiest way to do this? -- Cheers Tony _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com -

Re: [ADMIN] logging queries

2002-09-23 Thread Phil Geer
- From: "Nick Fankhauser" <[EMAIL PROTECTED]> To: "pgsql-admin" <[EMAIL PROTECTED]> Sent: Monday, September 23, 2002 6:05 PM Subject: [ADMIN] logging queries > Hi- > > I'd like to set the logging or debug level so that the text of the queries &

Re: [ADMIN] logging queries

2002-09-24 Thread Gaetano Mendola
""Nick Fankhauser"" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Hi- > > I'd like to set the logging or debug level so that the text of the queries > that are executed show up in the log file. It seems to me that I recall this > being discussed before, but I

Re: [ADMIN] logging queries

2002-09-25 Thread Nick Fankhauser
Geer > Sent: Monday, September 23, 2002 7:25 PM > To: [EMAIL PROTECTED]; pgsql-admin > Subject: Re: [ADMIN] logging queries > > > Here is a link to the doc you need. > > http://www.postgresql.org/idocs/index.php?runtime-config.html#LOGGING > > DEBUG_PRINT_QUERY (boolean) >

[ADMIN] Logging PostgreSQL output

2004-07-17 Thread Joost Kraaijeveld
Hi all, I want to log all PostgreSQL's output in a seperate file. Is it possible to use the syslog system to do that or is the only way to use the stdout method? If it is possible to use the syslog system, how should I do this (I have tried several things but nothing I tried worked)? Groeten,

[ADMIN] logging SQL statements

2008-10-09 Thread c k
Is it possible to log all sql statements submitted to database server in a table in that database it self? This will be different from database logs which are written by db server. Regards, CPK

Re: [ADMIN] Logging autovacuum

2008-12-01 Thread Joshua D. Drake
On Mon, 2008-12-01 at 21:35 -0700, Kevin Kempter wrote: > > Hi All; > > I wonder is there a way to force autovacuum events to be logged to the > postgres log ? I believe they are, if you turn it up to DEBUG or DEBUG2. Joshua D. Drake > > > Thanks in advance > -- PostgreSQL Consulting,

Re: [ADMIN] Logging autovacuum

2008-12-02 Thread Alvaro Herrera
Kevin Kempter wrote: > > > Hi All; > > I wonder is there a way to force autovacuum events to be logged to the > postgres log ? See the log_autovacuum_min_duration parameter (new in 8.3) -- Alvaro Herrerahttp://www.CommandPrompt.com/ PostgreSQL Replication, Con

Re: [ADMIN] Logging parameters

2010-05-11 Thread Kevin Grittner
"Maria L. Wilson" wrote: > log_statement = 'all' # none, ddl, mod, all Try setting this to 'none'. -Kevin -- Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-admin

Re: [ADMIN] Logging parameters

2010-05-11 Thread Maria L. Wilson
thanks Kevin - will any statements resulting in errors be logged no matter how long they take? Maria- Kevin Grittner wrote: "Maria L. Wilson" wrote: log_statement = 'all' # none, ddl, mod, all Try setting this to 'none'. -Kevin

Re: [ADMIN] Logging parameters

2010-05-11 Thread Kevin Grittner
"Maria L. Wilson" wrote: > thanks Kevin - will any statements resulting in errors be logged > no matter how long they take? I believe so, but my naturally paranoid nature always has me testing such things before I roll them to production. ;-) It's always possible I misunderstood or overlook

Re: [ADMIN] Logging parameters

2010-05-11 Thread Maria L. Wilson
ok - I'll set these up on our test machine. I'm not rebooting either - just sending a reload. Kevin Grittner wrote: "Maria L. Wilson" wrote: thanks Kevin - will any statements resulting in errors be logged no matter how long they take? I believe so, but my naturally paranoid nat

Re: [ADMIN] Logging questions

2010-12-10 Thread Peter Eisentraut
On fre, 2010-12-10 at 10:01 -0800, Wells Oliver wrote: > Hello- a quick question about logging. I'm trying to set logging to the > most minimal level possible. e.g. I really don't want to see the > following kind of thing: > > 2010-12-10 09:59:40 PST FATAL: database "woliver" does not exist > >

Re: [ADMIN] logging issue

2012-03-06 Thread Jerry Sievers
"Campbell, Lance" writes: > PostgreSQL 9.1.3 > > I just moved our test database from PostgreSQL 9.0 to 9.1. I also > changed my log settings. I am seeing every single SQL statement > that PostgreSQL performs by my Java applications. Is there some way > to only display the details when there is

Re: [ADMIN] logging issue

2012-03-07 Thread Campbell, Lance
Sievers [mailto:gsiever...@comcast.net] Sent: Tuesday, March 06, 2012 3:43 PM To: Campbell, Lance Cc: pgsql-admin@postgresql.org Subject: Re: [ADMIN] logging issue "Campbell, Lance" writes: > PostgreSQL 9.1.3 > > I just moved our test database from PostgreSQL 9.0 to 9.1. I

Re: [ADMIN] Logging autovacuum activity

2007-06-20 Thread Sibte Abbas
On 6/20/07, Ireneusz Pluta <[EMAIL PROTECTED]> wrote: Hello, How can I make sure that autovacuum is running, beyond believing that all autovacuum_ settings in postgresql.conf are set correctly? In the 8.1 I could see: LOG: autovacuum: processing database "test" in the log. But I can't find i

Re: [ADMIN] Logging autovacuum activity

2007-06-20 Thread Ireneusz Pluta
Sibte Abbas napisał(a): On 6/20/07, Ireneusz Pluta <[EMAIL PROTECTED]> wrote: Hello, How can I make sure that autovacuum is running, beyond believing that all autovacuum_ settings in postgresql.conf are set correctly? In the 8.1 I could see: LOG: autovacuum: processing database "test" in

Re: [ADMIN] Logging autovacuum activity

2007-06-20 Thread Shoaib Mir
You can also use the following query to check the autovacuum activity: select last_autovacuum, last_autoanalyze from "pg_catalog"."pg_stat_all_tables" -- Shoaib Mir EnterpriseDB (www.enterprisedb.com) On 6/20/07, Ireneusz Pluta <[EMAIL PROTECTED]> wrote: Sibte Abbas napisał(a): > On 6/20/07

[ADMIN] [ADMIN} Logging - events supported

1999-10-25 Thread hal Lynch
> >Logging classes: >--- >1xz - The PostgreSQL server >2xx - User-related information >3xx - Transaction information >4xx - EXPLAIN results (???) >9xx - General system alerts >1000-1999 debugging events Is it possible that someday there will be a need for more than 99 "items" in log c

Re: [ADMIN] Logging - events supported

1999-10-27 Thread Herouth Maoz
At 20:22 +0200 on 24/10/1999, Tim Holloway wrote: > show commands > Session ID, command text > 301 - SELECT text > 302 - INSERT text > 303 - UPDATE text > 304 - DELETE text FWIW, don't forget CREATE, ALTER, DROP - DDL items in general. Nor COPY in and out, perhaps SET. Herouth -- Herouth Mao

Re: [ADMIN] Logging in postgres

2002-01-26 Thread Markus Bertheau
On Sat, 2002-01-26 at 13:30, Antony Stace wrote: > > Hi Folks > > I want to log all of the inserts and delete that occur in a postgres database. >Whats the easiest way to do this? tweak your postgresql.conf Markus Bertheau ---(end of broadcast)

Re: [ADMIN] Logging in postgres

2002-01-26 Thread Antony Stace
Thanks for the reply Markus. I have added log_connections = yes log_timestamp = true log_pid = true syslog = 2 to my postgresql.conf file but it dosent seem to have caused any logging to occur in /var/log/postgresql Anything else I need to do? > tweak your postgresql.conf > > Markus Berthe

Re: [ADMIN] Logging in postgres

2002-01-26 Thread Markus Bertheau
On Sat, 2002-01-26 at 16:12, Antony Stace wrote: > Thanks for the reply Markus. I have added > > log_connections = yes > log_timestamp = true > log_pid = true > syslog = 2 > > to my postgresql.conf file but it dosent seem to have caused any logging to occur in > > /var/log/postgresql > > Any

Re: [ADMIN] Logging in postgres

2002-01-26 Thread Antony Stace
> > > log_connections = yes > > log_timestamp = true > > log_pid = true > > syslog = 2 > > > > to my postgresql.conf file but it dosent seem to have caused any logging to occur >in > > > > /var/log/postgresql > > > > Anything else I need to do? > > add > > debug_print_query = true > I jus

Re: [ADMIN] Logging in postgres

2002-01-26 Thread Markus Bertheau
On Sat, 2002-01-26 at 16:51, Antony Stace wrote: > > > > > > log_connections = yes > > > log_timestamp = true > > > log_pid = true > > > syslog = 2 > > > > > > to my postgresql.conf file but it dosent seem to have caused any logging to >occur in > > > > > > /var/log/postgresql > > > > > > An

Re: [ADMIN] Logging in postgres

2002-01-26 Thread Tom Lane
Antony Stace <[EMAIL PROTECTED]> writes: > restarted postgres and then did a few queries in the database. But nothing > is being logged in /var/log/postgresql. Any ideas what else might be wrong? If you're not seeing any log output at all, then either: 1. Postgres is logging to postmaster's st

[ADMIN] logging time with queries

2005-02-23 Thread Anjan Dave
Hi,   I need some help on a logging situation. I am logging the stdout to a file (/var/log/pglogs) like this:   In Postgresql.conf: ** syslog = 0  # range 0-2; 0=stdout; 1=both; 2=syslog syslog_facility = 'LOCAL0' syslog_ident = 'postgres'  

[ADMIN] Logging nested function calls...

2006-01-10 Thread Mario Splivalo
Dobar dan! (Means 'good day' in Croatian) I have a postgres (plpgsql) function that calls other (plpgsql and sql) functions. Those plpgsql functions then may call other plpsql or sql functions. The 'problem' is that, in the log file, I only see the top calling function, the one that client calle

[ADMIN] Logging for psql only

2003-02-20 Thread Al Sutton
Hi, Does anyone have a solution to the following situation;   I have an application which uses postgresql as its database, I also have technicians who need to made occasional data changes using psql, is there any way to log the changes made by the technicians without logging the SQL stateme

[ADMIN] Logging: statements and users

2003-11-13 Thread ow
Hi, It appears that pgSql can be configured to log the executed statements. However, the log does not appear to contain any info about who's running the statement. Any way to change this? Thanks __ Do you Yahoo!? Protect your identity with Yahoo! Mail Addres

Re: [ADMIN] Logging PostgreSQL output

2004-07-17 Thread Tom Lane
"Joost Kraaijeveld" <[EMAIL PROTECTED]> writes: > I want to log all PostgreSQL's output in a seperate file. Is it > possible to use the syslog system to do that or is the only way to use > the stdout method? If it is possible to use the syslog system, how > should I do this (I have tried several th

Re: [ADMIN] Logging PostgreSQL output

2004-07-17 Thread Joost Kraaijeveld
Hi Gaetano Gaetano Mendola schreef: > ad that "-" char in front of your file location log This remark was what did it (all the other things allready were in place). Thanks. It is in the man pages but just as an ommission of file sync flag. Groeten, Joost Kraaijeveld Askesis B.V. Molukkenstraat

Re: [ADMIN] Logging PostgreSQL output

2004-07-20 Thread Gaetano Mendola
Joost Kraaijeveld wrote: Hi all, I want to log all PostgreSQL's output in a seperate file. Is it possible to use the syslog system to do that or is the only way to use the stdout method? If it is possible to use the syslog system, how should I do this (I have tried several things but nothing I trie

Re: [ADMIN] logging SQL statements

2008-10-10 Thread Jagadeesh
On Oct 9, 6:23 pm, [EMAIL PROTECTED] ("c k") wrote: > Is it possible to log all sql statements submitted to database server in a > table in that database it self? This will be different from database logs > which are written by db server. > Regards, > CPK I am not confident but it should be posibl

Re: [ADMIN] logging SQL statements

2008-10-10 Thread IJS/System - Joko
It's surely possible. Just enable this at postgresql.conf: log_destination = 'stderr' redirect_stderr = on And then choose what to log: log_statement = 'all' Valid values are none, ddl, mod, and all. ddl logs all data definition commands like CREATE, ALTER, and DROP commands. mod logs all ddl

[ADMIN] logging full queries separately

2013-02-22 Thread Charles Sprickman
Howdy, I've been finding that keeping full query logs is quite helpful; I started doing this to be able to run pgbadger each day to get a nice overview of what's going on with the db servers. The one huge downside to this is that the logs are so noisy, it's hard to track down errors and stats

[ADMIN] Logging query for Postgresql 8.1

2007-05-21 Thread Ritu Khetan
Hello, I have a few queries regarding logging in Posgtresql 8.1 on windows: 1) Is the -l option same as using the log_directory and log_filename attributes in postgresql.conf (assuming redirect_stderr is on). 2) Is it ok to not see the -l details in the properties of Postgres service in the

Re: [ADMIN] [ADMIN} Logging - events supported

1999-10-25 Thread Tim Holloway
hal Lynch wrote: > > > > >Logging classes: > >--- > >1xz - The PostgreSQL server > >2xx - User-related information > >3xx - Transaction information > >4xx - EXPLAIN results (???) > >9xx - General system alerts > >1000-1999 debugging events > > Is it possible that someday there will

Re: [ADMIN] [ADMIN} Logging - events supported

1999-10-25 Thread Aaron J. Seigo
On Mon, 25 Oct 1999, Tim Holloway wrote: > hal Lynch wrote: > > Is it possible that someday there will be a need for more than 99 "items" > > in log classes 1-9? > > > > hal > > > > > > Um. I hope not. I was hoping for an admin aid, not a core dump. In any event, > a log code is es

Re: [ADMIN] [ADMIN} Logging - events supported

1999-10-26 Thread Tim Holloway
"Aaron J. Seigo" wrote: > > On Mon, 25 Oct 1999, Tim Holloway wrote: > > hal Lynch wrote: > > > Is it possible that someday there will be a need for more than 99 "items" > > > in log classes 1-9? > > > > > > hal > > > > > > > > > > Um. I hope not. I was hoping for an admin aid, not a

Re: [ADMIN] Logging nested function calls...

2006-01-10 Thread hubert depesz lubaczewski
On 1/10/06, Mario Splivalo <[EMAIL PROTECTED]> wrote: The 'problem' is that, in the log file, I only see the top callingfunction, the one that client called. Is there a way to tell postgres tolog all the nested functions?smiply use:raise log '' at the beginning of your functions.will work.depes

Re: [ADMIN] Logging nested function calls...

2006-01-10 Thread codeWarrior
What about putting a "RAISE NOTICE" statement inside each of your child functions ? "Mario Splivalo" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Dobar dan! (Means 'good day' in Croatian) > > I have a postgres (plpgsql) function that calls other (plpgsql and sql) > functions. T

Re: [ADMIN] Logging: statements and users

2003-11-14 Thread Andrew Sullivan
On Wed, Nov 12, 2003 at 11:10:09PM -0800, ow wrote: > Hi, > > It appears that pgSql can be configured to log the executed statements. > However, the log does not appear to contain any info about who's running the > statement. Any way to change this? You can log the pid and log connections, and th

[ADMIN] logging a single user session

2009-03-24 Thread Kasia Tuszynska
Hi Everybody, I am convinced that this question has been posted on either the novice or admin forum but I can not find the answer - so sorry for the repeat. I would like to log (or trace) the output from a single user session, what parameters in the postgresql.conf do I set to what to achieve th

[ADMIN] Logging in with postgres remotely

2009-03-27 Thread Newbie Poster
I am trying to connect to a postgres database ona remote server using pgAdmin III, and the user postgres. According to some instructions I found in the mailing list archives, I reset the password of the postgres user, which is required before one can use that username to connect to a remote dat

[ADMIN] logging how to add timestamp

2011-06-01 Thread Campbell, Lance
Postgresql: 8.4.x How do you add a timestamp to the logs. Currently I see: ERROR: {some error message} STATEMENT: {the sql statement} Ideally I would like to have the timestamp in front of the statements. Thanks, Lance Campbell Software Architect/Project Manager/DBA Web Services at Public Affa

Re: [ADMIN] logging full queries separately

2013-02-23 Thread k...@rice.edu
On Sat, Feb 23, 2013 at 12:55:07AM -0500, Charles Sprickman wrote: > Howdy, > > I've been finding that keeping full query logs is quite helpful; I started > doing this to be able to run pgbadger each day to get a nice overview of > what's going on with the db servers. The one huge downside to t

Re: [ADMIN] logging full queries separately

2013-02-25 Thread John Rouillard
On Sat, Feb 23, 2013 at 12:55:07AM -0500, Charles Sprickman wrote: >[...] >The one huge downside to this is that the logs are so noisy, it's >hard to track down errors and stats real-time since the query logging >is so noisy. > [...] >Right now I'm considering just switching to syslog-ng or rsyslog

Re: [ADMIN] logging full queries separately

2013-02-27 Thread Charles Sprickman
On Feb 25, 2013, at 9:59 AM, John Rouillard wrote: > On Sat, Feb 23, 2013 at 12:55:07AM -0500, Charles Sprickman wrote: >> [...] >> The one huge downside to this is that the logs are so noisy, it's >> hard to track down errors and stats real-time since the query logging >> is so noisy. >> [...] >>

Re: [ADMIN] logging full queries separately

2013-02-27 Thread John Rouillard
On Wed, Feb 27, 2013 at 05:52:49AM -0500, Charles Sprickman wrote: > On Feb 25, 2013, at 9:59 AM, John Rouillard wrote: > > On Sat, Feb 23, 2013 at 12:55:07AM -0500, Charles Sprickman wrote: > >> [...] > >> The one huge downside to this is that the logs are so noisy, it's > >> hard to track down er

[ADMIN] Logging VACUUM activity in version 7.3

2003-08-28 Thread Murthy Kambhampaty
Does version 7.3 provide a way to get VACUUM activity reports in the server log (postmaster's stderr) without having them show up in the client's stderr? In 7.2, running vacuum "quiet", i.e., /usr/local/pgsql/bin/vacuumdb -U postgres -q -a -z logged vacuum activity to the server log. e.g., "DEBU

Re: [ADMIN] logging a single user session

2009-03-24 Thread Scott Marlowe
On Tue, Mar 24, 2009 at 11:43 AM, Kasia Tuszynska wrote: > Hi Everybody, > I am convinced that this question has been posted on either the novice or > admin forum but I can not find the answer - so sorry for the repeat. > > I would like to log (or trace) the output from a single user session, wha

Re: [ADMIN] Logging in with postgres remotely

2009-03-27 Thread Newbie Poster
, March 27, 2009 4:14:05 PM Subject: Re: [ADMIN] Logging in with postgres remotely Newbie Poster wrote: > Error connecting to the server: FATAL: password authentication failed > for user "postgres" Sounds like a hunt for the pgpass file is recommended: http://www.postgresql.org/

Re: [ADMIN] Logging in with postgres remotely

2009-03-29 Thread Flavio Henrique Araque Gurgel
Hi Newbie - "Newbie Poster" escreveu: Thanks for the response. I was able to get postgres user to connect to the remote database by using the 'alter user' command from within psql. However, I am unable to connect to the same server with a different user. I created a generic user called

Re: [ADMIN] Logging in with postgres remotely

2009-03-30 Thread Newbie Poster
I am fairly sure my pg_hba file is correct. Here is what I have under IP4 connections: # IPv4 local connections: hostall all 127.0.0.1/32 md5 hostall all 10.0.0.0/8 md5 Is anything else required to access the database from a different ma

Re: [ADMIN] Logging in with postgres remotely

2009-03-30 Thread Tena Sakai
Tena Sakai tsa...@gallo.ucsf.edu -Original Message- From: pgsql-admin-ow...@postgresql.org on behalf of Newbie Poster Sent: Mon 3/30/2009 4:05 PM To: PGSQL Admin Subject: Re: [ADMIN] Logging in with postgres remotely I am fairly sure my pg_hba file is correct. Here is what I have under IP4 connections

Re: [ADMIN] logging how to add timestamp

2011-06-01 Thread Ray Stell
On Wed, Jun 01, 2011 at 04:56:12PM +, Campbell, Lance wrote: > Postgresql: 8.4.x > How do you add a timestamp to the logs. Currently I see: > > ERROR: {some error message} > STATEMENT: {the sql statement} > > Ideally I would like to have the timestamp in front of the statements. > > Thanks,

[ADMIN] Logging the starting and stopping of PostgreSQL

2007-08-23 Thread Campbell, Lance
I have a script that starts PostgreSQL as a service. It uses the following command to start the database: $SU -l postgres -c "$PGENGINE/postmaster -p '$PGPORT' -D '$PGDATA' ${PGOPTS} &" >> "$PGLOG" 2>&1 < /dev/null On my production server I use a slightly different command: exec ${PGEN

[ADMIN] Logging long queries: not all get logged

2006-05-10 Thread ogjunk-pgjedan
Hi, I'm running PG 8.0.3. I'm trying to catch slow queries, so I have this in postgresql.conf: # log queries that take more than 500 ms log_min_duration_statement = 500 # in ms This does log _some_ queries that take > 500 ms to run. However, it looks like not all queries get logged!

Re: [ADMIN] Logging the starting and stopping of PostgreSQL

2007-08-23 Thread Chander Ganesan
Campbell, Lance wrote: I have a script that starts PostgreSQL as a service. It uses the following command to start the database: $SU -l postgres -c "$PGENGINE/postmaster -p '$PGPORT' -D '$PGDATA' ${PGOPTS} &" >> "$PGLOG" 2>&1 < /dev/null You do know that there is a pre-built startup sc

Re: [ADMIN] Logging the starting and stopping of PostgreSQL

2007-08-24 Thread Campbell, Lance
:[EMAIL PROTECTED] Sent: Thursday, August 23, 2007 5:00 PM To: Campbell, Lance Cc: pgsql-admin@postgresql.org Subject: Re: [ADMIN] Logging the starting and stopping of PostgreSQL Campbell, Lance wrote: I have a script that starts PostgreSQL as a service. It uses the following command to start

Re: [ADMIN] Logging long queries: not all get logged

2006-05-10 Thread Simon Riggs
On Wed, 2006-05-10 at 09:34 -0700, [EMAIL PROTECTED] wrote: > Has anyone seen this behaviour before? > Are there logging fixes in PG 8.1.3 that might address this issue? Yes and Yes. But good detective work. Sounds like it needs adding to the 8.0 docs...or would you like to put a comment on the

Re: [ADMIN] Logging long queries: not all get logged

2006-05-10 Thread Chris Browne
[EMAIL PROTECTED] writes: > Hi, > > I'm running PG 8.0.3. I'm trying to catch slow queries, so I have this in > postgresql.conf: > > # log queries that take more than 500 ms > log_min_duration_statement = 500 # in ms > > This does log _some_ queries that take > 500 ms to run. > However,

Re: [ADMIN] Logging long queries: not all get logged

2006-05-10 Thread ogjunk-pgjedan
day, May 10, 2006 3:28:02 PM Subject: Re: [ADMIN] Logging long queries: not all get logged [EMAIL PROTECTED] writes: > Hi, > > I'm running PG 8.0.3. I'm trying to catch slow queries, so I have this in > postgresql.conf: > > # log queries that take more than 500

[ADMIN] Logging just SQL commands in an SQL script format

2007-01-24 Thread Campbell, Lance
I want to log all SQL commands as an executable script file for use in performance testing. Currently there is a lot of information in the log that is generated that would not be executable. Below is an example of what I would want to see; which is just the SQL. Example of log output: Select

[ADMIN] Logging RAISE statement to a logfile aside from syslog

2002-11-03 Thread Ludwig Lim
Hi: Is there a way of logging the RAISE statements in a plpgsql function to a logfile (aside from syslog)? I noticed that all RAISE statments are only logged in the syslog. The following is a portion my current configuration related to logging: log_connection = true log_timestamp = tr

[ADMIN] Logging query durations into another table in PostgreSQL 7.4

2003-10-30 Thread Rajesh Kumar Mallah
Hi, Is it possible to log the statements and durations of executed queries into a special table for later analysis. Or capturing the logfile and parsing it the only way? In the case of latter is it possible to use syslog to pipe the lines through a program can anyone please share the config if he

Re: [ADMIN] Logging query durations into another table in PostgreSQL

2003-10-30 Thread Bruce Momjian
Rajesh Kumar Mallah wrote: > > Hi, > > Is it possible to log the statements and durations of executed > queries into a special table for later analysis. Or capturing the No table option. > logfile and parsing it the only way? In the case of latter is it > possible to use syslog to pipe the line

Re: [ADMIN] Logging just SQL commands in an SQL script format

2007-01-25 Thread Rigmor Ukuhe
Campbell, Lance wrote: I want to log all SQL commands as an executable script file for use in performance testing. Currently there is a lot of information in the log that is generated that would not be executable. Below is an example of what I would want to see; which is just the SQL. E

Re: [ADMIN] Logging just SQL commands in an SQL script format

2007-01-25 Thread Daniel Cristian Cruz
Look at pgfouine. It can extract SQL commands from log, and build a xml file to be used with tsung to generate some load testing. Kind regards... On 1/24/07, Campbell, Lance <[EMAIL PROTECTED]> wrote: I want to log all SQL commands as an executable script file for use in performance testin

Re: [ADMIN] Logging just SQL commands in an SQL script format

2007-01-25 Thread Campbell, Lance
PROTECTED] On Behalf Of Rigmor Ukuhe Sent: Thursday, January 25, 2007 7:21 AM To: pgsql-admin@postgresql.org Subject: Re: [ADMIN] Logging just SQL commands in an SQL script format Campbell, Lance wrote: > I want to log all SQL commands as an executable script file for use in > performance t

Re: [ADMIN] Logging RAISE statement to a logfile aside from syslog

2002-11-05 Thread Robert Treat
On Mon, 2002-11-04 at 01:29, Ludwig Lim wrote: > Hi: > >Is there a way of logging the RAISE statements in a > plpgsql function to a logfile (aside from syslog)? I > noticed that all RAISE statments are only logged in > the syslog. > I dont think there is any way to get just the RAISE stateme

[ADMIN] logging or debugging to report time to establish a database connection

2013-07-12 Thread Mike Broers
I was recently asked how long it takes for postgres (or in my case pgbouncer) to create a database connection and could not find a way within postgres logging or psql to report this information. I came across depesz's great article on pgbouncer utilizing tcpdump: http://www.depesz.com/2012/12/02/w

Re: [ADMIN] logging or debugging to report time to establish a database connection

2013-07-12 Thread Scott Ribe
On Jul 12, 2013, at 9:00 AM, Mike Broers wrote: > Is there something I am overlooking in postgres logging or psql client > switches that would make this information available or am I stuck with lower > level tools? Well, if you want to log how long pgbouncer takes to hand out a connection from

Re: [ADMIN] logging or debugging to report time to establish a database connection

2013-07-12 Thread Scott Ribe
BTW, just for the heck of it, I decided to try it out on my dev system (several year old 17" MacBook Pro, meaning core i7 processor), PostgreSQL 9.2, pgbouncer 1.5. So, connecting via libpq to postgres directly takes 2-3 ms, connecting to pgbouncer takes typically 70-150 us, with the occasional

Re: [ADMIN] logging or debugging to report time to establish a database connection

2013-07-12 Thread Scott Ribe
On Jul 12, 2013, at 9:59 AM, Mike Broers wrote: > Thanks, did you use tcpdump to determine that? I'm happy to learn a new tool > (to me), but wanted to make sure I wasnt overlooking something at my disposal > within postgres. When I said "connecting via libpq" I meant I inserted timers in some