> ## Documentation Index
> Fetch the complete documentation index at: https://cockroachlabs.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Alerts Page

export const InternalLink = ({version, path = "", children, ...props}) => {
  let detectedVersion = version || "stable";
  if (typeof window !== 'undefined' && !version) {
    const match = window.location.pathname.match(/\/docs\/([^/]+)/);
    if (match) {
      detectedVersion = match[1];
    }
  }
  const normalizedPath = path.startsWith("/") ? path.slice(1) : path;
  return <a href={`/docs/${detectedVersion}/${normalizedPath}`} {...props}>
      {children}
    </a>;
};

The **Alerts** page allows you to enable email alerts, send test alerts, and view the email recipients and alert history for your CockroachDB Cloud organization. To view the Alerts page, [log in](https://cockroachlabs.cloud/) and click **Alerts**.

<Note>
  The **Alerts** page is applicable for CockroachDB Advanced clusters in your CockroachDB Cloud organization. For CockroachDB Standard and Basic clusters in your organization, all <InternalLink path="authorization#organization-admin">Organization Admins</InternalLink> automatically receive email alerts when your cluster reaches 50%, 75%, and 100% of your <InternalLink version="stable" path="architecture/glossary#resource-limits">resource limits</InternalLink>.
</Note>

## Automatic alerts

### Cluster Maintenance

<InternalLink path="authorization#organization-admin">Organization Admins</InternalLink> receive email alerts when:

* A cluster is scheduled for an automatic <InternalLink path="upgrade-policy#patch-version-upgrades">patch version upgrade</InternalLink> and again after the upgrade is complete.
* When a cluster is scheduled for <InternalLink path="advanced-cluster-management#set-a-maintenance-window">maintenance</InternalLink> that could temporarily impact the cluster's performance.
* When a cluster's CockroachDB version is nearing <InternalLink version="releases" path="release-support-policy#support-phases">unsupported</InternalLink> and must be upgraded to maintain support.

### CMEK

The <InternalLink path="cmek">Customer-Managed Encryption Keys (CMEK)</InternalLink> alert is triggered when the cluster node is unable to start due to CMEK key access failure.

If you receive the alert repeatedly, verify the following:

* The key is still enabled in their cloud provider KMS.
* The role or account used to access the key still has valid permissions.
* The credentials or access key are still valid, and generate new credentials if needed.

## Opt-in alerts

Even with CockroachDB's various <InternalLink version="stable" path="frequently-asked-questions#how-does-cockroachdb-survive-failures">built-in safeguards</InternalLink> against failure, it is critical to [enable](#configure-alerts) alerts and actively monitor the overall health and performance of a cluster running in production.

<Note>
  CockroachDB Advanced clusters do not auto-scale and upgrade cluster capacity in response to utilization alerts. If you receive an alert repeatedly, you may need to <InternalLink version="stable" path="make-queries-fast">optimize your workload</InternalLink> or <InternalLink path="advanced-cluster-management#scale-your-cluster">scale your CockroachDB Cloud cluster</InternalLink>.
</Note>

If alerts are enabled, CockroachDB Cloud sends alerts to [specified email recipients](#configure-alerts) when the following usage metrics are detected:

### Storage Utilization

Storage utilization alerts are triggered when:

* Cluster-wide available disk capacity is **20% or less**.
* Node-level available disk capacity is **10% or less**.

If the condition triggering an alert does not change, the alert will repeat every 60 minutes.

If you receive an alert repeatedly:

* Consider <InternalLink path="advanced-cluster-management#scale-your-cluster">increasing storage per node</InternalLink>.
* Consider <InternalLink version="stable" path="truncate">truncating</InternalLink> or <InternalLink version="stable" path="drop-table">dropping unused tables</InternalLink>.

### CPU Utilization

CPU utilization alerts are triggered when:

* Cluster-wide CPU usage is **80% or greater** on *average* for at least 60 minutes.
* Node-level CPU usage is **90% or greater** on *average* for at least 90 minutes.

If the condition triggering an alert does not change, the cluster-wide alert will repeat every 60 minutes and the node-level alert will repeat every 90 minutes.

If you receive an alert repeatedly:

* Identify unoptimized queries and <InternalLink version="stable" path="make-queries-fast">optimize your workload</InternalLink>.
* Add one or more <InternalLink version="stable" path="create-index">indexes</InternalLink> to improve query performance.
* Consider <InternalLink path="advanced-cluster-management#scale-your-cluster">increasing the capacity</InternalLink> of the nodes or <InternalLink path="advanced-cluster-management#scale-your-cluster">add more nodes</InternalLink> to reduce the load per node.

### Memory Utilization

Memory utilization alerts are triggered when:

* Cluster-wide available memory is **20% or less** on *average* for at least 60 minutes.
* Node-level available memory is **10% or less** on *average* for at least 90 minutes.

If the condition triggering an alert does not change, the cluster-wide alert will repeat every 60 minutes and the node-level alert will repeat every 90 minutes.

If you receive an alert repeatedly:

* Identify unoptimized queries and <InternalLink version="stable" path="make-queries-fast">optimize your workload</InternalLink>.
* Add one or more <InternalLink version="stable" path="create-index">indexes</InternalLink> to improve query performance.
* Consider <InternalLink path="advanced-cluster-management#scale-your-cluster">increasing the capacity</InternalLink> of the nodes or <InternalLink path="advanced-cluster-management#scale-your-cluster">add more nodes</InternalLink> to reduce the load per node.

### Maintenance Window

For clusters with <InternalLink path="advanced-cluster-management#set-a-maintenance-window">maintenance windows</InternalLink> configured, users who have [signed up for alerts](#configure-alerts) will receive email notifications.

## Configure alerts

Managing alerts requires the <InternalLink path="authorization#organization-admin">Organization Admin</InternalLink> role.

To enable alerts:

1. Under **Configure CockroachDB Cloud alerts**, toggle the **Alerts are on** switch.
2. Under **Add Email Recipients**, add at least one email address and click **Add**.

Alerts are enabled for all CockroachDB Advanced clusters in your Organization.

<Tip>
  You can use an email alias to send alerts to a monitoring tool such as [Alertmanager](https://prometheus.io/docs/alerting/latest/alertmanager) or [PagerDuty](https://www.pagerduty.com/).
</Tip>

## Send a test alert

Sending test alerts requires the <InternalLink path="authorization#organization-admin">Organization Admin</InternalLink> or <InternalLink path="authorization#cluster-operator">Cluster Operator</InternalLink> role.

To send a test alert:

1. Under **Send test email**, select a cluster and an alert type.
2. Add at least one email address and click **Add**.
3. Click **Send test email**.
