Re: streaming replication question

Поиск
Список
Период
Сортировка
От Rajesh Kumar Mallah
Тема Re: streaming replication question
Дата
Msg-id AANLkTikJ2OB7OPUsE98L5ZFH+Frse1-uGOMpyMgPOpsb@mail.gmail.com
обсуждение исходный текст
Ответ на Re: streaming replication question  (Fujii Masao <masao.fujii@gmail.com>)
Ответы Re: streaming replication question  (Fujii Masao <masao.fujii@gmail.com>)
Список pgsql-general


On Tue, Oct 5, 2010 at 12:09 AM, Fujii Masao <masao.fujii@gmail.com> wrote:
On Tue, Oct 5, 2010 at 2:57 AM, Rajesh Kumar Mallah
> I am currently aiming to setup only SR  between 2 servers only.

"only SR" means that you don't need Hot Standby (i.e., you don't need to
run any query on the standby server)? If so, you can set wal_level to
archive instead of hot_standby, and disable hot_standby parameter on the
standby.

Thanks for the kind replies,
May be I am mistaken in understanding of the terms. I do issue read only
queries to the standby server. So I think its HS. But I also stream the
wal records.
 

> My question is in SR setup do i need to keep transferring the archived WAL
> files also ?

No if wal_keep_segments is high enough that WAL files required for the standby
can be saved in pg_xlog directory of the master.

> when the slave requests WAL records from the master does the master consult
> the archived
> wal files also for sending the records ?

No. In 9.0, the master doesn't read and send the archived WAL files.
But I agree to make the master send the archived WAL files, and I'm
now proposing that.
http://archives.postgresql.org/pgsql-hackers/2010-09/msg02040.php

Regards,

I just wanted to let you know how i am now managing the wal logs.
i have mounted the wal archive folder(Xp) of primary on the slave via NFS to
a folder (Ys).
The folder Xp of primary is periodically rsynced to folder Xs on slave with option --delete
in recovery.conf of slave archive_cleanup_command has been specified to cleanup Ys
(not Xs), since it is a NFS rw mount it removes the unneeded archived WAL files from the
 source also ie Xp . subsequently the files are removed from Xs also because of the
--delete option of rsync.

My original requirement is that , I should be able to divert certain amount of Read Only
queries from the master to salve so as to reduce load in primary. Our pilot applications
have been modified so that they always contact master when that have to modify data
and slave when they have to read data. The current setup provides for the requirement
but I am concerned what happens if the slave is shutdown for a prolonged duration how
will i get to know when  a base backup is required. I am trying to read the docs and
practically observing also the effects of various steps. We have a switch in the software
that lets was not to use the slave at all ! .

Regds
Rajesh Kumar Mallah.
Tradeindia.com - India's Largest B2B MarketPlace.
(uses PostgreSQL for past 10 years)
 

--
Fujii Masao
NIPPON TELEGRAPH AND TELEPHONE CORPORATION
NTT Open Source Software Center

В списке pgsql-general по дате отправления:

Предыдущее
От: "Satoshi Nagayasu"
Дата:
Сообщение: Re: Why would a scan take so long?
Следующее
От: Arjen Nienhuis
Дата:
Сообщение: Re: Question regarding custom parser