Re: Read data from WAL - Mailing list pgsql-general

From Baldur Þór Emilsson
Subject Re: Read data from WAL
Date
Msg-id CAMqGZ2y=k0P_ePEwiEbc+ynQEF4ivk4OeGMXMwi-3vO0ZkZzVQ@mail.gmail.com
Whole thread Raw
In response to Re: Read data from WAL  (Peter Geoghegan <peter.geoghegan86@gmail.com>)
Responses Re: Read data from WAL
Re: Read data from WAL
List pgsql-general
Thank you all for your responses. I'm aware of xlogdump but I'm afraid it does not help me with readign the data in the WAL. It is mainly "for debugging or educational purposes" (citing the docs) and it outputs a lot of information about the WAL records but not the contents of them (e.g. it says where an INSERT wrote the data, but not what the data is). Please correct me if I'm mistaken.

What I'm looking for is a way to read the data that is inserted into the database. I was hoping there was some known way of doing that to save me the time it takes to patch Postgres to do that.

Regards,
Baldur


On 15 July 2013 12:59, Peter Geoghegan <peter.geoghegan86@gmail.com> wrote:
On Mon, Jul 15, 2013 at 1:45 PM, Baldur Þór Emilsson <baldur@baldur.biz> wrote:
> Are there any projects or standard procedures for reading the data from the
> WAL to get a change log for the database (or without the WAL, using some
> other method)? I have searched for information about this quite thoroughly
> without luck, so I thought I'd try asking here before I started to patch
> Postgres :)

I think that pg_xlogdump is what you're looking for:

http://www.postgresql.org/docs/9.3/static/pgxlogdump.html

It only became available with Postgres 9.3. On prior versions, you can use:

https://github.com/snaga/xlogdump

--
Regards,
Peter Geoghegan

pgsql-general by date:

Previous
From: Haiming Zhang
Date:
Subject: Re: Update big table
Next
From: "guxiaobo1982"
Date:
Subject: Reply: Can we specify transaction level when connectting toexternal postgresql server via postgres_fdw