Ever imagined if you could automatically resolve the operational issues that vCenter Operations has identified using vCenter Orchestrator workflows? That’s what the vCenter Operations remediation workflow package is about.
vCenter Operations performs constant analysis of the datacenter health, and launches alerts when certain problems or risks arise. These alerts can be sent externally via mail, or as SNMP trap messages. On the other hand, through its scripting API and its library of workflows that can be downloaded from VMware Solutions Exchange, vCenter Orchestrator is powerful enough to perform reconfiguration actions at almost any level of vCenter. And guess what? It can receive SNMP traps using its SNMP plug-in. I guess you already get the idea. And here is the picture to visualize it:
You said 5 minutes or less
Really anyone can write his/her own implementation of this scenario, using a vCenter Orchestrator appliance and the SNMP plug-in. However, it can take some time to track down what exactly happens on the SNMP level, parse all the valuable information, code the mapping between trap messages and remediation workflows in a clear and maintainable fashion. That’s why we decided to spare that effort to any user who does not necessarily feel the urge to be a code-hero. So we created a vCO .package with the following goals in mind:
- Be easy to work with
- Be easy to configure
- Do the task, of course, of launching workflows on events from vCenter Operations
- No programming required
So here we are – ready to share the vCenter Operations remediation workflow package!
Here’re all the things you need to try this out:
- vCenter Orchestrator virtual appliance. (vCenter Orchestrator 5.1 recommended) (VMware download)
- SNMP plugin (VMware download)
- vCenter Operations integration package (technical preview)
To quickly run this solution, the following items must be installed:
- vCenter Orchestrator virtual appliance. (vCenter Orchestrator 5.1 recommended) (public VMware download)
- vCenter Orchestrator SNMP plugin. (public VMware download)
- vCenter Operations integration package (technical preview)
Basic vCenter and vCenter Orchestrator configuration skills are required, in order to install the vCenter Orchestrator VA and the SNMP plugin.
- Deploy the virtual appliance ovf in your datacenter.
- Install the SNMP plugin from the vCenter Orchestrator Configurator interface.
- Install the vCenter Operations integration package in vCenter Orchestrator, using the vCenter Orchestrator client.
(In vCenter Operations)
- Set the vCenter Operations server to be sending SNMP traps to the vCenter Orchestrator server address.
(In vCenter Orchestrator)
- Register vCenter Operations server. Register the vCenter Operations server (vCenter Operations Analysis VM IP address) in the SNMP inventory of vCenter Orchestrator, using the “Library/SNMP/Device Management/Register an SNMP device” workflow (only add the address and optionally a friendly name, leave defaults to the other settings).
- Apply Policy. Go to the “Policy Templates” tab in the “Administer” menu, select “Library/SNMP/vCenter Operations SNMP Trap” element, and perform “Apply Policy…” operation. As SNMP device parameter, specify the vCenter Operations server that was added in the previous step.
- Start the policy. Start the newly created policy. If you want this policy to start automatically with server restart, edit it and change the Startup parameter on the General tab.
- Attach remediation workflows. Go to the “Configuration elements” tab in “Design” menu, and locate the “SNMP/vCOps Configuration” element. In the attributes tab, you can find the mapping between vCenter Operations alerts (in the Name column) and workflows in the “Value” column.
There are two sample remediation workflows included in the package:
- Default Action – it only prints the trap parameters in the log.
- Capacity Remediation Action – It is a real remediation action, that takes the trap-specific inputs (like EntityName, EntityType, Criticality, etc.), takes only the ones needed, and forwards them to the real remediation workflow – “Library/vCOps Remediation/Capacity Remediation Action/vCOps Remediation Datastore Capacity”. This is a non-intrusive workflow, that finds the Datastore object, corresponding to the datastoreName parameter, checks for its powered off VMs, analyses their disk usage, and the disk usage of their snapshots, then prepares an email report and sends it to the user. For this workflow to work, you have to add your email in the “toAddress” attribute in the General tab of the workflow. You also have to setup the right smtp server in the settings of the Mail plugin in vCenter Orchestrator Configurator. This workflow has to be assigned to the “riskCapacityNew” alert, so it can be triggered correctly.
- Filtering. As there may be a lot of Alerts coming from vCenter Operations, we provide the possibility to filter the incoming traffic, and not launch any workflows, unless the filtering criteria are met.
This can most easily be accomplished with the help of the “Library/vCOps Remediation/Configuration/Configure Filters” workflow, although it is also possible to achieve the same directly in the “SNMP/vCOps Filters” configuration element. This workflow could fail validation on prior to vCenter Orchestrator 5.1 systems, and the workaround is to manually open the “SNMP/vCOps Filters” configuration element, and set empty array for each of the five attributes (just click the “Not Set” value and immediately hit the “Accept” button after this).
Although we are only providing non-intrusive examples, any workflow can be assigned to any alert, moving or deleting VMs based on some criteria, defined by the user. In fact, vCenter Orchestrator provides a library of thousands of out-of-the-box workflows that can integrate various third party management systems.
For the ones eager for technology detail – here is what happens under the cover:
- A vCenter Orchestrator policy is waiting for trap messages from vCenter Operations.
- Then it checks in a map (associative array, actually) if there is an alert definition for the incoming SNMP OID.
For example: “184.108.40.206.4.1.6876.0.31” -> “riskCapacityNew”
- It checks if there are filter conditions defined, and if the trap matches them, if defined.
- The policy finds if there is workflow assigned to this alert, in the “vCOps Configuration” configuration element.
- Launches the workflow if such a workflow has been defined.
How are the project goals achieved
- All the complications, technical details and scripting resides in the policy.
- Great flexibility can be achieved by setting of correct configuration and filters.
- All configuration is moved to configuration elements.
- There is a workflow for even easier configuration of the filtering.
Congratulations! Your system is now installed and configured.
No programming involved.
vCenter Operations is fully integrated with vCenter Orchestrator so you can leverage more of what you already have. Automated workflow triggers let you associate workflows created in vCenter Orchestrator with vCenter Operations alerts. For example, these workflows can be used to automatically delete old VM snapshots when available capacity falls below a critical threshold or to add resources when workload demands are rising above normal. You’re always in control and can customize workflows with simple drag and drop operations. With vCenter Operations you can finally pull the trigger on automation.