Postgresql 中文操作指南
Chapter 28. Monitoring Database Activity
Table of Contents
数据库管理员经常想知道,“系统现在正在做什么?”本章讨论如何找出这一点。
A database administrator frequently wonders, “What is the system doing right now?” This chapter discusses how to find that out.
有几个工具可用于监视数据库活动并分析性能。本章大部分内容致力于描述 PostgreSQL 的累积统计系统,但不应忽视常规 Unix 监视程序,如 ps 、 top 、 iostat 和 vmstat 。此外,一旦识别出性能不佳的查询,可能需要使用 PostgreSQL 的 EXPLAIN 命令进行进一步调查。 Section 14.1 讨论了 EXPLAIN 和其他方法以了解个人查询的行为。
Several tools are available for monitoring database activity and analyzing performance. Most of this chapter is devoted to describing PostgreSQL’s cumulative statistics system, but one should not neglect regular Unix monitoring programs such as ps, top, iostat, and vmstat. Also, once one has identified a poorly-performing query, further investigation might be needed using PostgreSQL’s EXPLAIN command. Section 14.1 discusses EXPLAIN and other methods for understanding the behavior of an individual query.