Skip site navigation (1) Skip section navigation (2)

Re: Forcing current WAL file to be archived

From: Hannu Krosing <hannu(at)skype(dot)net>
To: Bruce Momjian <bruce(at)momjian(dot)us>
Cc: Simon Riggs <simon(at)2ndquadrant(dot)com>,PostgreSQL-development <pgsql-hackers(at)postgreSQL(dot)org>,Marko Kreen <markokr(at)gmail(dot)com>
Subject: Re: Forcing current WAL file to be archived
Date: 2006-07-25 16:05:49
Message-ID: 1153843549.2922.22.camel@localhost.localdomain (view raw or flat)
Thread:
Lists: pgsql-hackers
Ühel kenal päeval, T, 2006-07-25 kell 11:48, kirjutas Bruce Momjian:
> Hannu Krosing wrote:
> > ?hel kenal p?eval, T, 2006-07-25 kell 11:27, kirjutas Bruce Momjian:
> > > Hannu Krosing wrote:
> > > > ?hel kenal p?eval, T, 2006-07-25 kell 10:51, kirjutas Bruce Momjian:
> > > > > Where are we on these TODO items:
> > > > > 
> > > > 
> > > > >           o Add reporting of the current WAL file, perhaps as part of
> > > > >             partial log file archiving
> > > > 
> > > > It would be nice to have a function that tells both filename and offset
> > > > of current WAL file, so it would be possible to do live async streaming
> > > > of up-to-subsecond changes without too much overhead.
> > > 
> > > OK, "offset" added to TODO item.  What would the offset give us?
> > 
> > the offset returned by lseek() on the WAL file, that is the end of the
> > part of the WAL file which has actually been written to.
> 
> Sorry, I was actually asking what use the offset would be to a user.

There would be an external async process, which continuously polls the
offset and pushes everything written between the polls to slave site.

so when this process starts up it gets (file = wal00001 and
offset=10000) and it sends first 10000 bytes to slave site, at next
rountd it gets (file = wal00001 and offset=15000) and it sends bytes
10001-15000 to remote and so on. this way the slave has a lag no more
than the poll interval in usable WAL data.

-- 
----------------
Hannu Krosing
Database Architect
Skype Technologies OÜ
Akadeemia tee 21 F, Tallinn, 12618, Estonia

Skype me:  callto:hkrosing
Get Skype for free:  http://www.skype.com




In response to

pgsql-hackers by date

Next:From: Tom LaneDate: 2006-07-25 16:10:43
Subject: Re: Forcing current WAL file to be archived
Previous:From: Simon RiggsDate: 2006-07-25 16:05:36
Subject: Re: Forcing current WAL file to be archived

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group