Eric Mamet
Eric Mamet

Reputation: 3641

is it good to leave pg_stat_statements permanently on production servers?

I am fairly new to Postgresql (coming from SQL Server)

I came across that package and it looks very interesting.

Is it good practice to leave it on permanently on production servers?

On one hand, I want to know what actually loads my system in production. On the other hand, I don't want to load my server by monitoring either...

Upvotes: 2

Views: 893

Answers (1)

Laurenz Albe
Laurenz Albe

Reputation: 246113

I always enable it on production databases. The benefits are well worth the small performance hit.

Particularly on a production database you want to know which statements cause the most pain and should be optimized.

Upvotes: 6

Related Questions