This post has been republished via RSS; it originally appeared at: Microsoft Tech Community - Latest Blogs - .
Azure Database for PostgreSQL Flexible Server is a fully managed database service offered by Microsoft Azure for PostgreSQL databases. It provides a flexible and customizable deployment option for PostgreSQL, which allows users to choose the compute and storage resources that best fit their workload requirements. Today, we are excited to announce the public preview of database availability monitoring in Azure Database for Postgres Flexible Server. This new feature provides you with real-time insights into the availability of your database, so you can quickly identify and resolve any issues that may arise.
With database availability monitoring, you can:
- View the status of your database.
- Get alerts when your database is unavailable.
- View historical data on database availability.
- Troubleshoot database availability issues.
To learn more about database availability monitoring, please visit our documentation, Database availability metric.
How does it work?
Database availability monitoring uses Azure Monitor and Azure Postgres Flexible Server to give you real-time insights into your database's availability. Database-Is-Alive is a gauge type metric based on database service health. Metric points are emitted at a 1-minute frequency and have up to 93 days (about 3 months) of retention. Azure Postgres Flexible Server automatically collects telemetry data for your database service. Azure Monitor then uses this data to calculate the availability of your database.
To start using the new metric in database availability metric, you need to:
- Go to the "Azure Database for PostgreSQL Flexible Server" portal.
- Click on the "Monitoring" blade.
- Click on the "Metrics" tile.
- In the "Metrics" blade, click on the "Add metric" button.
- In the "Add metric" dialog, select "Scope" and "Metric Namespace".
- In the "Metric" list, select the "Database Is Alive" metric.
- Select "Max" aggregation.
- Click on the "Add" button.
The new metric will now be displayed in the Azure Monitor dashboard. You can use the metric to track the availability of your Azure Postgres Flexible Server instance.
Let us consider a scenario
In this situation, we have a monitoring dashboard that tracks the "Database Is Alive" metric. Additionally, we are displaying the "Succeeded Connections" metric on the same dashboard for correlation purposes. At approximately 4:00 PM, the "Succeeded Connections" metric drops to zero. Concurrently, the "Database Is Alive" metric also reports zero, which indicates that the database is unavailable. It was discovered that the database had to be restarted, and it subsequently came back online at around 4:10 PM.
Some additional tips for using the new metric
- You can use the "Database Is Alive" metric to create Azure Monitor alerts that will notify you when your database is unavailable.
- You can use the metric to troubleshoot database availability over a period of time and generate reports.
- You can chart this metric along with other key metrics such App server, API (application programming interfaces) response for your application stack to quickly identify application availability issues in your environment.
In conclusion, the new Database availability monitoring feature in Azure Postgres Flexible Server is an exciting addition that offers increased visibility, control, and flexibility over databases' availability and performance. We are committed to providing our customers with the tools and features they need to ensure the reliability and uptime of their databases. We look forward to hearing feedback from our customers on how this new feature has helped them achieve their business goals.