<commit_before>---
title: Configuring Health Monitor Notifications
owner: Notifications
---

<strong><%= modified_date %></strong>

This topic describes how to configure notifications from the Health Monitor (HM), which monitors the health of the virtual machines in a Cloud Foundry (CF) deployment.

The HM is a BOSH component that continuously monitors all BOSH-deployed virtual machines (VMs) in a deployment. Each BOSH-deployed VM produces a heartbeat every minute and sends it to the HM, along with status and lifecycle events.

Operators can configure the HM to send an alert through notification plugins by editing the BOSH manifest and redeploying.

##<a id='creds'></a>Step 1: Set Up BOSH Director Credentials

To enable HM notifications, you must provide the HM with credentials to access the BOSH Director. Perform the procedures below to give the HM the correct credentials.

1. Open your BOSH manifest and locate `hm: director_account` under `properties`:

	```
	hm:
	  director_account:
	    ca_cert: "CA-CERT"
		client_id: UAA-CLIENT-ID
		client_secret: UAA-CLIENT-SECRET
		password: PASSWORD
		user: USERNAME
	```

1. To enable the HM to access the BOSH Director, do one of the following:
	* Provide the `user` and `password` for a user that can access the BOSH Director, and remove the other lines under `director_account`.
	* Provide a UAA client ID for `client_id`, a UAA client secret for `client_secret`, and a certificate to verify the UAA endpoint for `ca_cert`. Remove the other lines under `director_account`.

##<a id='config'></a>Step 2: Configure Notifications

Perform the procedures below to set the logging level of the HM and to configure how you receive notifications.

1. Locate the `loglevel` property in your BOSH manifest.

    ```
    hm:
      loglevel: info
    ```
    This property sets the logging level of the HM. You can set `loglevel` to `fatal`, `error`, `warn`, `info`, or `debug`.

1. You can enable notifications by e-mail, PagerDuty, AWS CloudWatch, DataDog, OpenTSDB, and Graphite. Follow the instructions below for the appropriate plugin.

###<a id='email'></a> Configure E-Mail

<%= vars.email_notifications %>

Replace the placeholders with the values appropriate for your deployment.

```
hm:
  email_notifications: true
  email_recipients: <EMAIL>, <EMAIL>
  smtp:
    from: SENDER-ADDRESS
    host: SENDER-SMTP-HOST
    port: SENDER-SMTP-PORT
    domain: SENDER-SMTP-DOMAIN
    tls: TRUE-OR-FALSE
    auth: SMTP-AUTH-TYPE
    user: SMTP-USER
    password: <PASSWORD>
```

* `email_notifications`: Set to `true`.
* `email_recipients`: Provide a comma-delimited list of recipient addresses.
* `smtp.from`: Provide the e-mail address of the sender of the notifications. For example, `<EMAIL>`.
* `smtp.host`: Provide the address of the SMTP server. For example, `smtp.example.com`.
* `smtp.port`: Provide the port of the SMTP server. For example, `25`, `465`, or `587`.
* `smtp.domain`: Provide the SMTP EHLO domain. This is typically the server's FQDN, such as `cloudfoundry.example.com`.
* `tls`: Set `tls` to `true` to enable automatic STARTTLS.
* `auth`: Provide the SMTP authentication type. Only `plain` is supported.
* `user`: If you set `auth` to `plain`, provide the username for SMTP authentication.
* `password`: If you set `auth` to `plain`, provide the password for SMTP authentication.

To customize the contents of your notification e-mail, see the [Getting Started with the Notifications Service](notifications.html) topic.

###<a id='pagerduty'></a> Configure PagerDuty

Replace the placeholders with the values appropriate for your deployment.<commit_msg>de-hyphenates email because it's 2016[#128522393]<commit_after>---
title: Configuring Health Monitor Notifications
owner: Notifications
---

<strong><%= modified_date %></strong>

This topic describes how to configure notifications from the Health Monitor (HM), which monitors the health of the virtual machines in a Cloud Foundry (CF) deployment.

The HM is a BOSH component that continuously monitors all BOSH-deployed virtual machines (VMs) in a deployment. Each BOSH-deployed VM produces a heartbeat every minute and sends it to the HM, along with status and lifecycle events.

Operators can configure the HM to send an alert through notification plugins by editing the BOSH manifest and redeploying.

##<a id='creds'></a>Step 1: Set Up BOSH Director Credentials

To enable HM notifications, you must provide the HM with credentials to access the BOSH Director. Perform the procedures below to give the HM the correct credentials.

1. Open your BOSH manifest and locate `hm: director_account` under `properties`:

	```
	hm:
	  director_account:
	    ca_cert: "CA-CERT"
		client_id: UAA-CLIENT-ID
		client_secret: UAA-CLIENT-SECRET
		password: PASSWORD
		user: USERNAME
	```

1. To enable the HM to access the BOSH Director, do one of the following:
	* Provide the `user` and `password` for a user that can access the BOSH Director, and remove the other lines under `director_account`.
	* Provide a UAA client ID for `client_id`, a UAA client secret for `client_secret`, and a certificate to verify the UAA endpoint for `ca_cert`. Remove the other lines under `director_account`.

##<a id='config'></a>Step 2: Configure Notifications

Perform the procedures below to set the logging level of the HM and to configure how you receive notifications.

1. Locate the `loglevel` property in your BOSH manifest.

    ```
    hm:
      loglevel: info
    ```
    This property sets the logging level of the HM. You can set `loglevel` to `fatal`, `error`, `warn`, `info`, or `debug`.

1. You can enable notifications by e-mail, PagerDuty, AWS CloudWatch, DataDog, OpenTSDB, and Graphite. Follow the instructions below for the appropriate plugin.

###<a id='email'></a> Configure Email

<%= vars.email_notifications %>

Replace the placeholders with the values appropriate for your deployment.

```
hm:
  email_notifications: true
  email_recipients: <EMAIL>, <EMAIL>
  smtp:
    from: SENDER-ADDRESS
    host: SENDER-SMTP-HOST
    port: SENDER-SMTP-PORT
    domain: SENDER-SMTP-DOMAIN
    tls: TRUE-OR-FALSE
    auth: SMTP-AUTH-TYPE
    user: SMTP-USER
    password: <PASSWORD>
```

* `email_notifications`: Set to `true`.
* `email_recipients`: Provide a comma-delimited list of recipient addresses.
* `smtp.from`: Provide the email address of the sender of the notifications. For example, `<EMAIL>`.
* `smtp.host`: Provide the address of the SMTP server. For example, `smtp.example.com`.
* `smtp.port`: Provide the port of the SMTP server. For example, `25`, `465`, or `587`.
* `smtp.domain`: Provide the SMTP EHLO domain. This is typically the server's FQDN, such as `cloudfoundry.example.com`.
* `tls`: Set `tls` to `true` to enable automatic STARTTLS.
* `auth`: Provide the SMTP authentication type. Only `plain` is supported.
* `user`: If you set `auth` to `plain`, provide the username for SMTP authentication.
* `password`: If you set `auth` to `plain`, provide the password for SMTP authentication.

To customize the contents of your notification email, see the [Getting Started with the Notifications Service](notifications.html) topic.

###<a id='pagerduty'></a> Configure PagerDuty

Replace the placeholders with the values appropriate for your deployment.
{'fraction_non_alphanumeric': 0.09137055837563451, 'fraction_numerical': 0.005624914254355878, 'mean_word_length': 4.356355620867009, 'pattern_counts': {'":': 0, '<': 35, '<?xml version=': 0, '>': 35, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3193383', 'n_tokens_mistral': 2256, 'n_tokens_neox': 2110, 'n_words': 951}