Monitoring the health of a virtualized environment is very important to maintaining uptime and detecting potential issues early. VMware vCenter 8 provides robust alarm and notification features that allow system administrators to be promptly alerted via email when specific conditions occur. In this guide, we’ll walk you through the process of configuring email notifications and setting up alarms in VMware vCenter 8.

Table of Contents

  1. Introduction
  2. Prerequisites
  3. Configuring Email Settings in vCenter 8
  4. Setting Up Alarms in vCenter
  5. Testing Your Email Notifications
  6. Conclusion

1. Introduction

Alarms and notifications in VMware vCenter are essential for maintaining a proactive approach to infrastructure management. Setting up email notifications allows administrators to receive alerts for a variety of events, such as resource usage thresholds being crossed, hosts going offline, or VMs encountering problems. With VMware vCenter 8, setting up this functionality is straightforward.


2. Prerequisites

Before you begin configuring email notifications, ensure the following:

  • You have administrative access to VMware vCenter 8.
  • You have access to an SMTP server (either internal or external) to send email alerts.
  • The required firewall ports are open between vCenter and the SMTP server.

3. Configuring Email Settings in vCenter 8

To configure email notifications, you first need to set up an SMTP server in the vCenter 8 settings.

Step 1: Log into vCenter 8

  1. Open a browser and access the vCenter Server through the web client by entering the URL (https://<vcenter-IP>/ui).
  2. Log in using your administrator credentials.

Step 2: Navigate to the SMTP Settings

  1. From the home screen, go to Menu and select Inventory.
  2. On the left panel, select the vCenter you would like to set up and click on Configure.
  3. Under Settings click on General and then EDIT

Step 3: Enter SMTP Server Information

  1. In the new opened window select Mail section.
  2. Enter the following details:
    • Mail server: Enter the IP address or hostname of your SMTP server.
    • Mail sender: This is the email address from which vCenter will send notifications.
  3. Click Save to apply the changes.

Step 4: Enter SMTP Server Authentication Information

  1. Under Settings click on Advanced Settings and then EDIT SETTINGS
  2. In the new window set the filter as “mail” for the column Name and enter a value for the following 3 parameters :
    • mail.smtp.password: Enter the password for SMTP authentication.
    • mail.smtp.port: Specify the port your SMTP server uses (default is 25 for non-secured and 465/587 for SSL/TLS).
    • mail.smtp.username: Enter the username for SMTP authentication.
  3. Click Save to apply the changes.

NOTE: I have used in this case my Gmail account. In order to use the SMTP server from Gmail for sending emails, you have to add an App Password. You can use this link for more info, it’s very well explained.


4. Setting Up Alarms in vCenter

Once email settings are configured, you can create or modify alarms to trigger email notifications based on specific conditions.

Step 1: Navigate to Alarms

  1. In the vCenter Server web client, click Menu and select Host and Clusters or VMs and Templates depending on where you want to set the alarm.
  2. Right-click the object (datacenter, host, or VM) where you want to configure the alarm and select Alarm > New Alarm Definition.

Step 2: Define Alarm Details

  1. Enter a name and description for your alarm (e.g., “CPU Usage Threshold”).
  2. Set the alarm type, whether you want to monitor a VM, host, datastore, or network.
  3. Under Triggers (IF), set the conditions that should trigger the alarm (e.g., CPU usage above 80%).
  4. Under Actions (THEN), click Add to specify the action to take when the condition is met:
    • Select Send email notifications from the action dropdown.
    • Enter the recipient’s email addresses (separate multiple emails with commas).
    • Choose the frequency of notifications (once, repeated, etc.).
  5. Click OK to save the alarm.

5. Modifying an Existing Alarm to Add Email Notifications

If you already have alarms configured in your environment but want to add email notifications or modify their conditions, follow these steps:

Step 1: Locate the Alarm

  1. In the vCenter Server web client, go to Menu and select Host and Clusters (or VMs and Templates if your alarm is set at the VM level).
  2. Navigate to the object (datacenter, host, or VM) where the alarm is set.
  3. Select the object click on Configure and select Alarm Definitions.

Step 2: Edit the Alarm

  1. In the Alarm Definitions list, locate the alarm you want to modify.
  2. Right-click on the alarm and select Edit.
  3. Review the alarm conditions in the Triggers tab and update them if needed.

Step 3: Add Email Notification

  1. Go to the Actions tab.
  2. If there is no email notification set, click Add to create a new action.
  3. From the Action dropdown menu, select Send email notifications.
  4. Enter the recipient’s email address in the provided field (you can enter multiple addresses separated by commas).
  5. Specify how frequently you want the notification to be sent (e.g., once, on repeat, etc.).
  6. Click OK to save your changes.

6. Testing Your Email Notifications

After setting up your alarms, it’s essential to test the configuration to ensure that email notifications are being sent correctly.

Step 1: Trigger a Test Alarm

You can manually simulate an alarm condition or set a low threshold to trigger an alert. For example, you can create a test alarm on CPU usage, then stress the system to generate an alert.

Step 2: Verify Email Delivery

Once the alarm triggers, check the recipient’s inbox to ensure that the notification email was delivered. If no email is received, revisit your SMTP and alarm configurations to verify that all settings are correct.


7. Conclusion

By configuring email notifications and alarms in VMware vCenter 8, you enable automated monitoring of your virtualized infrastructure, ensuring that issues are promptly identified and addressed. This not only reduces downtime but also makes infrastructure management more efficient. Keep refining your alarms to match the specific needs of your environment, and regularly review your SMTP and alert configurations for optimal results.


Pro Tips

  • Regularly review the configured alarms to ensure they’re still relevant to your infrastructure.
  • Set escalation rules for critial alarms to ensure appropriate follow-up actions.
  • Use descriptive names and clear notification emails to avoid confusion among administrators.

Share:

Leave a Reply

Your email address will not be published. Required fields are marked *