The connection to the console is allowed only if the configuration parameter admin_users or stats_users.
In addition, if the connection is through a UNIX socket, and the client and the running process have the same UNIX user uid, the user is allowed to log on without a password via pgbouncer. [edit] Show command
The show command outputs some rows of data, which are described below. [edit] show STATS;
Displays statistics.
Database statistics are proportional to each of the databases.
The total number of SQL requests processed by the Total_requests pgbouncer connection pool.
The total number of bytes of network traffic that the Total_received Pgbouncer received.
Total number of bytes of network traffic emitted by Total_sent Pgbouncer.
Total_query_time Pgbouncer is active in the total amount of time spent with PostgreSQL, in milliseconds.
Avg_req average number of requests per second in the last statistical process.
Avg_recv The average amount of data received per second (from the client).
Avg_sent The average amount of data sent (to the client) per second.
Avg_query average query time, in milliseconds. [edit] show SERVERS;
Type S, representing the server.
User Pgbouncer the username used to connect to the server.
Database name on server side.
State Pgbouncer The status of the server connection, active,used or idle.
Addr The IP address of the PostgreSQL server.
Port PostgreSQL Server.
Local_addr The originating connection address on the local machine.
Local_port The originating connection port on the local machine.
Connect_time the time the connection was established.
Request_time the time the request was issued.
PTR the internal object address of this connection. Used as a unique ID.
Link this server corresponds to the client address. [edit] show CLIENTS;
Type C, which represents the client.
User Client connection.
Database name.
State Client Connection status, active,used,waiting or one of idle.
Addr The IP address of the client.
Port clients are connected to.
LOCAL_ADDR the End-to-end address that is connected to the local machine.
Local_port to the End-to-end port on the local machine.
Connect_time the timestamp of the last client connection.
Request_time the timestamp of the last client request.
The address of the internal object that PTR this connection. Used as a unique ID.
Link this client connects to the address of the corresponding server. [edit] show pools;
A new connection pool record is maintained for each pair (database, user).
Database name.
User username.
Cl_active the number of current active (active) client connections.
Cl_waiting the number of client connections currently waiting (waiting).
Sv_active the current active (active) Number of server connections.
Sv_idle the number of server connections currently idle (idle).
sv_used the number of server connections currently used (in use).
sv_tested the number of server connections currently tested (tested).
Sv_login the number of current login (login) to PostgreSQL servers.
The length of time, in seconds, that the first (oldest) client in the maxwait queue waits. If this number starts to rise, it means that the server in the current connection pool is not processing the request fast enough. The reason may be that the server is overloaded, or it may just be pool_size too small. [edit] show LISTS;
Displays the following internal information, which is displayed in a field (not by row):
Number of databases databases.
The number of users.
Number of pools connection pools.
Number of free_clients idle clients.
Used_clients the number of clients that have been used.
Login_clients the number of clients in the logged on state.
Free_servers the number of idle servers.
Used_servers number of servers already used. [edit] show USERS;
Each line displays a user, and the word Deming is name. [edit] show DATABASES;
Name records of database names that have been configured.
Hostname to which the host Pgbouncer is connected.
Port number to which port Pgbouncer is connected.
Database Pgbouncer the names of the databases that are actually connected.
Force_user When a user is part of a connection string, the connection between Pgbouncer and PostgreSQL is coerced into the given user, regardless of the client user.
Pool_size the maximum number of server-side connections. [edit] show FDS;
Displays the list of FD that is in use. If the user name of the connected user is "Pgbouncer", it is connected through a UNIX socket and has the same UID as the running process, and the actual FD list is passed through this connection. This mechanism is used to do online restart.
The numeric value of the FD file descriptor.
One of the task Pooler,client or servers.
User uses the connection users for this FD.
Database using the connection of this FD.
Addr uses the IP address of the connection for this FD, which is UNIX if the UNIX socket is used.
Port number that uses the connection port for this FD.
Cancel the key word for this connection.
Link corresponds to the server/client FD. If idle (idle) is null. [edit] show CONFIG;
Displays the current configuration settings, one row for configuration, and the following fields:
Key configuration variable Name
Value configuration values