Unix Technical Forum

Switchover : WAL archiving and shutdown...

This is a discussion on Switchover : WAL archiving and shutdown... within the Pgsql General forums, part of the PostgreSQL category; --> Hi, I'm setting up switchover (to another server) with WAL/PITR. But, I'm wondering what could be the behaviour of ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > Pgsql General

Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-09-2008, 07:14 AM
Philippe Ferreira
 
Posts: n/a
Default Switchover : WAL archiving and shutdown...

Hi,

I'm setting up switchover (to another server) with WAL/PITR.

But, I'm wondering what could be the behaviour of Postgresql if you
shutdown the
service while a new WAL archive is just ready to be copied, or if the
transfer is in
progress...
Will the tranfer be canceled (until the next start), or will Postgresql
wait for the end
of the transfer before exiting ?

In other words, when I want to switchover, is it sufficient to stop
postgresql,
and rsync the last partial WAL (the last modified one), or do I have to
check if
every WAL file is in sync before starting the other server ??


Thank you in advance,
Philippe Ferreira

---------------------------(end of broadcast)---------------------------
TIP 9: In versions below 8.0, the planner will ignore your desire to
choose an index scan if your joining column's datatypes do not
match

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 04-09-2008, 07:14 AM
Stephen Frost
 
Posts: n/a
Default Re: Switchover : WAL archiving and shutdown...

* Philippe Ferreira (phil.f@worldonline.fr) wrote:
> But, I'm wondering what could be the behaviour of Postgresql if you
> shutdown the
> service while a new WAL archive is just ready to be copied, or if the
> transfer is in
> progress...
> Will the tranfer be canceled (until the next start), or will Postgresql
> wait for the end
> of the transfer before exiting ?


I'd expect the transfer to continue because it's a seperate spawned
program... I don't think it'd get a signal or be killed when the parent
shuts down but I'm not entirely sure.

> In other words, when I want to switchover, is it sufficient to stop
> postgresql,
> and rsync the last partial WAL (the last modified one), or do I have to
> check if
> every WAL file is in sync before starting the other server ??


I think you need to rsync across all of the WALs which aren't yet
archived. That could be more than 1... That's my understanding anyway.

Thanks,

Stephen

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (GNU/Linux)

iD8DBQFDj1pnrzgMPqB3kigRAv4eAJ96D2QwT9KzrfBcvJT14P 5bkP5UGwCdGFWT
x6TkHsLCVI04NOER2buB59g=
=lJ8l
-----END PGP SIGNATURE-----

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 12:47 AM.


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