turn pitr 'on' on PostgreSQL 8.2 - pg_standby

--_000_7965A9DCF12CC14984420BCC37B1608F25ABF310ABElzargrantc ou_
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

Dear all,

I have been playing with PITR on version 8.3 so far, but I need to get it w=
orking on version 8.2.

What is the difference between:

archive_command =3D on (is this command for 8.2?)
archive_mode =3D on (This one is for 8.3!)

I need to enable 'archive_mode =3D on', restart postgres, before I can do t=
he base backup, is that correct?

In order to bring the standby online I need a trigger file, something like:
can I call the trigger file whatever I want? for example; '/var/log/postgre=
s/postgresql.8.2.trigger'

Postgres 8.2 config

Master:
Postgresql.conf
archive_command =3D on
archive_command =3D 'cp -i %p /mnt/pitr/%f </dev/null'
archive_timeout =3D 60

# mkdir /mnt/pitr
# chown postgres: /mnt/pitr (this will be an NFS mount point)
# mount -t nfs fnsserver01:/pitr /mnt/pitr
# service postgresql restart
# su - postgres
# psql -U postgres
SELECT pg_start_backup('pitr_backup');
\q
# Tar -cvf pg_data.tar /usr/loca/pgsql/data
# Psql -U postgres
SELECT pg_stop_backup();
# cp pg_data.tar /mnt/pitr


Postgres 8.2 config

StandBy:
# Compile pg_standy from the contrib/ folder
# cd /usr/local/pgsql
# rm -rf data/
# tar -xvf /mnt/pitr/pg_data.tar
# chown -R postgres: data
# cd data/
# cd pg_xlog/ - delete the content
# cd ../data
# touch recovery.conf
restore_command =3D 'pg_standby -l -d -s 2 -t /var/log/postg=
res/ postgresql.8.2.trigger /mnt/pitr/ %f %p %r 2>>pitr_standby.log'

Postgresql.conf
#archive_command =3D off - disabled and commented out
#archive_command =3D '' - disabled and command removed
# archive_timeout =3D 60 - disabled

Is this correct, am I missing something or anything here isn't correct?

If anyone could give me some light with this it would be very much apprecia=
ted.

Thank you very much

Renato


Renato Oliveira
Systems Administrator
e-mail: renato.oliveira [at] grant.co.uk

Tel: +44 (0)1763 260811
Fax: +44 (0)1763 262410
www.grant.co.uk<http://www.grant.co.uk/>

Grant Instruments (Cambridge) Ltd

Company registered in England, registration number 658133

Registered office address:
29 Station Road,
Shepreth,
CAMBS SG8 6GB
UK





P Please consider the environment before printing this email
CONFIDENTIALITY: The information in this e-mail and any attachments is conf=
idential. It is intended only for the named recipients(s). If you are not t=
he named recipient please notify the sender immediately and do not disclose=
the contents to another person or take copies.

VIRUSES: The contents of this e-mail or attachment(s) may contain viruses w=
hich could damage your own computer system. Whilst Grant Instruments (Cambr=
idge) Ltd has taken every reasonable precaution to minimise this risk, we c=
annot accept liability for any damage which you sustain as a result of soft=
ware viruses. You should therefore carry out your own virus checks before o=
pening the attachment(s).

OpenXML: For information about the OpenXML file format in use within Grant =
Instruments please visit our website<http://www.grant.co.uk/Support/openxml=
..html>

--_000_7965A9DCF12CC14984420BCC37B1608F25ABF310ABElzargrantc ou_
Content-Type: text/html; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

<HTML xmlns=3D"http://www.w3.org/TR/REC-html40" xmlns:a=3D"urn:schemas-micr=
osoft-com:office:access" xmlns:b=3D"urn:schemas-microsoft-com:office:publis=
her" xmlns:c=3D"urn:schemas-microsoft-com:office:component:spread sheet" xml=
ns:D=3D"DAV:" xmlns:dir=3D"http://schemas.microsoft.com/sharepoint/soap/di r=
ectory/" xmlns:ds=3D"http://www.w3.org/2000/09/xmldsig#" xmlns:dsp=3D"http:=
//schemas.microsoft.com/sharepoint/dsp" xmlns:dssi=3D"http://schemas.micros=
oft.com/office/2006/digsig" xmlns:dsss=3D"http://schemas.microsoft.com/offi=
ce/2006/digsig-setup" xmlns:dt=3D"uuid:C2F41010-65B3-11d1-A29F-00AA00C14882=
" xmlns:ec=3D"http://www.w3.org/2001/04/xmlenc#" xmlns:ex12m=3D"http://sche=
mas.microsoft.com/exchange/services/2006/messages" xmlns:ex12t=3D"http://sc=
hemas.microsoft.com/exchange/services/2006/types" xmlns:html=3D"http://www.=
w3.org/TR/REC-html40" xmlns:m=3D"http://schemas.microsoft.com/office/2004/1=
2/omml" xmlns:mdssi=3D"http://schemas.openxmlformats.org/package/200 6/digit=
al-signature" xmlns:mrels=3D"http://schemas.openxmlformats.org/package/200 6=
/relationships" xmlns:mt=3D"http://schemas.microsoft.com/sharepoint/soap/me=
etings/" xmlns:mver=3D"http://schemas.openxmlformats.org/markup-compa tibili=
ty/2006" xmlns:o=3D"urn:schemas-microsoft-com:office:office" xmlns:oa=3D"ur=
n:schemas-microsoft-com:office:activation" xmlns:odc=3D"urn:schemas-microso=
ft-com:office:odc" xmlns:ois=3D"http://schemas.microsoft.com/sharepoint/soa=
p/ois/" xmlns:p=3D"urn:schemas-microsoft-com:office:powerpoint" xmlns:ppda=
=3D"http://www.passport.com/NameSpace.xsd" xmlns:pptsl=3D"http://schemas.mi=
crosoft.com/sharepoint/soap/SlideLibrary/" xmlns:q=3D"http://schemas.xmlsoa=
p.org/soap/envelope/" xmlns:Repl=3D"http://schemas.microsoft.com/repl/" xml=
ns:rs=3D"urn:schemas-microsoft-com:rowset" xmlns:rtc=3D"http://microsoft.co=
m/officenet/conferencing" xmlns:s=3D"uuid:BDC6E3F0-6DA3-11d1-A2A3-00AA00C14=
882" xmlns:sp=3D"http://schemas.microsoft.com/sharepoint/" xmlns:sps=3D"htt=
p://schemas.microsoft.com/sharepoint/soap/" xmlns:spsl=3D"http://microsoft.=
com/webservices/SharePointPortalServer/PublishedLinksService " xmlns:spwp=3D=
"http://microsoft.com/sharepoint/webpartpages" xmlns:ss=3D"urn:schemas-micr=
osoft-com:office:spreadsheet" xmlns:st=3D"" xmlns:sub=3D"http://schemas=
..microsoft.com/sharepoint/soap/2002/1/alerts/" xmlns:udc=3D"http://schemas.=
microsoft.com/data/udc" xmlns:udcp2p=3D"http://schemas.microsoft.com/data/u=
dc/parttopart" xmlns:udcs=3D"http://schemas.microsoft.com/data/udc/soap" xm=
lns:udcxf=3D"http://schemas.microsoft.com/data/udc/xmlfile" xmlns:v=3D"urn:=
schemas-microsoft-com:vml" xmlns:w=3D"urn:schemas-microsoft-com:office:word=
" xmlns:wf=3D"http://schemas.microsoft.com/sharepoint/soap/wor kflow/" xmlns=
:x=3D"urn:schemas-microsoft-com:office:excel" xmlns:x2=3D"http://schemas.mi=
crosoft.com/office/excel/2003/xml" xmlns:xsd=3D"http://www.w3.org/2001/XMLS=
chema" xmlns:xsi=3D"http://www.w3.org/2001/XMLSchema-instance" xmlns:Z=3D"u=
rn:schemas-microsoft-com:"><head><META content=3D"text/html; charset=3Dus-a=
scii" http-equiv=3D"Content-Type">
<META content=3D"text/html; charset=3Dus-ascii" http-equiv=3D"Content-Type"=
>

<meta content=3D"text/html; charset=3Dus-ascii" http-equiv=3DContent-Type>
<meta content=3D"Microsoft Word 12 (filtered medium)" name=3DGenerator>
<style>
<!--
/* Font Definitions */
[at] font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
code
{mso-style-priority:99;
font-family:"Courier New";}
pre
{mso-style-priority:99;
mso-style-link:"HTML Preformatted Char";
margin:0cm;
margin-bottom:.0001pt;
font-size:10.0pt;
font-family:"Courier New";}
span.EmailStyle17
{mso-style-type:personal-compose;
font-family:"Calibri","sans-serif";
color:windowtext;}
span.HTMLPreformattedChar
{mso-style-name:"HTML Preformatted Char";
mso-style-priority:99;
mso-style-link:"HTML Preformatted";
font-family:"Courier New";}
..MsoChpDefault
{mso-style-type:export-only;}
[at] page Section1
{size:612.0pt 792.0pt;
margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.Section1
{page:Section1;}
-->
</style>
<!--[if gte mso 9]><xml>
<o:shapedefaults v:ext=3D"edit" spidmax=3D"1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext=3D"edit">
<o:idmap v:ext=3D"edit" data=3D"1" />
</o:shapelayout></xml><![endif]-->
</head><BODY>
<DIV STYLE=3D"FONT-SIZE: 9pt; FONT-FAMILY: Courier New">
<DIV>
<DIV><FONT FACE=3D"Arial" SIZE=3D"2">

<div class=3DSection1>

<p class=3DMsoNormal>Dear all,<o:p></o:p></p>

<p class=3DMsoNormal><o:p> </o:p></p>

<p class=3DMsoNormal>I have been playing with PITR on version 8.3 so far, b=
ut I
need to get it working on version 8.2.<o:p></o:p></p>

<p class=3DMsoNormal><o:p> </o:p></p>

<p class=3DMsoNormal>What is the difference between:<o:p></o:p></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'><o:p> </o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>archive_command
=3D on  (is this command for 8.2?)<o:p></o:p></span></p>

<p class=3DMsoNormal><code><span lang=3DEN style=3D'font-size:10.0pt;color:=
#333333'>archive_mode
=3D    on  (This one is for 8.3!)<o:p></o:p></span></co=
de></p>

<p class=3DMsoNormal><code><span lang=3DEN style=3D'font-size:10.0pt;color:=
#333333'><o:p> </o:p></span></code></p>

<p class=3DMsoNormal><code><span lang=3DEN style=3D'font-size:10.0pt;color:=
#333333'>I
need to enable ‘archive_mode =3D on’, restart postgres, before =
I can
do the base backup, is that correct?<o:p></o:p></span></code></p>

<p class=3DMsoNormal><code><span lang=3DEN style=3D'font-size:10.0pt;color:=
#333333'><o:p> </o:p></span></code></p>

<p class=3DMsoNormal><code><span lang=3DEN style=3D'font-size:10.0pt;color:=
#333333'>In
order to bring the standby online I need a trigger file, something like:<o:=
p></o:p></span></code></p>

<p class=3DMsoNormal><code><span lang=3DEN style=3D'font-size:10.0pt;color:=
#333333'>can
I call the trigger file whatever I want? for example; ‘/var/log/postg=
res/postgresql.8.2.trigger’<o:p></o:p></span></code></p>

<p class=3DMsoNormal><code><span lang=3DEN style=3D'font-size:10.0pt;color:=
#333333'><o:p> </o:p></span></code></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>Postgres
8.2 config<o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'><o:p> </o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>Master:<o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>        Postgresql.conf<o:p></o:p><=
/span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>           &nbs=
p;   archive_command
=3D on  <o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>           &nbs=
p;   archive_command
=3D 'cp -i %p /mnt/pitr/%f &lt;/dev/null' <o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>           &nbs=
p;   archive_timeout
=3D 60<o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>        <o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>        #
mkdir /mnt/pitr<o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>        #
chown postgres: /mnt/pitr (this will be an NFS mount point)<o:p></o:p></spa=
n></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>        #
mount –t nfs fnsserver01:/pitr /mnt/pitr<o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>        #
service postgresql restart<o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>        #
su – postgres<o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>        #
psql –U postgres <o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>            &nb=
sp;   </span><code><span lang=3DEN style=3D'font-size:10.0pt;colo=
r:#333333'>SELECT pg_start_backup('pitr_backup');</span></code><span style=
=3D'font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>            &nb=
sp;   </span><code><span lang=3DEN style=3D'font-size:10.0pt;colo=
r:#333333'>\q<o:p></o:p></span></code></p>

<p class=3DMsoNormal><code><span lang=3DEN style=3D'font-size:10.0pt;color:=
#333333'>        #
Tar –cvf pg_data.tar /usr/loca/pgsql/data<o:p></o:p></span></code></p=
>

<p class=3DMsoNormal><code><span lang=3DEN style=3D'font-size:10.0pt;color:=
#333333'>        #
Psql –U postgres<o:p></o:p></span></code></p>

<p class=3DMsoNormal><code><span lang=3DEN style=3D'font-size:10.0pt;color:=
#333333'>            =
;    SELECT
pg_stop_backup();<o:p></o:p></span></code></p>

<p class=3DMsoNormal><code><span lang=3DEN style=3D'font-size:10.0pt;color:=
#333333'>        #
cp pg_data.tar /mnt/pitr</span></code><span style=3D'font-size:10.0pt;font-=
family:
"Courier New"'><o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>        <o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'><o:p> </o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>Postgres
8.2 config<o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'><o:p> </o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>StandBy:<o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>        #
Compile pg_standy from the contrib/ folder<o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>        #
cd /usr/local/pgsql<o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>        #
rm –rf data/<o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>        #
tar –xvf /mnt/pitr/</span><code><span lang=3DEN style=3D'font-size:10=
..0pt;
color:#333333'>pg_data.tar<o:p></o:p></span></code></p>

<p class=3DMsoNormal><code><span lang=3DEN style=3D'font-size:10.0pt;color:=
#333333'>        #
chown –R postgres: data<o:p></o:p></span></code></p>

<p class=3DMsoNormal><code><span lang=3DEN style=3D'font-size:10.0pt;color:=
#333333'>        #
cd data/<o:p></o:p></span></code></p>

<p class=3DMsoNormal><code><span lang=3DEN style=3D'font-size:10.0pt;color:=
#333333'>        #
cd pg_xlog/ - delete the content<o:p></o:p></span></code></p>

<p class=3DMsoNormal><code><span lang=3DEN style=3D'font-size:10.0pt;color:=
#333333'>        #
cd ../data<o:p></o:p></span></code></p>

<p class=3DMsoNormal><code><span lang=3DEN style=3D'font-size:10.0pt;color:=
#333333'>        #
touch recovery.conf<o:p></o:p></span></code></p>

<p class=3DMsoNormal><code><span lang=3DEN style=3D'font-size:10.0pt;color:=
#333333'>           =
    restore_command
=3D 'pg_standby -l -d -s 2 -t /var/log/postgres/ postgresql.8.2.trigger /mn=
t/pitr/
%f %p %r 2>>pitr_standby.log'</span></code><span style=3D'font-size:1=
0.0pt;
font-family:"Courier New"'><o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'><o:p> </o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>        Postgresql.conf<o:p></o:p><=
/span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>           &nbs=
p;   #archive_command
=3D off  - disabled and commented out<o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>           &nbs=
p;   #archive_command
=3D '' – disabled and command removed<o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>           &nbs=
p;   #
archive_timeout =3D 60 – disabled<o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'><o:p> </o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'>Is
this correct, am I missing something or anything here isn’t correct?&=
nbsp;    <o:p></o:p></span></p>

<p class=3DMsoNormal><span style=3D'font-size:10.0pt;font-family:"Courier N=
ew"'><o:p> </o:p></span></p>

<p class=3DMsoNormal>If anyone could give me some light with this it would =
be
very much appreciated.<o:p></o:p></p>

<p class=3DMsoNormal><o:p> </o:p></p>

<p class=3DMsoNormal>Thank you very much<o:p></o:p></p>

<p class=3DMsoNormal><o:p> </o:p></p>

<p class=3DMsoNormal>Renato<o:p></o:p></p>

<p class=3DMsoNormal><o:p> </o:p></p>

</div>

</FONT></DIV>
<DIV><FONT FACE=3D"Arial" SIZE=3D"2"></FONT> </DIV>
<DIV><FONT FACE=3D"Arial" SIZE=3D"2"><FONT FACE=3D"Arial" SIZE=3D"2">Renato=
Oliveira<BR>Systems Administrator<BR>e-mail: renato.oliveira [at] grant.co.uk</=
FONT></FONT><FONT FACE=3D"Arial" SIZE=3D"2"><FONT FACE=3D"Arial" SIZE=3D"2"=
></FONT></FONT></DIV>
<DIV><FONT FACE=3D"Arial" SIZE=3D"2"><FONT FACE=3D"Arial" SIZE=3D"2"></FONT=
></FONT> </DIV>
<DIV><FONT FACE=3D"Arial" SIZE=3D"2"><FONT FACE=3D"Arial" SIZE=3D"2">Tel: +=
44 (0)1763 260811<BR>Fax: +44 (0)1763 262410<BR><A HREF=3D"http://www.grant=
..co.uk/">www.grant.co.uk</A></FONT></FONT></DIV>
<DIV><FONT FACE=3D"Arial" SIZE=3D"2"><FONT FACE=3D"Arial" SIZE=3D"2"></FONT=
></FONT> </DIV>
<DIV><FONT FACE=3D"Arial" SIZE=3D"2"><FONT FACE=3D"Arial" SIZE=3D"2">Grant =
Instruments (Cambridge) Ltd <BR> <BR>Company registered in England, re=
gistration number 658133<BR> <BR>Registered office address:<BR>29 Stat=
ion Road, <BR>Shepreth, <BR>CAMBS SG8 6GB <BR>UK</FONT></FONT></DIV>
<DIV><FONT FACE=3D"Arial" SIZE=3D"2"><FONT FACE=3D"Arial" SIZE=3D"2"></FONT=
></FONT><FONT FACE=3D"Arial" SIZE=3D"2"><FONT FACE=3D"Arial" SIZE=3D"2"></F=
ONT></FONT> </DIV>
<DIV><FONT FACE=3D"Arial" SIZE=3D"2"><FONT FACE=3D"Arial" SIZE=3D"2"></FONT=
></FONT></DIV>
<DIV><FONT FACE=3D"Arial" SIZE=3D"2"><FONT FACE=3D"Arial" SIZE=3D"2"></FONT=
></FONT> </DIV>
<DIV><FONT FACE=3D"Arial" SIZE=3D"2"><FONT FACE=3D"Arial" SIZE=3D"2"></FONT=
></FONT></DIV>
<DIV> </DIV>
<DIV><FONT FACE=3D"Arial" SIZE=3D"2"><FONT FACE=3D"Arial" SIZE=3D"2"></FONT=
></FONT></DIV>
<DIV> </DIV> </DIV>
<DIV>
<P CLASS=3D"MsoNormal"><EM><B><SPAN LANG=3D"EN-US" STYLE=3D"FONT-SIZE: 18pt=
; COLOR: green; FONT-FAMILY: Webdings"></SPAN></B></EM> </P>
<P CLASS=3D"MsoNormal"><EM><B><SPAN LANG=3D"EN-US" STYLE=3D"FONT-SIZE: 18pt=
; COLOR: green; FONT-FAMILY: Webdings">P</SPAN></B></EM><EM><B><SPAN LANG=
=3D"EN-US" STYLE=3D"FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: 'Verdana','=
sans-serif'"> </SPAN></B></EM><STRONG><I><SPAN STYLE=3D"FONT-SIZE: 7.5pt; C=
OLOR: green; FONT-FAMILY: 'Arial','sans-serif'">Please consider the environ=
ment before printing this email</SPAN></I></STRONG></P></DIV>
<DIV><FONT FACE=3D"Arial" SIZE=3D"2"><STRONG>CONFIDENTIALITY</STRONG>: The =
information in this e-mail and any attachments is confidential. It is inten=
ded only for the named recipients(s). If you are not the named recipient pl=
ease notify the sender immediately and do not disclose the contents to anot=
her person or take copies. </FONT></DIV>
<DIV><FONT FACE=3D"Arial" SIZE=3D"2"></FONT> </DIV>
<DIV><FONT FACE=3D"Arial" SIZE=3D"2"><STRONG></STRONG></FONT></DIV>
<DIV><FONT FACE=3D"Arial" SIZE=3D"2"><STRONG>VIRUSES:</STRONG> The contents=
of this e-mail or attachment(s) may contain viruses which could damage you=
r own computer system. Whilst Grant Instruments (Cambridge) Ltd has taken e=
very reasonable precaution to minimise this risk, we cannot accept liabilit=
y for any damage which you sustain as a result of software viruses. You sho=
uld therefore carry out your own virus checks before opening the attachment=
(s).</FONT></DIV>
<DIV> </DIV>
<DIV><FONT FACE=3D"Arial" SIZE=3D"2"></FONT></DIV>
<DIV><FONT FACE=3D"Arial" SIZE=3D"2"><STRONG>OpenXML</STRONG>: For informat=
ion about the OpenXML file format in use within Grant Instruments please vi=
sit our <A HREF=3D"http://www.grant.co.uk/Support/openxml.html">website</A>=
</FONT></DIV></DIV></BODY></HTML>

--_000_7965A9DCF12CC14984420BCC37B1608F25ABF310ABElzargrantc ou_--
Renato Oliveira [ Mi, 07 April 2010 15:30 ] [ ID #2037997 ]

Re: turn pitr 'on' on PostgreSQL 8.2 - pg_standby

Renato Oliveira wrote:
>
> What is the difference between:
>
> archive_command =3D on (is this command for 8.2?)
>
> |archive_mode =3D on (This one is for 8.3!)|
>

8.2 doesn't have a archive_mode setting, that was added in 8.3. With
8.2, you set the archive_command in the same way as you do in 8.3. There
just isn't a dedicated parameters to toggle archiving on and off that's
separate from changing the command used.

> |In order to bring the standby online I need a trigger file, something
> like:|
>
> |can I call the trigger file whatever I want? for example;
> =91/var/log/postgres/postgresql.8.2.trigger=92|
>

It doesn't matter where the trigger file is at so long as you use it
correctly.

The other thing to be careful of, that you already noted, is that since
8.2 doesn't ship with pg_standby, you need to grab your version of that.
You should try to use the one that ships with 8.4. Also, it's not going
to support the "%r" syntax in the restore_command, so you need to set
the "-k" setting to a moderately high value for 8.2 servers. It's
difficult to say exactly how high that must be for any possible
workload. Something like "-k 256" is a reasonable starter setting that
will save the last 4GB of archive logs shipped over on the standby,
which is high enough to make deleting one of them prematurely unlikely
(but not impossible for the right difficult workload).

--
Greg Smith 2ndQuadrant US Baltimore, MD
PostgreSQL Training, Services and Support
greg [at] 2ndQuadrant.com www.2ndQuadrant.us


--
Sent via pgsql-admin mailing list (pgsql-admin [at] postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin
Greg Smith [ Mi, 07 April 2010 19:47 ] [ ID #2038001 ]
Datenbanken » gmane.comp.db.postgresql.admin » turn pitr 'on' on PostgreSQL 8.2 - pg_standby

Vorheriges Thema: Compile Problem for Alpha 5 in /src/backend/utils/error/elog.c
Nächstes Thema: dblink_connect is slow