Get the App
SLTechnology News&Howtos  ›  Database  › 

How to implement PostgreSQL database server monitoring settings and client connection

Shulou Source: shulou.com Published: 2022-05-31 17:43:42 10月04日 Update

This article mainly explains "how to achieve PostgreSQL database server monitoring settings and client connection", the content of the article is simple and clear, easy to learn and understand, the following please follow the editor's ideas slowly in depth, together to study and learn "how to achieve PostgreSQL database server monitoring settings and client connection" bar!

Background introduction:

The PostgreSQL server described in this paper runs on RedHat Linux, and the IP is 192.168.230.128.

The client is installed on Windows XP, and the IP is 192.168.230.1

2. Configuration method:

1. Modify the server / opt/postgresql/data/postgresql.conf file to:

# listen_address='localhost'

Change to

Listen_address='*'

two。 Modify the / opt/postgresql/data/gp_hba.conf file:

Add the client's ip to it as follows, and note the last line:

# TYPE DATABASE USER CIDR-ADDRESS METHOD# "local" is for Unix domain socket connections onlylocal all all trust# IPv4 local connections:host all all 127.0.0.1 is for Unix domain socket connections onlylocal all all trust# IPv4 local connections:host all all 32 trust# IPv6 local connections:host all all:: 1 128 trust#kevin add# IPv4 local connections:host all all 192.168.230.1 trust

3. Restart the PG service:

[postgres@localhost data] $pg_ctl restartwaiting for server to shut down....LOG: received smart shutdown requestLOG: autovacuum launcher shutting downLOG: shutting downLOG: database system is shutdown doneserver stoppedserver starting [postgres@localhost data] $LOG: database system was shutdown at 2011-07-09 14:54:29 CSTLOG: autovacuum launcher startedLOG: database system is ready to accept connections [postgres@localhost data] $

4. Using a client connection, configure as follows:

5. Click "OK" to connect, after success, as follows:

Thank you for your reading, the above is "how to achieve PostgreSQL database server monitoring settings and client connection" content, after the study of this article, I believe you on how to achieve PostgreSQL database server monitoring settings and client connection this problem has a deeper understanding, the specific use also needs to be verified in practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!

Tags: Customers services clients data databases monitoring learning content files configuration success one line that is ideas situations articles methods more knowledge Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Shulou Information Docker NVidia OPPO Reno macOS