Follow

How to Edit the zenmodeler File to Configure Model Scheduling in Zenoss 5.x

Applies To

  • Zenoss 5.x

Summary

This KB discusses the procedure to change or configure the modelling frequency for Zenoss 5.x. For information about changing the modelling frequency on previous Zenoss versions, see the KB titled: How to Change the Frequency of Modelling (Zenoss 4.x and below).

Modeling refers to discovering information on a device. Modeling information is gathered by the zenmodeler daemon. This information can include basic configuration such as hardware model, OS information, serial numbers, and software inventory. It can also include components such as network interfaces and file systems. After a device is modeled, performance monitoring daemons can use the modelling information to determine what to monitor, such as which file systems to monitor or exclude from monitoring and how to monitor, for example using SNMP index.

Note: The vSphere ZenPack is a special case that uses the zenvsphere daemon, and is not discussed here.

The zenmodeler daemon chooses the modeler plugins and runs them against the device to gather modeling information. The modeling information is then passed to zenhub to make changes to the ZODB database.
By default, modeling runs every 12 hours, starting from the time the zenmodeler daemon starts. Because modeling can be processor / disk / resource intensive for both devices as well as the Zenoss server, manually scheduling the modeling process can be helpful in managing resources.

The zenmodeler daemon, as of Zenoss 5.x, includes it own cron-like scheduler that is defined by its configuration file. Zenoss recommends using this scheduling functionality instead of crontab because it is more straight forward and prevents potential issues that can result from invoking serviced to launch zenmodeler from within a crontab file.

Procedures

The following procedures describe how to configure the modelling frequency for Zenoss version 5.x. The configuration file can be edited from either the Control Center UI or the Zenoss Resource Manager.

Note: A minimum access of global zenmanager is required to edit the zenmodeler configuration file through the Zenoss Resource Manager.

From the Control Center UI

  1. From the Control Center UI, click Zenoss.resmgr
  2. Navigate to: Zenoss > Collector> localhost > localhost
  3. Find your collector. Scroll down to zenmodeler.
  4. Click on zenmodeler
  5. Scroll up to Configuration Files
  6. Locate the zenmodeler.conf file.
  7. Click Edit to display the editor dialog.
  8. Scroll down to the entry:
    #startat None
  9. Add an entry to the the zenmodeler.conf file. For example to run zenmodeler every day, every month, any day at 3pm and 3am, create the following (five fields):
    startat 0 3,15 * * * 
    

    NOTE: The zenmodeler.conf configuration file uses the same format as crontab. See zenmodeler.conf File Format, below for additional information.

  10. Click Save to save and exit the editor dialog.
  11. Restart zenmodeler. Click Restart to write out the changes.
    Note: No other restart is required.

From the Zenoss Resource Manager UI

  1. Login to the Zenoss Resource Manager UI
  2. Click Advanced
  3. Click Control Center
  4. Scroll down to zenmodeler
  5. Change the display drop down to Configuration Files
  6. Edit the file within the zenmodeler.conf file pane:
    1. Scroll down to the entry:
      #startat None
    2. Add an entry to the zenmodeler.conf file. For example to run zenmodeler every day, every month, any day at 3pm and 3am, create the following (five fields):
      startat 0 3,15 * * * 
              

      NOTE: The zenmodeler.conf file uses the same format as crontab. See zenmodeler.conf File Format, below for additional information.

  7. Click Save to save the changes. A yellow flair message in the top bar indicates the file is successfully changed.
  8. Restart zenmodeler, click Restart.

zenmodeler.conf File Format

The zenmodeler.conf file uses the same format as crontab.

Excerpt from the crontab(5) man page:

  The time and date fields are:
  field          allowed values
  -----          --------------
  minute         0-59
  hour           0-23
  day of month   1-31
  month          1-12 (or names, see below)
  day of week    0-7 (0 or 7 is Sunday, or use names)
  
A field may contain an asterisk (*), which always stands for "first-last".

Ranges of numbers are allowed.  
   Ranges are two numbers separated with a hyphen. 
   The specified range is inclusive.
 
Lists  are allowed.  
   A list is a set of numbers (or ranges) separated by commas.  
   Examples: "1,2,5,9", "0-4,8-12".
Was this article helpful?
1 out of 1 found this helpful
Have more questions? Submit a request

Comments

Powered by Zendesk