<div dir="ltr">Hi Tatsuo,<div><br></div><div>Please help me to solve the following problems.<br><div><br></div><div><b>Problem:1</b></div><div>Replication is working properly after I added <span style="color:rgb(0,0,0);font-size:13.3333px;white-space:pre-wrap"> 'password=1234' at </span><font color="#000000"><span style="font-size:13.3333px;white-space:pre-wrap">primary_conninfo parameter in recovery.conf, but Standby Server didn't started automatically after clicking "Recovery" from pgpool. I have edited the path of PFCTL in </span></font><span style="color:rgb(0,0,0);font-size:13.3333px;white-space:pre-wrap">pgpool_remote_start file,</span><span style="font-size:13.3333px;white-space:pre-wrap;color:rgb(0,0,0)"> do I need to edit anything else there?</span></div></div><div><font color="#000000"><span style="font-size:13.3333px;white-space:pre-wrap"><br></span></font></div><div><b>Problem:2</b><font color="#000000"><span style="font-size:13.3333px;white-space:pre-wrap"><br></span></font></div><div>I have stopped the Primary Server, but autofailover didn't work. Here are some logs from Standby Server when I had stopped the Primary Server.</div><div>-----------------------------------------------------------------</div><div><div>9381 2015-10-05 11:47:01 UTC STATEMENT: INSERT INTO rep_test VALUES ('Shumi');</div><div>9381 2015-10-05 11:47:32 UTC LOG: statement: select * from rep_test;</div><div>9381 2015-10-05 11:48:04 UTC LOG: statement: select * from rep_test;</div><div>9521 2015-10-05 11:49:28 UTC LOG: statement: select * from t1;</div><div>9521 2015-10-05 11:49:42 UTC LOG: statement: select * from t1;</div><div>9357 2015-10-05 11:53:22 UTC LOG: replication terminated by primary server</div><div>9357 2015-10-05 11:53:22 UTC DETAIL: End of WAL reached on timeline 1 at 0/4D000090.</div><div>9357 2015-10-05 11:53:22 UTC FATAL: could not send end-of-streaming message to primary: no COPY in progress</div><div><span class="" style="white-space:pre"> </span></div><div>9356 2015-10-05 11:53:22 UTC LOG: invalid record length at 0/4D000090</div><div>9536 2015-10-05 11:53:28 UTC LOG: statement: SELECT pg_is_in_recovery()</div><div>9537 2015-10-05 11:53:29 UTC LOG: statement: SELECT pg_is_in_recovery()</div><div>9538 2015-10-05 11:53:30 UTC LOG: statement: SELECT pg_is_in_recovery()</div><div>9539 2015-10-05 11:53:31 UTC LOG: statement: SELECT pg_is_in_recovery()</div><div>9540 2015-10-05 11:53:32 UTC LOG: statement: SELECT pg_is_in_recovery()</div><div>9542 2015-10-05 11:53:32 UTC LOG: statement: SELECT pg_is_in_recovery()</div><div>9543 2015-10-05 11:53:33 UTC LOG: statement: SELECT pg_is_in_recovery()</div><div>9544 2015-10-05 11:53:34 UTC LOG: statement: SELECT pg_is_in_recovery()</div><div>9545 2015-10-05 11:53:35 UTC LOG: statement: SELECT pg_is_in_recovery()</div><div>9546 2015-10-05 11:53:36 UTC LOG: statement: SELECT pg_is_in_recovery()</div><div>9547 2015-10-05 11:53:37 UTC FATAL: could not connect to the primary server: could not connect to server: Connection refused</div><div><span class="" style="white-space:pre"> </span>Is the server running on host "192.168.10.54" and accepting</div><div><span class="" style="white-space:pre"> </span>TCP/IP connections on port 5432?</div><div><span class="" style="white-space:pre"> </span></div><div>9548 2015-10-05 11:53:37 UTC LOG: statement: SELECT pg_is_in_recovery()</div><div>9550 2015-10-05 11:53:42 UTC FATAL: could not connect to the primary server: could not connect to server: Connection refused</div><div><span class="" style="white-space:pre"> </span>Is the server running on host "192.168.10.54" and accepting</div><div><span class="" style="white-space:pre"> </span>TCP/IP connections on port 5432?</div></div><div>---------------------------------------------------------------------------------------------------------------------------------------------</div><div><br></div><div>Please check the attachment.</div><div><br></div><div>Best regards,</div><div>Giles.</div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On 4 October 2015 at 11:36, Giles Gomes <span dir="ltr"><<a href="mailto:giles.gomes@retailephant.com" target="_blank">giles.gomes@retailephant.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi Tatsuo,<div><br></div><div>Thanks for your response. I have attached <span style="font-size:12.8px">postgresql.conf </span><span style="font-size:12.8px">of primary and recovery.conf of standby with this email.</span></div><div><span style="font-size:12.8px"><br></span></div><div><span style="font-size:12.8px">Regards,</span></div><div><span style="font-size:12.8px">Giles.</span></div></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">On 3 October 2015 at 13:08, Tatsuo Ishii <span dir="ltr"><<a href="mailto:ishii@postgresql.org" target="_blank">ishii@postgresql.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Seems streaming replication is not working. Standby requests a WAL<br>
segment but primary does not have it. Can you show me postgresql.conf<br>
of primary and recovery.conf of standby?<br>
<div><div><br>
Best regards,<br>
--<br>
Tatsuo Ishii<br>
SRA OSS, Inc. Japan<br>
English: <a href="http://www.sraoss.co.jp/index_en.php" rel="noreferrer" target="_blank">http://www.sraoss.co.jp/index_en.php</a><br>
Japanese:<a href="http://www.sraoss.co.jp" rel="noreferrer" target="_blank">http://www.sraoss.co.jp</a><br>
<br>
> Hi Tatsuo,<br>
><br>
> I was able to minimize some errors at master (primary) PostgreSQL's log. I<br>
> have attached the new log with this email.<br>
><br>
> Best regards,<br>
> Giles.<br>
><br>
><br>
> On 30 September 2015 at 18:59, Giles Gomes <<a href="mailto:giles.gomes@retailephant.com" target="_blank">giles.gomes@retailephant.com</a>><br>
> wrote:<br>
><br>
>> Hi Tatsuo,<br>
>><br>
>> The pgpool log, master (primary) PostgreSQL's log and basebackup,sh have<br>
>> been attached with this email.<br>
>><br>
>> Best regards,<br>
>> Giles.<br>
>><br>
>> On 28 September 2015 at 16:50, Giles Gomes <<a href="mailto:giles.gomes@retailephant.com" target="_blank">giles.gomes@retailephant.com</a>><br>
>> wrote:<br>
>><br>
>>> Hi Tatsuo,<br>
>>><br>
>>> The pgpool log, master (primary) PostgreSQL's log and basebackup,sh have<br>
>>> been attached with this email.<br>
>>><br>
>>> Best regards,<br>
>>> Giles.<br>
>>><br>
>>> On 27 September 2015 at 11:06, Tatsuo Ishii <<a href="mailto:ishii@postgresql.org" target="_blank">ishii@postgresql.org</a>> wrote:<br>
>>><br>
>>>> pcp_recovery_node command failed for some reason. Unfortunately the<br>
>>>> error code emitted by pgpoolAdmin is not very helpful. pgpool log and<br>
>>>> master (primary) PostgreSQL's log when the command ran will be<br>
>>>> more helpful.<br>
>>>><br>
>>>> Best regards,<br>
>>>> --<br>
>>>> Tatsuo Ishii<br>
>>>> SRA OSS, Inc. Japan<br>
>>>> English: <a href="http://www.sraoss.co.jp/index_en.php" rel="noreferrer" target="_blank">http://www.sraoss.co.jp/index_en.php</a><br>
>>>> Japanese:<a href="http://www.sraoss.co.jp" rel="noreferrer" target="_blank">http://www.sraoss.co.jp</a><br>
>>>><br>
>>>> > Hi, how are you??<br>
>>>> > A query, you could solve this problem you had ??<br>
>>>> > I have the same error connection error pgpooladmin<br>
>>>> ><br>
>>>> ><br>
>>>> > 2015-09-20 11:29 GMT-03:00 Giles Gomes <<a href="mailto:giles.gomes@retailephant.com" target="_blank">giles.gomes@retailephant.com</a>>:<br>
>>>> ><br>
>>>> >> Hello Tatsuo Ishii,<br>
>>>> >><br>
>>>> >> After enabling health check parameters 'postgres' is showing up now.<br>
>>>> But<br>
>>>> >> when I click on Recovery an error is generating.<br>
>>>> >> Error Code: e1012, Error Message: pcp_recovery_node command error<br>
>>>> occurred and<br>
>>>> >> 'Stop', 'Restart', 'Reload' and 'Remove' buttons are still disabled.<br>
>>>> >><br>
>>>> >> I have attached the screen shots and waiting for your help.<br>
>>>> >><br>
>>>> >> Best regards,<br>
>>>> >> Giles.<br>
>>>> >><br>
>>>> >><br>
>>>> >> On 17 September 2015 at 19:52, Giles Gomes <<br>
>>>> <a href="mailto:giles.gomes@retailephant.com" target="_blank">giles.gomes@retailephant.com</a>><br>
>>>> >> wrote:<br>
>>>> >><br>
>>>> >>> Hello Tatsuo Ishii,<br>
>>>> >>><br>
>>>> >>> I was able to start the Standby Database and Successfully Installed<br>
>>>> >>> pgpoolAdmin. But 'postgres' is showing down and 'Stop', 'Restart',<br>
>>>> 'Reload'<br>
>>>> >>> and 'Remove' buttons are disabled.<br>
>>>> >>><br>
>>>> >>> pgpool.log and the screen shot is attached with this email.<br>
>>>> >>><br>
>>>> >>> --<br>
>>>> >>> Best regards,<br>
>>>> >>> Giles Cornelius Gomes<br>
>>>> >>> Database Administrator<br>
>>>> >>> Impel IT Solutions Ltd.<br>
>>>> >>> Phone: <a href="tel:%2B88%2001%20714329389" value="+8801714329389" target="_blank">+88 01 714329389</a><br>
>>>> >>><br>
>>>> >>> On 16 September 2015 at 21:24, Giles Gomes <<br>
>>>> <a href="mailto:giles.gomes@retailephant.com" target="_blank">giles.gomes@retailephant.com</a>><br>
>>>> >>> wrote:<br>
>>>> >>><br>
>>>> >>>> Hi Tatsuo,<br>
>>>> >>>><br>
>>>> >>>> Thanks for your response. install-functions.sh has worked properly<br>
>>>> >>>> after installing postgresql-server-dev-9.3.<br>
>>>> >>>><br>
>>>> >>>> I was also able to run basebackup.sh, although "mkdir: cannot create<br>
>>>> >>>> directory ‘/var/lib/postgresql/9.3/main/pg_xlog’: File exists" is<br>
>>>> showing<br>
>>>> >>>> while running this as following:<br>
>>>> >>>><br>
>>>> >>>><br>
>>>> -------------------------------------------------------------------------------------------<br>
>>>> >>>> postgres@osspc17:~/9.3/main$ ./basebackup.sh<br>
>>>> >>>> pg_start_backup<br>
>>>> >>>> -----------------<br>
>>>> >>>> 0/1C000028<br>
>>>> >>>> (1 row)<br>
>>>> >>>><br>
>>>> >>>> mkdir: cannot create directory<br>
>>>> ‘/var/lib/postgresql/9.3/main/pg_xlog’:<br>
>>>> >>>> File exists<br>
>>>> >>>> mytemp23915<br>
>>>> >>>> 100%<br>
>>>> 153<br>
>>>> >>>> 0.2KB/s 00:00<br>
>>>> >>>> NOTICE: pg_stop_backup complete, all required WAL segments have<br>
>>>> been<br>
>>>> >>>> archived<br>
>>>> >>>> pg_stop_backup<br>
>>>> >>>> ----------------<br>
>>>> >>>> 0/1C0000F0<br>
>>>> >>>> (1 row)<br>
>>>> >>>><br>
>>>> >>>><br>
>>>> --------------------------------------------------------------------------------------------<br>
>>>> >>>><br>
>>>> >>>> After running this script I have restarted the standby database as<br>
>>>> >>>> following:<br>
>>>> >>>><br>
>>>> >>>> $ service postgresql restart<br>
>>>> >>>><br>
>>>> >>>> After restarting the database I am unable to login to database.<br>
>>>> >>>> following error is showing:<br>
>>>> >>>><br>
>>>> >>>><br>
>>>> --------------------------------------------------------------------------<br>
>>>> >>>> postgres@osspc18:~$ psql<br>
>>>> >>>> psql: FATAL: the database system is starting up<br>
>>>> >>>><br>
>>>> >>>><br>
>>>> --------------------------------------------------------------------------<br>
>>>> >>>><br>
>>>> >>>> What should I do now?<br>
>>>> >>>><br>
>>>> >>>> Best regards,<br>
>>>> >>>> Giles.<br>
>>>> >>>><br>
>>>> >>>><br>
>>>> >>>><br>
>>>> >>>> On 16 September 2015 at 04:59, Tatsuo Ishii <<a href="mailto:ishii@postgresql.org" target="_blank">ishii@postgresql.org</a>><br>
>>>> >>>> wrote:<br>
>>>> >>>><br>
>>>> >>>>> > Hi Tatsuo,<br>
>>>> >>>>> ><br>
>>>> >>>>> > Thanks for your quick response. I was trying to configure<br>
>>>> replication<br>
>>>> >>>>> with<br>
>>>> >>>>> > pgpool II between three VM.<br>
>>>> >>>>> > 1. Pgpool Server. where pgpool-II-3.4.3 is installed .I wish to<br>
>>>> >>>>> install<br>
>>>> >>>>> > Pgpool Admin here also.<br>
>>>> >>>>> > 2. Primary Server, where PostgreSQL 9.3.9 is installed.<br>
>>>> >>>>> > 3. Standby Server, where PostgreSQL 9.3.9 is installed.<br>
>>>> >>>>> ><br>
>>>> >>>>> > The main problem is I didn't get any complete document where all<br>
>>>> the<br>
>>>> >>>>> > necessary steps are described. Last time I was following the<br>
>>>> document<br>
>>>> >>>>> below.<br>
>>>> >>>>> ><br>
>>>> >>>>> ><br>
>>>> <a href="http://www.pgpool.net/pgpool-web/contrib_docs/simple_sr_setting2_3.3/" rel="noreferrer" target="_blank">http://www.pgpool.net/pgpool-web/contrib_docs/simple_sr_setting2_3.3/</a><br>
>>>> >>>>> ><br>
>>>> >>>>> > Here they told to run a script named install-functions.sh<br>
>>>> >>>>> ><br>
>>>> >>>>> > But following errors are showing while running it.<br>
>>>> >>>>> ><br>
>>>> >>>>><br>
>>>> --------------------------------------------------------------------------------------------------------------------<br>
>>>> >>>>> > postgres@osspc16:/home/vagrant$ ./install-functions.sh<br>
>>>> >>>>> > Makefile:19: /usr/lib/postgresql/9.3/lib/pgxs/src/makefiles/<br>
>>>> <a href="http://pgxs.mk" rel="noreferrer" target="_blank">pgxs.mk</a>:<br>
>>>> >>>>> No<br>
>>>> >>>>> > such fil<br>
>>>> >>>>> > e or directory<br>
>>>> >>>>> > make: *** No rule to make target<br>
>>>> >>>>><br>
>>>> >>>>> Seems like a PostgreSQL RPM installation problem, rather than a<br>
>>>> >>>>> pgpool-II installation problem. Have you installed postgresql-devel<br>
>>>> >>>>> package?<br>
>>>> >>>>><br>
>>>> >>>>> Best regards,<br>
>>>> >>>>> --<br>
>>>> >>>>> Tatsuo Ishii<br>
>>>> >>>>> SRA OSS, Inc. Japan<br>
>>>> >>>>> English: <a href="http://www.sraoss.co.jp/index_en.php" rel="noreferrer" target="_blank">http://www.sraoss.co.jp/index_en.php</a><br>
>>>> >>>>> Japanese:<a href="http://www.sraoss.co.jp" rel="noreferrer" target="_blank">http://www.sraoss.co.jp</a><br>
>>>> >>>>><br>
>>>> >>>><br>
>>>> >>>><br>
>>>> >>>><br>
>>>> >>>> --<br>
>>>> >>>> Best regards,<br>
>>>> >>>> Giles Cornelius Gomes<br>
>>>> >>>> Database Administrator<br>
>>>> >>>> Impel IT Solutions Ltd.<br>
>>>> >>>> Phone: <a href="tel:%2B88%2001%20714329389" value="+8801714329389" target="_blank">+88 01 714329389</a><br>
>>>> >>>><br>
>>>> >>><br>
>>>> >>><br>
>>>> >>><br>
>>>> >>> --<br>
>>>> >>> Best regards,<br>
>>>> >>> Giles Cornelius Gomes<br>
>>>> >>> Database Administrator<br>
>>>> >>> Impel IT Solutions Ltd.<br>
>>>> >>> Phone: <a href="tel:%2B88%2001%20714329389" value="+8801714329389" target="_blank">+88 01 714329389</a><br>
>>>> >>><br>
>>>> >><br>
>>>> >><br>
>>>> >><br>
>>>> >> --<br>
>>>> >> Best regards,<br>
>>>> >> Giles Cornelius Gomes<br>
>>>> >> Database Administrator<br>
>>>> >> Impel IT Solutions Ltd.<br>
>>>> >> Phone: <a href="tel:%2B88%2001%20714329389" value="+8801714329389" target="_blank">+88 01 714329389</a><br>
>>>> >><br>
>>>> >> _______________________________________________<br>
>>>> >> pgpool-general mailing list<br>
>>>> >> <a href="mailto:pgpool-general@pgpool.net" target="_blank">pgpool-general@pgpool.net</a><br>
>>>> >> <a href="http://www.pgpool.net/mailman/listinfo/pgpool-general" rel="noreferrer" target="_blank">http://www.pgpool.net/mailman/listinfo/pgpool-general</a><br>
>>>> >><br>
>>>> >><br>
>>>><br>
>>><br>
>>><br>
>>><br>
>>> --<br>
>>> Best regards,<br>
>>> Giles Cornelius Gomes<br>
>>> Database Administrator<br>
>>> Impel IT Solutions Ltd.<br>
>>> Phone: <a href="tel:%2B88%2001%20714329389" value="+8801714329389" target="_blank">+88 01 714329389</a><br>
>>><br>
>><br>
>><br>
>><br>
>> --<br>
>> Best regards,<br>
>> Giles Cornelius Gomes<br>
>> Database Administrator<br>
>> Impel IT Solutions Ltd.<br>
>> Phone: <a href="tel:%2B88%2001%20714329389" value="+8801714329389" target="_blank">+88 01 714329389</a><br>
>><br>
><br>
><br>
><br>
> --<br>
> Best regards,<br>
> Giles Cornelius Gomes<br>
> Database Administrator<br>
> Impel IT Solutions Ltd.<br>
> Phone: <a href="tel:%2B88%2001%20714329389" value="+8801714329389" target="_blank">+88 01 714329389</a><br>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div><div dir="ltr"><div><div dir="ltr">Best regards,<div>Giles Cornelius Gomes</div><div>Database Administrator</div><div>Impel IT Solutions Ltd.</div><div>Phone: +88 01 714329389 </div></div></div></div></div>
</div>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr"><div><div dir="ltr">Best regards,<div>Giles Cornelius Gomes</div><div>Database Administrator</div><div>Impel IT Solutions Ltd.</div><div>Phone: +88 01 714329389 </div></div></div></div></div>
</div>