Simple idea: Start the SNMP service on the router, make sure Zabbix supports SNMP, get the required OIB, design the item
1 Start the SMTP service on the router
Snmp-agent Enable Snmp-agent
Snmp-agent Local-engineid 800063a280586ab1b9cd1700000001
Snmp-agent community read monitor; Create read-only Community--monitor
Snmp-agent community write private; Create a privately writable community
Snmp-agent Sys-info version all; support Snmpv1,v2c,v3
Snmp-agent target-host Trap Address Udp-domain 60.60.60.11 Udp-port 161 params securityname monitor v2c ; Send data to the Zabbix server
Snmp-agent Trap Enable ARP
Snmp-agent Trap Enable radius
2 Get the OID code in the required MIB library
You can do this on the Zabbix_server side, enter the following command
Snmpwalk-v your_version (1,2c,3)-C community_name (my for monitor) your router's intranet or extranet ip# me, without this command please download it yourself net-snmp-utilsnmpwalk-v 2C-C Monitor 192.168.6.254
This will get a lot of data, if the reality no response from x.x.x.x, please check your community name is correct, the version is correct
So save it to Out.txt inside, and then you can see the shape of the MIB tree, I intercept part, so OID everyone can fill, eg: I want to fill out the port flow
650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M01/73/4D/wKioL1X6Hj2yYBRUAAQihfogpTw278.jpg "title=" 23.png "alt=" Wkiol1x6hj2yybruaaqihfogptw278.jpg "/>
In the switch input display interface brief, according to the network said three kinds of excuses, followed by local exchange loop, network interface, dial port
Display Interface Brief
Protocol: (s)-spoofing
Interface Link Protocol Main IP Description
Aux0 up----
Dia10 up (s)--
ge0/0 up to x.x.x.x (my public IP)
GE0/1 down--
GE0/2 up 192.168.6.254
InLoop0 up (s)--
NULL0 up (s)--
REG0 down----
VA0 up 172.16.1.1
VT0 down 172.16.1.1
So the order is this, LOOP (1), 0/0 (2), 0/1 (3), OK, here we start adding, and so we can fill If-mib:: Behind the guys, For example, Ifoutoctets.2 will get the traffic of the public network port, the delta is the rate, the OID value is ifoutoctets corresponding value. 2, it corresponds to is actually do not need to know, if really want to please go to the router inside, know
[H3c-gzdx-617-route]display snmp-agent Mib-node | Include Ifoutoctets
|-*ifoutoctets<1.3.6.1.2.1.2.2.1.16> (RO)
3 Add H3C Router host host,650 in Zabbix web) this.width=650; "Src=" http://s3.51cto.com/wyfs02/M00/73/5F/ Wkiol1x7rutdzl18aamjmhlyigo442.jpg "title=" 23.png "alt=" Wkiol1x7rutdzl18aamjmhlyigo442.jpg "/>
Note that if the host is added, the back availability has not been displayed, and you have added item enable for a while for SNMP checks are not compiled in. So open your log and you'll find that SNMP Service is not supported, please install NET-SNMP components, recompile, is--WITH-NET-SNMP instead of--ENABLE-NET-SNMP, this problem delayed me a day to solve, so I suggest you refer to the official documents better
4 Add template, create item for template, link template
Note the points:
1 key can be filled in, but it's best to uniquely identify
2 SNMP Community Default is public, if you are other please modify yourself, the port is the same
The 3 SNMP OID can be abbreviated as follows
4 *8 Reason: The data sent by the router is like this
If-mib::ifoutoctets.2 = counter32:2907083659, which means we get the number of eight-bit groups (eight 2 binary codes, so there are 8 bit), and we know that if it's the rate, that's the egress bandwidth.
There are the following: 1bps=8bps, note that the B here is byte,b is bit rather than byte, and there is no byte argument at this point. The general communication uses a bit bit more, and talking about the network we all say that byte, learn the information theory should know at this time byte emphasis on carrying the amount of information, and bit more emphasis on storage.
So 1 octet = 8 bit = 1 Byte, so if we don't *8, we get the rate of bps.
650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M01/73/5F/wKioL1X7rmDCcmYjAANuW5nu_P4649.jpg "title=" 24.png "alt=" Wkiol1x7rmdccmyjaanuw5nu_p4649.jpg "/>
650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M01/73/5F/wKioL1X7sRLhSzkBAAJwJYGlNSU641.jpg "title=" 25.png "alt=" Wkiol1x7srlhszkbaajwjyglnsu641.jpg "/>
650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M01/73/62/wKiom1X7r2nyd1eJAAR9Vv9uygg909.jpg "title=" 26.png "alt=" Wkiom1x7r2nyd1ejaar9vv9uygg909.jpg "/>
650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M02/73/5F/wKioL1X7sb7zAbLwAAR9Vv9uygg189.jpg "title=" 26.png "alt=" Wkiol1x7sb7zablwaar9vv9uygg189.jpg "/>
5 then go to the link template, the last to see graph, please view graph in host
650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M02/73/60/wKioL1X7sf2xheSbAARXebtAXVg351.jpg "title=" 27.png "alt=" Wkiol1x7sf2xhesbaarxebtaxvg351.jpg "/>
Nice, but will garbled, refer to the online http://blog.chinaunix.net/uid-11121450-id-3296646.html this eldest brother's article, specifically I will not say.
Later found that the 30s update for traffic is a bit unscientific, so later I release again.
This article is from the "Learning Path of Kai Learning" blog, please make sure to keep this source http://qixue.blog.51cto.com/7213178/1696038
Zabbix------Monitoring H3C MSR Routers