SNMP
SNMP
Implementation of the library snmp4j to give an access to devices connected through snmp. This is the hardware module that give support to SNMP Datastreams.
To access source code click here.
Dependencies
This module requires the following modules:
- Commons: Provide the SNMP APIs, exceptions and types and the basic APIs to register the service.
Configuration
To configure SNMP Hardware module, a file named es.amplia.oda.hardware.snmp.cfg must be created with the next parameters for each device that you want to register:
- deviceId: Required data. DeviceId associated to this conecction
- ip: Required data. Ip Address where the device is installed.
- port: Required data. Port where device is listening for requests.
- listenPort: Required data. Port where we listen for events sent by devices (like SNMP Traps).
- version: Required data. Indicates the version of SNMP protocol used to connect with device. Possible values are : 1, 2, 3.
For version 1 and 2 of SNMP we must also define this parameters:
- community: Required data for version 1 and 2. Name of the community
For version 3 we must also define this parameters:
- contextName: Required data for version 3. Name assigned to the MIB of the device
- securityName: Required data for version 3. Username
- authPassphrase: Required data for version 3. Key used for authentication
- privPassphrase: Required data for version 3. Password used for privacy
- authProtocol: Required data for version 3. Protocol used for authentication. Possible values are: MD5, SHA
- privProtocol: Required data for version 3. Protocol used for privacy. Possible values are: DES, 3DES, AES128, AES192, AES256
es.amplia.oda.hardware.snmp.cfg will have a similar format to:
testSnmpDeviceV1 = ip:127.0.0.1, port:1160, listenPort:1161, version:1, community:public
testSnmpDeviceV2 = ip:127.0.0.1, port:1162, listenPort:1163, version:2, community:public
testSnmpDeviceV3 = ip:127.0.0.1, port:1160, listenPort:1161, version:3, contextName: public, securityName:simulator, authPassphrase:auctoritas, privPassphrase:privatus, authProtocol: MD5, privProtocol:DES