Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

Nearly for 6 days i 'm trying to get over this problem .

I have 2 machines . One of them is manager 10.201 machine, and the other is agent (10.226)

i've configured manager's snmptrap.conf file like this .

authCommunity  execute  public      default  .1
traphandle  default /usr/bin/traptoemail -s localhost -f snmp@localhost root@localhost

and then i've configured agent's snmpd.conf file like this.

###########################################################################
# SECTION: Access Control Setup

rocommunity  public  
rwcommunity  private



###########################################################################
# SECTION: System Information Setup

syslocation  "Izmir, 226. machine "
syscontact  info@abc.com

###########################################################################
# SECTION: Trap Destinations

trap2sink  10.0.0.201  162

authuser   read -s v2c guest_user noauth  .1
authuser   read -s usm guest_user noauth  .1
authcommunity read  public  default .1
iquerySecName guest_user
agentSecName  guest_user

monitor   -u guest_user  -r  1  "interface down" -o ifDescr ifOperStatus != 1

But I want to trap for agent machine's CPUIdle rate. For example I can get CpuIdle like this way by snmpwalk command.

# snmpwalk -v 2c  -c public 10.0.0.226 .iso.org.dod.internet.private.enterprises.ucdavis.systemStats.**ssCpuIdle**.0

I want to trap to manager host(10.0.0.201) when agent's (10.0.0.226) CPuIdle rate is over 98.

Is there anyone that can help me ? Where I ve done mistakes,conf files or anything else ?

share|improve this question
add comment

1 Answer 1

After reading man snmpd.conf, it seems that net-snmp can not send traps about CPuIdle rate.

A simple solution would be to have cron invoke a bash script that will check the top output for CPU idle % and send trap via snmptrap if it exceeds your threshold.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.