Skip to content

Commit

Permalink
Motorola Canopy 3.0
Browse files Browse the repository at this point in the history
  • Loading branch information
mattray committed Oct 5, 2010
0 parents commit f7b5e7e
Show file tree
Hide file tree
Showing 17 changed files with 3,058 additions and 0 deletions.
16 changes: 16 additions & 0 deletions COPYRIGHT.txt
Original file line number Original file line Diff line number Diff line change
@@ -0,0 +1,16 @@
All files in this directory and below are:

Copyright (c) 2010 Zenoss, Inc. All rights reserved.

This program is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License version 2 as published
by the Free Software Foundation.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
1 change: 1 addition & 0 deletions MANIFEST.in
Original file line number Original file line Diff line number Diff line change
@@ -0,0 +1 @@
graft ZenPacks
8 changes: 8 additions & 0 deletions ZenPacks/AndreaConsadori/Motorola/__init__.py
Original file line number Original file line Diff line number Diff line change
@@ -0,0 +1,8 @@

import Globals
import os.path

skinsDir = os.path.join(os.path.dirname(__file__), 'skins')
from Products.CMFCore.DirectoryView import registerDirectory
if os.path.isdir(skinsDir):
registerDirectory(skinsDir, globals())
2 changes: 2 additions & 0 deletions ZenPacks/AndreaConsadori/Motorola/datasources/__init__.py
Original file line number Original file line Diff line number Diff line change
@@ -0,0 +1,2 @@
# __init__.py

1 change: 1 addition & 0 deletions ZenPacks/AndreaConsadori/Motorola/lib/__init__.py
Original file line number Original file line Diff line number Diff line change
@@ -0,0 +1 @@
# __init__.py
1 change: 1 addition & 0 deletions ZenPacks/AndreaConsadori/Motorola/migrate/__init__.py
Original file line number Original file line Diff line number Diff line change
@@ -0,0 +1 @@
# __init__.py
Empty file.
Original file line number Original file line Diff line number Diff line change
@@ -0,0 +1,37 @@
###########################################################################
#
# This program is part of Zenoss Core, an open source monitoring platform.
# Copyright (C) 2007, Zenoss Inc.
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License version 2 as published by
# the Free Software Foundation.
#
# For complete information please visit: http://www.zenoss.com/oss/
#
###########################################################################

from Products.DataCollector.plugins.CollectorPlugin import SnmpPlugin, GetMap

class CanopyDeviceMap(SnmpPlugin):
"""Map mib elements from Motorola mib to get hw and os products.
"""

maptype = "CanopyDeviceMap"

snmpGetMap = GetMap({
#'' : 'manufacturer',
'.1.3.6.1.4.1.161.19.3.3.1.1.0' : 'setHWProductKey',
'.1.3.6.1.4.1.161.19.3.3.1.3.0' : 'setHWSerialNumber',
'.1.3.6.1.4.1.161.19.3.3.1.2.0': 'setOSProductKey',
})


def process(self, device, results, log):
"""collect snmp information from this device"""
log.info('processing %s for device %s', self.name(), device.id)
getdata, tabledata = results
if getdata['setHWProductKey'] is None: return None
om = self.objectMap(getdata)
return om

37 changes: 37 additions & 0 deletions ZenPacks/AndreaConsadori/Motorola/modeler/plugins/PTPDeviceMap.py
Original file line number Original file line Diff line number Diff line change
@@ -0,0 +1,37 @@
###########################################################################
#
# This program is part of Zenoss Core, an open source monitoring platform.
# Copyright (C) 2007, Zenoss Inc.
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License version 2 as published by
# the Free Software Foundation.
#
# For complete information please visit: http://www.zenoss.com/oss/
#
###########################################################################

from Products.DataCollector.plugins.CollectorPlugin import SnmpPlugin, GetMap

class PTPDeviceMap(SnmpPlugin):
"""Map mib elements from Motorola mib to get hw and os products.
"""

maptype = "PTPDeviceMap"

snmpGetMap = GetMap({
#'' : 'manufacturer',
'.1.3.6.1.4.1.17713.1.8.3.0' : 'setHWProductKey',
#'.' : 'setHWSerialNumber',
'.1.3.6.1.4.1.17713.1.19.1.0': 'setOSProductKey',
})


def process(self, device, results, log):
"""collect snmp information from this device"""
log.info('processing %s for device %s', self.name(), device.id)
getdata, tabledata = results
if getdata['setHWProductKey'] is None: return None
om = self.objectMap(getdata)
return om

Original file line number Original file line Diff line number Diff line change
@@ -0,0 +1,37 @@
###########################################################################
#
# This program is part of Zenoss Core, an open source monitoring platform.
# Copyright (C) 2007, Zenoss Inc.
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License version 2 as published by
# the Free Software Foundation.
#
# For complete information please visit: http://www.zenoss.com/oss/
#
###########################################################################

from Products.DataCollector.plugins.CollectorPlugin import SnmpPlugin, GetMap

class PTPDeviceMap(SnmpPlugin):
"""Map mib elements from Motorola mib to get hw and os products.
"""

maptype = "PTPDeviceMap"

snmpGetMap = GetMap({
#'' : 'manufacturer',
'.1.3.6.1.4.1.17713.6.8.3.0' : 'setHWProductKey',
#'.' : 'setHWSerialNumber',
'.1.3.6.1.4.1.17713.6.19.1.0': 'setOSProductKey',
})


def process(self, device, results, log):
"""collect snmp information from this device"""
log.info('processing %s for device %s', self.name(), device.id)
getdata, tabledata = results
if getdata['setHWProductKey'] is None: return None
om = self.objectMap(getdata)
return om

Empty file.
Loading

0 comments on commit f7b5e7e

Please sign in to comment.