Custom Zenoss Reports
From SysAdminWiki
Contents |
Overview
Zenoss reports are HTML pages that use TALES markup. This gives you an immense amount of customization possibilities. This guide attempts to bring this into the light and provide some useful example reports.
Procedure
To add a report to Zenoss do the following:
- 1. Navigate to http://localhost:8080/zport/dmd/Reports . Here you can see what reports currently exist.
- 2. Next add /manage to your URL: http://localhost:8080/zport/dmd/Reports/manage
- 3. Click the drop down menu, choose Reports, then click add.
- 4. Name your report. Test will suffice if this is your first report.
- 5. Next you will notice your new report in the list, click on it you will be taken to the template. By default it added the following code:
<html>
<head>
<title tal:content="template/title">The title</title>
</head>
<body>
<h2><span tal:replace="here/title_or_id">content title or id</span>
<span tal:condition="template/title"
tal:replace="template/title">optional template title</span></h2>
This is Page Template <em tal:content="template/id">template id</em>.
</body>
</html>
- 6. At this point i run into an error :( still trying to find the fix. It still seems to work, if i browse to it from the Reports menu.
- 7. Finish me.
Custom Graph Reports
Probably the reporting feature I use the most is to pull up performance graphs from a couple systems and compare them. The Zenoss reporting makes this simple to do. A more detailed example of what I would use this for would be in a load balanced DNS infrastructure, I would create a report to show the interface utilization of each of service interfaces and display them at once in the same report to allow for comparison. You could tell how well your load balancer config is working by simply doing this.
Note: The report feature seems buggy still, so in this guide there is a couple work arounds along the way for these silly issues. Maybe you won't even see them.
- 1. Click on Reports on the left menu.
- 2. Click on the Graph reports link.
- 3. Click the dropdown and choose Add Graph Report and enter the ID which is just the name of the graph.
- 4. So here is the first little bug, I think. I end up on a white unrendered html page. Thats ok tho. Just hit back. Then refresh the page and you will see the new report.
- 5. Click on the link for the new report and you should be on the properties page. Here we can add the graphs. Its broken up into 3 blocks: Graph Report, Add New Graph, and Graphs. The only one we need to play with really is the Add New Graph Block.
- 6. So lets go ahead and add our graphs. You basically pick a server, pick a compent, pick the values and then his add. Here is a screenshot for example.
So basically I picked two servers, selected their bonded service interface (just select eth0 or eth1 if you do not do bonding), picked the values I wanted to see and clicked Add.
- 7. Your Graphs block should be auto-populated and look something like this:
NOTE: You change the order of these graphs by changing the sequence number. You will likely end up wanting to do that.
- 8. So now we just view the report. Fastest way is to click on the Report Tab at the top of the page we have been working on. It will look something like this:
NOTE: I cut the last graph off where it wouldn't fit on my screen.
- 9. So like I mentioned above you will likely want to re-setup the sequence order so you can view it as you like.
Links
http://www.zenoss.com/community/docs/howtos/how-to-add-a-report



