<div dir="ltr"><div><div><div>Hi Bo!<br><br></div>I changed the configuration to 

















<span style="font-size:12pt;line-height:125%;font-family:宋体" lang="EN-US">process_management_mode =static,</span> <br></div>and everything related to it as commented, but the mal-function persists.<br></div>Here is the log in debug mode:<br><span style="color:rgb(0,0,255)">2023-07-07 14:58:48.964: main pid 20671: DEBUG:  BackendDesc: 113672 bytes requested for shared memo<br>ry<br>2023-07-07 14:58:48.964: main pid 20671: DEBUG:  pool_coninfo_size: num_init_children (32) * max_poo<br>l (4) * MAX_NUM_BACKENDS (128) * sizeof(ConnectionInfo) (160) = 2621440 bytes requested for shared m<br>emory<br>2023-07-07 14:58:48.964: main pid 20671: DEBUG:  ProcessInfo: num_init_children (32) * sizeof(Proces<br>sInfo) (48) = 1536 bytes requested for shared memory<br>2023-07-07 14:58:48.964: main pid 20671: DEBUG:  UserSignalSlot: 24 bytes requested for shared memor<br>y<br>2023-07-07 14:58:48.964: main pid 20671: DEBUG:  POOL_REQUEST_INFO: 5272 bytes requested for shared<br>memory<br>2023-07-07 14:58:48.964: main pid 20671: DEBUG:  stat_shared_memory_size: 9216 bytes requested for s<br>hared memory<br>2023-07-07 14:58:48.964: main pid 20671: LOG:  health_check_stats_shared_memory_size: requested size<br>: 12288<br>2023-07-07 14:58:48.964: main pid 20671: DEBUG:  SI_ManageInfo: 24 bytes requested for shared memory<br>2023-07-07 14:58:48.964: main pid 20671: LOG:  memory cache initialized<br>2023-07-07 14:58:48.964: main pid 20671: DETAIL:  memcache blocks :64<br>2023-07-07 14:58:48.964: main pid 20671: DEBUG:  shared_memory_cache_size: 67108864<br>2023-07-07 14:58:48.964: main pid 20671: DEBUG:  shared_memory_fsmm_size: 64<br>2023-07-07 14:58:48.964: main pid 20671: DEBUG:  pool_hash_size: 67108880<br>2023-07-07 14:58:48.964: main pid 20671: DEBUG:  POOL_QUERY_CACHE_STATS: 24 bytes requested for shared memory<br>2023-07-07 14:58:48.964: main pid 20671: LOG:  allocating (136981824) bytes of shared memory segment<br>2023-07-07 14:58:48.964: main pid 20671: LOG:  allocating shared memory segment of size: 136981824<br>2023-07-07 14:58:49.041: main pid 20671: DEBUG:  pool_coninfo_size: num_init_children (32) * max_pool (4) * MAX_NUM_BACKENDS (128) * sizeof(ConnectionInfo) (160) = 2621440 bytes requested for shared memory<br>2023-07-07 14:58:49.041: main pid 20671: LOG:  health_check_stats_shared_memory_size: requested size: 12288<br>2023-07-07 14:58:49.041: main pid 20671: LOG:  health_check_stats_shared_memory_size: requested size: 12288<br>2023-07-07 14:58:49.041: main pid 20671: LOG:  memory cache initialized<br>2023-07-07 14:58:49.041: main pid 20671: DETAIL:  memcache blocks :64<br>2023-07-07 14:58:49.041: main pid 20671: DEBUG:  shared_memory_cache_size: 67108864<br>2023-07-07 14:58:49.041: main pid 20671: DEBUG:  memory cache request size : 67108864<br>2023-07-07 14:58:49.041: main pid 20671: DEBUG:  shared_memory_fsmm_size: 64<br>2023-07-07 14:58:49.044: main pid 20671: LOG:  pool_discard_oid_maps: discarded memqcache oid maps<br>2023-07-07 14:58:49.058: main pid 20671: LOG:  unix_socket_directories[0]: /run/.s.PGSQL.9999<br>2023-07-07 14:58:49.059: main pid 20671: LOG:  listen address[0]: *<br>2023-07-07 14:58:49.059: main pid 20671: LOG:  Setting up socket for <a href="http://0.0.0.0:9999">0.0.0.0:9999</a><br>2023-07-07 14:58:49.059: main pid 20671: LOG:  Setting up socket for :::9999<br>2023-07-07 14:58:49.061: child pid 20680: DEBUG:  initializing backend status<br>2023-07-07 14:58:49.061: child pid 20679: DEBUG:  initializing backend status<br>2023-07-07 14:58:49.061: child pid 20678: DEBUG:  initializing backend status<br>2023-07-07 14:58:49.061: child pid 20681: DEBUG:  initializing backend status<br>2023-07-07 14:58:49.062: child pid 20677: DEBUG:  initializing backend status<br>2023-07-07 14:58:49.062: child pid 20682: DEBUG:  initializing backend status<br>2023-07-07 14:58:49.062: child pid 20683: DEBUG:  initializing backend status<br>2023-07-07 14:58:49.062: child pid 20676: DEBUG:  initializing backend status<br>2023-07-07 14:58:49.064: child pid 20684: DEBUG:  initializing backend status<br>2023-07-07 14:58:49.064: child pid 20685: DEBUG:  initializing backend status<br>2023-07-07 14:58:49.064: child pid 20686: DEBUG:  initializing backend status<br>2023-07-07 14:58:49.064: child pid 20675: DEBUG:  initializing backend status</span><div><span style="color:rgb(0,0,255)">2023-07-07 14:58:49.067: child pid 20697: DEBUG:  initializing backend status<br>2023-07-07 14:58:49.067: child pid 20698: DEBUG:  initializing backend status<br>2023-07-07 14:58:49.067: child pid 20699: DEBUG:  initializing backend status<br>2023-07-07 14:58:49.067: child pid 20700: DEBUG:  initializing backend status<br>2023-07-07 14:58:49.068: child pid 20674: DEBUG:  initializing backend status<br>2023-07-07 14:58:49.069: main pid 20671: DEBUG:  find_primary_node_repeatedly: not in streaming replication mode<br>2023-07-07 14:58:49.069: main pid 20671: LOG:  listen address[0]: localhost<br>2023-07-07 14:58:49.069: main pid 20671: LOG:  Setting up socket for ::1:9898<br>2023-07-07 14:58:49.069: main pid 20671: LOG:  Setting up socket for <a href="http://127.0.0.1:9898">127.0.0.1:9898</a><br>2023-07-07 14:58:49.069: child pid 20701: DEBUG:  initializing backend status<br>2023-07-07 14:58:49.070: child pid 20705: DEBUG:  initializing backend status<br>2023-07-07 14:58:49.070: child pid 20704: DEBUG:  initializing backend status<br>2023-07-07 14:58:49.070: sr_check_worker pid 20707: LOG:  process started<br>2023-07-07 14:58:49.070: pcp_main pid 20706: DEBUG:  I am PCP child with pid:20706<br>2023-07-07 14:58:49.070: sr_check_worker pid 20707: DEBUG:  I am 20707<br>2023-07-07 14:58:49.070: main pid 20671: LOG:  pgpool-II successfully started. version 4.4.3 (nurikoboshi)<br>2023-07-07 14:58:49.070: child pid 20703: DEBUG:  initializing backend status<br>2023-07-07 14:58:49.070: pcp_main pid 20706: LOG:  PCP process: 20706 started<br>2023-07-07 14:58:49.071: child pid 20702: DEBUG:  initializing backend status<br>2023-07-07 14:59:12.379: child pid 20684: DEBUG:  reading startup packet<br>2023-07-07 14:59:12.379: child pid 20684: DETAIL:  Protocol Major: 1234 Minor: 5679 database:  user:<br>2023-07-07 14:59:12.379: child pid 20684: DEBUG:  forwarding error message to frontend<br>2023-07-07 14:59:12.379: child pid 20684: FATAL:  pgpool is not accepting any new connections<br>2023-07-07 14:59:12.379: child pid 20684: DETAIL:  all backend nodes are down, pgpool requires at least one valid node<br>2023-07-07 14:59:12.379: child pid 20684: HINT:  repair the backend nodes and restart pgpool<br>2023-07-07 14:59:12.380: main pid 20671: LOG:  reaper handler<br>2023-07-07 14:59:12.380: main pid 20671: DEBUG:  child process with pid: 20684 exits with status 256<br>2023-07-07 14:59:12.380: main pid 20671: DEBUG:  fork a new child process with pid: 20711<br>2023-07-07 14:59:12.380: main pid 20671: LOG:  reaper handler: exiting normally<br>2023-07-07 14:59:12.380: child pid 20711: DEBUG:  initializing backend status</span><br><br></div><div>And attached is the new configuration.<br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, Jul 5, 2023 at 3:58 PM Bo Peng <<a href="mailto:pengbo@sraoss.co.jp">pengbo@sraoss.co.jp</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi,<br>
<br>
Thank you for sharing the configuration file.<br>
<br>
You are using "dynamic process management mode".<br>
It seems if max_spare_children is greater than num_init_children,<br>
segment fault occurs.<br>
<br>
I think it is a bug of pgpool.<br>
I will share your report with the developer who is in charge of dynamic process management mode.<br>
<br>
On Wed, 5 Jul 2023 13:39:51 +0800<br>
Zhaoxun Yan <<a href="mailto:yan.zhaoxun@gmail.com" target="_blank">yan.zhaoxun@gmail.com</a>> wrote:<br>
<br>
> On Wed, Jul 5, 2023 at 1:00 PM Bo Peng <<a href="mailto:pengbo@sraoss.co.jp" target="_blank">pengbo@sraoss.co.jp</a>> wrote:<br>
> <br>
> > Hi,<br>
> ><br>
> > I tested 4.4.3 and it should not happen normally.<br>
> > Could you share your pgpool.conf?<br>
> ><br>
> > On Wed, 5 Jul 2023 12:03:29 +0800<br>
> > Zhaoxun Yan <<a href="mailto:yan.zhaoxun@gmail.com" target="_blank">yan.zhaoxun@gmail.com</a>> wrote:<br>
> ><br>
> > > Hi guys!<br>
> > ><br>
> > > Is it a bug? I started local postgres as  backend_hostname0 =<br>
> > '172.17.0.2'<br>
> > > And it is visitable:<br>
> > > # psql -h 172.17.0.2 -p 5432 -U checker template1<br>
> > > Password for user checker:<br>
> > > psql (13.10)<br>
> > > Type "help" for help.<br>
> > ><br>
> > > template1=> \q<br>
> > ><br>
> > > Although pgpool is listening on 9999:<br>
> > > # ss -tlnp<br>
> > > State        Recv-Q       Send-Q             Local Address:Port<br>
> > > Peer Address:Port       Process<br>
> > > LISTEN       0            244                      <a href="http://0.0.0.0:5432" rel="noreferrer" target="_blank">0.0.0.0:5432</a><br>
> > >      0.0.0.0:*           users:(("postgres",pid=8680,fd=6))<br>
> > > LISTEN       0            64                     <a href="http://127.0.0.1:9898" rel="noreferrer" target="_blank">127.0.0.1:9898</a><br>
> > >      0.0.0.0:*<br>
> > ><br>
> > users:(("pgpool",pid=8780,fd=11),("pgpool",pid=8773,fd=11),("pgpool",pid=8720,fd=11))<br>
> > > LISTEN       0            64                       <a href="http://0.0.0.0:9999" rel="noreferrer" target="_blank">0.0.0.0:9999</a><br>
> > >      0.0.0.0:*<br>
> > ><br>
> > users:(("pgpool",pid=8780,fd=5),("pgpool",pid=8773,fd=5),("pgpool",pid=8754,fd=5),("pgpool",pid=8753,fd=5),("pgpool",pid=8752,fd=5),("pgpool",pid=8751,fd=5),("pgpool",pid=8750,fd=5),("pgpool",pid=8749,fd=5),("pgpool",pid=8748,fd=5),("pgpool",pid=8747,fd=5),("pgpool",pid=8746,fd=5),("pgpool",pid=8745,fd=5),("pgpool",pid=8744,fd=5),("pgpool",pid=8742,fd=5),("pgpool",pid=8741,fd=5),("pgpool",pid=8740,fd=5),("pgpool",pid=8739,fd=5),("pgpool",pid=8738,fd=5),("pgpool",pid=8737,fd=5),("pgpool",pid=8736,fd=5),("pgpool",pid=8735,fd=5),("pgpool",pid=8734,fd=5),("pgpool",pid=8733,fd=5),("pgpool",pid=8732,fd=5),("pgpool",pid=8731,fd=5),("pgpool",pid=8730,fd=5),("pgpool",pid=8729,fd=5),("pgpool",pid=8728,fd=5),("pgpool",pid=8727,fd=5),("pgpool",pid=8726,fd=5),("pgpool",pid=8724,fd=5),("pgpool",pid=8723,fd=5),("pgpool",pid=8720,fd=5))<br>
> > > LISTEN       0            128                      <a href="http://0.0.0.0:22" rel="noreferrer" target="_blank">0.0.0.0:22</a><br>
> > >      0.0.0.0:*           users:(("sshd",pid=1395,fd=3))<br>
> > > LISTEN       0            244                         [::]:5432<br>
> > >         [::]:*           users:(("postgres",pid=8680,fd=7))<br>
> > > LISTEN       0            64                         [::1]:9898<br>
> > >         [::]:*<br>
> > ><br>
> > users:(("pgpool",pid=8780,fd=10),("pgpool",pid=8773,fd=10),("pgpool",pid=8720,fd=10))<br>
> > > LISTEN       0            64                          [::]:9999<br>
> > >         [::]:*<br>
> > ><br>
> > users:(("pgpool",pid=8780,fd=6),("pgpool",pid=8773,fd=6),("pgpool",pid=8754,fd=6),("pgpool",pid=8753,fd=6),("pgpool",pid=8752,fd=6),("pgpool",pid=8751,fd=6),("pgpool",pid=8750,fd=6),("pgpool",pid=8749,fd=6),("pgpool",pid=8748,fd=6),("pgpool",pid=8747,fd=6),("pgpool",pid=8746,fd=6),("pgpool",pid=8745,fd=6),("pgpool",pid=8744,fd=6),("pgpool",pid=8742,fd=6),("pgpool",pid=8741,fd=6),("pgpool",pid=8740,fd=6),("pgpool",pid=8739,fd=6),("pgpool",pid=8738,fd=6),("pgpool",pid=8737,fd=6),("pgpool",pid=8736,fd=6),("pgpool",pid=8735,fd=6),("pgpool",pid=8734,fd=6),("pgpool",pid=8733,fd=6),("pgpool",pid=8732,fd=6),("pgpool",pid=8731,fd=6),("pgpool",pid=8730,fd=6),("pgpool",pid=8729,fd=6),("pgpool",pid=8728,fd=6),("pgpool",pid=8727,fd=6),("pgpool",pid=8726,fd=6),("pgpool",pid=8724,fd=6),("pgpool",pid=8723,fd=6),("pgpool",pid=8720,fd=6))<br>
> > > LISTEN       0            128                         [::]:22<br>
> > >         [::]:*           users:(("sshd",pid=1395,fd=4))<br>
> > ><br>
> > > It is not visitable:<br>
> > > # psql -h 127.0.0.1 -p 9999 -U checker template1<br>
> > > psql: error: server closed the connection unexpectedly<br>
> > >         This probably means the server terminated abnormally<br>
> > >         before or while processing the request.<br>
> > > Checking out the log, any pgpool subprocess is killed by segment fault.<br>
> > > And I run it again using debug mode, the same thing happens.<br>
> > > Attached is the pgpool log. Thanks in advance.<br>
> ><br>
> ><br>
> > --<br>
> > Bo Peng <<a href="mailto:pengbo@sraoss.co.jp" target="_blank">pengbo@sraoss.co.jp</a>><br>
> > SRA OSS LLC<br>
> > TEL: 03-5979-2701 FAX: 03-5979-2702<br>
> > URL: <a href="https://www.sraoss.co.jp/" rel="noreferrer" target="_blank">https://www.sraoss.co.jp/</a><br>
> ><br>
<br>
<br>
-- <br>
Bo Peng <<a href="mailto:pengbo@sraoss.co.jp" target="_blank">pengbo@sraoss.co.jp</a>><br>
SRA OSS LLC<br>
TEL: 03-5979-2701 FAX: 03-5979-2702<br>
URL: <a href="https://www.sraoss.co.jp/" rel="noreferrer" target="_blank">https://www.sraoss.co.jp/</a><br>
</blockquote></div>