8. Creating Custom Reports

There are a few ways to create reports of your own. You can create some reports through the Zenoss user Interface or using the Zope management Interface (ZMI).

8.1. Creating Custom Reports Using the ZMI

Zenoss Reports are written in python and templates are available through the Zope Management Interface (ZMI). To access the ZMI for a particular page, add a /manage to whichever report you are looking at. The ability to create individual reports is largely dependent on your ability to create python strings to get and display the information. More details on this will be forthcoming as we add more new reports and create more.

8.2. Create A Custom Device Report Example

Here are the steps for creating a Custom Device Report that will show device name, network address, and device serial number.

  1. From the left navigation menu, select Reports.

  2. From the Report Organizers list, click the Device Reports link.

    This is where you will be adding a new report.

  3. From the bottom of the page enter a name for this custom report in the Add text box.

  4. Click the Add button.

    The report you just created will appear in the Report list.

  5. Click the name of the new report from the list.

    The Report detail page appears.

  6. Click the Edit tab to define the report parameters.

  7. Fill out the fields for this report as follows.

    • Name- The name you want to give to the report.

    • Title - The way the report is named in the display. Can be different from the name.

    • Path -The path in the hierarchy where the report will be stored.

    • Query - The actual query string for If you want to limit the report to just those devices that have a serial number, you can set the Query value to:

      here.hw.serialNumber != ""

    • Sort Column - What column you want to use to sort the report.

    • Sort Sense - The sense that the system uses to sort (For example asc is ascii)

    • Columns These columns are the actual data that be retrieved and displayed in the report.

      For example:

      getId – would get the name of any devices

      getManageIp – would get the IP addresses of the devices

      getHWSerialNumber – will grab serial numbers for device.

    • Column Names - You can add column names to make the column headers more descriptive.

      For the example columns above you could use the column names:

      Device

      Address

      Serial #

      NOTE: The information that appears in the fields and how you actually get this information is found in the admin guide in the Tales Expressions appendix in the Device schema section.

  8. Click the Save button.

  9. Now click the Report tab at the top of the page.

    The new device report appears showing the devices that meet the criteria.