简体   繁体   English

如何为 crunchy data postgres 运算符查看/安装 pg_activity?

[英]How to see/install pg_activity for the crunchy data postgres operator?

I have setup an Rancher (RKE) (kuberbetes) for my application.我已经为我的应用程序设置了 Rancher (RKE) (kuberbetes)。

and application using the postgres so i have setup Crunchydata postgres operator and create postgres cluster using that.和使用 postgres 的应用程序,所以我设置了 Crunchydata postgres 运算符并使用它创建 postgres 集群。

everything fine but now i want to see the pg_activity for my postgresql.一切都很好,但现在我想查看我的 postgresql 的 pg_activity。

how i can see the activity of whole postgres?我怎样才能看到整个 postgres 的活动?

you use the monitoring tools in rancher to monitor the Postgres.你使用 Rancher 中的监控工具来监控 Postgres。

apart from that you can SSH inside the respective pod of the database and use the cli command and check the output.除此之外,您可以在数据库的相应 pod 内使用 SSH 并使用 cli 命令并检查 output。

In rancher, you can also use the client tool to connect with the rancher and run the cli command to check the pg_activity.在rancher中,也可以使用客户端工具连接rancher,运行cli命令查看pg_activity。

Client docker image: https://hub.docker.com/r/jbergknoff/postgresql-client/客户端 docker 映像: https://hub.docker.com/r/jbergknoff/postgresql-client/

you can also deploy the GUI docker client on rancher and use it您还可以在 Rancher 上部署 GUI docker 客户端并使用它

GUI postgress client: https://hub.docker.com/r/dpage/pgadmin4/ GUI postgress 客户端: https://hub.docker.com/r/dpage/pgadmin4/

GUI Example: https://dataedo.com/kb/query/postgresql/list-database-sessions#:~:text=Using%20pgAdmin,all%20connected%20sessions%20(3) . GUI 示例: https://dataedo.com/kb/query/postgresql/list-database-sessions#:~:text=Using%20pgAdmin,all%20connected%20sessions%20(3)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM