pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Michal Glowacki <mg.scandic@gmail.com>
To: Guillaume Lelarge <guillaume@lelarge.info>
Cc: Fujii Masao <masao.fujii@gmail.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: Hot standby server does not start
Date: Fri, 01 Oct 2010 13:07:35 +0200
Message-ID: <4CA5C0F7.8040407@gmail.com> (raw)
In-Reply-To: <4CA2FF32.6070002@lelarge.info>
References: <4CA2F025.3010508@gmail.com>
	<AANLkTim8eZ3nMPN3_1Au1pb32Rfv6v2NtifmCu0OCf6u@mail.gmail.com>
	<4CA2F5ED.3000209@gmail.com>
	<4CA2FF32.6070002@lelarge.info>

  hi,

     it's fine now - the problem was WinRAR which reported that he can't 
access some files and I ignored that - big mistake :)

     Thanks for help - working fine now.

Michal
> Le 29/09/2010 10:16, Michal Glowacki a écrit :
>>   Fujii, I believe I should follow this (from documentation):
>>
>> ************************
>>
>> The procedure for making a base backup is relatively simple:
>>
>>    1.
>>
>>       Ensure that WAL archiving is enabled and working.
>>
>>    2.
>>
>>       Connect to the database as a superuser, and issue the command
>>
>>       SELECT pg_start_backup('label');
>>
>>       where label is any string you want to use to uniquely identify
>>       this backup operation. (One good practice is to use the full path
>>       where you intend to put the backup dump file.) |pg_start_backup|
>>       creates a /backup label/ file, called backup_label, in the cluster
>>       directory with information about your backup.
>>
>>       It does not matter which database within the cluster you connect
>>       to to issue this command. You can ignore the result returned by
>>       the function; but if it reports an error, deal with that before
>>       proceeding.
>>
>>    3.
>>
>>       Perform the backup, using any convenient file-system-backup tool
>>       such as tar or cpio. It is neither necessary nor desirable to stop
>>       normal operation of the database while you do this.
>>
>>    4.
>>
>>       Again connect to the database as a superuser, and issue the command
>>
>>       SELECT pg_stop_backup();
>>
>>       This should return successfully.
>>
>>    5.
>>
>>       Once the WAL segment files used during the backup are archived as
>>       part of normal database activity, you are done.
>>
>>
>> **********************************
>>
>> BUT I have some questions:
>>
>> 1. I connect to database using psql and issue command SELECT
>> pg_start_backup('my_backup'); The result (in less than second) is:
>>
>>   pg_start_backup
>> -----------------
>>   4/DA000020
>> (1 row)
>>
>> Is it correct it goes that fast?
>>
> Yes.
>
>> 2. Now I proceed to step 3 - perform the backup using file system
>> backup. Could you assist me on this one? I should archive what?The
>> '/data' folder (please note I use Windows)? Should I just compress it
>> into rar file and transfer to standby server and overwrite it's '/data'
>> folder?
>>
> Using rar on the data folder should work if you don't have tablespaces.
> If you have some, add them to your data rar archive.
>
> And instead of overwriting the data folder on the slave, wipe out your
> old data folder and recreate it by restoring your rar archive.
>
> BTW, pgAdmin backup and restore facilities use pg_dump/pg_restore. So
> it's not really surprising that you get the same results :)
>
>




view thread (6+ messages)

Message-ID: <4CA5C0F7.8040407@gmail.com>
Permalink:  ../4CA5C0F7.8040407@gmail.com/
Also on:    postgresql.org/message-id/4CA5C0F7.8040407@gmail.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: mg.scandic@gmail.com, guillaume@lelarge.info, masao.fujii@gmail.com
  Subject: Re: Hot standby server does not start
  In-Reply-To: <4CA5C0F7.8040407@gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox