[AGENT++]how to send a trap?

Jerry OELoo oyljerry at hotmail.com
Thu Jul 29 03:50:39 CEST 2004


hi Frank
i have modify the implementation as you said ,and it's ok, 
thank you 
Best regards
Jerry


>From: Frank Fock <fock at agentpp.com>
>To: Jerry OELoo <oyljerry at hotmail.com>
>CC: AGENTPP at agentpp.org
>Subject: Re: [AGENT++]how to send a trap?
>Date: Wed, 28 Jul 2004 18:04:54 +0200
>
>Hi Jerry,
>
>As written a couple of times now here on the list,
>the NotificationOriginator::add_*_trap_destination
>methods are *examples* only, that most likely will
>not be suitable for production needs.
>
>Nevertheless, you can use these examples or your
>own derived implementation to configure the
>destinations (or even better configure the destinations
>using SNMP SET requests on the SNMP-TARGET-MIB and
>SNMP-NOTIFICATION-MIB), even though you use the
>MIB::notify method.
>
>When you get an access violation, then you most likely
>have not created and added the snmp_target_mib and the
>snmp_notification_mib to your Mib instance.
>
>Best regards,
>Frank
>
>Jerry OELoo wrote:
>
> > hi all
> > I have sent a notification with code as shown below:
> > coldStartOid coldOid;
> >
> > NotificationOriginator no;
> >
> > UdpAddress dest("127.0.0.1/162");
> >
> > no.add_v1_trap_destination(dest);
> >
> > no.generate(vbs, 0, coldOid, "", "");
> >
> > but when i run the program,it crashes and shows :0xC0000005: Access
> > Violation.
> > I want to know why? and I have found something in the maillist:
> > Frank Fock recommend to use theMib::notify method.
> > but as this method ,how do I configure the manager' address and port ?
> > Thanks in advance!
> >
> > Jerry
> >
> > _________________________________________________________________
> > 与联机的朋友进行交流,请使用 MSN Messenger: http://messenger.msn.com/cn
> > _______________________________________________
> > AGENTPP mailing list
> > AGENTPP at agentpp.org
> > http://agentpp.org/mailman/listinfo/agentpp
> >
>
>

_________________________________________________________________
享用世界上最大的电子邮件系统― MSN Hotmail。  http://www.hotmail.com  




More information about the AGENTPP mailing list