Book Image

PostgreSQL 9 Administration Cookbook - Second Edition

Book Image

PostgreSQL 9 Administration Cookbook - Second Edition

Overview of this book

Table of Contents (19 chapters)
PostgreSQL 9 Administration Cookbook Second Edition
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Preface
Index

Chapter 8. Monitoring and Diagnosis

In this chapter, we will cover the following recipes:

  • Checking whether a user is connected

  • Checking which queries are running

  • Checking which queries are active or blocked

  • Knowing who is blocking a query

  • Killing a specific session

  • Detecting an in-doubt prepared transaction

  • Knowing whether anybody is using a specific table

  • Knowing when a table was last used

  • Usage of disk space by temporary data

  • Understanding why queries slow down

  • Investigating and reporting a bug

  • Producing a daily summary of log file errors

  • Analyzing the real-time performance of your queries