Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1c4phW-0008Eq-0K for pgsql-admin@arkaria.postgresql.org; Thu, 10 Nov 2016 13:47:34 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1c4phV-0002Y8-J5 for pgsql-admin@arkaria.postgresql.org; Thu, 10 Nov 2016 13:47:33 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1c4XAp-0006ha-Su for pgsql-admin@postgresql.org; Wed, 09 Nov 2016 18:00:36 +0000 Received: from mail-ua0-x244.google.com ([2607:f8b0:400c:c08::244]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.84_2) (envelope-from ) id 1c4XAm-00010u-P7 for pgsql-admin@postgresql.org; Wed, 09 Nov 2016 18:00:34 +0000 Received: by mail-ua0-x244.google.com with SMTP id 12so9685524uas.3 for ; Wed, 09 Nov 2016 10:00:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dssolutions-com.20150623.gappssmtp.com; s=20150623; h=from:mime-version:thread-index:date:message-id:subject:to; bh=f2WVX9dnqsJxP+t88fEsB4gtlIt0NmZDALfnF2wRVdk=; b=BenIx/1MaBH41IQariwgRYMz9BHh03fMXwVw8A0p6p8Pk9ZKUUr3THtvM+/fns/4wf DqbQGMhYj4K5GXTLbc1BBWF35JnmoXjINy+CiQ98jBy3e7rnjlSnloSbYqDrtVl5ljNJ jMuA0dF3vbyF2tfZIt9FWU6NmoiMOXSZnMuzM1j6ev+EafZ/+MSkbh0AHh7LvjCmcY4b sRykUqPuaExePqVt6Nbw42iXO+XpAjijfshHRJj4NV5IdyajX9NYk4E1POyBjxTK1qLc gPIg9mCsl4w1HE/fZS9CpqwEVTmTh0c2vlN/hoFKm4JblGEUOiJ3NSGtiRf9Xr5nOOsL 5rQg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:mime-version:thread-index:date:message-id :subject:to; bh=f2WVX9dnqsJxP+t88fEsB4gtlIt0NmZDALfnF2wRVdk=; b=LrJNWvpREJ9x1hDaHysVLgE9mXuD5cgNwjD5HjR0L5h0Q0jq9WN5SNAKH8TnLQlYj+ mzHx4Js8q5ZqyExystQEdwijgVSpBHUp4foSV+zZ/dbLPz9MgRWwHncHatbb4/Ikc/Of Yd8wP4JjB2RU8Tp3dto8c+2Eoab6OoNek5sSX2l764HkKVAKWA+iKeI/fRJKQYXcojNx 83O7TvzmzgDuhYpAc7kwwy3Fo0PzMdwDY4sQ3sLDfzeMg2mNbsPqQBlW9FYDlS9zY3dJ 6bv/36SlZLQC1BlrhQnYY1pGotictjJnIvdsdhPm9M7u9CyWtpl1TM2QIq/vy3PMeu0P vQ8w== X-Gm-Message-State: ABUngvchSBe+AGVqxM2LN6ondlRI0SwtZrW1M7LUvvLQ3XLpTbhzJtKpWBaudLK3eA9msVGHBbBe68EnB5AoFQJW X-Received: by 10.176.67.196 with SMTP id l62mr521996ual.164.1478714431191; Wed, 09 Nov 2016 10:00:31 -0800 (PST) From: Ron Watkins MIME-Version: 1.0 X-Mailer: Microsoft Outlook 14.0 Thread-Index: AdI6soAxdXLU4rkjSm2uuYAp3SdXuA== Date: Wed, 9 Nov 2016 11:00:24 -0700 Message-ID: Subject: psql remote database access To: pgsql-admin@postgresql.org Content-Type: multipart/alternative; boundary=001a114bdf606554060540e20859 X-Pg-Spam-Score: -1.9 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-admin Precedence: bulk Sender: pgsql-admin-owner@postgresql.org --001a114bdf606554060540e20859 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Im sure this has been addressed somewhere, but I wasn=E2=80=99t able to loc= ate any answers. I have a postgres database running on a different host and I need to access it remotely from another box. Boxes are CentOS 6, and I opened the firewall port 5432 on the database server host. Also, on the database server host, I made the following entries to /var/lib/pgsql/9.6/data/pg_hba.conf. local all all md5 host all all 127.0.0.1/32 md5 host all all 10.42.42.16/24 md5 When I try to use psql to attach to the remote database, I get the following error: [root@host1 ~]# psql -h host2 -p 5432 -U postgres psql: FATAL: no pg_hba.conf entry for host "10.0.0.254", user "postgres", database "postgres", SSL off --001a114bdf606554060540e20859 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable

Im sure this has been address= ed somewhere, but I wasn=E2=80=99t able to locate any answers.

I have a postgres database running on a different host and I= need to access it remotely from another box.

=C2= =A0

Boxes are CentOS 6, and I opened the firewall= port 5432 on the database server host.

Also, on = the database server host, I made the following entries to /var/lib/pgsql/9.6/data/= pg_hba.conf.

local=C2=A0=C2=A0 all=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 all=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 md5

host=C2=A0=C2=A0=C2=A0 all=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 all=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 127.0.= 0.1/32=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0 md5

host=C2=A0=C2=A0=C2=A0 all=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 all=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 10.42.42.16/24=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0 md5

=C2=A0

When I try to use psql to attach to the remote database, I g= et the following error:

[root@host1 ~]# psql -h host2 -= p 5432 -U postgres

psql: FATAL:=C2=A0 no pg_hba.c= onf entry for host "10.0.0.254", user "postgres", datab= ase "postgres", SSL off

--001a114bdf606554060540e20859--