Unix Technical Forum

Re: Data Restore from WAL

This is a discussion on Re: Data Restore from WAL within the pgsql Hackers forums, part of the PostgreSQL category; --> Vishal Arora wrote: > I would like to know how the data is been read from WAL file. If ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > pgsql Hackers

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-12-2008, 08:17 AM
Heikki Linnakangas
 
Posts: n/a
Default Re: Data Restore from WAL

Vishal Arora wrote:
> I would like to know how the data is been read from WAL file. If anyone
> can help me with the WAL file structure. What are the basic functions
> used by a pg_restore call.


pg_restore has nothing to do with WAL.

AFAIK the best description of the WAL file structure is in the comments
in the source code. I'd suggest starting by reading the header files
under src/include/access/xlog.h and src/include/access/xlog_utils.h, and
the source file in src/backend/access/transam/xlog.c.

Basically each file in pg_xlog (aka WAL segment) is divided into fixed
size pages, and pages are filled with WAL records.

For more information on the internals of pg_restore, look at the
corresponding source and header files in src/bin/pg_dump.

Mind you, both the WAL file format and the binary pg_dump/pg_restore
file format are internal to PostgreSQL, and not designed to be readable
by external applications. The format can also change between releases.

--
Heikki Linnakangas
EnterpriseDB http://www.enterprisedb.com

---------------------------(end of broadcast)---------------------------
TIP 7: You can help support the PostgreSQL project by donating at

http://www.postgresql.org/about/donate

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 02:38 PM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com