SNMP on embedded Linux device

Jun 18, 2004 1 Replies

Hello,



I develope a device which should send alarms when something goes wrong. I would like to use snmp and send traps.



I run snmptrapd server.



Then created MIB:



TRAP-TEST-MIB DEFINITIONS ::= BEGIN IMPORTS ucdExperimental FROM UCD-SNMP-MIB;



demotraps OBJECT IDENTIFIER ::= { ucdExperimental 990 }



demo-trap TRAP-TYPE STATUS current ENTERPRISE demotraps VARIABLES { sysLocation } DESCRIPTION "This is just a demo" ::= 17



END


And finally used command :



snmptrap -v 1 -c public 192.168.1.1 TRAP-TEST-MIB:demotraps 192.168.1.1 6 17 '' SNMPv2-MIB::sysLocation.0 s "Alarm"


Unfortunatelly, man pages and tutorial is poor for me, and I am not able to understand idea of snmp traps and even meaning of parameters for snmptrap.



I would like just to send (alarm code in integer of string) trap to snmptrapd server, when something is wrong with a device.



If you provide me with some good materials or explanation how to do it, I will be glad.



Thanks in advice, Pavel.


You'll probable find more help in a news group related to snmp, such as comp.protocols.snmp

James

Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required