CN104917628B - A kind of ethernet router/interchanger packet loss automatic fault diagnosis method - Google Patents

A kind of ethernet router/interchanger packet loss automatic fault diagnosis method Download PDF

Info

Publication number
CN104917628B
CN104917628B CN201510167520.6A CN201510167520A CN104917628B CN 104917628 B CN104917628 B CN 104917628B CN 201510167520 A CN201510167520 A CN 201510167520A CN 104917628 B CN104917628 B CN 104917628B
Authority
CN
China
Prior art keywords
message
forwarding
router
packet loss
chip
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201510167520.6A
Other languages
Chinese (zh)
Other versions
CN104917628A (en
Inventor
张登银
王雪强
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Jiangsu anlante Intelligent Technology Co., Ltd
Original Assignee
Nanjing Post and Telecommunication University
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Nanjing Post and Telecommunication University filed Critical Nanjing Post and Telecommunication University
Priority to CN201510167520.6A priority Critical patent/CN104917628B/en
Publication of CN104917628A publication Critical patent/CN104917628A/en
Application granted granted Critical
Publication of CN104917628B publication Critical patent/CN104917628B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention discloses a kind of ethernet router/interchanger packet loss automatic fault diagnosis methods.This method timing sampling message first extracts the register information of router/switch, software emulation router/switch hardware chip forwarding process, and the result for forwarding the packet emulation is included in statistical information.When a failure occurs, software emulation statistical information is exported out by Breakdown Maintenance personnel, packet loss reason is searched in packet loss count table according to the type of message of traffic failure, you can find failure cause.This method can be particularly effective with quick diagnosis Ethernet loss of forwarded packets class failure, failure that is small especially for reproduction probability and making a very bad impression.The present invention, which need not write, gets positioning version ready, reduces positioning version Production Time;Software can be long lasting for work, and it is on duty to be not required to manpower intervention, substantially reduces human input and improves fault location efficiency.

Description

A kind of ethernet router/interchanger packet loss automatic fault diagnosis method
Technical field
The present invention relates to the automatic collection of ethernet router/interchanger forwarding data packetloss failure, analysis and statistics Method belongs to ethernet router/interchanger field.
Background technology
Ethernet switch and router are a very complicated systems, undertake the work(of bottom transmission data in practical applications Energy.In actual data transmission, the phenomenon that message packet loss failure is objective reality.Some message packet losses are just often occurring for transmission As this kind of message does not constitute upper-layer service influence;It is to have larger shadow that the transmission of some messages, which abandons for upper-layer service, It is loud, failure show as the performance bottleneck of business, burr, when extend, even interrupt between business etc..When upper-layer service goes wrong When, often require that route switch module maintenance personnel cooperates with investigation problem.Especially when the business of operator breaks down, such as Fast and accurately positioning failure reason becomes a urgent realistic problem for what.
For ethernet router/interchanger forwarding class fault location, the method for traditional investigation problem is manually to arrange It looks into, the approach that first theoretically analysis system networking and business datum forward, then specific aim collects the soft or hard of each correlation module Part information includes statistical information, register information, software state machine etc., the link that then manual analysis may go wrong, then by Step, which reduces the scope, analyzes verification.Due to the system complex to come into operation, network node is numerous, the process of this investigation orientation problem Often time-consuming and laborious, efficiency is extremely low.
In order to reduce the workload of Breakdown Maintenance, manpower is discharged, fault location efficiency is improved, the present invention proposes a kind of base It is emulated in chip hardware Framework Software, software obtains message descriptor, process flow of the emulation message in hardware chip.It is emulating When Message processing flow, do not consider chip how hardware realization, according only to black box principle realize chip forwarding as a result, i.e. according to core Piece forwards principle, in specified processing links, according to the hardware condition of current hardware register information setting forwarding, at this Ether network packet should do forwarding or discard processing or next link is sent to handle under part, and corresponding message descriptor software is stamped Corresponding handling result, associated counter do accumulation operations, and next link is sent to be emulated.Iteration that above process is repeated, Until the final simulation result of message comes out.
Chip software emulation mode is based on the hardware chip forwarding plane of router/switch, according to adopting in real time Forward process flow of the chip register information emulation message of collection in hardware chip, and the result of emulation is included in statistics letter Breath.Since the information of hardware register is real-time, the message descriptor of acquisition is also real-time, and hardware chip forwarding process is It is fixed, message descriptor is substituted into chip forwarding register with software and forwarding process emulates, is forwarded with chip oneself hardware Message effect is equivalent, and the message emulating obtained is the result is that true and reliable.The statistical counting of relevant treatment link can help System maintenance personnel quickly directly judges the operating condition of current system, and when system has packet loss failure, associated count information can be with Directly point out the register and packet loss reason of packet loss.
Conventional failure positioning needs to judge traffic affecting message type, manually acquires register information, is forwarded in conjunction with chip Hardware structure, artificial judgment packet loss reason.When Rule of judgment is unintelligible, it is often necessary to which making is got version auxiliary positioning ready and asked Topic, heavy workload and inefficiency.Compared to conventional mapping methods, invention software emulates not only accurate positioning, but also convenient fast It is prompt.Because software processing cycle is quickly, can iterate, it is when a failure occurs, fixed in addition to being analyzed for conventional data acquisition To when analyzing certain class message packet loss reason, setting filter condition, Fast Convergent orientation range can also be passed through.Especially for multiple The failure that existing probability is small and makes a very bad impression, the present invention, which need not rewrite, gets positioning version ready, when reducing positioning version making Between;Software can be long lasting for work simultaneously, and it is on duty to be not required to manpower intervention, substantially reduces human input and improves fault location effect Rate.
When external manifestation of the present invention is fault location, a key acquires and analyzes the packet loss reason that is out of order, fault automatic location Efficiency is very high.
Invention content
Technical problem:The technical problem to be solved by the present invention is to obtain message descriptor in real time using software and imitated with software The very process flow of the message in the chips, statistical data is included in by handling result, and artificial point is substituted with the mode that software is handled There is the reason of packet loss failure in analysis message forwarding, can significantly reduce the workload of maintenance personnel and improve fault location efficiency.
Technical solution:In order to solve the above technical problem, the present invention provides a kind of descriptions that dynamic acquisition E-Packets Symbol, real-time acquisition chip forward register information, software to emulate message according to chip forwarding process and done in the processing procedure of chip Forwarding determines, and is included in statistical information according to handling result, includes the following steps:
1, the descriptor of message is extracted
Software provides setting packet sampling frequency interface, and system is according to the sample frequency of setting to each message for forwarding port It is sampled.The setting principle of sample frequency, which is the rate of sampling, to be caused to impact to the performance of CPU, while cannot be influenced The processing of CPU regular traffics.CPU identifies which message is the message that sampling comes up according to the CPU CODE of message up sending, which Message is normally to give the CPU messages of processing.Wherein sampling message is sent to dedicated cache area caching, and it is normal cannot to walk CPU processing The channel of service message prevents the processing of sampling message interference operation layer and protocol layer.
Software timing up-samples message in each forwarding port, and giving the message of sampling to CPU is described symbol extraction.CPU After receiving sampling message, source mac, purpose mac, VLAN, protocol number, CRC check and extraction descriptor information are pressed first.Then root Further provide that the field information used extracts related data by the agreement according to protocol type, such as:Message protocol number is 0x0800 indicates that message is IP types, extraction source IP, destination IP, TTL, packet header verification and according to the sub-protocol number of ip more into The field informations such as onestep extraction corresponding TCP, UDP;Such as message protocol type is 0x8847-0x8848, expression is MPLS classes Type, extraction label information etc..It will be in the descriptor of each field information classification write-in message of extraction.The principle of extraction is report Each protocol fields for the ether network packet that text is related to all extract, and except calculating message checking in addition to, are carried to message Data content can be indifferent to.
In addition, software also needs to provide packet sampling filter interface, CPU only samples the message of specified type after setting, for It is highly effective when certain Class Type message packet loss fault diagnosis.
2, CPU extracts switch/router hardware register information
Each forwarding register information of the entire chip of CPU timing acquisitions, the hardware chip used due to switch/router Often more complicated, register type is various, and list item is very big, if all extraction is used for software emulation, although accuracy is very high, But larger pressure can be caused to the CPU overhead of Installed System Memory and sample register.For the performance of system, memory and the standard of emulation Exactness considers, and generally only samples the critical registers of each forwarding process used.
The register information of acquisition include but are not limited to VLAN, MPLS/MinM/TRILL, L2, L3, ACL, TRUNK, The related registers information such as INGRESS MIRROR, MMU, L3 TUNNEL, VLAN/STP, EGRESS MIRROR, PORT.
3, forwarding process of the software emulation message in hardware chip
1)The descriptor of message is substituted into the forwarding process of hardware chip;
2)Pass through the processing ring of router/switch forwarding chip according to the specific data simulation message of the descriptor of message Section;
3)When emulating the router/switch chip processing link that message passes through, deposited according to the hardware that front obtains Device information, judges handling result of the message under Current hardware state, and by result statistical counting;
4)According to 3)Handling result, message is sent to next link and is handled;
5)Iterate 2),3),4)Until message is forwarded away or discard processing;
4, the forward process information of message is included in statistical form
1)According to the register type decile of the type of message, length, protocol type, the port numbers of entrance, forwarding link Forwarding is not set up and abandons two kinds of counters;
2)The duration unit of setting statistics, and the interface of the type of statistics are provided, personnel is maintained easily and reads statistical result;
3)Log recording function is provided, daily record is written into relevant statistical information, is used for historical analysis;
4)Online query statistical information interface, the current forwarding statistical information of online query are provided.
Advantageous effect:Compared with prior art, the present invention haing the following advantages:
It a) can be by the way that filter condition, Fast Convergent orientation range be arranged.
B) it need not rewrite and get positioning version ready, reduce positioning version Production Time;
C) software can be not required to manpower intervention long lasting for work, substantially reduce human input and improve fault location efficiency
Description of the drawings
Fig. 1 is the software frame figure for diagnosing ethernet router/interchanger packet loss failure automatically based on chip emulation.
Specific implementation mode
The implementation of ether network packet packet loss reason technical solution of the present invention is made below in conjunction with the accompanying drawings further Detailed description:
Chip timing sampling message function is arranged in the first step, gives entering to message for each forwarding port to CPU, setting report The priority of literary grace sample, it is desirable that the rate of sampling cannot cause to impact to the performance of CPU, while cannot influence CPU regular traffics Processing.CPU identifies which message is the message that sampling comes up according to the CPU CODE of message up sending, which message is intended for The message of CPU processing.Wherein sampling message is sent to dedicated cache area caching, cannot walk the channel of CPU processing regular traffic messages, Prevent the processing of sampling message interference operation layer and protocol layer.
Software creates thread, is parsed to the message of buffer area, extracts the descriptor of message, such as:Purpose MAC, source MAC, vlan number, protocol number, CRC check, message ingress port information etc..Specific field is extracted according to protocol number, such as:Report Text is 0x0800, indicates that message is IP types, extraction source IP, destination IP, further extracts corresponding TCP, UDP field letter Breath;Such as message protocol type is 0x8847-0x8848, expression is MPLS types, extraction label information etc..
Second step, software extract forwarding chip register information or software processing links information, the information of acquisition include but Be not limited only to VLAN, MPLS/MinM/TRILL, L2, L3, ACL, TRUNK, INGRESS MIRROR, MMU, L3 TUNNEL, The related registers information such as VLAN/STP, EGRESS MIRROR, PORT.
Third walks, and message descriptor is substituted into chip forwarding process by software, is sentenced according to each register information obtained in real time Disconnected message is flowed in the forwarding of chip.Because being to use software emulation chip hardware forwarding process, software processes and core The ardware model number of piece and the process flow of chip series are strong correlations.Software has in concrete processing procedure further according to chip The train type of body carries out the subdivision of switching value.
The emulation is the principle based on Black-box Testing, and switching value is arranged, eligible, is passed through, ineligible, is lost It abandons, is then counted according to correlated results, this is a simple deterministic process, because hardware has been carried out forwarding capability, It does not need software and realizes specific forwarding capability again, it is only necessary to which black box judges whether by forwarding switch and statistics, therefore in fact Now get up simple and fast.The register letter for judging because software carries out message forwarding in strict accordance with the forwarding logic of chip, and judging Breath obtains in real time, therefore obtained data forwarding result is also true and reliable.
Below by taking common IP packet forwarding process as an example, illustrate software be how with descriptor substitute into chip forwarding process 's;Other types message forwards emulation mode similar, is no longer described in detail.
(1)Whether chip first checks for message source MAC legal, if source MAC is multicast or broadcast MAC, abandons;If Source MAC is set to DISCARD in L2, then abandons;
(2)Secondly according to the purpose MAC+VLAN of message, judge next step forwarding process;If purpose MAC is broadcast MAC is then broadcasted in VLAN, to check entrance broadcast speed limit label at this time, the statistics that may be abandoned is stamped according to label information;
If purpose MAC is multicast MAC, look into whether multicast table L3 switches are opened, if opening L3 Multicast Routings, L3 interfaces table and L3 routing table informations are judged at this time, if it does not match, abandoning;IP verifications are then done in matching, TTL subtracts 1, source mesh MAC replace etc. operations, judge whether to abandon according to the value of IP check results and TTL;Otherwise L2 multicast tables are looked into, hit is walked Know that multicast forwarding, miss walk unknown multicast forwarding(It needs to check that unknown multicast speed limit label and VLAN forbid unknown group at this time Broadcast forwarding label), abandoned according to mark value/may be abandoned or the statistics of forwarding;
If purpose MAC is unicast MAC, look into L2 tables, if hit, look into corresponding table item L3 fields whether set, set Walk L3 forwardings(Process flow is the same as L3 multicasts);The forwarding of L2 known unicasts is walked in non-set, does corresponding INGRESS L2 PASS statistics; Otherwise the forwarding of L2 unknown unicasts is walked(Check at this time L2 unknown unicasts whether speed limit, forward/may speed limit statistics).
(3)Message port enters to MTU and stp state inspection, looks at whether message is more than inbound port MTU, more than abandoning Processing;If port STP is BLOCK, message purpose MAC is not bpdu type and acl rule is not arranged allow such message into Come, then does discard processing.
(4)Before message enters the channels EGRESS, checks the current-configuration of MMU and occupy resource information, if MMU resources go out When existing insufficient, the counting of MMU abandoning statistics is done.
(5)After message enters the channels EGRSS, check that destination interface is common port or the ports TRUNK, if it is Corresponding exit port is found out according to after TRUNK HASH rule computation index in the ports TRUNK;Additionally to check VLAN STP Whether BLOCK, if BLOCK, and the non-bpdu type message of message does discard processing;If FORWARDING is arranged in STP, do Forward process;Check exit port MTU configurations, if message length is more than exit port MTU, message does discard processing.Then will Relevant information terminates forwarding process emulation after counting.
4th step, software do detail statistics according to each message descriptor information, to the sample information of chip forwarding.Such as root According to message MAC points of broadcast, multicast, unicasts;It is divided in detail according to message length, and statistic of classification.It is sketched according to descriptor, Each processing links packet loss of statistic of classification, possible packet loss, letting pass counts, and final forwarding decision counts.When a failure occurs, failure Software emulation statistical information is exported out by maintenance personnel, is searched and is lost in packet loss count table according to the type of message of traffic failure Packet reason, you can find failure cause.It, can be by the way that software emulation message be arranged if failure cause can't determine completely Filtering rule, specific aim sample service message and carry out software Packet Loss Simulation, directly orient packet loss concrete reason.It can keep away in this way Exempt to change in office side and get the operations such as version ready, greatly reduce the difficulty and workload of later stage Breakdown Maintenance, improves fault location effect Rate.

Claims (1)

1. a kind of ethernet router/interchanger packet loss automatic fault diagnosis method, which is characterized in that this method includes following step Suddenly:
1) cpu extracts the descriptor of message;
2) forward process result of the emulation message in hardware chip;
3) the forwarding result of the descriptor type of message, each link is subjected to statistic of classification, and is included in log information;
In the step 1), message descriptor is extracted in accordance with the following steps:
Timing sampling message gives this sampling message copy portion to system CPU;The setting interface of sample frequency is provided;It provides Resampling filter interface, the accurate message for filtering specified type;
In step 2), the detailed process that emulation message is forwarded in hardware chip is:
2-1) descriptor of message is substituted into the forwarding process of hardware chip;
2-2) pass through the processing ring of router/switch forwarding chip according to the specific data simulation message of the descriptor of message Section;
2-3) when emulating the router/switch chip processing link that message passes through, it is required hard that the link is obtained in real time Part register information, judges handling result of the message under Current hardware state, and by result statistical counting;
2-4) according to handling result 3), message is sent to next link and is handled;
2-5) iterate 2- 2), 2- 3), 2- 4) until message is simulated forwards or discard processing;
In step 3), the flow of statistic of classification message forwarding result is:
3-1) set respectively according to the register type of the type of message, length, protocol type, the port numbers of entrance, forwarding link Two kinds of counters of vertical forwarding and discarding;
The duration unit of setting statistics, and the interface of the type of statistics 3-2) are provided, personnel is maintained easily and reads statistical result;
Log recording function 3-3) is provided, is used for historical analysis;
Online query statistical information interface, online query current forwarding statistical information 3-4) are provided.
CN201510167520.6A 2015-04-09 2015-04-09 A kind of ethernet router/interchanger packet loss automatic fault diagnosis method Active CN104917628B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510167520.6A CN104917628B (en) 2015-04-09 2015-04-09 A kind of ethernet router/interchanger packet loss automatic fault diagnosis method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510167520.6A CN104917628B (en) 2015-04-09 2015-04-09 A kind of ethernet router/interchanger packet loss automatic fault diagnosis method

Publications (2)

Publication Number Publication Date
CN104917628A CN104917628A (en) 2015-09-16
CN104917628B true CN104917628B (en) 2018-10-23

Family

ID=54086357

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510167520.6A Active CN104917628B (en) 2015-04-09 2015-04-09 A kind of ethernet router/interchanger packet loss automatic fault diagnosis method

Country Status (1)

Country Link
CN (1) CN104917628B (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109327344B (en) * 2018-11-29 2021-10-26 郑州云海信息技术有限公司 Fault diagnosis method and device for white box switch
CN110661716B (en) * 2019-09-16 2022-07-19 锐捷网络股份有限公司 Network packet loss notification method, monitoring device, switch and storage medium
CN112073256B (en) * 2020-06-01 2022-07-19 新华三信息安全技术有限公司 Packet loss processing method, device, equipment and machine readable storage medium
CN112787857B (en) * 2020-12-29 2023-07-25 中国航空工业集团公司西安飞机设计研究所 Remote data concentrator data monitoring and fault positioning method
CN114125912B (en) * 2021-10-27 2023-09-29 中盈优创资讯科技有限公司 Method and device for locating packet loss fault of 5G private line service
CN114489014B (en) * 2022-01-27 2023-07-28 东风商用车有限公司 Bus controller fault troubleshooting method and system

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1855855A (en) * 2005-04-28 2006-11-01 华为技术有限公司 Device and method for emulated route analysis test
CN103560923A (en) * 2013-11-20 2014-02-05 烽火通信科技股份有限公司 Network failure quick positioning method of packet transport network

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7460472B2 (en) * 2003-07-25 2008-12-02 Nokia Corporation System and method for transmitting information in a communication network

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1855855A (en) * 2005-04-28 2006-11-01 华为技术有限公司 Device and method for emulated route analysis test
CN103560923A (en) * 2013-11-20 2014-02-05 烽火通信科技股份有限公司 Network failure quick positioning method of packet transport network

Also Published As

Publication number Publication date
CN104917628A (en) 2015-09-16

Similar Documents

Publication Publication Date Title
CN104917628B (en) A kind of ethernet router/interchanger packet loss automatic fault diagnosis method
US9065770B2 (en) Traffic item impairment emulation
CN101488925B (en) Method for collecting and designing VPN flow by using Netflow
CN102315974B (en) Stratification characteristic analysis-based method and apparatus thereof for on-line identification for TCP, UDP flows
CN112085039A (en) ICMP hidden channel detection method based on random forest
CN101594265B (en) Method and device for diagnosing network fault and network device
Phan et al. Sdn-mon: Fine-grained traffic monitoring framework in software-defined networks
CN105099916B (en) Open flows route exchange device and its processing method to data message
CN111935063B (en) Abnormal network access behavior monitoring system and method for terminal equipment
CN106330584A (en) Identification method and identification device of business flow
CN106789728A (en) A kind of voip traffic real-time identification method based on NetFPGA
WO2016169121A1 (en) Link analysis method, device and system
CN103916289B (en) Message screening device and method in IPFIX output device
Gómez et al. Traffic classification in IP networks through Machine Learning techniques in final systems
CN102223261A (en) Method and device for sampling message
CN114095383B (en) Network flow sampling method and system and electronic equipment
CN110798345A (en) Network flow monitoring and analyzing equipment based on ZYNQ
CN115514683A (en) Method and device for determining packet loss reason, exchange chip and storage medium
WO2022176035A1 (en) Conversion device, conversion method, and conversion program
CN105282050B (en) The method and apparatus of aggregate data flow
CN113037551B (en) Quick identification and positioning method for sensitive-related services based on traffic slice
CN104753726A (en) Serial data stream auditing control method and serial data stream auditing control system
CN111082992A (en) SDN network data packet identification method based on deep learning
EP2854340B1 (en) Misdirected packet statistics collection and analysis
CN114826775B (en) Method, device, system, equipment and medium for generating filtering rule of data packet

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
TR01 Transfer of patent right

Effective date of registration: 20201207

Address after: 648 Zhujiang Road, Xuanwu District, Nanjing, Jiangsu Province, 210018

Patentee after: Jiangsu anlante Intelligent Technology Co., Ltd

Address before: 210003 Gulou District, Jiangsu, Nanjing new model road, No. 66

Patentee before: NANJING University OF POSTS AND TELECOMMUNICATIONS

TR01 Transfer of patent right