Unix Technical Forum

Re: trigger run of archive_command?

This is a discussion on Re: trigger run of archive_command? within the pgsql Admins forums, part of the PostgreSQL category; --> Hi, Thomas Karcher <thkarcher@gmx.de> wrote: > Hi, > > > this one is still open when I run pg_stop_backup(), ...


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

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-10-2008, 09:18 AM
Sebastian Reitenbach
 
Posts: n/a
Default Re: trigger run of archive_command?

Hi,

Thomas Karcher <thkarcher@gmx.de> wrote:
> Hi,
>
> > this one is still open when I run pg_stop_backup(), so I want to trigger

the
> > archive_command to be sure that I don't miss anything.

>
> I guess what you want is pg_switch_xlog() (see
> http://www.postgresql.org/docs/8.2/s...ons-admin.html)

this is exactly what I am looking for
> which became available with PG 8.2 ...

unfortunately right now I am stuck to PG 8.1.4.
I hope I can manage to upgrade without too much hassle, it seems meanwhile I
have to use my workaround.

thanks a lot
Sebastian


---------------------------(end of broadcast)---------------------------
TIP 6: explain analyze is your friend

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 04-10-2008, 09:18 AM
Andreas 'ads' Scherbaum
 
Posts: n/a
Default Re: trigger run of archive_command?


Hello,

On Mon, 14 Jan 2008 17:39:34 +0100 Sebastian Reitenbach wrote:

> Thomas Karcher <thkarcher@gmx.de> wrote:
> >
> > > this one is still open when I run pg_stop_backup(), so I want to trigger
> > > the archive_command to be sure that I don't miss anything.

> >
> > I guess what you want is pg_switch_xlog() (see
> > http://www.postgresql.org/docs/8.2/s...ons-admin.html)

> this is exactly what I am looking for
> > which became available with PG 8.2 ...

> unfortunately right now I am stuck to PG 8.1.4.
> I hope I can manage to upgrade without too much hassle, it seems meanwhile I
> have to use my workaround.


a very rude hack is to produce enough changes so that PG will rotate
the logfile anyway:

CHECKPOINT;
CREATE TABLE xlog_switch AS SELECT
'0123456789ABCDE'::VARCHAR FROM generate_series(1,300000);
DROP TABLE xlog_switch;

This is a lot of overhead, but it does the job.


Kind regards

--
Andreas 'ads' Scherbaum
German PostgreSQL User Group

---------------------------(end of broadcast)---------------------------
TIP 6: explain analyze is your friend

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 06:29 PM.


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