FAQ- How to collect traffic statistics for a vlan interface by SNMP on CE switches

Publication Date:  2017-01-31 Views:  1385 Downloads:  0
Issue Description

The standard ifTable MIB  table can be used to query information about interfaces including traffic statistics on Huawei devices but on  a Cloudengine switch the MIB table is not returning any traffic information for the vlan interfaces.

Solution

In order to enable the device to collect statistics for a vlan interface we need to run the statistic enable command under the interface view. After the command is  enabled we can query the statistics for the virtual interface from command line or SNMP.


Example:

 

1.Before enabling statistics under the vlan interface, the device does not measure the traffic sent through the interface:

[CE6850]diplays interface vlan 900                                               

Vlanif900 current state : UP (ifindex: 299)                                     

Line protocol current state : UP                                               

Last line protocol up time : 2017-01-18 10:04:40                               

Description:                                                                    

Route Port,The Maximum Transmit Unit is 1500                                   

Internet Address is 145.145.0.50/30                                            

IP Sending Frames' Format is PKTFMT_ETHNT_2, Hardware address is 643e-8c40-66a6

Current system time: 2017-01-31 14:20:35                                       

    Input bandwidth utilization  : --                                          

    Output bandwidth utilization : --

 

2.To collect statistics, run the statistics enable command under the interface vlan :

 

[CE6850-Vlanif900]statistics enable  

[CE6850-Vlanif900]display interface vlan 900                                     

Vlanif900 current state : UP (ifindex: 299)                                    

Line protocol current state : UP                                               

Last line protocol up time : 2017-01-18 10:04:40                               

Description:                                                                   

Route Port,The Maximum Transmit Unit is 1500                                   

Internet Address is 145.145.0.50/30                                            

IP Sending Frames' Format is PKTFMT_ETHNT_2, Hardware address is 643e-8c40-66a6

Current system time: 2017-01-31 14:22:16                                       

Last 300 seconds input rate 0 bits/sec, 0 packets/sec                          

Last 300 seconds output rate 0 bits/sec, 0 packets/sec                         

Input:  0 packets, 0 bytes                                                      

Output:  0 packets, 0 bytes                                                    

    Input bandwidth utilization  : --                                          

    Output bandwidth utilization : --                                           

                                        

END