Insights and metrics

Crunchy Bridge provides a few different mechanisms for getting insights into your Postgres database and metrics related to it:

  • Insights - These are point in time insights into your database base on Postgres' internal systems.
  • Metrics - These are metrics that Crunchy Bridge's internal monitoring captures and records against your system
  • Production check - This lists the status of your cluster using our list of recommended settings.
  • Scope - cb scope is the equivalent of insights available in your CLI.

Users with admin or manager permissions are able to view Insights by default. You can also create a custom access group to provide the Insights View permission to any users on your team.

Insights

Database insights provides point in time insights into your database along with recommendations on actions you can take to improve performance. These insights include:

For Crunchy Data Warehouse, additional table insights:

Resetting statistics

Postgres statistics can collect over long periods of time. It can be a good idea to reset statistics if you've made major changes like adding indexes or updating your application for performance improvements. This can help with validating updates. See Refreshing system statistics for when to reset statistics.

You can do a manual reset from the cluster settings:

A full statistics reset delays autovacuum, because autovacuum uses the insert, update, and delete counters to decide when to visit a table. Reset query statistics, or the counters for a single table, instead.

Reset query statistics:

SELECT pg_stat_statements_reset();

Reset statistics for one table:

SELECT pg_stat_reset_single_table_counters('public.sampletable'::regclass);

If you want to see the last time insights were refreshed, run:

SELECT stats_reset FROM pg_stat_database WHERE datname = current_database();

Metrics

You can find system metrics on the Crunchy Bridge Dashboard under the Metrics tab. Metrics monitored and displayed in the Dashboard include:

Resetting metrics

Metrics are tied to the individual instance and are reset anytime you have a failover to a new machine for maintenance, upgrade, or version change. If you currently have HA enabled, you will see duplicate metrics.

Production checks

You can find the production check under Cluster Overview panel at the bottom left. See Production check for additional documentation.

Scope

The data in the insights tab in the Dashboard is available by running cb scope --cluster CLUSTER_ID --suite all.