I'm trying to grab all devices of a particular hardware device type, but am
getting stuck with what's perhaps a low-prority bug.
Essentially, what I want is
for hw in Manufacturers.Cisco.products.37xxStack.instances:
hw.device.zDeviceTemplates = ['Device', 'xSpecial']
However, when experimenting with accessing this via zendmd, I run into the
following
problems:
>>> cisco.getProductNames()
Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "/opt/zenoss/Products/ZenModel/Manufacturer.py", line 175, in
getProductNames
Manufacturer.products.objectValuesAll()))
AttributeError: type object 'Manufacturer' has no attribute 'products'
if I try to access the product directly, I run into a python syntax error:
>>> dmd.Manufacturers.Cisco.products.37xxStack
File "<stdin>", line 1
dmd.Manufacturers.Cisco.products.37xxStack
^
SyntaxError: invalid syntax
I can get to these via ZMI but that doesn't help me automate my task.
Thanks.
--
David Carmean Network Appliance, Inc
Infosystems Architect, 495 E. Java Drive
Java (Sunnyvale) Engineering Lab Services Sunnyvale, CA 94089
_______________________________________________
zenoss-users mailing list
[email protected]
http://lists.zenoss.org/mailman/listinfo/zenoss-users