Tutorial: Configure Apache Ambari email notifications in Azure HDInsight

In this tutorial, you'll configure Apache Ambari email notifications using SendGrid as an example. Apache Ambari simplifies the management and monitoring of an HDInsight cluster by providing an easy to use web UI and REST API. Ambari is included on HDInsight clusters, and is used to monitor the cluster and make configuration changes. SendGrid is a free cloud-based email service that provides reliable transactional email delivery, scalability, and real-time analytics along with flexible APIs that make custom integration easy. Azure customers can unlock 25,000 free emails each month.


SendGrid is not mandatory to configure Apache Ambari email notifications. You can also use other third party email box. For example, outlook, gmail and so on.

In this tutorial, you learn how to:

  • Obtain Sendgrid Username
  • Configure Apache Ambari email notifications



Users can no logner set passwords for their SendGrid account, so we need use apikey to send email.

Obtain SendGrid apikey

  1. From the Azure portal, navigate to your SendGrid resource.

  2. From the Overview page, click Open SaaS Account on publisher’s site, to go the SendGrid webpage for your account.

    SendGrid overview in azure portal

  3. From the left menu, navigate to your Settings and then API Keys.

    SendGrid dashboard navigation

  4. Click Create API Key to create an apikey and copy the apikey as smtp password in later use.

    SendGrid account details

Configure Ambari e-mail notification

  1. From a web browser, navigate to https://CLUSTERNAME.azurehdinsight.net/#/main/alerts, where CLUSTERNAME is the name of your cluster.

  2. From the Actions drop-down list, select Manage Notifications.

  3. From the Manage Alert Notifications window, select the + icon.

    Screenshot shows the Manage Alert Notifications dialog box.

  4. From the Create Alert Notification dialog, provide the following information:

    Property Description
    Name Provide a name for the notification.
    Groups Configure as desired.
    Severity Configure as desired.
    Description Optional.
    Method Leave at EMAIL.
    Email To Provide e-mail(s) to receive notifications, separated by a comma.
    SMTP Server smtp.sendgrid.net
    SMTP Port 25 or 587 (for unencrypted/TLS connections).
    Email From Provide an email address. The address doesn't need to be authentic.
    Use authentication Select this check box.
    Username Use "apikey" directly if using SendGrid
    Password Provide the password you copied when you created the SendGrid apikey in Azure.
    Password Confirmation Reenter password.
    Start TLS Select this check box

    Screenshot shows the Create Alert Notification dialog box.

    Select Save. You'll return to the Manage Alert Notifications window.

  5. From the Manage Alert Notifications window, select Close.


No appropriate protocol error if the TLS checkbox is checked

If you select Start TLS from the Create Alert Notification page, and you receive a "No appropriate protocol" exception in the Ambari server log:

  1. Go to the Apache Ambari UI.
  2. Go to Alerts > ManageNotifications > Edit (Edit Notification).
  3. Select Add Property.
  4. Add the new property, mail.smtp.ssl.protocols with a value of TLSv1.2.

Next steps

In this tutorial, you learned how to configure Apache Ambari email notifications using SendGrid. Use the following to learn more about Apache Ambari: