From: | Jeff Janes <jeff(dot)janes(at)gmail(dot)com> |
---|---|
To: | ning chan <ninchan8328(at)gmail(dot)com> |
Cc: | "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org> |
Subject: | Re: WAL_DEBUG |
Date: | 2013-03-06 22:03:59 |
Message-ID: | CAMkU=1y-0d06y3sxeUPjML+pXOQGYXBHOToMHj6auP3uVviQOg@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Wed, Mar 6, 2013 at 1:31 PM, ning chan <ninchan8328(at)gmail(dot)com> wrote:
> Hi,
> Does anyone know how to enable WAL_DEBUG?
> I download postgresql 9.2.3 src code and compile it as follow:
>
>
> modify ./src/include/pg_config_manual.h
> /*
> * Enable debugging print statements for WAL-related operations; see
> * also the wal_debug GUC var.
> */
> #define WAL_DEBUG 4
>
>
> ./configure --without-readline --without-zlib CPPFLAGS='-DWAL_DEBUG'
>
Either one of those works for me.
>
> I don't see anything special log to the log file.
>
open running pgbench -i, I see a lot of things like this in the log, once I
set wal_debug:
STATEMENT: alter table pgbench_accounts add primary key (aid)
LOG: INSERT @ 0/18BEDC0: prev 0/18BED78; xid 1838; len 34: Btree - insert:
rel 1663/16384/12678; tid 1/8
STATEMENT: alter table pgbench_accounts add primary key (aid)
LOG: INSERT @ 0/18BEE08: prev 0/18BEDC0; xid 1838; len 52: Heap - insert:
rel 1663/16384/12765; tid 46/29
STATEMENT: alter table pgbench_accounts add primary key (aid)
LOG: INSERT @ 0/18BEE60: prev 0/18BEE08; xid 1838; len 42: Btree - insert:
rel 1663/16384/12767; tid 27/140
STATEMENT: alter table pgbench_accounts add primary key (aid)
LOG: INSERT @ 0/18BEEB0: prev 0/18BEE60; xid 1838; len 42: Btree - insert:
rel 1663/16384/12768; tid 26/14
> I even try to add a line wal_debug=number to the postgresql.conf, doesn't
> help either.
>
If I include literally "wal_debug=number", upon start up I get the
self-explanatory error:
LOG: parameter "wal_debug" requires a Boolean value
FATAL: configuration file "/tmp/data/postgresql.conf" contains errors
If I replace "number" with a valid true value ("true", "on", "1"), then I
get the above-reported WAL debugging log messages.
Cheers,
Jeff
From | Date | Subject | |
---|---|---|---|
Next Message | Dean Rasheed | 2013-03-06 22:28:18 | Re: Why does slony use a cursor? Anyone know? |
Previous Message | ning chan | 2013-03-06 21:31:31 | WAL_DEBUG |