Re: SNMPTRAP & traptoemai
"Dave Shield" <[email protected]>
| Newsgroups | gmane.network.net-snmp.user |
|---|---|
| Message-ID | <[email protected]> |
On 08/11/06, BENAMAR Khalid <[email protected]> wrote: > >OK - so it is at least *trying* to run the traptoemail script. > >What happens if you run that same command by hand? > > > >You'll need to give it at least three lines of input. > >Try: > > (echo localhost; echo 127.0.0.1; echo OID Value) | > > /usr/local/bin/traptoemail -f [email protected] > > -s smtp.menara.ma [email protected]' > > the response when i try it is > > illegal trap at /usr/local/bin/traptoemail line 56, <STDIN> line 3 Sorry - my mistake. The trap handler will always be passed at least *two* varbinds (the trap OID itself, and the sysUpTime varbind). That's why the script is complaining here. Try: (echo localhost; echo 127.0.0.1; echo snmpTrapOID oidValue ; echo sysUpTime 1) | /usr/local/bin/traptoemail -f [email protected] -s smtp.menara.ma [email protected] instead. Dave ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys - and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ 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