Home icon

Performance impact of excessive logging in Amazon Aurora PostgreSQL

Database Blog



This article demonstrates how excessive error and audit logging in Amazon Aurora PostgreSQL can become a hidden performance bottleneck, with costs that only manifest at high concurrency levels.

  • At low concurrency (8 clients), verbose logging and pgaudit show negligible performance impact within normal variance
  • At high concurrency (800 clients), verbose statement logging reduces throughput by ~10% (16,202 to 14,654 TPS)
  • Adding pgaudit.log=ALL cuts throughput by ~70% (16,202 to 5,039 TPS) and increases latency from 49ms to 158ms
  • Bottleneck sits in log-writing path, not query execution; pg_stat_activity shows 97% CPU usage with minimal wait events
  • pgaudit logs nested statements inside functions, generating 537MB log files per minute at 800 concurrent clients
  • Recommendations: test at production-representative concurrency, use pgaudit.log_statement=off to drop SQL text, audit only needed statement classes, sample pg_stat_activity to confirm bottleneck

Logging configuration changes must be validated under realistic concurrent load, not development-scale testing, to avoid discovering performance costs only in production.



Go to article

The AWS News Feed is currently looking for gold sponsors. If you want to support the AWS community and reach a large audience of AWS professionals, consider sponsoring the AWS News Feed.

Related articles

Nov 18
2026
Amazon Aurora DSQL now supports audit logging
Nov 16
2026
PostgreSQL large objects: Best practices for Amazon Aurora and RDS
Nov 16
2026
How to use Amazon Aurora DSQL audit logs
Nov 11
2026
Diagnose Amazon Aurora MySQL performance using CloudWatch Database Insights

The AWS News Feed is currently looking for silver sponsors. If you want to support the AWS community and reach a large audience of AWS professionals, consider sponsoring the AWS News Feed.