What is the proper item-key to monitor when looking for CPU interrupts caused by NICs.
1 Answers
There is not a direct item key for that in Zabbix. You will need to create a user parameter to make it happen. The documentation is found here: http://www.zabbix.com/documentation/1.8/manual/config/user_parameters
An Example would be:
UserParameter=devint[*],cat /proc/interrupts | grep $1 | sed 's/\s/\n/g' | egrep '^[0-9]{1,}$'| awk '{sum+=$1} END {print sum}'
This will create the devint item which will accept parameters, which can be used to determine how many interrupts are being used by which device. This should work equally well for systems which have any number of CPUs. The first grep statement selects the appropriate line in the interrupts file. The sed statement puts one item per line (it's a little sloppy since it leaves a lot of blank lines, but it does not matter in the end). The egrep statement selects only lines which are only numeric (Which is the interrupt count cols from /proc/interrupts), and the awk statement sums the numbers and prints the results.
- 2,074
- 13
- 14