ScreenShots
Who's Online
We have 146 guests onlineMost Popular howTo's
Python News
Latest Posts
HowTo
Newest Downloads
| HowTo backup all of your Zenoss Templates the easy way. |
| Programming HowTo's - Python HowTo's | ||||||||||||||||||||||||||||||
| Written by Allen Sanabria | ||||||||||||||||||||||||||||||
| Friday, 12 February 2010 15:19 | ||||||||||||||||||||||||||||||
|
Recently I had to prepare for a Zenoss upgrade. During my prep work I had to create a zenpack of all of our Templates. For those of you who use Zenoss, you know how many templates you can start to accumulate in a short amount of time. You can have Templates attached to single Devices, to SubClasses, and to Classes. Now if you have a few devices this is not a big deal. But if you have a couple hundred to a couple of thousand devices, this could be a real hassle. Now you can take a ton of your time and review Class by Class and Device by Device until you finally finish. You will eventually get it all in a Zenpack....... Well lucky for you guys I created a Python Script that runs as the Zenoss user and create a Zenpack for you. All you have to do is pick a name for the ZenPack and optionally the Device Class you want to scan. The script will scan the Device Class that you specified ( or by default scan the entire /Device Class and its Sub Classes). It will then create the ZenPack with all the locally attached Device Templates. I am thinking of also adding the Events class as part of the next release of this script. Update 1.0.1, I added the --unique option. If you decide to use this option, This Zenpack will only add, The Device Templates that are not already part of an existing ZenPack. I also added the --verbose option, so that you can see which Device Templates are being added or being dismissed. You can download the script here
Example..... python createZenPack.py -p "ZenPacks.Allen.Test1" -a "Allen Sanabria" -v "0.9" -r "/Server/Linux/" Another Example, with the unique option and verbose option. python createZenPack.py -p "ZenPacks.Allen.Test1" -a "Allen Sanabria" -v "0.9" -u -V Another Example... python createZenPack.py --list Help OutPut... python createZenPack.py -h
Only registered users can write comments!
Powered by !JoomlaComment 3.22
3.22 Copyright (C) 2007 Alain Georgette / Copyright (C) 2006 Frantisek Hliva. All rights reserved."
|
||||||||||||||||||||||||||||||
| Last Updated on Monday, 01 March 2010 11:20 |



Download Create ZenPack
( Votes)








