<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Thu, May 4, 2017 at 1:12 PM, Tatsuo Ishii <span dir="ltr">&lt;<a href="mailto:ishii@sraoss.co.jp" target="_blank">ishii@sraoss.co.jp</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Usama,<br>
<br>
Thank you for letting me know it.  The problem only happens when node<br>
0 is stopped.  The segfault happens while initializing pgpool child<br>
process starting up. The bug was introduced in commit<br>
18f95017586aacb7254bbccda18ba6<wbr>7c01468483 by me, sigh. Also 3.5 stable<br>
tree has the same problem. I have pushed fix to 3.6 and 3.5<br>
stable. More invasive fix was pushed to master branch.<br></blockquote><div><br></div><div>Thanks for fixing the issue. </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
Because the bug is significant, probably we need to release new minor<br>
versions for 3.5 and 3.6.<br></blockquote><div><br></div><div>Yes that is correct, Since there is no way around for the issue and after the failover of first backend node the Pgpool-II service can effectively become unavailable because of this issue so we may need to expedite the next minor release.</div><div><br></div><div><br></div><div><br></div><div>Thanks</div><div>Best Regards.</div><div>Muhammad Usama</div><div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<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_<wbr>en.php</a><br>
Japanese:<a href="http://www.sraoss.co.jp" rel="noreferrer" target="_blank">http://www.sraoss.co.<wbr>jp</a><br>
<div class="HOEnZb"><div class="h5"><br>
&gt; Hi Ishii-San<br>
&gt;<br>
&gt; I am getting the segmentation fault in Pgpool-II child process on master<br>
&gt; and 3_6 stable branches.<br>
&gt;<br>
&gt; Steps to reproduce.<br>
&gt;<br>
&gt; 1-) Start the pgpool-II with two backend nodes (both PG up and running).<br>
&gt; 2-) Stop one backend node (bin/pg_ctl -D data_5432/ stop)<br>
&gt; 3-) pgpool-II will perform failover.<br>
&gt; 4-) Connect to Pgpool-II using PSQL after failover is done.<br>
&gt;<br>
&gt; Step 4 is producing the segmentation fault<br>
&gt;<br>
&gt; The configuration file I was using for testing is attached and see below<br>
&gt; the stack trace.<br>
&gt;<br>
&gt; --stack trace--<br>
&gt;<br>
&gt; [usama@localhost pgpool]$ gdb --core /tmp/core_pgpool.97854 bin/pgpool<br>
&gt; GNU gdb (GDB) Red Hat Enterprise Linux 7.6.1-94.el7<br>
&gt; Copyright (C) 2013 Free Software Foundation, Inc.<br>
&gt; License GPLv3+: GNU GPL version 3 or later &lt;<a href="http://gnu.org/licenses/gpl.html" rel="noreferrer" target="_blank">http://gnu.org/licenses/gpl.<wbr>html</a><br>
&gt;&gt;<br>
&gt; This is free software: you are free to change and redistribute it.<br>
&gt; There is NO WARRANTY, to the extent permitted by law.  Type &quot;show copying&quot;<br>
&gt; and &quot;show warranty&quot; for details.<br>
&gt; This GDB was configured as &quot;x86_64-redhat-linux-gnu&quot;.<br>
&gt; For bug reporting instructions, please see:<br>
&gt; &lt;<a href="http://www.gnu.org/software/gdb/bugs/" rel="noreferrer" target="_blank">http://www.gnu.org/software/<wbr>gdb/bugs/</a>&gt;...<br>
&gt; Reading symbols from<br>
&gt; /home/usama/work/community/<wbr>installed/pgpool/bin/pgpool...<wbr>done.<br>
&gt; [New LWP 97854]<br>
&gt; [Thread debugging using libthread_db enabled]<br>
&gt; Using host libthread_db library &quot;/lib64/libthread_db.so.1&quot;.<br>
&gt; Core was generated by `pgpool: usama postgres  idle<br>
&gt;                          &#39;.<br>
&gt; Program terminated with signal 11, Segmentation fault.<br>
&gt; #0  0x0000000000422f21 in select_load_balancing_node () at<br>
&gt; protocol/child.c:1669<br>
&gt; 1669 char *database = MASTER_CONNECTION(ses-&gt;<wbr>backend)-&gt;sp-&gt;database;<br>
&gt; Missing separate debuginfos, use: debuginfo-install<br>
&gt; audit-libs-2.6.5-3.el7.x86_64 cyrus-sasl-lib-2.1.26-20.el7_<wbr>2.x86_64<br>
&gt; glibc-2.17-157.el7.x86_64 keyutils-libs-1.5.8-3.el7.x86_<wbr>64<br>
&gt; krb5-libs-1.14.1-27.el7_3.x86_<wbr>64 libcap-ng-0.7.5-4.el7.x86_64<br>
&gt; libcom_err-1.42.9-9.el7.x86_64 libgcc-4.8.5-11.el7.x86_64<br>
&gt; libmemcached-1.0.16-5.el7.x86_<wbr>64 libselinux-2.5-6.el7.x86_64<br>
&gt; libstdc++-4.8.5-11.el7.x86_64 nspr-4.13.1-1.0.el7_3.x86_64<br>
&gt; nss-3.28.2-1.6.el7_3.x86_64 nss-softokn-freebl-3.16.2.3-<wbr>14.4.el7.x86_64<br>
&gt; nss-util-3.28.2-1.1.el7_3.x86_<wbr>64 openldap-2.4.40-13.el7.x86_64<br>
&gt; openssl-libs-1.0.1e-60.el7_3.<wbr>1.x86_64 pam-1.1.8-18.el7.x86_64<br>
&gt; pcre-8.32-15.el7_2.1.x86_64 zlib-1.2.7-17.el7.x86_64<br>
&gt; (gdb) bt<br>
&gt; #0  0x0000000000422f21 in select_load_balancing_node () at<br>
&gt; protocol/child.c:1669<br>
&gt; #1  0x000000000043d935 in pool_init_session_context (frontend=&lt;optimized<br>
&gt; out&gt;, backend=&lt;optimized out&gt;) at context/pool_session_context.<wbr>c:97<br>
&gt; #2  0x0000000000423dee in do_child (fds=fds@entry=0xf41600) at<br>
&gt; protocol/child.c:350<br>
&gt; #3  0x00000000004087e5 in fork_a_child (fds=0xf41600, id=3) at<br>
&gt; main/pgpool_main.c:586<br>
&gt; #4  0x000000000040bf6e in failover () at main/pgpool_main.c:1952<br>
&gt; #5  0x000000000040ccce in sigusr1_interupt_processor () at<br>
&gt; main/pgpool_main.c:1427<br>
&gt; #6  0x000000000040df9a in PgpoolMain (discard_status=discard_<wbr>status@entry=1<br>
&gt; &#39;\001&#39;, clear_memcache_oidmaps=clear_<wbr>memcache_oidmaps@entry=0 &#39;\000&#39;) at<br>
&gt; main/pgpool_main.c:436<br>
&gt; #7  0x0000000000406dbe in main (argc=&lt;optimized out&gt;, argv=&lt;optimized out&gt;)<br>
&gt; at main/main.c:300<br>
&gt; (gdb)<br>
&gt;<br>
&gt;<br>
&gt; Thanks<br>
&gt; Best Regards<br>
&gt; Muhammad Usama<br>
</div></div></blockquote></div><br></div></div>