As we all know, PostgreSQL is a free object-relational database server (database management system), is a free access to the open source database system. In this paper, the PostgreSQL database server-side listening settings and client connection methods are described in detail as follows:
First, Background introduction:
The PostgreSQL server in this article runs on Redhat linux, IP: 192.168.230.128
The client is installed on Windows XP, IP is: 192.168.230.1
Second, the configuration method:
1. Modify the service-side/opt/postgresql/data/postgresql.conf file to:
#listen_address = ' localhost '
Change into
2. Modify the/opt/postgresql/data/gp_hba.conf file:
In which the IP of the client is increased, as follows, note the last line:
# TYPE DATABASE USER cidr-address Method
# ' local ' to Unix domain socket connections only
local< C6/>all all Trust
# IPv4 Local connections:
host all All 127.0.0.1/32 Trust
# IPV6 Local connections: "
host All": 1/128 trust
#kevin add
# IPV4 Local connections:
host all All 192.168.230.1/32 Trust
3. Restart PG Service:
[Postgres@localhost data]$ pg_ctl Restart
waiting for server to shut down .... Log:received Smart shutdown request
log:autovacuum launcher shutting down
log:shutting down
Log:databa SE system is shut down
do
server stopped
server starting
[Postgres@localhost data]$ log:database System was shut down at 2011-07-09 14:54:29 CST
log:autovacuum launcher started Log:database
system is ready t o Accept Connections
[Postgres@localhost data]$
4. Using client connections, configure the following:
5. Click "OK" to connect, after success, as follows: