extend monitor and trap problem

<[email protected]>
Newsgroups gmane.network.net-snmp.user
Message-ID <14378333.1158159593759.JavaMail.root@ps23>
Hello, sorry if this has been already answered.

I downloaded a week ago the last version of the package and now it is 
running
on red hat Enterprise 3.
I'm learning how to use SNMP and my goal is extending the agent to 
monitor our system.

At the moment I'm interested in using extend/monitor directives in 
snmpd.conf to send a trap. I added
the following lines:

extend mytest /bin/sh /home/alberto/mytest
createUser pippo
agentSecName pippo
rouser pippo
trapcommunity public
trap2sink localhost
monitor -u pippo -r 3 mymon nsExtendResult.\"mytest\" != 0

where 'mytest' is a script returning an exit value 0 or 1 based on 
same external condition
(the presence of a file).
After restarting the snmpd, walking the tree I get:

> snmpwalk -c public -v 2c localhost nsExtendOutput1Table
NET-SNMP-EXTEND-MIB::nsExtendOutput1Line."mytest" = STRING: 
NET-SNMP-EXTEND-MIB::nsExtendOutputFull."mytest" = STRING: 
NET-SNMP-EXTEND-MIB::nsExtendOutNumLines."mytest" = INTEGER: 1
NET-SNMP-EXTEND-MIB::nsExtendResult."mytest" = INTEGER: 0

And this seems ok: the nsExtendResult changes when the exit status of 
the script 'mytest'
changes. BUT the trap doesn't start (note that other traps works fine 
and are received by
snmptrapd).
Starting the daemon with -D I get the following trace:

trace: mteTrigger_run(): disman/event/mteTrigger.c, 548:
disman:event:trigger:fire: Returned non-integer result(s): NET-SNMP-
EXTEND-MIB::nsExtendResult."mytest" (boolean/threshold) 0

Here I have a 'type error' on nsExtendResult, that I suppose is the 
cause af the missing trap, 
while from the walk above the same OID is identified as INTEGER.

I would be happy if someone could tell me what's wrong!

Thank you!
Alberto


Naviga e telefona senza limiti con Tiscali     
Scopri le promozioni Tiscali adsl: navighi e telefoni senza canone Telecom

http://abbonati.tiscali.it/adsl/


-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Net-snmp-users mailing list
[email protected]
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.