I have a very basic setup for snmpd.conf

1. procfix "runs" according to the logs
2. nothing happens
3. snmpd is running as root (with -u root in OPTIONS
4. the command being "run" never executes.  simply trying to touch a file
to prove it works, nothing is created


=====================================================
snmpd.conf

trap2sink 10.10.10.10


createuser snmpadmin
rwuser snmpadmin

iquerySecName snmpadmin
agentSecName snmpadmin


rwcommunity snmpadmin 10.10.10.10
rocommunity public

disk /

includeAllDisks 15%

proc smbd
procfix smbd touch /tmp/test.file

setEvent prFixIt prErrFix = 1
monitor -r 1 -e prFixIt  "Samaba Down" prErrorFlag != 0


=====================================================
snmpwalk of prTable ( notice prErrFix is set to 1, which that works from
the monitor/setEvent)

UCD-SNMP-MIB::prIndex.1 = INTEGER: 1
UCD-SNMP-MIB::prNames.1 = STRING: smbd
UCD-SNMP-MIB::prMin.1 = INTEGER: 1
UCD-SNMP-MIB::prMax.1 = INTEGER: 0
UCD-SNMP-MIB::prCount.1 = INTEGER: 0
UCD-SNMP-MIB::prErrorFlag.1 = INTEGER: error(1)
UCD-SNMP-MIB::prErrMessage.1 = STRING: No smbd process running
UCD-SNMP-MIB::prErrFix.1 = INTEGER: runFix(1)
UCD-SNMP-MIB::prErrFixCmd.1 = STRING: touch /tmp/test.file



=====================================================
here's the log output of the exec actually being called

exec:get_exec_output: calling touch /tmp/test.file
run:exec: running 'touch /tmp/test.file'
verbose:run:exec:   waiting for child 23478...
verbose:run:exec:     calling select
verbose:run:exec:     read 33 bytes
verbose:run:exec:     119966 left in buffer
verbose:run:exec:     calling select
verbose:run:exec:     read 0 bytes
verbose:run:exec:     no data!
verbose:run:exec:       child done
verbose:run:exec:   done reading
run:exec:   got 120000 bytes
run:exec:   child 23478 finished. result=256


thanks ahead
------------------------------------------------------------------------------
_______________________________________________
Net-snmp-users mailing list
Net-snmp-users@lists.sourceforge.net
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users

Reply via email to