pg_stat_replication

pg_stat_replication视图包含用于Greenplum数据库主镜像的walsender进程的元数据。

Table 1. pg_catalog.pg_stat_replication
类型参考描述
procpidinteger WAL-sender后台进程的进程ID。
usesysidinteger 运行WAL-sender后台进程的用户系统ID。
usenamename 运行WAL-sender后台进程的用户名。
application_nameoid 客户端应用名。
client_addrname 客户端IP地址。
client_portinteger 客户端端口号。
backend_starttimestamp 操作开始的时间戳。
statetext WAL发送状态。可取值有:

startup

backup

catchup

streaming

sent_locationtext WAL-sender已发送的xlog记录位置。
write_locationtext WAL-receiver的xlog记录写位置。
flush_locationtext WAL-receiver的xlog记录刷入位置。
replay_locationtext Standby xlog记录的重放位置。
sync_prioritytext 优先级,值为1
sync_statetext WAL-sender的同步状态。该值为sync

Parent topic: 系统目录定义