CN104092613A - Rapid table lookup method based on fuzzy matching - Google Patents

Rapid table lookup method based on fuzzy matching Download PDF

Info

Publication number
CN104092613A
CN104092613A CN201410335259.1A CN201410335259A CN104092613A CN 104092613 A CN104092613 A CN 104092613A CN 201410335259 A CN201410335259 A CN 201410335259A CN 104092613 A CN104092613 A CN 104092613A
Authority
CN
China
Prior art keywords
address
list item
fuzzy matching
addresses
matching
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.)
Pending
Application number
CN201410335259.1A
Other languages
Chinese (zh)
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.)
Shandong Chaoyue Numerical Control Electronics Co Ltd
Original Assignee
Shandong Chaoyue Numerical Control Electronics Co Ltd
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 Shandong Chaoyue Numerical Control Electronics Co Ltd filed Critical Shandong Chaoyue Numerical Control Electronics Co Ltd
Priority to CN201410335259.1A priority Critical patent/CN104092613A/en
Publication of CN104092613A publication Critical patent/CN104092613A/en
Pending legal-status Critical Current

Links

Abstract

The invention relates to a table lookup method, in particular to a rapid table lookup method based on fuzzy matching. According to the method, firstly, a head characteristic value and a tail characteristic value of each key field in a table item are determined, the fields of common parts of the head characteristic values and the tail characteristic values serve as basic addresses of table items of the fuzzy matching, fuzzy matching ranges serve as offset addresses, and the basic addresses and the offset addresses jointly form table item addresses for storing table item content. When table lookup operations are executed, the basic addresses of the table items are determined according to the matching ranges, message mapping addresses are calculated on the basis of the basic addresses, and it is showed that lookup succeeds if mapping addresses are in the range of the table item addresses. The rapid table lookup method based on the fuzzy matching can meet rapid table lookup needs of the fuzzy matching.

Description

A kind of quick look-up method based on fuzzy matching
Technical field
The present invention relates to a kind of look-up method, particularly a kind of quick look-up method based on fuzzy matching.
Background technology
In the network switching equipment, the forwarding of message, according to strategy execution respective operations all by the realization of tabling look-up.Concerning three layers of architecture for exchanging, existing look-up method is five-tuple Hash look-up table, concrete grammar is the five-tuple (SIP/DIP/PROTOCOL/SPORT/DPORT) that extracts IP message, does hash(Hash) computing, using the result of hash computing as the list item address of depositing forwarding strategy.This look-up table speed, can meet the requirement of surface speed forwarding, thereby uses in a large number in switching equipment.But the defect of this look-up table is to realize exact matching.The in the situation that of fuzzy matching, need to there is a kind of new matching algorithm to realize table lookup function at a high speed.
Summary of the invention
In order to solve the problem of prior art, the invention provides a kind of quick look-up method based on fuzzy matching, it can meet the fast zoom table demand of fuzzy matching.
The technical solution adopted in the present invention is as follows:
Based on a quick look-up method for fuzzy matching, comprise the following steps:
First characteristic value and the tail characteristic value of each critical field in A, first definite list item;
B, by the common ground field of head and the tail characteristic value as fuzzy matching list item base address, fuzzy matching scope is as offset address, base address and offset address form list item address jointly, deposit contents in table;
C, execution table lookup operation, determine list item base address according to matching range, calculates message mapping address on basis, base address, if mapping address is in list item address realm, illustrates and search successfully.
When the condition of tabling look-up is the scope between from A to B, using the common ground field of condition A and condition B as list item base address, the scope of the field that condition A and condition B there are differences is as list item offset address, and base address+offset address has characterized the physical address that contents in table is deposited.
When table lookup operation, according to the length range of difference field, the message receiving is carried out to data cutting, be divided into common trait section and critical field; By cutting after common trait section and the common trait section in list item compare, if identical, continue comparison keyword section, keyword to be matched and first feature keyword are subtracted each other, if result within the scope of matching length, list item hits.
The beneficial effect that technical scheme provided by the invention is brought is:
A kind of quick look-up method based on fuzzy matching of the present invention, it can meet the fast zoom table demand of fuzzy matching.
Brief description of the drawings
In order to be illustrated more clearly in the technical scheme in the embodiment of the present invention, below the accompanying drawing of required use during embodiment is described is briefly described, apparently, accompanying drawing in the following describes is only some embodiments of the present invention, for those of ordinary skill in the art, do not paying under the prerequisite of creative work, can also obtain according to these accompanying drawings other accompanying drawing.
Fig. 1 is the fundamental diagram of a kind of quick look-up method based on fuzzy matching of the present invention.
Embodiment
For making the object, technical solutions and advantages of the present invention clearer, below in conjunction with accompanying drawing, embodiment of the present invention is described further in detail.
A kind of quick look-up method based on fuzzy matching of the present invention, generally comprises following steps:
First characteristic value and the tail characteristic value of each critical field in A, first definite list item;
B, by the common ground field of head and the tail characteristic value as fuzzy matching list item base address, fuzzy matching scope is as offset address, base address and offset address form list item address jointly, deposit contents in table;
C, execution table lookup operation, determine list item base address according to matching range, calculates message mapping address on basis, base address, if mapping address is in list item address realm, illustrates and search successfully.
As shown in Figure 1, dotted line top is the matching condition leaving in fuzzy matching list item, issuing is message to be matched, receive after message to be matched, first according to matching length information, message is cut, be divided into common trait section and critical field, secondly the common trait section after cutting and the common trait section in list item are compared, if identical, continue comparison keyword section, keyword to be matched and first feature keyword are subtracted each other, if result within the scope of matching length, list item hits.
The foregoing is only preferred embodiment of the present invention, in order to limit the present invention, within the spirit and principles in the present invention not all, any amendment of doing, be equal to replacement, improvement etc., within all should being included in protection scope of the present invention.

Claims (3)

1. the quick look-up method based on fuzzy matching, comprises the following steps:
First characteristic value and the tail characteristic value of each critical field in A, first definite list item;
B, by the common ground field of head and the tail characteristic value as fuzzy matching list item base address, fuzzy matching scope is as offset address, base address and offset address form list item address jointly, deposit contents in table;
C, execution table lookup operation, determine list item base address according to matching range, calculates message mapping address on basis, base address, if mapping address is in list item address realm, illustrates and search successfully.
2. a kind of quick look-up method based on fuzzy matching according to claim 1, it is characterized in that, when the condition of tabling look-up is the scope between from A to B, using the common ground field of condition A and condition B as list item base address, the scope of the field that condition A and condition B there are differences is as list item offset address, and base address+offset address has characterized the physical address that contents in table is deposited.
3. a kind of quick look-up method based on fuzzy matching according to claim 1, is characterized in that, when table lookup operation, according to the length range of difference field, the message receiving is carried out to data cutting, is divided into common trait section and critical field; By cutting after common trait section and the common trait section in list item compare, if identical, continue comparison keyword section, keyword to be matched and first feature keyword are subtracted each other, if result within the scope of matching length, list item hits.
CN201410335259.1A 2014-07-15 2014-07-15 Rapid table lookup method based on fuzzy matching Pending CN104092613A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410335259.1A CN104092613A (en) 2014-07-15 2014-07-15 Rapid table lookup method based on fuzzy matching

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410335259.1A CN104092613A (en) 2014-07-15 2014-07-15 Rapid table lookup method based on fuzzy matching

Publications (1)

Publication Number Publication Date
CN104092613A true CN104092613A (en) 2014-10-08

Family

ID=51640295

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410335259.1A Pending CN104092613A (en) 2014-07-15 2014-07-15 Rapid table lookup method based on fuzzy matching

Country Status (1)

Country Link
CN (1) CN104092613A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108073556A (en) * 2016-11-14 2018-05-25 英业达科技有限公司 Word string discrimination method and machine learning method
CN113392039A (en) * 2021-06-09 2021-09-14 新华三信息安全技术有限公司 Data storage and search method and device

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090006394A1 (en) * 2007-06-29 2009-01-01 Snapp Robert F Systems and methods for validating an address
CN101556610A (en) * 2009-05-04 2009-10-14 中兴通讯股份有限公司 Table creating and searching method used by network processor
CN101719128A (en) * 2009-12-31 2010-06-02 浙江工业大学 Fuzzy matching-based Chinese geo-code determination method
CN102567741A (en) * 2010-12-27 2012-07-11 汉王科技股份有限公司 Form matching method and device
CN102831235A (en) * 2012-09-03 2012-12-19 苏州雄立科技有限公司 Range match and lookup method

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090006394A1 (en) * 2007-06-29 2009-01-01 Snapp Robert F Systems and methods for validating an address
CN101556610A (en) * 2009-05-04 2009-10-14 中兴通讯股份有限公司 Table creating and searching method used by network processor
CN101719128A (en) * 2009-12-31 2010-06-02 浙江工业大学 Fuzzy matching-based Chinese geo-code determination method
CN102567741A (en) * 2010-12-27 2012-07-11 汉王科技股份有限公司 Form matching method and device
CN102831235A (en) * 2012-09-03 2012-12-19 苏州雄立科技有限公司 Range match and lookup method

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108073556A (en) * 2016-11-14 2018-05-25 英业达科技有限公司 Word string discrimination method and machine learning method
CN113392039A (en) * 2021-06-09 2021-09-14 新华三信息安全技术有限公司 Data storage and search method and device

Similar Documents

Publication Publication Date Title
US10742722B2 (en) Server load balancing
US20160277297A1 (en) Sdn packet forwarding
CN102377664B (en) TCAM (ternary content addressable memory)-based range matching device and method
US9219681B2 (en) System and method for storing flow entries in hardware tables
US10621080B2 (en) Pipelined hash table with reduced collisions
CN113519144B (en) Exact match and Ternary Content Addressable Memory (TCAM) hybrid lookup for network devices
JP2015517272A (en) Chaining inline services using software-defined networking
CN105429879B (en) Flow entry querying method, equipment and system
WO2015106729A1 (en) A load balancing method, device, system and computer storage medium
CN103746919A (en) Method for quickly classifying network packets through combining multi-way decision tree and Hash tables
US11133947B2 (en) Multicast routing
CN110061921B (en) Cloud platform data packet distribution method and system
CN104092613A (en) Rapid table lookup method based on fuzzy matching
CN107995116B (en) Message sending method and communication equipment
CN106716870A (en) Local packet switching at a satellite device
CN102289453B (en) TCAM (ternary content addressable memory) rule storing method, device and network equipment
CN105282133A (en) A method of forming a Hash input from packet contents and an apparatus thereof
CN103581020B (en) The method of a kind of message forwarding, Apparatus and system
CN103812774A (en) TCAM based strategy configuration method, message processing method and corresponding device
CN106850442B (en) Message processing method and forwarding device
CN106411553A (en) Optimization method of service chain path and apparatus thereof
CN103503386B (en) The network equipment and processing message method
CN104539537B (en) A kind of method for searching route and device
CN102316012A (en) Method for realizing Internet protocol (IP) express forwarding and three-layer forwarding equipment
US9853891B2 (en) System and method for facilitating communication

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
WD01 Invention patent application deemed withdrawn after publication

Application publication date: 20141008

WD01 Invention patent application deemed withdrawn after publication