Plugin Creation
Plugin Creation
Hello !
I'd like to create a plugin calculating the average size of Ethernet packets received by one NIC. But I don't know what MIB (snmp) is doing that.
Can you help me please ?
Thank you.
I'd like to create a plugin calculating the average size of Ethernet packets received by one NIC. But I don't know what MIB (snmp) is doing that.
Can you help me please ?
Thank you.
-
- Former Nagios Staff
- Posts: 4583
- Joined: Wed Sep 21, 2016 10:29 am
- Location: NoLo, Minneapolis, MN
- Contact:
Re: Plugin Creation
The best thing to do is probably to contact your NIC manufacturer. That said, on what OS are you trying to capture this info?
What's the output of ifconfig? Can you provide any other information about the NIC?
What's the output of ifconfig? Can you provide any other information about the NIC?
Re: Plugin Creation
I'm trying to capture this info on Debian
Here is the result of ifconfig :
Here is the result of ifconfig :
Re: Plugin Creation
So you're creating a plugin that will use SNMP to calculate the average size of Ethernet packets for one NIC?
Maybe take a look at the IF-MIB --> This is a summary of information regarding objects below the interfaces MIB object
http://www.net-snmp.org/docs/mibs/interfaces.html
Are you only creating this plugin for that specific NIC? I'm not sure. Any other information about it?
If you don't know, you can install the pciutils package on Debian.
Maybe take a look at the IF-MIB --> This is a summary of information regarding objects below the interfaces MIB object
http://www.net-snmp.org/docs/mibs/interfaces.html
Are you only creating this plugin for that specific NIC? I'm not sure. Any other information about it?
If you don't know, you can install the pciutils package on Debian.
Code: Select all
sudo apt-get install pciutils
Code: Select all
lspci | egrep -i --color 'network|ethernet'
Re: Plugin Creation
* Exactlykyang wrote:So you're creating a plugin that will use SNMP to calculate the average size of Ethernet packets for one NIC?*
Maybe take a look at the IF-MIB --> This is a summary of information regarding objects below the interfaces MIB object
http://www.net-snmp.org/docs/mibs/interfaces.html
Are you only creating this plugin for that specific NIC?** I'm not sure. Any other information about it?***
If you don't know, you can install the pciutils package on Debian.
Code: Select all
sudo apt-get install pciutils
Code: Select all
lspci | egrep -i --color 'network|ethernet'
** No, not necessarily, but I want the result of ONE NIC, not all of them
*** Here :
- (rev 01)
- PCI Express Gigabit Ethernet Controller (rev 0c)
Re: Plugin Creation
Thanks, I get what you mean.
One thing to keep in mind is the scope of this forum is to point you in the right direction into solving a Nagios related issue.
Something like this would be custom development, in which we do offer if you want to email our sales team to get a quote --> sales@nagios.com
Otherwise, most of the time this is a battle you will have to solve.
If it were my problem, I would keep looking at how SNMP grabs this information, or search for a plugin that does something similar and changing it to your needs.
The Nagios Exchange is a great place to find other plugins.
https://exchange.nagios.org/
One thing to keep in mind is the scope of this forum is to point you in the right direction into solving a Nagios related issue.
Something like this would be custom development, in which we do offer if you want to email our sales team to get a quote --> sales@nagios.com
Otherwise, most of the time this is a battle you will have to solve.
If it were my problem, I would keep looking at how SNMP grabs this information, or search for a plugin that does something similar and changing it to your needs.
The Nagios Exchange is a great place to find other plugins.
https://exchange.nagios.org/
Re: Plugin Creation
Ok thanks. Last question, just to be clear. Ethernet packet of a NIC represents bytes it receives, right ?
Re: Plugin Creation
Correct, it would be in Bytes.
Did you have any more questions or are we okay to lock this up?
Did you have any more questions or are we okay to lock this up?
Re: Plugin Creation
Nope, that's all. Thank you !
Re: Plugin Creation
Sounds good! I'll be closing this thread!
If you have any more questions, feel free to create another thread.
Thanks for using the Nagios Support Forum!
If you have any more questions, feel free to create another thread.
Thanks for using the Nagios Support Forum!