This 5 minute frequency is expected behavior and serves as a way to prevent spamming of alarm events which could lead to an increased database size. This can result in other complications.
Workaround:
Adjust the frequency of the alarms to 0. Setting the frequency to 0 effectively disables any throttling on alarms and their actions.
Note: Editing and saving the alarm after applying either of the workarounds below will revert the reporting frequency to its default of 5 minutes again.
To work around this issue, follow one of the options below:
Using PowerCLI
- Download the zipped file reset-alarm-reporting-frequency.ps1.gz, that is attached to this KB. This has been provided by VMware Engineering.
- Open the script in a text editor of your choice and replace the text SPECIFY with the relevant info and save it.
For example:
$vcIP = 'VCENTER_IP'
$user = 'VCENTER_SSO_ADMIN_USERNAME'
$pass = 'VCENTER_SSO_ADMIN_PASSWORD'
$alarmName = "ALARM_NAME"
- Run the PowerCLI script.
Using the Database
- Connect to the vCenter Server database.
- Run the script below to get the XML required to update the alarm:
SELECT setting_data FROM vpx_alarm LIMIT 1;
You will see output similar to:
<obj xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="urn:vim25" versionId="7.0.0.0" xsi:type="AlarmSetting"><toleranceRange>0</toleranceRange><rep
ortingFrequency>300</reportingFrequency></obj>
Note: The XML contains unique versionId values for each version of vCenter Server.
- Copy the XML content into the command below, change the reportingFrequency value to 0 and run the command:
UPDATE vpx_alarm SET setting_data='XML_FROM_STEP_3' WHERE name='ALARM_NAME';
For example, for vCenter Server 7.0 GA, this command would update the reportingFrequency of My Alarm to 0:
UPDATE vpx_alarm SET setting_data='<obj xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="urn:
vim25" versionId="7.0.0.0" xsi:type="AlarmSetting"><toleranceRange>0</toleranceRange><reportingFrequency>0</reportingFrequency></obj>' WHERE name='My Alarm';
- Restart the vCenter Server service using the command:
service-control --stop vmware-vpxd;service-control --start vmware-vpxd;