JP2005252954A - Table retrieval apparatus - Google Patents
Table retrieval apparatus Download PDFInfo
- Publication number
- JP2005252954A JP2005252954A JP2004063834A JP2004063834A JP2005252954A JP 2005252954 A JP2005252954 A JP 2005252954A JP 2004063834 A JP2004063834 A JP 2004063834A JP 2004063834 A JP2004063834 A JP 2004063834A JP 2005252954 A JP2005252954 A JP 2005252954A
- Authority
- JP
- Japan
- Prior art keywords
- search
- unit
- packet
- identification code
- order
- 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
Links
Images
Abstract
Description
本発明は、複数のテーブルを検索する技術に関する。例えば、ネットワーク中継装置において、パケットの中継先を決定する際に必要となる宛先テーブルの検索処理に関する。 The present invention relates to a technique for searching a plurality of tables. For example, the present invention relates to a destination table search process necessary for determining a packet relay destination in a network relay device.
近年、インターネットや企業ネットワークの高速化が進み、中継装置の高速処理が求められている。これに伴い、中継装置に搭載される宛先テーブル検索処理部にも高速化・小型化・低消費電力化が要求されている。 In recent years, speeding up of the Internet and corporate networks has progressed, and high-speed processing of relay devices has been demanded. Along with this, the destination table search processing unit mounted on the relay apparatus is also required to be faster, smaller, and consume less power.
図7は、従来の宛先テーブル検索処理部を示す図である。この宛先テーブル検索処理部は、宛先テーブルと共に、パケット処理部の一部としてネットワーク中継装置に搭載される。 FIG. 7 is a diagram illustrating a conventional destination table search processing unit. The destination table search processing unit is mounted on the network relay device as a part of the packet processing unit together with the destination table.
また、宛先テーブルはCAMやRAM等のメモリ上に構築され、パケット処理部と別に実装されるのが一般的である。このため図7に示すようにパケットの種類A,Bに対応した処理を行う場合、宛先テーブルはパケットの種類A,Bについて各々3種類、計6種類が必要であり、それぞれが独立のメモリ4A−1〜4A−3,4B−1〜4B−3に構築される。そして、これらに対応した複数のテーブル検索処理部A−1〜A−3,B−1〜B−3が個別のインタフェース回路8A−1〜8A−3,8B−1〜8B−3を介して独立に検索処理を行っている。
The destination table is generally built on a memory such as CAM or RAM, and is generally mounted separately from the packet processing unit. For this reason, as shown in FIG. 7, when processing corresponding to packet types A and B is performed, the destination table requires three types for each of packet types A and B, for a total of six types, each of which is an independent memory 4A. -1-4A-3, 4B-1-4B-3. A plurality of table search processing units A-1 to A-3, B-1 to B-3 corresponding to these are provided via
また、本願発明に関連する先行技術として、例えば、下記の特許文献1に開示される技術がある。
上述した従来の技術では、以下の問題点があった。
複数の宛先テーブル検索処理部を含むパケット処理部をFPGAやASICといったデバイスまたはネットワークプロセッサに代表される汎用デバイスに実装する際、全種類の宛先テーブルとのインタフェースを1つのデバイスに実装することは、デバイスのピン数などの物理的要因により不可となるケースが多い。
The conventional technology described above has the following problems.
When a packet processing unit including a plurality of destination table search processing units is mounted on a device such as an FPGA or ASIC or a general-purpose device typified by a network processor, it is possible to mount interfaces with all types of destination tables on one device. In many cases, this is not possible due to physical factors such as the number of pins on the device.
例えば、図7の装置では、点線で示したように、宛先テーブル検索処理部を2つずつ、3つのデバイスに分けて実装することになる。このため、装置の大型化、消費電力・コストの増大を招くという問題が生ずる。 For example, in the apparatus of FIG. 7, as indicated by the dotted line, the destination table search processing unit is divided into three devices and mounted in two. For this reason, the problem that the enlargement of an apparatus and the increase in power consumption and cost will arise.
また、上記従来の宛先テーブル検索処理部は、検索順序がその回路構成によって決まり、図7であれば、4A−1→4A−2→4A−3の順、或は4B−1→4B−2→4B−3の順でしか検索することができず、ユーザの要求や新技術への対応等のために検索内容や検索順序を変えることができないという問題があった。 In the conventional destination table search processing unit, if the search order is determined by the circuit configuration and FIG. 7 is used, the order is 4A-1 → 4A-2 → 4A-3 or 4B-1 → 4B-2. The search can be performed only in the order of 4B-3, and there has been a problem that the search contents and the search order cannot be changed due to the user's request or the response to the new technology.
また、従来技術での宛先テーブル検索処理部は、各テーブル検索を順次処理で行うため、検索依頼の到着順でしか検索することができず、あるパケットの検索を優先的に行うといった宛先検索の優先制御ができないという問題が生ずる。 In addition, since the destination table search processing unit in the prior art performs each table search sequentially, it can only search in the order of arrival of the search request. There arises a problem that priority control cannot be performed.
更に、従来技術では、宛先テーブルとして使用する外部デバイス(CAM、RAM等)
に特化したインタフェース信号を生成していたため、デバイスが特定種類に固定されてしまい、ユーザがテーブル用デバイスを自由に選択することや新デバイスへの変更ができないという問題が生ずる。
Furthermore, in the prior art, an external device (CAM, RAM, etc.) used as a destination table
Since the interface signal specialized for the device is generated, the device is fixed to a specific type, and there arises a problem that the user cannot freely select a table device or change to a new device.
そこで本発明の目的は、一つの検索部が所定の順序に従って複数のテーブルの検索を行うことにより、装置設計の自由度向上や装置の簡素化を図る技術を提供することである。 Therefore, an object of the present invention is to provide a technique for improving the degree of freedom in device design and simplifying the device by allowing a single search unit to search a plurality of tables in a predetermined order.
上記課題を解決するために本発明は、以下の手段を備えている。即ち、本発明のテーブル検索装置は、受信したパケットからパケットの種類を識別して、このパケットの種類に応じた識別コードを生成すると共に、該パケットから検索に必要となるフィールドの情報を抽出して、このフィールドの種類に応じた検索キーを生成し、前記識別コード及び検索キーを送信する検索識別部と、
前記識別コードに応じた順で、前記検索キーについて複数のテーブルの検索を行い、この検索結果を出力する検索部と、
前記パケットに係る検索結果から結果情報を生成して出力する結果情報生成部と
を備え、
前記検索識別部と検索部と結果情報生成部とが一つのデバイス上に実装され、このデバイス外のテーブルに対して前記検索を行う。
In order to solve the above problems, the present invention includes the following means. That is, the table search apparatus of the present invention identifies the packet type from the received packet, generates an identification code corresponding to the packet type, and extracts field information necessary for the search from the packet. Generating a search key according to the type of the field, and transmitting the identification code and the search key;
A search unit that searches a plurality of tables for the search key in the order according to the identification code, and outputs the search results;
A result information generating unit that generates and outputs result information from a search result relating to the packet;
The search identification unit, the search unit, and the result information generation unit are mounted on one device, and the search is performed on a table outside the device.
前記検索部は、
所定の検索シーケンスに基づいて前記識別コードと対応する検索順序を決定する順序決定部と、
前記順序決定部が決定した順序で検索キーを提供する検索依頼部と、
を備えても良い。
The search unit
An order determining unit that determines a search order corresponding to the identification code based on a predetermined search sequence;
A search request unit that provides search keys in the order determined by the order determination unit;
May be provided.
前記順序決定部は、前記検索シーケンスを書換え可能に記憶しても良い。
前記テーブル検索装置は、前記検索依頼部に前記検索キーを格納する複数のキューを有し、
前記各キューから優先度に応じて検索キーを読み出す検索調停部を前記検索部が更に備えても良い。
The order determination unit may store the search sequence in a rewritable manner.
The table search device has a plurality of queues for storing the search key in the search request unit,
The search unit may further include a search arbitration unit that reads a search key from each queue according to priority.
前記検索部が、前記検索キーについて所定のインタフェースシーケンスに基づいて前記テーブルの検索を行うインタフェース部を備えても良い。
前記インタフェース部が、前記インタフェースシーケンスを書換え可能に記憶しても良い。
The search unit may include an interface unit that searches the table based on a predetermined interface sequence for the search key.
The interface unit may store the interface sequence in a rewritable manner.
本発明のテーブル検索方法は、
受信したパケットからパケットの種類を識別して、このパケットの種類に応じた識別コードを生成するステップと、
該パケットから検索に必要となるフィールドの情報を抽出して、このフィールドの種類に応じた検索キーを生成するステップと、
前記識別コードに応じた順で、前記検索キーについて複数のテーブルの検索を行い、この検索結果を出力するステップと、
前記パケットに係る検索結果から結果情報を生成して出力するステップと、
を装置にて行う。
The table search method of the present invention includes:
Identifying the packet type from the received packet and generating an identification code according to the packet type;
Extracting field information necessary for the search from the packet and generating a search key according to the type of the field;
Searching a plurality of tables for the search key in the order according to the identification code, and outputting the search results;
Generating and outputting result information from a search result relating to the packet;
Is performed by the apparatus.
前記テーブル検索方法は、前記検索を行うステップにて、
所定の検索シーケンスに基づいて前記識別コードと対応する検索順序を決定するステップと、
前記順序で検索キーを提供するステップと、
を行っても良い。
The table search method includes the step of performing the search,
Determining a search order corresponding to the identification code based on a predetermined search sequence;
Providing a search key in the order;
May be performed.
前記テーブル検索方法は、前記順序を決定するステップにて、前記検索シーケンスを書換え可能に記憶した記憶部を参照しても良い。 The table search method may refer to a storage unit that stores the search sequence in a rewritable manner in the step of determining the order.
前記テーブル検索方法は、前記検索キーを格納する複数のキューから優先度に応じて検索キーを読み出すステップを行っても良い。 The table search method may perform a step of reading a search key from a plurality of queues storing the search key according to priority.
前記テーブル検索方法は、前記検索キーについて所定のインタフェースシーケンスに基づいて前記テーブルの検索を行うステップを含んでも良い。 The table search method may include a step of searching the table based on a predetermined interface sequence for the search key.
前記テーブル検索方法は、前記検索を行う際に、前記インタフェースシーケンスを書換え可能に記憶した記憶部を参照しても良い。 The table search method may refer to a storage unit that stores the interface sequence in a rewritable manner when performing the search.
図6は、本発明の原理説明図である。同図に示すように、本発明のテーブル検索装置10は、検索識別部1と、検索部2と、結果情報生成部3とを備える。また、前記検索部2は、検索依頼部5や、検索調停部6、検索制御部7、インタフェース部8、検索結果識別部(順序決定部)9を備える。
FIG. 6 is a diagram for explaining the principle of the present invention. As shown in the figure, the
以下、具体的動作を示す。
(1)検索識別部1は、受信したパケットからパケットの種類を識別し、識別結果である識別コードを生成する。また、パケットから検索に必要となるフィールドを抽出し、検索キーを生成する。識別コードと検索キーを検索依頼とともに検索依頼部5に格納する。
Specific operations will be described below.
(1) The search and
(2)検索依頼部5は、メモリ等により構成されるFIFOである。即ち検索依頼部(FIFO)は、格納された順に読み出しが可能となるように識別コードと検索キーを記憶する。
(2) The
(3)検索調停部6は、検索依頼部5の検索依頼格納状況を監視し、検索依頼がある場合はFIFOから識別コードと検索キーを読み出し、検索制御部7に送信する。
(3) The search arbitration unit 6 monitors the search request storage status of the
(4)検索制御部7は、識別コードから検索の種類を識別し、検索キーを該当テーブル検索の所定フォーマットに並べ替え、インタフェース部8に送信する。また、送信した順に識別コードを保持しておく。
(4) The
(5)インタフェース部8は、外部デバイス4に応じたインタフェース信号を生成し、検索制御部7からの検索キーを外部デバイスへ送信する。
(5) The
(6)外部デバイスの宛先テーブルからは、宛先検索の結果である検索結果が送信される。 (6) A search result that is a result of the destination search is transmitted from the destination table of the external device.
(7)インタフェース部8は、外部デバイス4からの検索結果を受信し、検索制御部7に送信する。
(7) The
(8)検索制御部7は、インタフェース部8からの検索結果を受け、保持しておいた識別コードとともに検索結果識別部9へ送信する。
(8) The
(9)検索結果識別部9は、識別コードをもとにさらに検索が必要であるか、検索終了であるかを識別する。
検索が必要であった場合は、新たに識別コードと検索キーを生成して検索FIFOに格納する。以降、(3)〜(9)を繰り返す。
検索終了であった場合は、識別コードと検索結果を結果情報生成部3へ送信する。
(9) The search
If a search is necessary, a new identification code and search key are generated and stored in the search FIFO. Thereafter, (3) to (9) are repeated.
If the search is completed, the identification code and the search result are transmitted to the result
(10)結果情報生成部3は、検索結果から宛先情報を生成し、送信する。
本発明のテーブル検索装置1は、宛先テーブル検索を行う際、装置・ユーザの要求や新技術への対応により検索内容や検索順序を変えるこができないという問題を解決する手段として、本発明における1つの検索制御部で処理できる利点を生かし、宛先テーブル検索シーケンスを設定可能とし、テーブル検索内容や検索順序を変更可能とする。
(10) The result
The
なお、検索部2は、検索シーケンスを記憶する記憶部として検索順序設定レジスタ12を備えている。上記(9)において、検索結果識別部9は、検索種別コードから検索順序設定レジスタを参照し、検索終了であるかを識別する。また、検索終了でない場合は、次検索識別コードを検索順序設定レジスタより決定する。
The
また、テーブル検索において宛先検索の優先制御ができないという従来の問題を解決するため、本発明のテーブル検索装置では、全宛先テーブル検索を1つの検索制御部で処理できる利点を生かし、宛先テーブル検索の優先制御を可能としている。そして本発明のテーブル検索装置1は、例えば検索部2の検索依頼部5を複数のFIFOで構成し、パケット毎または検索毎に個別のFIFOに格納するキュー構成とする。そして、検索識別部1と検索結果識別部9にパケット毎・検索種別毎に検索依頼を格納するFIFOを選択する機能を設ける。また、検索調停部6に検索依頼を読み出すFIFOに優先度を持たせる機能を設ける。
In addition, in order to solve the conventional problem that destination search priority control cannot be performed in table search, the table search apparatus of the present invention takes advantage of the ability to process all destination table searches with a single search control unit. Priority control is possible. In the
これにより検索調停部6は、上記(3)において優先度の高いFIFOから順に検索依頼を読み出す。
また、ユーザがテーブル用のデバイスを自由に選択することや新デバイスへの変更ができないという問題を解決するための手段として、本発明のテーブル検索装置1では、外部デバイスとのインタフェース信号を設定により制御することを可能とし、デバイス選択できるようにしている。このため、検索部2は、インタフェースシーケンス設定レジスタ13を備えた。このレジスタ13には、所定のシーケンスに従った信号レベル(0,1)を設定しておく。
上記(7)において、インタフェース部8は、インタフェースシーケンス設定レジスタ13をクロック毎に読み出し、インタフェース信号として送出する。
As a result, the search arbitration unit 6 reads the search requests in order from the FIFO with the highest priority in (3).
Further, as a means for solving the problem that the user can freely select a device for a table and cannot change to a new device, the
In the above (7), the
本発明によれば、一つの検索部が所定の順序に従って複数のテーブルの検索を行うことにより、装置設計の自由度向上や装置の簡素化を図る技術を提供することである。 According to the present invention, there is provided a technique for improving the degree of freedom in device design and simplifying a device by allowing a single search unit to search a plurality of tables in a predetermined order.
以下、図面を参照して本発明を実施するための最良の形態について説明する。以下の実施の形態の構成は例示であり、本発明は実施の形態の構成に限定されない。
図1は、本発明に係るパケット処理装置10の概略構成図である。このパケット処理装置10は、パケットの種類に応じて宛先テーブルの検索を行い、この検索結果に基づいてブリッジ中継やIPv4中継を行う。
The best mode for carrying out the present invention will be described below with reference to the drawings. The configuration of the following embodiment is an exemplification, and the present invention is not limited to the configuration of the embodiment.
FIG. 1 is a schematic configuration diagram of a
同図に示すようにパケット処理装置10は、検索識別部1や、検索部2、結果情報生成部3、宛先テーブル4を備える。また、前記検索部2は、検索依頼部5や、検索調停部6、検索制御部7、インタフェース部8、検索結果識別部(順序決定部)9を備える。
As shown in FIG. 1, the
検索識別部1は、受信したパケットからパケットの種類を識別して、このパケットの種類に応じた識別コードを生成すると共に、該パケットから検索に必要となるフィールドの情報を抽出して、このフィールドの種類に応じた検索キーを生成し、前記識別コード及び検索キーを送信する。
The
検索部2は、前記識別コードに応じた順で、前記検索キーについてテーブルの検索を行い、この検索結果を出力する。また、この検索部2は、検索依頼部5や、検索調停部6、検索制御部7、インタフェース部8、検索結果識別部(順序決定部)9を備える。
The
検索依頼部5は、検索結果識別部9が決定した順序で検索キー及び識別コードを提供する。本例の検索依頼部5は、FIFOメモリであり、検索結果識別部9によって格納された順に検索キー及び識別コードを提供する。この検索依頼部5は、検索するテーブルに応じた複数のキューを有している。図中、学習依頼キューは、学習テーブルの検索を依頼するキュー、R依頼キューは、IPv4ルーティングテーブルの検索を依頼するキュー、MFL依頼キューは、MACフローテーブルの検索を依頼するキュー、IPFL依頼キューは、IPv4フローテーブルの検索を依頼するキュー、MFI依頼キューは、MACフィルタリングテーブルの検索を依頼するキュー、IPFI依頼キューは、IPv4フィルタリングテーブルの検索を依頼するキューである。
The
検索調停部6は、検索依頼部5の各キューから優先度に応じて検索キーを読み出して優先制御を行う。この優先度は、予め検索調停部6に書換え可能に記憶させておく。この優先制御は、検索シーケンスに基づいて順序決定部が決定する検索順序より優先して行う。即ち、順序決定部が種類Aのパケットの検索をテーブルA−1,A−2,A−3の順序で行い、種類Bのパケットの検索をテーブルB−1,B−2,B−3の順序で行うと決定し、検索調停部6が種類Bのパケットを優先する設定で、テーブルA−1〜A−3を検索している途中に、テーブルB−1の検索依頼があった場合に、検索調停部6は、テーブルB−1,B−2,B−3の検索を優先して行わせたのち、テーブルA−1,A−2,A−3の残りの検索を行わせる。
The search arbitration unit 6 reads the search key from each queue of the
検索制御部7は、識別コードから検索の種類を識別し、検索キーを該当テーブル検索のフォーマットに並べ替え、インタフェース部8に送信する。また、送信した順に識別コードを保持しておく。
The
インタフェース部8は、前記検索キーについて所定のインタフェースシーケンスに基づいて前記テーブルこのインタフェース部8は、前記インタフェースシーケンスを書換え可能に記憶した記憶部(インタフェースシーケンス設定レジスタ)13を有し、該レジスタ13を参照してインタフェースシーケンスを得ている。の検索を行う。
The
検索結果識別部(順序決定部を含む)9は、検索制御回路から検索結果及び識別コードを受信した際に、この識別コードに基づいてさらに検索が必要であるか、検索終了であるかを所定の検索シーケンスに照らして識別し、検索が必要であった場合は、新たに識別コードと検索キーを生成して検索依頼部5に格納する。このように検索結果識別部9は、所定の検索シーケンスに基づく順で検索キーを作成して検索依頼部5に格納することで検索の順序を決定している。
When the search result identification unit (including the order determination unit) 9 receives the search result and the identification code from the search control circuit, the search
なお、本実施形態では、検索依頼部5をFIFOとし、検索結果識別部9がこの検索依頼部5に決定した順で検索を依頼するように検索キー等の情報を格納する構成としたが、これに限らず、所定の検索シーケンスに従って検索を行える構成であれば良い。
結果情報生成部3は、前記パケットに係る複数の検索結果から結果情報を生成して出力する。
In this embodiment, the
The result
これらの検索識別部1、検索部2、結果情報生成部3が、本装置10のパケット処理部を構成し、FPGAやASICといったデバイスまたはネットワークプロセッサに代表される汎用デバイスに実装されている。即ち本例では図1の点線で示した範囲が一つのデバイス上に実装されている。
The
また、このデバイスの外部に宛先テーブル4を備えている。この宛先テーブル4は、CAMとメモリにて構成され、学習テーブル、IPv4ルーティングテーブル、MACフローテーブル、MACフィルタリングテーブル、IPv4フローテーブル、IPv4フィルタリングテーブルといった複数のテーブルを記憶している。 A destination table 4 is provided outside the device. The destination table 4 includes a CAM and a memory, and stores a plurality of tables such as a learning table, an IPv4 routing table, a MAC flow table, a MAC filtering table, an IPv4 flow table, and an IPv4 filtering table.
この各テーブルに対する識別コードの割り当て例を図2に示す。この識別コードの割り当ては、検索結果識別部9が記憶している。また、上記検索シーケンスの設定例を図3、図4に示す。
An example of assignment of identification codes to the respective tables is shown in FIG. The assignment of the identification code is stored in the search
図3の設定例−1は、パケットの種類がブリッジ中継するものであるとき、学習テーブル→MACフローテーブル→MACフィルタリングテーブルの順で検索し、パケットの種類がIPv4中継するものであるとき、IPv4ルーティングテーブル→IPv4フローテーブル→IPv4フィルタリングテーブルの順に検索する設定であることを示している。 In setting example-1 in FIG. 3, when the packet type is to be relayed by bridge, search is performed in the order of learning table → MAC flow table → MAC filtering table, and when the packet type is to relay IPv4, IPv4 This indicates that the setting is to search in the order of routing table → IPv4 flow table → IPv4 filtering table.
図4の設定例−2は、ブリッジ中継時に設定例−1と同様、IPv4中継時に、IPv4ルーティングテーブル→IPv4フィルタリングテーブルの順で検索する設定であることを示している。 Setting example-2 in FIG. 4 indicates that the setting is to search in the order of the IPv4 routing table → the IPv4 filtering table at the time of IPv4 relaying as in setting example-1 at the time of bridge relaying.
図5は、本実施形態のパケット処理装置(テーブル検索装置)によるテーブル検索方法の説明図である。このテーブル検索方法の各ステップ(S1のように略記する)について以下に説明する。 FIG. 5 is an explanatory diagram of a table search method by the packet processing device (table search device) of the present embodiment. Each step (abbreviated as S1) of this table search method will be described below.
(S1)検索識別部1は、入力されたイーサネット(登録商標)パケットのMACヘッダを識別し、ブリッジ中継かIPv4ルーティング中継かを識別する。検索識別部1は、識別の結果を示す識別コード(例えばブリッジ時は0、IPv4ルーティング時は1)を生成し、検索に必要となるフィールド(ブリッジ時はMACヘッダ、IPv4ルーティング時はIPヘッダ)を入力パケットから抽出し、検索キーを生成する。
そして検索識別部1は、識別結果がブリッジの場合、先ず検索依頼部5の複数のキューのうち、学習テーブルの検索を依頼する為のキュー、即ち図中の学習依頼キューに、識別コードと検索キーを書き込む。一方、検索識別部1は、識別結果がIPv4ルーティングの場合、先ず検索依頼部5の複数のキューのうち、IPルーティングテーブルの検索を依頼する為のキュー、即ち図中のR依頼キューに、識別コードと検索キーを書き込む。
(S1) The
When the identification result is a bridge, the
(S2)検索依頼部5は、検索調停部6へ各キュー(FIFO)の検索依頼の格納状況を通知する。
(S2) The
(S3)検索調停部6は、検索依頼部の格納状況を監視し、識別コード及び検索キー即ち検索依頼がFIFOに格納されていれば、優先度の高いFIFOから順に検索依頼を読み出して検索制御部7へ送信する。
(S3) The search arbitration unit 6 monitors the storage status of the search request unit. If the identification code and the search key, that is, the search request is stored in the FIFO, the search request is sequentially read out from the FIFO with the highest priority. Send to
(S4)検索制御部7は、検索調停部6からの識別コードと検索キーを受け、識別コードに対応した検索キーに並べ替え、インタフェース部8へ送信する。
また、識別コードと検索キーを保持しておく。
(S4) The
Also, an identification code and a search key are held.
(S5)インタフェース部8は、検索キーを受け、インタフェースシーケンス設定レジスタ13をクロック毎に読み出し、このインタフェースシーケンスに従ったインタフェース信号を生成しながら検索キーを宛先テーブル4である外部デバイスに送信する。
(S5) The
(S6)外部デバイスは、検索キーを受け、あらかじめ登録されたテーブル中から検索キーが一致する宛先情報を検索する。そして外部デバイスは、比較が一致すれば、ヒットフラグとともに該当する宛先情報を検索結果としてインタフェース部8へ送信し、比較が一致しなければ、ミスヒットフラグをインタフェース部8へ送信する。
(S6) The external device receives the search key, and searches for destination information that matches the search key from a pre-registered table. If the comparison matches, the external device transmits the corresponding destination information together with the hit flag to the
(S7)インタフェース部8は、検索結果を検索制御部7へ送信する。
(S7) The
(S8)検索制御部7は、検索結果を受け、検索依頼時に保持しておいた識別コードと検索キーとともに検索結果識別部9へ送信する。
(S8) The
(S9)検索結果識別部9は、検索結果、識別コード、検索キーを受信した場合に、検索順序設定レジスタ12を参照してシーケンス情報(検索シーケンス)を得る。検索結果識別部9は、このシーケンス情報のうち、受信した識別コードに該当する検索終了フラグが’0’であれば、検索続行と判断し、この識別コードと検索結果を保持し、該シーケンス情報中の次識別コードを新しい識別コードとして検索キーと共にこの新しい識別コードが割り当てられた(図2)検索依頼部5の該当キューに格納する。検索結果識別部9が、この新しい識別コードと検索キーを検索依頼部5に格納すると、検索依頼部5が上記ステップ2から処理を繰り返す。
そして検索結果識別部9は、受信した識別コードに該当する検索終了フラグが’1’であれば検索終了と判断し、シーケンス情報に基づいて前記パケットに係る一連の検索結果を結果情報生成部3に送信する。例えば図4の設定であれば識別コード0,2,4或は識別コード1,3,5と共に受信した検索結果を一連の検索結果として送信する。
(S9) When receiving the search result, the identification code, and the search key, the search
If the search end flag corresponding to the received identification code is “1”, the search
(S10)結果情報生成部3は、この検索結果を受信し、宛先情報を生成して送信する。
このように本実施形態によれば、複数のテーブルに対する検索処理を1つのインタフェース部8で行うことが可能となり、パケット処理部1,2,3を1つのデバイスに実装することができ、装置のコストダウン・小型化・省電力化が可能となる。
(S10) The result
As described above, according to the present embodiment, it is possible to perform a search process for a plurality of tables by using one
また、本実施形態では、検索順序設定レジスタが検索シーケンスを書換え可能に保持しており、ソフトウェア設定により、この検索シーケンスを更新することにより、検索順序を変更することができる。例えば、図3の設定から図4の設定に書き換えることにより、IPv4中継のシーケンスを、IPv4ルーティングテーブル→IPv4フローテーブル→IPv4フィルタリングテーブルの順から、IPv4ルーティングテーブル→IPv4フィルタリングテーブルの順に変更できる。 In the present embodiment, the search order setting register holds the search sequence in a rewritable manner, and the search order can be changed by updating the search sequence by software setting. For example, by rewriting the setting of FIG. 3 to the setting of FIG. 4, the IPv4 relay sequence can be changed from the IPv4 routing table → the IPv4 flow table → the IPv4 filtering table to the IPv4 routing table → the IPv4 filtering table.
また、本実施形態では、検索依頼を読み出す順序、即ちあて先テーブル4を検索する順序に優先度を設定しているので、特定のパケットの検索を優先することが可能となる。
更に、本実施形態では、インタフェース部8が、書換え可能なインタフェースシーケンス設定レジスタ13のインタフェースシーケンスに基づいてインタフェース信号を作成しているので、このインタフェースシーケンス設定レジスタ13の設定を外部デバイス(CAM、メモリ)に応じて変更出来るので、ユーザが自由に外部デバイスを選択することが可能となる。
In this embodiment, the priority is set in the order in which the search requests are read, that is, the order in which the destination table 4 is searched, so that it is possible to prioritize the search for a specific packet.
Further, in the present embodiment, the
〈その他の実施形態〉
本発明は、上述の図示例にのみ限定されるものではなく、本発明の要旨を逸脱しない範
囲内において種々変更を加え得ることは勿論である。
例えば、以下に付記した構成であっても上述の実施形態と同様の効果が得られる。また、これらの構成要素は可能な限り組み合わせることができる。
<Other embodiments>
The present invention is not limited to the illustrated examples described above, and various modifications can be made without departing from the scope of the present invention.
For example, the same effects as those of the above-described embodiment can be obtained even with the configurations described below. These components can be combined as much as possible.
(付記1)
受信したパケットからパケットの種類を識別して、このパケットの種類に応じた識別コードを生成すると共に、該パケットから検索に必要となるフィールドの情報を抽出して、このフィールドの種類に応じた検索キーを生成し、前記識別コード及び検索キーを送信する検索識別部と、
前記識別コードに応じた順で、前記検索キーについて複数のテーブルの検索を行い、この検索結果を出力する検索部と、
前記パケットに係る検索結果から結果情報を生成して出力する結果情報生成部と
を備え、
前記検索識別部と検索部と結果情報生成部とが一つのデバイス上に実装され、このデバイス外のテーブルに対して前記検索を行うテーブル検索装置。(1)
(Appendix 1)
The packet type is identified from the received packet, an identification code corresponding to the packet type is generated, and field information necessary for the search is extracted from the packet, and the search according to the field type is performed. A search identification unit for generating a key and transmitting the identification code and the search key;
A search unit that searches a plurality of tables for the search key in the order according to the identification code, and outputs the search results;
A result information generating unit that generates and outputs result information from a search result relating to the packet;
A table search apparatus in which the search identification unit, the search unit, and the result information generation unit are mounted on a single device, and performs the search for a table outside the device. (1)
(付記2)
前記検索部が、
所定の検索シーケンスに基づいて前記識別コードと対応する検索順序を決定する順序決定部と、
前記順序決定部が決定した順序で検索キーを提供する検索依頼部と、
を備える付記1に記載のテーブル検索装置。(2)
(Appendix 2)
The search unit
An order determining unit that determines a search order corresponding to the identification code based on a predetermined search sequence;
A search request unit that provides search keys in the order determined by the order determination unit;
The table search device according to
(付記3)
前記順序決定部が、前記検索シーケンスを書換え可能に記憶した付記2に記載のテーブル検索装置。(3)
(Appendix 3)
The table search device according to
(付記4)
前記検索依頼部に前記検索キーを格納する複数のキューを有し、前記各キューから優先度に応じて検索キーを読み出す検索調停部を前記検索部が更に備えた付記2に記載のテーブル検索装置。(4)
(Appendix 4)
The table search device according to
(付記5)
前記検索部が、前記検索キーについて所定のインタフェースシーケンスに基づいて前記テーブルの検索を行うインタフェース部を備えた付記1に記載のテーブル検索装置。
(Appendix 5)
The table search apparatus according to
(付記6)
前記インタフェース部が、前記インタフェースシーケンスを書換え可能に記憶した付記5に記載のテーブル検索装置。
(Appendix 6)
The table search device according to
(付記7)
受信したパケットからパケットの種類を識別して、このパケットの種類に応じた識別コードを生成するステップと、
該パケットから検索に必要となるフィールドの情報を抽出して、このフィールドの種類に応じた検索キーを生成するステップと、
前記識別コードに応じた順で、前記検索キーについて複数のテーブルの検索を行い、この検索結果を出力するステップと、
前記パケットに係る検索結果から結果情報を生成して出力するステップと、
を装置にて行うテーブル検索方法。(5)
(Appendix 7)
Identifying the packet type from the received packet and generating an identification code according to the packet type;
Extracting field information necessary for the search from the packet and generating a search key according to the type of the field;
Searching a plurality of tables for the search key in the order according to the identification code, and outputting the search results;
Generating and outputting result information from a search result relating to the packet;
Table search method for performing the above in the apparatus. (5)
(付記8)
前記検索を行うステップにて、
所定の検索シーケンスに基づいて前記識別コードと対応する検索順序を決定するステップと、
前記順序で検索キーを提供するステップと、
を行う付記7に記載のテーブル検索方法。
(Appendix 8)
In the step of performing the search,
Determining a search order corresponding to the identification code based on a predetermined search sequence;
Providing a search key in the order;
The table search method according to
(付記9)
前記順序を決定するステップにて、前記検索シーケンスを書換え可能に記憶した記憶部を参照する付記7に記載のテーブル検索方法。
(Appendix 9)
The table search method according to
(付記10)
前記検索キーを格納する複数のキューから優先度に応じて検索キーを読み出すステップを行う付記7に記載のテーブル検索方法。
(Appendix 10)
The table search method according to
(付記11)
前記検索キーについて所定のインタフェースシーケンスに基づいて前記テーブルの検索を行うステップを含む付記7に記載のテーブル検索方法。
(Appendix 11)
The table search method according to
(付記12)
前記検索を行う際に、前記インタフェースシーケンスを書換え可能に記憶した記憶部を参照する付記11に記載のテーブル検索方法。
(Appendix 12)
The table search method according to
1 検索識別部
2 検索部
3 結果情報生成部
4 外部デバイス
5 検索依頼部
6 検索調停部
7 検索制御部
8 インタフェース部
9 検索結果識別部
10 パケット処理装置(テーブル検索装置)
12 検索順序設定レジスタ
13 インタフェースシーケンス設定レジスタ
DESCRIPTION OF
12 Search
Claims (5)
前記識別コードに応じた順で、前記検索キーについて複数のテーブルの検索を行い、この検索結果を出力する検索部と、
前記パケットに係る検索結果から結果情報を生成して出力する結果情報生成部と
を備え、
前記検索識別部と検索部と結果情報生成部とが一つのデバイス上に実装され、このデバイス外のテーブルに対して前記検索を行うテーブル検索装置。 The packet type is identified from the received packet, an identification code corresponding to the packet type is generated, and field information necessary for the search is extracted from the packet, and the search according to the field type is performed. A search identification unit for generating a key and transmitting the identification code and the search key;
A search unit that searches a plurality of tables for the search key in an order according to the identification code, and outputs the search result;
A result information generating unit that generates and outputs result information from a search result relating to the packet;
A table search apparatus in which the search identification unit, the search unit, and the result information generation unit are mounted on a single device, and performs the search for a table outside the device.
所定の検索シーケンスに基づいて前記識別コードと対応する検索順序を決定する順序決定部と、
前記順序決定部が決定した順序で検索キーを提供する検索依頼部と、
を備える請求項1に記載のテーブル検索装置。 The search unit
An order determining unit that determines a search order corresponding to the identification code based on a predetermined search sequence;
A search request unit that provides search keys in the order determined by the order determination unit;
The table search device according to claim 1, comprising:
該パケットから検索に必要となるフィールドの情報を抽出して、このフィールドの種類に応じた検索キーを生成するステップと、
前記識別コードに応じた順で、前記検索キーについて複数のテーブルの検索を行い、この検索結果を出力するステップと、
前記パケットに係る検索結果から結果情報を生成して出力するステップと、
を装置にて行うテーブル検索方法。 Identifying the packet type from the received packet and generating an identification code according to the packet type;
Extracting field information necessary for the search from the packet and generating a search key according to the type of the field;
Searching a plurality of tables for the search key in the order according to the identification code, and outputting the search results;
Generating and outputting result information from a search result relating to the packet;
Table search method for performing the above in the apparatus.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2004063834A JP2005252954A (en) | 2004-03-08 | 2004-03-08 | Table retrieval apparatus |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2004063834A JP2005252954A (en) | 2004-03-08 | 2004-03-08 | Table retrieval apparatus |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2005252954A true JP2005252954A (en) | 2005-09-15 |
Family
ID=35032982
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2004063834A Pending JP2005252954A (en) | 2004-03-08 | 2004-03-08 | Table retrieval apparatus |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2005252954A (en) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2009239401A (en) * | 2008-03-26 | 2009-10-15 | Alaxala Networks Corp | Packet transfer apparatus |
JP2012010144A (en) * | 2010-06-25 | 2012-01-12 | Nec Corp | Routing agent device, routing information management method and routing information management program |
JP2012034192A (en) * | 2010-07-30 | 2012-02-16 | Alaxala Networks Corp | Packet transfer device, packet transfer device management system, and packet transfer device management method |
JP5561366B2 (en) * | 2010-09-08 | 2014-07-30 | 日本電気株式会社 | Switch system, switch control method, and storage medium |
-
2004
- 2004-03-08 JP JP2004063834A patent/JP2005252954A/en active Pending
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2009239401A (en) * | 2008-03-26 | 2009-10-15 | Alaxala Networks Corp | Packet transfer apparatus |
JP2012010144A (en) * | 2010-06-25 | 2012-01-12 | Nec Corp | Routing agent device, routing information management method and routing information management program |
JP2012034192A (en) * | 2010-07-30 | 2012-02-16 | Alaxala Networks Corp | Packet transfer device, packet transfer device management system, and packet transfer device management method |
JP5561366B2 (en) * | 2010-09-08 | 2014-07-30 | 日本電気株式会社 | Switch system, switch control method, and storage medium |
US9577931B2 (en) | 2010-09-08 | 2017-02-21 | Nec Corporation | Switching system, switching control system, and storage medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US7349399B1 (en) | Method and apparatus for out-of-order processing of packets using linked lists | |
CN108370352B (en) | High speed flexible packet classification using network processors | |
US8228908B2 (en) | Apparatus for hardware-software classification of data packet flows | |
JP5466257B2 (en) | Table search method | |
EP1492295A1 (en) | Stream data processing device, stream data processing method, program, and medium | |
US20100114973A1 (en) | Deterministic Finite Automata Graph Traversal with Nodal Bit Mapping | |
US10038571B2 (en) | Method for reading and writing forwarding information base, and network processor | |
JP6926953B2 (en) | Information processing equipment, information processing methods and programs | |
JP2006135574A (en) | Packet transmitter | |
JP2005252954A (en) | Table retrieval apparatus | |
KR100456671B1 (en) | Parallel lookup engine and method for fast packet forwarding in network router | |
JP2007228227A (en) | Communication device | |
JP3837670B2 (en) | Data relay apparatus, associative memory device, and associative memory device utilization information retrieval method | |
JP3233353B2 (en) | Header processing device and header processing method | |
CN105791124B (en) | Message detecting method and device | |
US9544226B1 (en) | Efficient address-based rule resolution in a network employing a bit-mapped index | |
EP3761575A1 (en) | Search apparatus and method | |
JP3791280B2 (en) | Printer server | |
JP4408052B2 (en) | Packet classifier | |
JPH10222535A (en) | Data retrieving circuit | |
JP2013038536A (en) | Semiconductor device | |
JP2009088622A (en) | Packet transfer device having buffer memory and method thereof | |
JP2010258811A (en) | Communication system | |
JP2000013438A (en) | Gateway device | |
EP0344915A2 (en) | Apparatus for processing bit streams |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20070208 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20090119 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20090623 |
|
A02 | Decision of refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A02 Effective date: 20091104 |