Hi,
I am running the following snmp packages on a Linux test server under RHEL
Enterprise 4 update 5:
net-snmp-utils-5.1.2-11.EL4.10
net-snmp-devel-5.1.2-11.EL4.10
net-snmp-libs-5.1.2-11.EL4.10
net-snmp-5.1.2-11.EL4.10
net-snmp-perl-5.1.2-11.EL4.10
I am trying to get active monitoring running on my test server. Following
the
man pages, documentation, etc, I thought I would try to get net-snmp to
restart
httpd if it goes down.
When I stop httpd and query the prTable, I see
prIndex.1 = 1
prNames.1 = httpd
prCount.1 = 0
prErrorFlag.1 = 1
prErrMessage.1 = No httpd process running.
prErrFixCmd.1 = /etc/init.d/httpd restart
BUT prErrFix.1 = 0 , which I though should = 1 in this case.
Below is the snmpd.conf that I am using. When I restart snmpd, I see the
following
/etc/snmp/snmpd.conf: line 73: Warning: Unknown token: setEvent.
I am assuming it is because of this error, that prErrFix.1 is not getting
set to 1
and thus httpd is not being restarted.
I am also seeing:
illegal value in mteTriggerBooleanComparison object: -2 repeated 12 times.
I assumed it was because my monitor statements are not correct.
Can anyone shed some light on why net-snmp isn't restarting httpd? What I
did wrong or what I am missing in my snmpd.conf?
Thanks,
Dave
------------snmpd.conf --------------------
# net-snmp-5.1.2-11.EL4.10 - test server configuration
sysDescr My Test Server
sysContact me
sysName testserver01
sysLocation Test Environment
sysservices 70
# At least one web server process must be running at all times
proc httpd
procfix httpd /etc/init.d/httpd restart
# There should never be more than 10 mail processes running
# (more implies a probable mail storm, so shut down the mail system)
proc sendmail 2
procfix sendmail /etc/init.d/sendmail stop
# There should be a single network management agent running
# ("There can be only one")
proc snmpd 1 1
proc syslogd 1 1
storageUseNFS 1
disk / MIN=3%
disk /boot MIN=95%
file /var/log/messages 15000
file /var/spool/mail/root 100000
rocommunity blahblah
rwcommunity yaddayadda
informsink 10.12.3.11 public
com2sec notConfigUser default public
group notConfigGroup v1 notConfigUser
group notConfigGroup v2c notConfigUser
view systemview included .1.3.6.1.2.1.1
view systemview included .1.3.6.1.2.1.25.1.1
access notConfigGroup "" any noauth exact systemview none
none
authtrapenable 1
agentSecName internal
rouser internal
# Active the standard monitoring entries
defaultMonitors yes
# Define Explicit Monitors:
monitor -r 60 -o hrSWRunName "high process memory" hrSWRunPerfMem > 10000
monitor -r 60 -D "network traffic" ifInOctets 10000 50000
monitor -r 60 -o sysUpTime.0 -o hrSWRunName "high process memory"
hrSWRunPerfMem > 10000
monitor -r 60 -t -r 15 -o prNames -o prErrMessage "process table"
prErrorFlag 0 1
setEvent prFixIt prErrFix = 1
monitor -e prFixIt "procTable" prErrorFlag != 0
________________________________________________
Message sent using UebiMiau 2.7.10
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
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