<div dir="ltr">Indeed, setting:<div> "host all all all password"<br></div><div>finally run and a database connection was succesfuly stablished from drupal<br></div><div><br></div><div>Apart from configuring hostssl, I still haven't found why client's ip aren't those specified...</div><div><br></div><div>How could I know which IP is connecting to DB in order to properly configure hba file?</div><div><br></div><div>Thanks a lot.</div><div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Aug 3, 2023 at 9:27 AM 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 your reply.<br>
<br>
> $ cat /opt/bitnami/pgpool/conf/pool_hba.conf<br>
> host all all <a href="http://192.162.122.0/24" rel="noreferrer" target="_blank">192.162.122.0/24</a> password<br>
> local all all trust<br>
> host all replica all trust<br>
> host all postgres all scram-sha-256<br>
> host all wide all trust<br>
> host all pop_user all trust<br>
> host all all all scram-sha-256<br>
<br>
I think one possible reason is that the client IP address doesn't match <a href="http://192.162.122.0/24" rel="noreferrer" target="_blank">192.162.122.0/24</a>.<br>
<br>
If the client doesn't match any entry, pgpool will return an error like:<br>
<br>
DETAIL: no pool_hba.conf entry for host "...", user "postgres"..., database "..."<br>
<br>
However, as you mentioned the connection failed with an error:<br>
<br>
DETAIL: pool_passwd file does not contain an entry for ...<br>
<br>
<br>
I guess your application matched the last entry "host all all all scram-sha-256".<br>
In this case, pgpool will try to read password from pool_passwd file.<br>
<br>
If it is possible, could you try to change the setting to "host all all all password"?<br>
In this case, if your application can successfully connect to pgpool-II,<br>
it can be determined that your application does not match <a href="http://192.162.122.0/24" rel="noreferrer" target="_blank">192.162.122.0/24</a>.<br>
<br>
On Wed, 2 Aug 2023 13:30:08 +0200<br>
Tan Mientras <<a href="mailto:tanimientras@gmail.com" target="_blank">tanimientras@gmail.com</a>> wrote:<br>
<br>
> pgadmin also fails to connect to other database than postgres/postgres (?)<br>
> <br>
> On Wed, Aug 2, 2023 at 12:43 PM Tan Mientras <<a href="mailto:tanimientras@gmail.com" target="_blank">tanimientras@gmail.com</a>> wrote:<br>
> <br>
> > $ cat /opt/bitnami/pgpool/conf/pool_hba.conf<br>
> > host all all <a href="http://192.162.122.0/24" rel="noreferrer" target="_blank">192.162.122.0/24</a> password<br>
> > local all all trust<br>
> > host all replica all trust<br>
> > host all postgres all scram-sha-256<br>
> > host all wide all trust<br>
> > host all pop_user all trust<br>
> > host all all all scram-sha-256<br>
> ><br>
> ><br>
> > On Wed, Aug 2, 2023 at 12:40 PM Tan Mientras <<a href="mailto:tanimientras@gmail.com" target="_blank">tanimientras@gmail.com</a>><br>
> > wrote:<br>
> ><br>
> >><br>
> >> Did you get the error when your application connects to pgpool or<br>
> >>> when you connect to pgpool using psql?<br>
> >>><br>
> >> when the application (drupal site/php) connects to db.<br>
> >><br>
> >><br>
> >><br>
> >>> As you mentioned you are using bitnami docker image.<br>
> >>> Sorry, I am not familiar with bitnami docker image.<br>
> >>> Please make sure the setting was updated.<br>
> >>><br>
> >><br>
> >><br>
> >> $ grep enable_pool_hba /opt/bitnami/pgpool/conf/pgpool.conf<br>
> >> enable_pool_hba = 'on'<br>
> >><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>