lextudio / sharpsnmplib

Sharp SNMP Library- Open Source SNMP for .NET
https://sharpsnmp.com
MIT License
356 stars 152 forks source link

Generate MIBs and send SNMP traps #470

Closed lextudio-support closed 3 hours ago

lextudio-support commented 3 hours ago

Hi Folks!

I have an application that is used for years. It was developed under .net in c#.
Now I have to integrate this app to another one by sending alarm information to that via SNMP trap.

I am an experienced developer, but I have never used SNMP. Now I am looking for a good, opensorce library for this purpose.

What I have to do:
- define and create MIB files those contain alarm information
- send SNMP traps in the defined format

My question is: does this library fit this requirements? Can I create and compile MIB files and send SNMP traps?
As I see the answer for the second is absolutely yes, I have looked at the source code an saw some samples about it. So, the main question is the first one: does your lib have any tool to define/generate/compile MIB files?

Sorry, if I have these kind of rookie questions, but I am in a 'do or die' situation and have a very limited time to implement this features.

Any help is appreciated, thanks for all!

Original Reported Date: 2012-01-27T02:53:52.99-08:00 Original CodePlex Discussion Thread ID: 287608

lextudio-support commented 3 hours ago

Copied from CodePlex without authors:

If you are familiar with SNMP (reading some books may help), you will see the typical workflow you described above does not always require a piece of code.

For example, to author your own MIB document, you don't always need a MIB compiler/generator. Notepad is enough if you pay attention to the syntax you use. A MIB compiler of course provides you syntax highlighting and error checking, and that what #SNMP MIB Compiler offers (well, you have to use our latest build, https://github.com/lextm/sharpsnmplib).

Then you can send out SNMP trap/notification messages. But this only requires you to build up the messages carefully following the rules you defined in the MIB document. You don't need a MIB compiler to help in the case. snmpsendtrap sample in Samples/C# folder demonstrates how to generate such traps.

Regards,

Lex

Original Posted Date: 2012-01-27T21:47:33.213-08:00

lextudio-support commented 3 hours ago

Marked as Answer Date: 2013-10-06T20:38:44.473-07:00