Skip navigation
Currently Being Moderated

Application Profiles

VERSION 15  Click to view document history
Created on: Sep 23, 2010 3:05 PM by Matt Ray - Last Modified:  Nov 22, 2011 11:49 AM by Nick Yeates

Submitted by: Joseph Anderson


Description:

The Application Profiler Zenpack is designed to reduce administrative complexity by automating the process of device organizer and user, group, administrative role, as well as alert management.  It does so by acting as a sort of “meta-modeler”, using device and component information already present in the Zenoss object database.  The user creates Rulesets, which are collections of Rules that define application characteristics, such as components and RRD templates.  These Rulesets are then used to manage device organizer memberships and facilitate user group role and alert management against devices that comply with the Ruleset.

 

The Application Profiler is managed through the Advanced menu option, and presents a new left-hand menu item named Profiles.  The Profiles menu allows the user to create, delete, or modify rulesets.  It also allows the user to run all rulesets with the Build All Memberships command.

image001.png

Figure 1:  Profiles Manager

 

The Profiles manager contains “rulesets”, which are in turn comprised of “rules”.  The “rulesets” are intended to characterize a given application with specific rules that describe a particular application attribute.  These will be either components (such as ports or processes) or RRD templates.

 

Each Ruleset has several properties, which are defined as follows:

  • Name:   Identifier of this ruleset
  • Contacts:  A list of users associated with this ruleset
  • Groups:  User groups associated with the ruleset.
  • Description:  A brief description of the ruleset
  • Ruleset Templates:  Any RRD Templates to be associated with the ruleset
  • System Organizers:  System Organizers to which matching devices will be added
  • Group Organizers:  Group Organizers to which matching devices will be added
  • Current Device Matches:  Devices that match one or more rules, and are also members of Ruleset System and Group Organizers
  • Potential Device Matches:  Devices that match one or more rules, but are not members of Ruleset System and Group Organizers

 

The View Ruleset menu option gives an overview of the ruleset and its properties, as seen here:

image003.png

Figure 2: Profile Ruleset

 

Each Rule has several properties, which are defined as follows:

  • Name:  Unique identifier
  • Rule Type:  Component meta type (selectable)
  • Rule Match:  A string to match against the component name
  • Remove:  Whether to remove devices from the Ruleset System and Group Organizers if they do not match the rule
  • Enabled:  Whether to use this rule to generate alerts and/or determine Ruleset System/Group Organizer membership
  • Potential Matches:  Devices that match the rule, but are not members of Ruleset System and  Group Organizers
  • Current Matches:  Devices that match the rule, and are also members of Ruleset System and Group Organizers

 

The View Rule menu option gives an overview of the ruleset and its properties, as seen here:

image005.png

Figure 3:  Profile Rule

 

Each Ruleset can be associated with Systems and Groups organizers.  The Apply Rules menu option will associate matching devices (listed in the Potential Device Matches table of the Ruleset page) with the selected Systems/Groups organizers (which are then listed in the “Current Device Matches” table).

 

Each Ruleset has at least one associated user group.  Upon Ruleset creation, a user group with the same name as the Ruleset will be created (if it does not exist).  Users associated with the Ruleset (via the Contacts property) will be automatically added to these groups as well.

 

The created user group is granted “ZenManager” Administrator Role access to every System/Group Organizer specified in the ruleset properties.

image007.png

Figure 4: Administrator Role

 

The Build Alerts menu option on the View Ruleset page creates one alert rule for each user group for each defined rule.

image009.png

Figure 5: Ruleset Alerting Rules

 

Each Alerting rule is filtered to send alerts only for events that match the Ruleset criteria.

image011.png

Figure 6: Per-Rule Alerting Rule Filters

 

The Alerting Rule message subjects are also changed to indicate which Rule generated a given alert rule definition.

image013.png

Figure 7:  Rule Alert Message formatting

 

For example, a Ruleset called “MySQL” could be created, and associated with several Group/System Organizers, as well as with given Zenoss users.

 

The Ruleset could also include several Rules.  One rule could be for “IpService” (component meta type) with a match for “mysql” (the component name).  Another might be for “OsProcess” (meta type) with a match of “mysqld”.  A third rule could be looking for device templates named “MySQL” (from the Zenoss MySQL ZenPack).

 

Once created, the Ruleset can then be used to automatically build alerts for each rule, as well as modifying the organizer memberships of devices matching the rulesets.

 

Each of these tasks could be performed manually, but the complexity of them all together (as well as the tedium involved) would guarantee enough room for error as to preclude their use.  With some automation of the steps, however, a substantial amount of Zenoss latent power can hopefully be better realized and leveraged towards more effective monitoring.

 


Installation Requirements:

  • Zenoss Versions Supported: 3.0
  • External Dependencies: none
  • ZenPack Dependencies: none
  • Installation Notes: zopectl restart after installing this ZenPack.

History:

Change History:

  • 1.0 initial release
  • 1.1 several bugfixes and speed enhancements, as well as added ruleset parameters (use all rules) and reorganized menu
  • 1.2 several bugfixes, major speed enhancement with catalog searching.  added ability to bind templates to ruleset members
  • 1.3 several usability enhancements including enhanced dialogs.  made top-level menu options fully recursive, misc. code cleanup
  • 1.4 numerous improvements, including menu simplification, alert consolidation (one alert definition is created for all rules, rather than one for each rule), ruleset "toRemove" functionality now logically coherent (hopefully), new custom event view defined per alert group (showing events pertaining to ruleset), terminology throughout code now more consistent.  Daemon will be added in near future after current functionality shows to be stable/consistent.
  • 1.5 changed rule matching criterion to use regular expression matches instead of simple string matches
  • 1.7  substantial rewrite to use python 'sets' over previous logic, as well as some change to overall structure and function...hopefully it's now simpler, easier to use, and more predictable.  Import and Export scripts are now included, but I don't believe they'll work with previous versions.

 

 

Tested: This ZenPack was tested with version 3.0.

Source: https://github.com/zenoss/ZenPacks.community.zenAppProfiler


Known issues:

Comments (22)