JP2002208945A - Destination information managing apparatus for packet - Google Patents

Destination information managing apparatus for packet

Info

Publication number
JP2002208945A
JP2002208945A JP2001003000A JP2001003000A JP2002208945A JP 2002208945 A JP2002208945 A JP 2002208945A JP 2001003000 A JP2001003000 A JP 2001003000A JP 2001003000 A JP2001003000 A JP 2001003000A JP 2002208945 A JP2002208945 A JP 2002208945A
Authority
JP
Japan
Prior art keywords
memory
routing table
destination information
packet
entry
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.)
Withdrawn
Application number
JP2001003000A
Other languages
Japanese (ja)
Inventor
Yutaka Ezaki
裕 江▲崎▼
Takeshi Kawasaki
健 川崎
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.)
Fujitsu Ltd
Original Assignee
Fujitsu 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 Fujitsu Ltd filed Critical Fujitsu Ltd
Priority to JP2001003000A priority Critical patent/JP2002208945A/en
Publication of JP2002208945A publication Critical patent/JP2002208945A/en
Withdrawn legal-status Critical Current

Links

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

PROBLEM TO BE SOLVED: To provide a destination information managing apparatus for packet capable of keeping more prefixes than those of a CAM, and retrieving prefixes more rapidly than a RAM. SOLUTION: The apparatus for managing the destination information of the packets for selecting the paths of the packets is provided with a first memory, a second memory having a retrieval speed lower than the first memory and the degree of integration higher than the first memory, and a compiling section for compiling a path table storing the destination information so that the information is over the first and second memories.

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【発明の属する技術分野】本発明はパケットの宛先情報
管理装置に関し、例えば、インターネットやイントラネ
ットで利用されるインターネットプロトコル(IP)アド
レスを管理する装置に関する。
[0001] 1. Field of the Invention [0002] The present invention relates to a packet destination information management device, and more particularly to a device for managing an Internet Protocol (IP) address used in the Internet or an intranet.

【0002】[0002]

【従来の技術】インターネットやイントラネットは、T
CP/IPを利用した通信方式であり、コンピュータ間
の簡易な通信方式としてローカル・エリア・ネットワー
ク(LAN)からワイド・エリア・ネットワーク(WAN)
まで広く利用されている。IPでは、あらゆる情報がパ
ケットに区切られて転送される。パケットは、数十バイ
ト〜数十キロバイト程度の可変長のサイズを持つ。パケ
ットには、送信先アドレス(ディスティネーションアド
レス),送信元アドレス(ソースアドレス)等を含むヘッ
ダが添付される。
2. Description of the Related Art The Internet and intranets are
This is a communication method using CP / IP, which is a simple communication method between computers, from a local area network (LAN) to a wide area network (WAN).
Widely used until. In IP, all information is transferred in packets. The packet has a variable length size of about several tens of bytes to several tens of kilobytes. A header including a destination address (destination address), a source address (source address) and the like is attached to the packet.

【0003】インターネットは、一般に、ルータと呼ば
れる通信装置を相互接続することによって構築される。
ルータは、パケットの宛先情報に基づいて、パケットの
経路を選択する(ルーティング:フォワーディングとも
いう)。即ち、ルータは、パケットを受信すると、受信
したパケットのヘッダに格納された宛先IPアドレスに
対応する次ホップアドレス(パケットを次に受信すべき
ルータのIPアドレス)をルーティングテーブル(「フォ
ワーディングテーブル」ともいう)から取得する。ルー
タは、次ホップアドレスを取得すると、当該次ホップア
ドレスを持つルータへパケットを転送する。ルーティン
グテーブルは、パケットの宛先のネットワーク(「ドメ
イン」と呼ばれる)のIPアドレス(「プレフィクス」と
呼ばれる)と、プレフィクスに対応する次ホップアドレ
スとを記憶している。
[0003] The Internet is generally constructed by interconnecting communication devices called routers.
The router selects a route of the packet based on the destination information of the packet (routing: also referred to as forwarding). That is, when the router receives a packet, the router stores the next hop address (IP address of the router that should receive the packet next) corresponding to the destination IP address stored in the header of the received packet in the routing table (also referred to as “forwarding table”). ). Upon acquiring the next hop address, the router transfers the packet to the router having the next hop address. The routing table stores the IP address (called “prefix”) of the network (called “prefix”) of the destination network of the packet, and the next hop address corresponding to the prefix.

【0004】ダイナミックルーティングが採用される場
合、ルータは、ルーティングプロトコルに従って、ルー
ティング情報(プレフィクス等)を他のルータと相互に交
換し、ルーティングテーブルを作成する。ルーティング
テーブルは、上記したルーティング情報の交換が定期
的,周期的に実行されることによって、数分〜数時間毎
に更新される。ルーティングプロトコルには、例えば、
OSPF(Open ShortestPath First),RIP(Routing
Information Protocol),BGP(Border Gateway Proto
col)等がある。
When dynamic routing is adopted, a router exchanges routing information (prefix and the like) with another router in accordance with a routing protocol and creates a routing table. The routing table is updated every few minutes to several hours by performing the above-described routing information exchange periodically and periodically. Routing protocols include, for example,
OSPF (Open Shortest Path First), RIP (Routing
Information Protocol), BGP (Border Gateway Proto
col) etc.

【0005】ルーティングは、ルータに到着したパケッ
ト毎に実行される。このため、ルーティング性能は、ル
ータの性能を決定する大きな要因となっている。インタ
ーネットサービスプロバイダ(ISP)によって使用され
るルータでは、約25万のIPアドレスに対応する次ホ
ップアドレスを検索可能なルーティングテーブルが要求
される。このような大容量の情報を高速に検索可能であ
り、且つ効率的に保存する技術が従来から検討されてき
た。
[0005] Routing is performed for each packet arriving at the router. For this reason, the routing performance is a major factor that determines the performance of the router. Routers used by Internet service providers (ISPs) require a routing table that can search for the next hop address corresponding to about 250,000 IP addresses. Techniques for searching for such a large amount of information at high speed and for efficiently storing the information have been conventionally studied.

【0006】ルーティングテーブルの構成方法には、大
略して、CAM(Contents Accessable Memory:「連想メ
モリ」と呼ばれる)などの専用のメモリを利用する方法
(「CAM方式」という)と、RAM(Rundam Access Mem
ory)を用いてツリーを構成する方法(「RAMツリー方
式」という)とがある。
The method of constructing the routing table is generally a method of using a dedicated memory such as a CAM (Contents Accessable Memory: referred to as “associative memory”).
(Called “CAM method”) and RAM (Rundam Access Mem
ory) (referred to as a “RAM tree method”).

【0007】IPアドレスは、ネットワークアドレス
(プレフィクス)とホストアドレスとで構成される。有効
なプレフィクス長(有効長)は、ネットワーク構成やアド
レス情報の集約(アグリゲーション)によって変化する。
具体的に説明すると、一般に、ネットワークは、コア
(中継),エッジ等からなる階層で構成されており、ルー
タが保持すべき機能やルーティング情報の細かさ(アド
レスのアグリゲーションの細かさ)は、ルータ毎に異な
る。例えば、ネットワークが、図12に示すように構成
されている場合、LANでは、ルーティングの際に、I
Pアドレスの全アドレス長(32ビット)がプレフィクス
(/32)として使用される。これに対し、アクセスネッ
トワークでは、ルーティングに際し、IPアドレスの上
位24ビット(/24)がプレフィクスとして使用され
る。さらに、コアネットワークでは、ルーティングに際
し、IPアドレスの上位16ビット(/16)がプレフィ
クスとして使用される。
The IP address is a network address
(Prefix) and host address. The effective prefix length (effective length) changes depending on the network configuration and the aggregation of address information (aggregation).
Specifically, in general, a network is a core
(Relay), edges, and the like, and the functions to be held by the routers and the fineness of the routing information (fineness of address aggregation) differ for each router. For example, in the case where the network is configured as shown in FIG.
All address length of P address (32 bits) is prefix
Used as (/ 32). On the other hand, in the access network, the upper 24 bits (/ 24) of the IP address are used as a prefix for routing. Further, in the core network, at the time of routing, the upper 16 bits (/ 16) of the IP address are used as a prefix.

【0008】このように、ネットワークの中心部に進む
に従ってルーティングに使用されるプレフィクスが短く
なる。これに従い、LANとアクセスネットワークとを
結ぶルータ(エッジルータ)は、IPアドレスの全バイト
又は上位24バイトを利用してルーティングを行う。ま
た、アクセスネットワークとコアネットワークとを結ぶ
ルータ(コアルータ)は、IPアドレスの上位24バイト
又は上位16バイトを利用してルーティングを行う。
[0008] As described above, the prefix used for routing becomes shorter toward the center of the network. In accordance with this, a router (edge router) connecting the LAN and the access network performs routing using all bytes or the upper 24 bytes of the IP address. Further, a router (core router) connecting the access network and the core network performs routing using the upper 24 bytes or the upper 16 bytes of the IP address.

【0009】但し、実際には、CIDR(Classless Int
er-Domain Routing)によって、個々のルータが受け取っ
たルーティング情報に基づく経路集約の計算が行われ
る。このため、プレフィクス長は固定ではなく、ドメイ
ンのIPアドレス毎に異なるプレフィクス長が用いられ
る。なお、CIDRのネットワークアドレスは、IPア
ドレス(プレフィクスに相当)とマスク値とで表現され
る。マスクは、ネットワークアドレスの有効ビットであ
り、アドレスの最左端(最上位ビット)からの可変の連続
ビット列で表現される。
However, actually, CIDR (Classless Int)
er-Domain Routing), calculation of route aggregation based on the routing information received by each router is performed. For this reason, the prefix length is not fixed, but a different prefix length is used for each IP address of the domain. The CIDR network address is represented by an IP address (corresponding to a prefix) and a mask value. The mask is a valid bit of the network address, and is expressed by a variable continuous bit string from the leftmost end (most significant bit) of the address.

【0010】ところで、ルータに入力されるパケットに
は、有効長が明示されていない。このため、ルータは、
パケットの宛先のIPアドレスに対応するプレフィクス
を検索する場合には、ロンゲストマッチ(longest matc
h)検索と呼ばれる特別な検索手順を実施する。ロンゲス
トマッチ検索は、宛先のIPアドレスのうち、プレフィ
クスを構成するビット列について、最左端(最上位)から
のビット列が最長に一致するプレフィクスのエントリを
ルーティングテーブルから検索する方法である。
[0010] Incidentally, the effective length is not specified in the packet input to the router. Therefore, the router
When searching for a prefix corresponding to the IP address of the packet destination, a longest match (longest matc
h) Perform a special search procedure called a search. The longest match search is a method of searching a routing table for an entry of a prefix whose bit string from the leftmost end (the highest order) matches the longest among the bit strings constituting the prefix in the destination IP address.

【0011】CAMは、エントリとして記憶されている
内容をキーとして、キーに対応するエントリのアドレス
を出力する特殊なメモリである。CAM方式を用いれ
ば、宛先のIPアドレスに対応するプレフィクスを、R
AMツリー方式に比べて高速に検索することができる。
The CAM is a special memory that outputs the address of the entry corresponding to the key using the contents stored as the entry as a key. If the CAM method is used, the prefix corresponding to the destination IP address is
The search can be performed faster than in the AM tree method.

【0012】RAMツリー方式では、RAM上にプレフ
ィクスのエントリがツリー状に並べられ、宛先IPアド
レスの各ビットが最上位ビットから最下位ビットへ向か
ってビット毎に比較されることによって、対応するプレ
フィクスのエントリが検索される。図13は、RAMツ
リー方式による検索方法の説明図である。図13には、
ツリー構成方法の1つとしてのパトリシア(PATRICIA)ツ
リーの論理構成が示されている。
In the RAM tree method, prefix entries are arranged in a tree on the RAM, and each bit of the destination IP address is compared bit by bit from the most significant bit to the least significant bit to correspond to each other. The prefix entry is searched. FIG. 13 is an explanatory diagram of a search method based on the RAM tree method. In FIG.
A logical configuration of a Patricia tree is shown as one of the tree configuration methods.

【0013】パトリシアツリーでは、エントリデータと
して、プレフィクス値,マスク値(有効長),0ポインタ
(ゼロポインタ),1ポインタ(ワンポインタ),及びルー
ティング情報(次ホップアドレス)が、RAM上に設定さ
れる(図14参照)。パトリシアツリーは、エントリデー
タに応じて設けられた複数のノードN及びリンクLから
なる。各ノードNは、上記したプレフィクス値と有効長
とを有し、さらに、ノードNでの処理対象となるビット
(0又は1)に対応するポインタP1及びポインタP2を
有している。ポインタP1又はポインタP2のジャンプ
先に相当するノードNがある場合には、ノードN同士は
リンクLで接続される。
In the Patricia tree, as entry data, a prefix value, a mask value (effective length), a 0 pointer
(Zero pointer), 1 pointer (one pointer), and routing information (next hop address) are set in the RAM (see FIG. 14). The Patricia tree is composed of a plurality of nodes N and links L provided according to the entry data. Each node N has the prefix value and the effective length described above, and further, a bit to be processed by the node N
It has a pointer P1 and a pointer P2 corresponding to (0 or 1). When there is a node N corresponding to the jump destination of the pointer P1 or the pointer P2, the nodes N are connected by a link L.

【0014】図13には、“000xxxxx(0/3)”,“001xxx
xx(32/3)”,“010xxxxx(64/3)”,“011000xx(96/6)”,
“01100011(99/8)”,“011001xx(100/6)”,“01101xxx
(104/5)”,“0111xxxx(112/4)”,“100xxxxx(128/3)”,
“101xxxxx(160/3)”,“110xxxxx(192/3)”,及び“111x
xxxx(224/3)”の各エントリデータに応じたパトリシア
ツリーが示されている。ここでは、例として、プレフィ
クスの最大有効長が、8ビットで設定されている。
FIG. 13 shows “000xxxxx (0/3)”, “001xxx”
xx (32/3) "," 010xxxxx (64/3) "," 011000xx (96/6) ",
“01100011 (99/8)”, “011001xx (100/6)”, “01101xxx
(104/5) "," 0111xxxx (112/4) "," 100xxxxx (128/3) ",
“101xxxxx (160/3)”, “110xxxxx (192/3)”, and “111x
A Patricia tree corresponding to each entry data of xxxx (224/3) "is shown. Here, as an example, the maximum effective length of the prefix is set to 8 bits.

【0015】エントリデータ中の“x”は、プレフィク
ス中の無効ビットを示す。括弧中の左側の数字は、プレ
フィクス値を示し、エントリデータ中の“x”に“0”
を代入した場合における2進数の値を10進数に換算し
た値である。また、右側の数字は、有効長を示す。例え
ば、エントリデータ“001xxxxx”は、プレフィクス“3
2”を示し、有効長は3ビットである。
"X" in the entry data indicates an invalid bit in the prefix. The number on the left side in parentheses indicates the prefix value, and “x” in the entry data is “0”.
Is a value obtained by converting a binary value into a decimal number when. The number on the right side indicates the effective length. For example, entry data “001xxxxx” is prefix “3”.
2 ", and the effective length is 3 bits.

【0016】パケットの宛先IPアドレスのプレフィク
スが、図13に示すように“01100010(98)”である場合
には、最初のノードN(図13の最も左側のノードN)に
おいて、最左端のビット(最上位ビット)が0か1かが判
定される。このとき、ビットは“0”であるので、ポイ
ンタP1に従った次のノード(プレフィクス値が“0”
で有効長が1のノードN((0/1)のノードN))へ進
み、次のビットが0か1かが判定される。このような処
理がポインタP1又はP2で指定されるリンク先が無く
なるまで繰り返し行われる(図13における太線の矢印
参照)。その後、リンク先が或るノードNで無くなった
時に、宛先のIPアドレスに対応するプレフィクス(宛
先のネットワークアドレス)が特定される。そして、特
定されたプレフィクスに対応する次ホップアドレスが出
力ルートの情報としてルーティングテーブルから取り出
される。
If the prefix of the destination IP address of the packet is “01100010 (98)” as shown in FIG. 13, the first node N (the leftmost node N in FIG. 13) It is determined whether the bit (most significant bit) is 0 or 1. At this time, since the bit is “0”, the next node according to the pointer P1 (the prefix value is “0”)
Then, the process proceeds to the node N having an effective length of 1 (node N of (0/1)), and it is determined whether the next bit is 0 or 1. Such processing is repeated until there is no longer any link destination specified by the pointer P1 or P2 (see the bold arrow in FIG. 13). Thereafter, when the link destination is lost at a certain node N, a prefix (destination network address) corresponding to the destination IP address is specified. Then, the next hop address corresponding to the specified prefix is extracted from the routing table as information on the output route.

【0017】実際のRAM上では、パトリシアツリー
は、図14に示すようなツリーテーブルに格納される。
例えば、図14に示すツリーテーブルを用い、“01
0”というプレフィクスを検索する場合には、以下の処
理が行われる。即ち、最初のエントリでは、最上位ビッ
ト“0”に基づいて0ポインタが調べられ、0ポインタ
で示されたエントリにジャンプする(S101)。次のエ
ントリでは、次のビット“1”に基づいて1ポインタが
調べられ、1ポインタで示された次のエントリにジャン
プする(S102)。そして、次のエントリでは、最下位
ビット“0”に基づいて0ポインタが調べられる。この
とき、0ポインタには、ジャンプ先が無いことを示すエ
ンドフラグがジャンプ先のアドレスの代わりに格納され
ている。このため、当該エントリに格納されている出力
ルートの情報(次ホップアドレス)がツリーテーブルから
読み出される(S103)。
On the actual RAM, the Patricia tree is stored in a tree table as shown in FIG.
For example, using the tree table shown in FIG.
When searching for the prefix “0”, the following processing is performed: In the first entry, the 0 pointer is checked based on the most significant bit “0”, and the jump to the entry indicated by the 0 pointer is performed. In the next entry, one pointer is checked based on the next bit "1", and the process jumps to the next entry indicated by the one pointer (S102). The 0 pointer is checked based on the bit “0.” At this time, an end flag indicating that there is no jump destination is stored in the 0 pointer instead of the jump destination address, and is stored in the entry. The output route information (next hop address) that has been set is read from the tree table (S103).

【0018】[0018]

【発明が解決しようとする課題】RAMツリー方式で
は、プロセッサ(CPU,MPU等)が、ソフトウェアの
実行によって、プレフィクスを構成するビット毎にRA
M上のツリーテーブルを次々と読み込んでいく。このた
め、プロセッサの読み込み回数(メモリアクセスの回数)
が有効長に比例する。IPアドレス(最長32ビット)の
場合、有効長の平均値は20ビット程度である。このた
め、20回程度のメモリアクセスが必要になる。このこ
とに鑑み、例えば、1回のRAMアクセスを30ナノ秒
[ns]程度で実行可能なRAMを使用しても、検索が終
了するまでに平均600[ns],遅い場合には1マイク
ロ秒[μs]程度かかる。従って、RAMツリー方式で
は、パケットの転送性能を1Mpps[mega packet per
second]程度までしか上げることができなかった。
In the RAM tree method, a processor (CPU, MPU, etc.) executes RA processing for each bit constituting a prefix by executing software.
The tree tables on M are read one after another. For this reason, the processor read count (memory access count)
Is proportional to the effective length. In the case of an IP address (up to 32 bits), the average value of the effective length is about 20 bits. For this reason, about 20 memory accesses are required. In view of this, for example, one RAM access takes 30 nanoseconds.
Even if a RAM that can be executed in about [ns] is used, an average of 600 [ns] is required until the search is completed, and about 1 microsecond [μs] if the search is slow. Therefore, in the RAM tree method, the packet transfer performance is set to 1 Mbps [mega packet per
[second] could only be raised.

【0019】RAMは集積度が高く、パトリシアツリー
は、比較的効率的にプレフィクスのエントリを格納する
ことができる。このため、RAMツリー方式がISPの
ルータに採用された場合でも、ルーティングテーブルに
は必要なエントリを格納することができる。半導体技術
の発達により、プロセッサがツリーテーブルからルーテ
ィング情報を検索する手順をハードウェア化した装置
(“レイヤ3スイッチ”と呼ばれる)もある。
The RAM is highly integrated, and the Patricia tree can store prefix entries relatively efficiently. For this reason, even when the RAM tree method is adopted in the ISP router, necessary entries can be stored in the routing table. Due to the development of semiconductor technology, a processor that implements a hardware procedure for searching routing information from a tree table
(Called "Layer 3 switches").

【0020】しかしながら、ツリー方式は、CAM方式
に比べて検索速度が遅いという問題があった。具体的に
は、CAM方式が、数十メガppsでパケットを転送可
能であるのに対し、RAMツリー方式では約1メガpp
sである。但し、CAMの集積度は、RAMに比べて低
く、現状では、数キロエントリ程度しか実現されていな
い。
However, the tree system has a problem that the search speed is lower than that of the CAM system. Specifically, the CAM system can transfer packets at several tens of megapps, whereas the RAM tree system can transfer about 1 megappp.
s. However, the degree of integration of the CAM is lower than that of the RAM, and only about several kilo entries are currently realized.

【0021】上述したように、ルーティングテーブルに
格納すべきエントリ数は、インターネットの拡大に伴っ
て増加している。また、パケットの転送速度の向上も望
まれている。このため、数百キロエントリという大容量
で且つ数十メガppsという高速に検索可能なルーティ
ングテーブルを実現することが望まれている。
As described above, the number of entries to be stored in the routing table is increasing with the expansion of the Internet. It is also desired to improve the packet transfer speed. For this reason, it is desired to realize a routing table having a large capacity of several hundred kilo entries and a high-speed search of several tens of megapps.

【0022】本発明の目的は、CAM方式で作成された
ルーティングテーブルよりも多くのプレフィクスを保持
することができ、且つRAMツリー方式で作成されたル
ーティングテーブルよりも高速にプレフィクスを検索す
ることが可能なパケットの宛先情報管理装置を提供する
ことである。
An object of the present invention is to retain more prefixes than a routing table created by the CAM system and to search for prefixes faster than a routing table created by the RAM tree system. Is to provide a destination information management device for packets that can perform the above.

【0023】[0023]

【課題を解決するための手段】本発明は、上述した目的
を達成するために以下の構成を採用する。
The present invention employs the following configuration to achieve the above object.

【0024】即ち、本発明は、パケットの経路を選択す
るためのパケットの宛先情報を管理する装置であって、
第1メモリと、前記第1メモリよりも情報の検索速度が
遅く且つ集積度が高い第2メモリと、前記宛先情報が前
記第1メモリと前記第2メモリとに跨がる状態で格納さ
れた経路表を作成する作成部と、を備える。
That is, the present invention is an apparatus for managing destination information of a packet for selecting a path of the packet,
A first memory, a second memory having a lower information retrieval speed and a higher degree of integration than the first memory, and the destination information is stored in a state of straddling the first memory and the second memory. A creation unit that creates a routing table.

【0025】本発明によると、第2メモリよりも検索速
度が速い第1メモリに宛先情報の一部が格納されるの
で、第2メモリのみを用いて格納された宛先情報を検索
する場合よりも速く宛先情報を検索することができる。
また、第2メモリは、第1メモリよりも集積度が高いの
で、第1メモリのみを用いる場合よりも多くの宛先情報
を格納することができる。
According to the present invention, a part of the destination information is stored in the first memory, which has a higher search speed than the second memory, so that the stored destination information is searched using only the second memory. The destination information can be searched quickly.
Further, since the second memory has a higher degree of integration than the first memory, it can store more destination information than when only the first memory is used.

【0026】第1メモリは、例えばCAM(連想メモリ)
であり、第2メモリは、例えばRAMである。宛先情報
は、例えばパケットの宛先のIPネットワークアドレス
(プレフィクス)や、VPN識別子とIPネットワークア
ドレスとの組み合わせである。
The first memory is, for example, a CAM (associative memory)
And the second memory is, for example, a RAM. The destination information is, for example, the IP network address of the destination of the packet.
(Prefix) or a combination of a VPN identifier and an IP network address.

【0027】本発明は、前記第1メモリの使用率の閾値
を記憶した閾値記憶部をさらに備え、前記作成部は、前
記第1メモリの使用率を取得し、取得した使用率が前記
閾値記憶部に記憶された閾値未満である場合には、前記
経路表に格納すべき宛先情報を前記第1メモリのみに格
納する、構成とするのが好ましい。
[0027] The present invention may further comprise a threshold storage unit which stores a threshold value of the usage rate of the first memory, wherein the creating unit obtains the usage rate of the first memory, and the obtained usage rate is stored in the threshold storage unit. When the number is less than the threshold value stored in the section, it is preferable that destination information to be stored in the routing table is stored only in the first memory.

【0028】また、本発明は、パケットの宛先情報が第
1メモリとこの第1のメモリよりも情報の検索速度が遅
く且つ集積度が高い第2メモリとに跨る状態で格納され
た経路表と、入力されたパケットに対応する宛先情報を
前記経路表から検索し、検索した宛先情報に対応する出
力ルートの情報を取得する検索部と、を備えた経路選択
装置である。
According to the present invention, there is provided a routing table in which destination information of a packet is stored in a state of straddling a first memory and a second memory having a lower information retrieval speed and a higher degree of integration than the first memory. And a search unit for searching the routing table for destination information corresponding to the input packet and acquiring information on an output route corresponding to the searched destination information.

【0029】[0029]

【発明の実施の形態】以下、図面を参照して本発明の実
施形態を説明する。なお、本発明は、実施形態の構成に
限定されるものではない。
Embodiments of the present invention will be described below with reference to the drawings. Note that the present invention is not limited to the configuration of the embodiment.

【0030】〔第1実施形態〕 〈ルータの構成〉図1は、本発明による宛先情報管理装
置及び経路選択装置が適用された通信装置としてのルー
タ1の構成例を示す図である。ルータ1は、大きく分け
て、物理層(レイヤ1)及びデータリンク層(レイヤ2)に
関する処理を実行する複数のインターフェイスカード2
と、パケットのルーティング(ネットワーク層:レイヤ
3)に関する処理を行うルーティング機構3とを備えて
いる。インターフェイスカード2は、パケットの出力ル
ート(入力ルート)毎に設けられている。
[First Embodiment] <Configuration of Router> FIG. 1 is a diagram showing a configuration example of a router 1 as a communication device to which a destination information management device and a route selection device according to the present invention are applied. The router 1 is roughly divided into a plurality of interface cards 2 that execute processes related to a physical layer (layer 1) and a data link layer (layer 2).
And a routing mechanism 3 for performing processing relating to packet routing (network layer: layer 3). The interface card 2 is provided for each packet output route (input route).

【0031】ルーティング機構3は、ルーティングプロ
トコル処理部4と、ルート計算・経路表作成部5(以
下、「経路表作成部5」と表記)と、ルーティングテー
ブル(経路表)20と、ヘッダ抽出部8と、アドレス検索
部9と、転送処理部10とを備えている。なお、ルーテ
ィング機構3が、本発明の管理装置及び経路選択装置に
相当し、経路表作成部5が本発明の作成部に相当し、ア
ドレス検索部9が本発明の検索部に相当する。
The routing mechanism 3 includes a routing protocol processing unit 4, a route calculation / route table creation unit 5 (hereinafter, referred to as a "route table creation unit 5"), a routing table (route table) 20, and a header extraction unit. 8, an address search unit 9, and a transfer processing unit 10. Note that the routing mechanism 3 corresponds to the management device and the route selection device of the present invention, the routing table creating unit 5 corresponds to the creating unit of the present invention, and the address searching unit 9 corresponds to the searching unit of the present invention.

【0032】ルーティングプロトコル処理部4は、RI
P,OSPF,BGP等の所定のルーティングプロトコ
ルに従ってルーティング情報の交換処理を実行し、他の
ルータからルーティング情報(プレフィクス等)を取得
し、取得したプレフィクスを経路表作成部5に与える。
The routing protocol processing unit 4
A routing information exchange process is executed in accordance with a predetermined routing protocol such as P, OSPF, BGP, etc., and routing information (prefix or the like) is obtained from another router, and the obtained prefix is given to the routing table creating unit 5.

【0033】経路表作成部5は、ルーティングプロトコ
ル処理部4から受け取ったプレフィクスに対応する最適
な出力ルートを計算し、プレフィクスと算出された出力
ルートの情報(次ホップアドレス)とが格納されたルーテ
ィングテーブル20を作成する(本発明の閾値記憶部,
許容時間記憶部,アクセス回数記憶部に相当)。
The routing table creation unit 5 calculates an optimal output route corresponding to the prefix received from the routing protocol processing unit 4, and stores the prefix and information (next hop address) of the calculated output route. Create a routing table 20 (the threshold storage unit of the present invention,
(Corresponds to an allowable time storage unit and an access count storage unit).

【0034】ルーティングテーブル20は、第1メモリ
としてのCAM6と、第2メモリとしてのRAM7とを
含んでいる。CAM6及びRAM7は、経路表作成部5
によって格納されたプレフィクス及び次ホップアドレス
に関するエントリを保持する。 なお、本実施形態で
は、ダイナミックルーティングによってプレフィクスが
取得される例について述べているが、本発明は、スタテ
ィックルーティングによって作成されたルーティングテ
ーブルを持つルータにも適用可能である。
The routing table 20 includes a CAM 6 as a first memory and a RAM 7 as a second memory. The CAM 6 and the RAM 7 include a routing table creation unit 5
Holds the entry for the prefix and the next hop address stored by. In the present embodiment, an example is described in which a prefix is obtained by dynamic routing. However, the present invention is also applicable to a router having a routing table created by static routing.

【0035】ヘッダ抽出部8は、各インターフェイスカ
ード2からルーティング機構3に入力されたパケットの
ヘッダを抽出し、抽出したヘッダから宛先IPアドレス
(ディスティネーションIPアドレス)を取り出し、アド
レス検索部9に与える。
The header extraction unit 8 extracts the header of the packet input from each interface card 2 to the routing mechanism 3, and extracts the destination IP address from the extracted header.
(Destination IP address) and gives it to the address search unit 9.

【0036】アドレス検索部9は、ヘッダ抽出部8から
受け取った宛先IPアドレスのプレフィクスに対応する
次ホップアドレスをルーティングテーブル20から読み
出し、転送処理部10に与える。
The address search unit 9 reads out the next hop address corresponding to the prefix of the destination IP address received from the header extraction unit 8 from the routing table 20 and supplies it to the transfer processing unit 10.

【0037】転送処理部10は、ルーティング機構3に
入力されたパケットをアドレス検索部9から受け取った
次ホップアドレスに対応するインターフェイスカード2
に入力する。
The transfer processing unit 10 receives the packet input to the routing mechanism 3 from the interface card 2 corresponding to the next hop address received from the address search unit 9.
To enter.

【0038】インターフェイスカード2は、ルーティン
グ機構3から入力されたパケットに対し、レイヤ1及び
レイヤ2に関する処理(例えば、宛先MACアドレスの
書換)を行う。その後、インターフェイスカード2は、
パケットを次ホップアドレスに相当する他のルータへ転
送する。
The interface card 2 performs a process (for example, rewriting a destination MAC address) on layers 1 and 2 for the packet input from the routing mechanism 3. After that, the interface card 2
Forward the packet to another router corresponding to the next hop address.

【0039】なお、ルーティングプロトコル処理部4,
経路表作成部5,ヘッダ抽出部8,アドレス検索部9
は、CPU等のプロセッサ(図示せず)がプログラムを実
行することによって実現される機能である。転送処理部
9は、例えば、ソフトウェア又はハードウェアで実現さ
れるスイッチを用いて構成される。
The routing protocol processing unit 4,
Routing table creation unit 5, header extraction unit 8, address search unit 9
Is a function realized by a processor (not shown) such as a CPU executing a program. The transfer processing unit 9 is configured using, for example, a switch realized by software or hardware.

【0040】〈CAMの構成〉次に、CAM6について
説明する。CAMは、与えられたパターンにマッチする
エントリのアドレスを出力する特殊なメモリである。比
較パターンとして“0”又は“1”しか設定できないC
AMは、“bimary CAM”と呼ばれ、比較パターンとして
“0”,“1”及び“d.c.(マスク)”の3パターンを設
定可能なCAMは、“ternary CAM”と呼ばれる。
<Configuration of CAM> Next, the CAM 6 will be described. The CAM is a special memory that outputs an address of an entry that matches a given pattern. C in which only "0" or "1" can be set as a comparison pattern
The AM is called “bimary CAM”, and the CAM in which three patterns “0”, “1” and “dc (mask)” can be set as a comparison pattern is called “ternary CAM”.

【0041】図2は、CAM6の構成例を示す図であ
る。CAM6は、ビット毎に比較器を有する特殊な記憶
素子を複数アレイ上に並べて構成されたデータアレイ及
びマスクアレイ12と、ロンゲストマッチ検索やアドレ
スの優先制御を実行するプライオリティ・エンコーダ(p
riority encoder)13と、書込データ等を出入力するた
めの入出力制御装置(I/O:図示せず)とを備えてお
り、CAM6の出力信号は、補助RAM14に入力され
る。
FIG. 2 is a diagram showing a configuration example of the CAM 6. The CAM 6 includes a data array and a mask array 12 in which special memory elements each having a comparator for each bit are arranged on a plurality of arrays, and a priority encoder (p) for performing longest match search and priority control of addresses.
A riority encoder 13 and an input / output control device (I / O: not shown) for inputting / outputting write data and the like are provided.

【0042】ロンゲストマッチ検索の前提として、書込
データとしてのプレフィクスとマスク情報との組み合わ
せが、I/Oを通じてデータアレイ/マスクアレイ12
にエントリとして書き込まれる。比較対象(出力ルート
の検索対象)としての宛先IPアドレスがI/Oを通じ
てCAM6に入力されると、当該宛先IPアドレスとデ
ータアレイ/マスクアレイ12の各エントリとが比較さ
れ、比較対象の宛先IPアドレスに一致するプレフィク
スを保持したエントリのアドレス(CAMアドレス)が検
出される。
As a premise of the longest match search, a combination of a prefix as write data and mask information is transmitted through the I / O to the data array / mask array 12.
Is written as an entry. When a destination IP address as a comparison target (output route search target) is input to the CAM 6 via I / O, the destination IP address and each entry of the data array / mask array 12 are compared, and the comparison target destination IP The address (CAM address) of the entry holding the prefix that matches the address is detected.

【0043】プライオリティ・エンコーダ13は、複数
のCAMアドレスが検出された場合に、宛先IPアドレ
スに最長に一致する(有効長が最も長い)CAMアドレ
ス,或いは、優先すべきCAMアドレスを特定し、特定
されたCAMアドレスが出力される。
When a plurality of CAM addresses are detected, the priority encoder 13 specifies a CAM address that has the longest match with the destination IP address (has the longest effective length) or a CAM address to be given priority, and specifies The output CAM address is output.

【0044】ternary CAMとしてのCAM6によるプレ
フィクス検索の例を図2を用いて説明する。今、CAM
6のデータアレイ/マスクアレイ12には、図2に示す
ように、複数のプレフィクスとマスク情報との組み合わ
せがエントリとして書き込まれている。この例では、エ
ントリに保持されたプレフィクスは、有効長が長い順で
ソートされている。
An example of a prefix search using the CAM 6 as a ternary CAM will be described with reference to FIG. Now, CAM
As shown in FIG. 2, combinations of a plurality of prefixes and mask information are written as entries in the data array / mask array 12 of FIG. In this example, the prefixes held in the entries are sorted in the order of the effective length.

【0045】ここで、例えば、或るパケットの宛先IP
アドレス“192.168.0.177”がCAM11
に入力されたとする。すると、宛先IPアドレス“19
2.168.0.177”と、データアレイ/マスクア
レイ12に保持されたエントリ(プレフィクスとマスク
情報との組み合わせ)の夫々とが比較され、両者が合致
するCAMアドレスを示す信号が、プライオリティ・エ
ンコーダ13に入力される。図2に示す例では、CAM
アドレス“1”,“1003”,“1007”及び“6
5535”が、プライオリティ・エンコーダ13に入力
される。
Here, for example, the destination IP of a certain packet
The address “192.168.0.177” is CAM11
Is entered. Then, the destination IP address “19”
2.168.0.177 "is compared with each entry (combination of prefix and mask information) held in the data array / mask array 12, and a signal indicating a CAM address that matches both is given a priority. Input to the encoder 13. In the example shown in FIG.
Addresses “1”, “1003”, “1007” and “6”
5535 "is input to the priority encoder 13.

【0046】プライオリティ・エンコーダ13は、入力
された信号のうち、アドレス値が最も若いCAMアドレ
ス“1”を示す信号を選択し、CAMアドレス“1”を
補助RAM14に入力する。これによって、CAMアド
レス“1”に保持された“192.168.0.177
/32”が、CAM6に入力された宛先IPアドレスに
対応するプレフィクスとして特定される。
The priority encoder 13 selects a signal indicating the CAM address “1” having the smallest address value among the input signals, and inputs the CAM address “1” to the auxiliary RAM 14. As a result, “192.168.0.177” held at the CAM address “1” is obtained.
/ 32 "is specified as a prefix corresponding to the destination IP address input to CAM6.

【0047】補助RAM14は、CAMアドレスに対応
する次ホップアドレスを保持しており、CAMアドレス
“1”が入力されると、入力されたCAMアドレスに対
応する次ホップアドレスを出力する。出力された次ホッ
プアドレスは、アドレス検索部9に与えられる。その
後、次ホップアドレスは、転送処理部10に与えられ、
転送処理部10は、パケットを次ホップアドレスに対応
するインターフェイスカード2に与える。インターフェ
イスカード2は、受け取ったパケットを次ホップへ転送
する。
The auxiliary RAM 14 holds the next hop address corresponding to the CAM address, and when the CAM address "1" is input, outputs the next hop address corresponding to the input CAM address. The output next hop address is provided to the address search unit 9. Then, the next hop address is given to the transfer processing unit 10,
The transfer processing unit 10 gives the packet to the interface card 2 corresponding to the next hop address. The interface card 2 transfers the received packet to the next hop.

【0048】CAM6は、宛先IPアドレスがCAM1
1に入力されてからCAMアドレスを示す信号が補助R
AM14に格納されるまでの動作(宛先IPアドレスに
対するロンゲストマッチ検索)を一度に行うことができ
る。現状では、CAMは、5千万〜1億サーチ/秒(=
10〜20ns/サーチ)の速度で高速な検索を行うこと
ができる。但し、CAM6の集積度は、前述した比較機
能を有するために、数Mbitであり、RAMに比べて
数分の1に落ちる。
CAM6 has a destination IP address of CAM1.
The signal indicating the CAM address is input to the auxiliary R
The operation until the data is stored in the AM 14 (long guest match search for the destination IP address) can be performed at a time. At present, CAM is 50 to 100 million searches / sec (=
A high-speed search can be performed at a speed of 10 to 20 ns / search). However, the degree of integration of the CAM 6 is several Mbits because of the above-described comparison function, and is reduced to a fraction of that of the RAM.

【0049】〈RAMの構成〉RAM7には、図13に
示したようなパトリシアツリー(ツリーテーブル)が作成
される。即ち、RAM7は、プレフィクス,マスク長,
0ポインタ,1ポインタ,及び次ホップアドレスをエン
トリとして格納したツリーテーブルを格納している(図
14参照)。RAMツリー及びツリーテーブルの構造自
体は、図13及び図14に示したものと同じである。経
路表作成部5は、新規のプレフィクスと、このプレフィ
クスに対応する次ホップアドレスを含むエントリをパト
リシアツリー(ツリーテーブル)に追加する。この場合に
は、経路表作成部5は、図3に示す4つのパターンの何
れかに従ってエントリを追加する。4つのパターンは、
以下の通りである。 (A)第1パターン:既存ノードに一致する場合 (B)第2パターン:既存ノードに子ノードとして追加す
る場合 (C)第3パターン:既存ノードの中間に追加する場合 (D)第4パターン:既存ノードから分木ノードとともに
追加する場合 第1パターンでは、エントリは、ツリー上に既に存在す
るノード(図3(A)のノードN1)に追加される。第2パ
ターンでは、エントリは、ツリー上に既に存在するノー
ド(図3(B)のノードN2)の子ノード(図3(B)のノー
ドN3)として追加される。第3パターンでは、エント
リは、或る親ノード(図3(C)のノードN4)と子ノード
(図3(C)のノードN5)との間の中間ノード(図3(C)
のノードN6)として追加される。
<Arrangement of RAM> In the RAM 7, a Patricia tree (tree table) as shown in FIG. 13 is created. That is, the RAM 7 stores a prefix, a mask length,
The tree table stores the 0 pointer, the 1 pointer, and the next hop address as entries (see FIG. 14). The structures themselves of the RAM tree and the tree table are the same as those shown in FIGS. The routing table creation unit 5 adds a new prefix and an entry including the next hop address corresponding to the prefix to the Patricia tree (tree table). In this case, the routing table creation unit 5 adds an entry according to any of the four patterns shown in FIG. The four patterns are
It is as follows. (A) 1st pattern: When matching with existing node (B) 2nd pattern: When adding to existing node as child node (C) 3rd pattern: When adding in the middle of existing node (D) 4th pattern In the case of adding from an existing node together with a branch tree node, in the first pattern, an entry is added to a node (node N1 in FIG. 3A) already existing on the tree. In the second pattern, the entry is added as a child node (node N3 in FIG. 3B) of a node (node N2 in FIG. 3B) already existing on the tree. In the third pattern, the entry is composed of a certain parent node (node N4 in FIG. 3C) and a child node.
(The node N5 in FIG. 3C).
As a node N6).

【0050】第4パターンでは、エントリは、或る親ノ
ード(図3(D)のノードN7)と子ノード(図3(D)のノ
ードN8)との間の分木ノード(図3(D)のノードN9)
とともに、分木ノードの子ノード(図3(D)のノードN
10)として追加される。エントリが追加された場合、
経路表作成部5は、追加されたエントリ(ノード)に関連
するノードのポインタ(0ポインタ及び/又は1ポイン
タ)を正しく付け替える。これによって、RAMツリー
が修正される。
In the fourth pattern, the entry is a tree node (FIG. 3 (D)) between a certain parent node (node N7 in FIG. 3 (D)) and a child node (node N8 in FIG. 3 (D)). ) Node N9)
And a child node of the branch tree node (node N in FIG. 3D).
10). When an entry is added,
The routing table creation unit 5 correctly replaces the pointers (0 pointer and / or 1 pointer) of the node related to the added entry (node). This modifies the RAM tree.

【0051】〈経路表を用いたアドレス検索〉次に、ア
ドレス検索部9がルーティングテーブル20を用いて次
ホップアドレスを検索する処理について説明する。図4
は、実施形態におけるルーティングテーブル20の構成
図である。図4において、CAM6は、ternary CAM を
用いて構成されている。RAM7は、パトリシアツリー
(RAMツリー)17(のツリーテーブル)を格納してい
る。
<Address Search Using Routing Table> Next, a process in which the address search unit 9 searches for a next hop address using the routing table 20 will be described. FIG.
FIG. 3 is a configuration diagram of a routing table 20 in the embodiment. In FIG. 4, CAM 6 is configured using ternary CAM. RAM7 is Patricia Tree
(RAM tree) 17 (a tree table thereof) is stored.

【0052】本実施形態では、宛先IPアドレスに対応
するプレフィクスは、以下の3つのパターンの何れかに
よってルーティングテーブル20に格納されている。 (A)CAM6のエントリとして格納 (B)RAMツリー17のエントリとして格納 (C)CAM6及びRAMツリー17に亘って(跨って)格
納 上記したパターン(C)では、プレフィクスが所定数の有
効ビットからなることに鑑み、プレフィクスのうち、最
左端のビット(最上位ビット)から所定ビットまで(第1
の部分)を検索するためのエントリがCAM16にセッ
トされ、上記所定ビットから最後のビット(最下位ビッ
ト)まで(第2の部分)を検索する為のエントリが、RA
Mツリー17にセットされる。
In this embodiment, the prefix corresponding to the destination IP address is stored in the routing table 20 in one of the following three patterns. (A) Stored as an entry in the CAM 6 (B) Stored as an entry in the RAM tree 17 (C) Stored (across) the CAM 6 and the RAM tree 17 In the pattern (C) described above, the prefix has a predetermined number of valid bits. In the prefix, from the leftmost bit (most significant bit) to a predetermined bit (first
Is set in the CAM 16, and an entry for searching (the second part) from the predetermined bit to the last bit (least significant bit) is RA
It is set in the M-tree 17.

【0053】例えば、プレフィクス“0000xxxx”(プレ
フィクス値0/有効長4)を、パターン(C)でルーティ
ングテーブル20にセットする場合には、CAM6及び
RAMツリー17は、以下の構成を持つ。即ち、CAM
6のデータアレイ/マスクアレイ12には、“0(0xxxx
xxx)/1”のエントリE1が設けられる。一方、RAM
ツリー17には、“0/1”のエントリを保持したノー
ドN11が設けられる。
For example, when the prefix “0000xxxx” (prefix value 0 / effective length 4) is set in the routing table 20 in the pattern (C), the CAM 6 and the RAM tree 17 have the following configurations. That is, CAM
No. 0 (0xxxx)
xxx) / 1 "is provided.
The tree 17 is provided with a node N11 holding an entry of “0/1”.

【0054】エントリE1のアドレス(CAMアドレス)
は、ノードN11のRAMアドレスにリンクされてい
る。これによって、アドレス検索部9(図1参照)は、C
AM16から出力されるエントリE1のアドレスを用い
てノードN11にアクセスすることができる。
Address of entry E1 (CAM address)
Are linked to the RAM address of the node N11. Thereby, the address search unit 9 (see FIG. 1)
The node N11 can be accessed using the address of the entry E1 output from the AM 16.

【0055】即ち、パターン(C)でプレフィクスがセッ
トされる場合には、CAMアドレスに対応するRAMア
ドレス(RAMツリーのエントリ(ノード)のアドレス)
が、CAMアドレスに対応する次ホップアドレスの代わ
りに、補助RAM14(図2参照)に格納される。ノード
N11は、“0/2”のエントリを保持したノードN1
2に0ポインタを介してリンクされており、ノードN1
2は、“0/3”のエントリを保持したノードN13に
0ポインタを介してリンクされている。
That is, when the prefix is set in the pattern (C), the RAM address (address of the entry (node) of the RAM tree) corresponding to the CAM address
Are stored in the auxiliary RAM 14 (see FIG. 2) instead of the next hop address corresponding to the CAM address. The node N11 is a node N1 holding an entry of “0/2”.
2 is linked to the node N1 via the 0 pointer.
2 is linked via a 0 pointer to a node N13 holding an entry of “0/3”.

【0056】また、例えば、プレフィクス“0110000x”
(プレフィクス値96/有効長7)について、CAM6及
びRAMツリー17は以下の構成を持つ。即ち、CAM
6のデータアレイ/マスクアレイ12には、“96(011
00xxx)/5”のエントリE2が設けられている。一方、
RAMツリー17には、“96/5”のエントリを保持
したノードN21が設けられている。
For example, the prefix “0110000x”
For (prefix value 96 / effective length 7), the CAM 6 and the RAM tree 17 have the following configuration. That is, CAM
The data array / mask array 12 of “6” contains “96 (011
00xxx) / 5 "entry is provided.
The RAM tree 17 is provided with a node N21 holding an entry of “96/5”.

【0057】エントリE2のCAMアドレスは、ノード
N21のRAMアドレスと補助RAM14を介してリン
クされており、アドレス検索部9は、CAM16から出
力されるエントリE2のCAMアドレスを用いてノード
N21にアクセスすることができる。ノードN21は、
“96/6”のエントリを保持したノードN22に0ポ
インタを介してリンクされている。
The CAM address of the entry E2 is linked to the RAM address of the node N21 via the auxiliary RAM 14, and the address search unit 9 accesses the node N21 using the CAM address of the entry E2 output from the CAM 16. be able to. Node N21
It is linked via a 0 pointer to the node N22 holding the entry of "96/6".

【0058】アドレス検索部9は、ヘッダ抽出部8から
宛先IPアドレスを受け取ると、以下のルーティング処
理を実行する。即ち、アドレス検索部9は、宛先IPア
ドレスをCAM6に入力する。ここで、入力された宛先
IPアドレスが、例えば“01100000”である場合には、
CAM6は、ロンゲストマッチ検索によって、プレフィ
クスの最上位ビットからの各ビット値が最長に一致する
“96/5”のエントリE2のCAMアドレスを出力す
る。出力されたCAMアドレスは、補助RAM14に入
力される。すると、エントリE2のCAMアドレスに対
応するRAMアドレス(ノードN21のアドレス)が補助
RAM14からアドレス検索部9に与えられる。
When receiving the destination IP address from the header extracting unit 8, the address searching unit 9 executes the following routing processing. That is, the address search unit 9 inputs the destination IP address to the CAM 6. Here, if the input destination IP address is, for example, “01100000”,
The CAM 6 outputs the CAM address of the entry E2 of “96/5” in which each bit value from the most significant bit of the prefix matches the longest by the longest match search. The output CAM address is input to the auxiliary RAM 14. Then, the RAM address (address of the node N21) corresponding to the CAM address of the entry E2 is given from the auxiliary RAM 14 to the address search unit 9.

【0059】アドレス検索部9は、補助RAM14から
RAMアドレスを受け取ると、受け取ったRAMアドレ
スを用いてRAMツリー17のノードN21にアクセス
する。次に、アドレス検索部9は、ノードN21の0ポ
インタによって指定されたノードN22にアクセスす
る。
When receiving the RAM address from the auxiliary RAM 14, the address search unit 9 accesses the node N21 of the RAM tree 17 using the received RAM address. Next, the address search unit 9 accesses the node N22 specified by the 0 pointer of the node N21.

【0060】アドレス検索部9は、ノードN22にて0
ポインタを参照する。0ポインタは、指定されるリンク
先の代わりに、リンク先がないことを示すエンドフラグ
を格納している。そこで、アドレス検索部9は、宛先I
Pアドレスに対応するプレフィクスが“011000xx(96
/6)”であるものとして、プレフィクス“96/6”
に対応する次ホップアドレスをRAM7から読み出す。
このようにして、宛先IPアドレスに対応するプレフィ
クスが特定され、出力ルート(次ホップ)が決定される。
The address search unit 9 sets 0 at the node N22.
Refers to a pointer. The 0 pointer stores an end flag indicating that there is no link destination instead of the designated link destination. Therefore, the address search unit 9 determines that the destination I
The prefix corresponding to the P address is “011000xx (96
/ 6) ”, the prefix“ 96/6 ”
Is read from the RAM 7.
In this way, the prefix corresponding to the destination IP address is specified, and the output route (next hop) is determined.

【0061】上述したルーティング処理によると、宛先
IPアドレスに対応するプレフィクスのうち、最上位ビ
ットから5ビット目までが、CAM16によって一度に
検索される。その後、プレフィクスの6ビット目と7ビ
ット目についての処理が、RAMツリー17を用いて行
われ、宛先IPアドレスのプレフィクスが特定される。
According to the above-described routing processing, the CAM 16 searches all the prefixes corresponding to the destination IP address from the most significant bit to the fifth bit at a time. Thereafter, the processing for the sixth and seventh bits of the prefix is performed using the RAM tree 17, and the prefix of the destination IP address is specified.

【0062】上記ルーティング処理において、最上位ビ
ットから5ビット目までに対する処理は、RAMツリー
17のみを用いて行うと、5回のRAMアクセスを要す
る。これに対し、上記ルーティング処理は、CAM16
を用いて一度に行うため、検索時間が短縮される。
In the above-described routing processing, if processing from the most significant bit to the fifth bit is performed using only the RAM tree 17, five RAM accesses are required. On the other hand, the above-mentioned routing process is performed in the CAM
, The search time is reduced.

【0063】また、7ビットの有効長を持つプレフィク
スがRAMツリー17のみを用いて検索される場合に
は、7回のRAMアクセスが必要である。これに対し、
上記ルーティング処理は、RAMアクセスを2回に抑え
ることができる。従って、検索に必要な時間が、RAM
ツリー17のみを用いてプレフィクスを検索する場合に
比べて短縮される。一方、プレフィクスのエントリが、
上記したパターン(B)によってRAMツリー17に設定
される。このため、CAM6に設定されるエントリの数
を減らすことができる。
When a prefix having an effective length of 7 bits is searched using only the RAM tree 17, seven RAM accesses are required. In contrast,
In the above routing process, the number of RAM accesses can be reduced to two. Therefore, the time required for the search is
This is shortened compared to a case where a prefix is searched using only the tree 17. On the other hand, if the prefix entry is
It is set in the RAM tree 17 according to the pattern (B) described above. Therefore, the number of entries set in the CAM 6 can be reduced.

【0064】従って、上述したルーティングテーブル2
0によれば、ルーティングテーブルがCAMのみを用い
て構成される場合よりも多くのエントリを格納すること
ができる。一方、ルーティングテーブル20によれば、
1つのパケットについてルーティングに要する時間を、
ルーティングテーブルがRAMツリーのみを用いて構成
される場合よりも短縮することができ、ルーティング性
能の向上を図ることができる。
Therefore, the above-described routing table 2
According to 0, more entries can be stored than when the routing table is configured using only the CAM. On the other hand, according to the routing table 20,
The time required for routing for one packet is
The routing table can be shorter than the case where the routing table is configured using only the RAM tree, and the routing performance can be improved.

【0065】〈エントリの追加〉ネットワークのトポロ
ジは、ネットワークの再構築,ネットワークの保守・点
検,リンクやノードの障害等によって変化する。トポロ
ジが変化すると、ルータ1から或るネットワークへ至る
最適なルートが変化する。ルータ1は、トポロジの変化
に対応すべく、定期的又は周期的にルーティングテーブ
ル20を更新する。 即ち、ルータ1のルーティングプ
ロトコル処理部4は、定期的又は周期的にルーティング
プロトコルに従ってルーティング情報の交換を行い、他
のルータから取得したルーティング情報からプレフィク
スを抽出し、経路表作成部5に与える。 経路表作成部
5は、新たなプレフィクスをルーティングプロトコル処
理部4から受け取った場合には、受け取ったプレフィク
スへパケットを転送するための最適な出力ルートを計算
し、計算結果に基づいて次ホップを決定する。
<Addition of Entry> The topology of the network changes due to network restructuring, network maintenance / inspection, link or node failure, and the like. When the topology changes, the optimal route from the router 1 to a certain network changes. The router 1 updates the routing table 20 periodically or periodically to respond to a change in topology. That is, the routing protocol processing unit 4 of the router 1 periodically or periodically exchanges routing information according to the routing protocol, extracts a prefix from the routing information acquired from another router, and provides the routing table creation unit 5 with the prefix. . When a new prefix is received from the routing protocol processing unit 4, the routing table creation unit 5 calculates an optimal output route for transferring the packet to the received prefix, and based on the calculation result, the next hop. To determine.

【0066】そして、経路表作成部5は、受け取ったプ
レフィクスをルーティングテーブル20にエントリとし
て格納し、格納された新たなエントリと決定された次ホ
ップアドレスとを関連づける。これによって、アドレス
検索部9が、新たなエントリに対応する宛先IPアドレ
スを持つパケットについて、対応する次ホップアドレス
を得ることができる。
Then, the routing table creating unit 5 stores the received prefix as an entry in the routing table 20, and associates the stored new entry with the determined next hop address. As a result, the address search unit 9 can obtain the corresponding next hop address for the packet having the destination IP address corresponding to the new entry.

【0067】図5及び図6は、経路表作成部5によるエ
ントリの追加処理を示すフローチャートである。図5に
おいて、ルータ1の管理者は、CAM6の利用率の閾値
ηc(max)と、RAM7の利用率の閾値ηr(max)とを、経
路表作成部5の図示せぬメモリに格納する(ステップS
1)。
FIGS. 5 and 6 are flowcharts showing the process of adding an entry by the routing table creation unit 5. FIG. In FIG. 5, the administrator of the router 1 stores the threshold ηc (max) of the usage rate of the CAM 6 and the threshold ηr (max) of the usage rate of the RAM 7 in a memory (not shown) of the routing table creation unit 5 ( Step S
1).

【0068】CAM6の利用率ηcは、CAM6(のデー
タアレイ/マスクアレイ12)に格納されたエントリ数
をCAM6に格納可能な全エントリ数で除した値(CA
M6のエントリ利用率)である。一方、RAM7の利用
率ηrは、RAM7にRAMツリー17を構成するノー
ドとして格納されたエントリ数をRAM7に格納可能な
全エントリ数で除した値(RAM7のエントリ利用率)で
ある。
The utilization rate ηc of the CAM 6 is obtained by dividing the number of entries stored in (the data array / mask array 12 of) the CAM 6 by the total number of entries that can be stored in the CAM 6 (CA
M6 entry utilization rate). On the other hand, the usage rate ηr of the RAM 7 is a value obtained by dividing the number of entries stored in the RAM 7 as nodes constituting the RAM tree 17 by the total number of entries that can be stored in the RAM 7 (entry usage rate of the RAM 7).

【0069】次に、ルータ1の管理者は、1回のルーテ
ィングの許容時間Tmaxと、RAM7へのアクセス時間
τrと、1回のルーティングにおけるRAM7への最大
アクセス回数δmax=Tmax/τrとを、経路表作成部5
の図示せぬメモリに格納する(ステップS2)。なお、ス
テップS1及びステップS2の処理は、ルータ1で自動
的に行われるようにしても良い。
Next, the administrator of the router 1 determines the permissible time Tmax for one routing, the access time τr to the RAM 7, and the maximum number of accesses δmax = Tmax / τr to the RAM 7 in one routing, Routing table creation unit 5
(Step S2). The processing in steps S1 and S2 may be automatically performed by the router 1.

【0070】その後、ステップS3以降の処理は、経路
表作成部5が、ルーティングプロトコル処理部4からプ
レフィクスを受け取った場合に開始される。経路表作成
部5は、ルーティングプロトコル処理部4から1以上の
プレフィクスを受け取ると(ステップS3;Yes)、ル
ーティングテーブル20に追加すべき新たなプレフィク
スが受け取ったプレフィクスに含まれているか否かを判
定し(ステップS4)、含まれていない場合には処理をス
テップS3に戻し、含まれている場合には、処理をステ
ップS5に進める。
Thereafter, the processing after step S3 is started when the routing table creator 5 receives the prefix from the routing protocol processor 4. When receiving one or more prefixes from the routing protocol processing unit 4 (step S3; Yes), the routing table creation unit 5 determines whether a new prefix to be added to the routing table 20 is included in the received prefix. (Step S4), and if not included, the process returns to step S3; otherwise, the process proceeds to step S5.

【0071】ステップS5では、経路表作成部5は、追
加対象の新規のプレフィクス(新たに得られたプレフィ
クス)を“N”に設定し、プレフィクス“N”の有効長
を“n”に設定する。続いて、経路表作成部5は、プレ
フィクス“N”を用いてルーティングテーブル20を検
索し、ルーティングテーブル20にエントリとして格納
されているプレフィクスのうち、プレフィクス“N”と
最長に一致するプレフィクス“M”と、プレフィクス
“M”の有効長“m”を求める(ステップS6)。次に、
有効長“n”から有効長“m”を減算し、有効長の差分
δを求める(ステップS7)。
In step S5, the routing table creator 5 sets a new prefix to be added (a newly obtained prefix) to "N" and sets the effective length of the prefix "N" to "n". Set to. Subsequently, the routing table creating unit 5 searches the routing table 20 using the prefix “N”, and among the prefixes stored as entries in the routing table 20, the longest match with the prefix “N” is performed. The prefix “M” and the effective length “m” of the prefix “M” are obtained (step S6). next,
The effective length “m” is subtracted from the effective length “n” to obtain the effective length difference δ (step S7).

【0072】次に、経路表作成部5は、図6に示すよう
に、CAM6の利用率ηcを計測するとともに、RAM
7の利用率ηrを計測する(ステップS8)。次に、経路
表作成部5は、CAM6に十分な空き領域があるか否か
を判定する(ステップS9)。即ち、経路表作成部5は、
CAM6の利用率ηcが条件“ηc < ηc(max)”を満た
すか否かを判定する。
Next, as shown in FIG. 6, the routing table creation unit 5 measures the utilization ηc of the CAM 6 and
Then, the utilization factor ηr of Step 7 is measured (Step S8). Next, the routing table creation unit 5 determines whether there is a sufficient free area in the CAM 6 (Step S9). That is, the routing table creation unit 5
It is determined whether the utilization rate ηc of the CAM 6 satisfies the condition “ηc <ηc (max)”.

【0073】このとき、条件が満たされる場合(ステッ
プS9;Yes)には、経路表作成部5は、プレフィク
ス“N”のエントリをCAM6に追加(格納)する(ステ
ップS10)。
At this time, if the condition is satisfied (step S9; Yes), the routing table creation unit 5 adds (stores) an entry with the prefix “N” to the CAM 6 (step S10).

【0074】このように、利用率ηcの値が閾値ηc(ma
x)未満である場合には、CAM6の利用率ηcが低く、
CAM6に十分な空き領域があるものとして、プレフィ
クス“N”のエントリがCAM6のみに格納される。こ
れによって、ルーティング時間を短縮することができ
る。これに対し、条件が満たされない場合には、処理が
ステップS11に進む。
As described above, the value of the utilization factor ηc is equal to the threshold value ηc (ma
x), the CAM 6 utilization rate ηc is low,
Assuming that the CAM 6 has a sufficient free area, the entry of the prefix “N” is stored only in the CAM 6. As a result, the routing time can be reduced. On the other hand, if the condition is not satisfied, the process proceeds to step S11.

【0075】ステップS11では、経路表作成部5は、
RAM7に十分な空き領域があるか否かを判定する。即
ち、経路表作成部5は、RAM7の利用率ηrが条件
“ηr< ηr(max)”を満たすか否かを判定する。
At step S11, the routing table creation unit 5
It is determined whether or not the RAM 7 has a sufficient free area. That is, the routing table creation unit 5 determines whether or not the utilization rate ηr of the RAM 7 satisfies the condition “ηr <ηr (max)”.

【0076】このとき、条件が満たされない場合(ステ
ップS11;No)には、ルータ1は、プレフィクス
“N”のエントリをルーティングテーブル20に登録で
きないものとしてエラーを出力する(ステップS12)。
これに対し、条件が満たされる場合(ステップS11;
Yes)には、処理がステップS13に進む。
At this time, if the condition is not satisfied (step S11; No), the router 1 outputs an error as an entry having the prefix “N” cannot be registered in the routing table 20 (step S12).
On the other hand, when the condition is satisfied (step S11;
If Yes, the process proceeds to step S13.

【0077】ステップS13では、経路表作成部5は、
差分δに対応するRAMツリーが作成された場合に、作
成されたRAMツリーにアクセスする回数(追加ツリー
の段数)がRAM7の最大アクセス回数δmax未満か否か
(許容範囲内か否か)を判定する。
At step S13, the routing table creation unit 5
When the RAM tree corresponding to the difference δ is created, whether or not the number of accesses to the created RAM tree (the number of stages of the additional tree) is less than the maximum access number δmax of the RAM 7
(Whether it is within the allowable range).

【0078】即ち、経路表作成部5は、差分δが条件
“δmax > δ”を満たすか否かを判定する。このと
き、経路表作成部5は、差分δが条件を満たす場合(ス
テップS13;Yes)には、差分δに対応する各ビッ
トのノード(エントリ)をRAM7に登録する(ステップ
S15)。
That is, the routing table creation unit 5 determines whether or not the difference δ satisfies the condition “δmax> δ”. At this time, when the difference δ satisfies the condition (step S13; Yes), the routing table creation unit 5 registers a node (entry) of each bit corresponding to the difference δ in the RAM 7 (step S15).

【0079】ここで、ルーティングテーブル20には、
既に、プレフィクス“M”が格納されている。このと
き、プレフィクス“M”がCAM6のみに格納されてい
る場合には、差分δに対応する各ビットのノードのう
ち、最もルート(root)側(上流側)のノードとCAM6に
格納されたプレフィクス“M”のエントリとが、上記手
法によって、リンクで接続される。
Here, the routing table 20 contains
The prefix “M” has already been stored. At this time, if the prefix “M” is stored only in the CAM 6, the node on the most root side (upstream side) and the node of each bit corresponding to the difference δ are stored in the CAM 6. The entry of the prefix “M” is connected by a link by the above method.

【0080】これに対し、プレフィクス“M”の有効ビ
ットの最下位ビットがRAM7にノードとして格納され
ている場合には、差分δに対応する各ビットのノード
は、当該ノードの後段にリンク付けされて配置される。
On the other hand, when the least significant bit of the valid bit of the prefix “M” is stored as a node in the RAM 7, the node of each bit corresponding to the difference δ is linked to the subsequent stage of the node. Being placed.

【0081】これらによって、プレフィクス“N”の有
効ビットのうち、最上位ビットから所定ビット(第1の
部分)までがCAM6に格納され、所定ビットから最下
位ビットまで(第2の部分)がRAMツリー17に格納さ
れる。即ち、プレフィクス“N”が、CAM6をルート
(root)とするツリーに格納される。これによって、CA
M6のオーバーフローが防止される。
As a result, of the valid bits of the prefix "N", the bits from the most significant bit to the predetermined bit (first part) are stored in the CAM 6, and the bits from the predetermined bit to the least significant bit (second part) are stored. It is stored in the RAM tree 17. That is, the prefix “N” routes CAM6
It is stored in the tree as (root). This allows CA
The overflow of M6 is prevented.

【0082】また、プレフィクス“M”に相当するプレ
フィクスがルーティングテーブル20に格納されていな
い場合には、プレフィクス“N”は、ステップS15に
おいて、RAM7のみに格納される。なお、CAM6が
“0/0”のエントリを有していれば、ルーティングテ
ーブル20に格納される全てのプレフィクスは、CAM
6とRAMツリー17とに跨って格納される。
If the prefix corresponding to the prefix "M" is not stored in the routing table 20, the prefix "N" is stored only in the RAM 7 in step S15. If the CAM 6 has an entry of “0/0”, all prefixes stored in the routing table 20 are CAM 6
6 and the RAM tree 17.

【0083】経路表作成部5は、差分δが条件を満たさ
ない場合(ステップS13;No)には、CAM6のエン
トリの書換処理を行う(ステップS14)。即ち、経路表
作成部5は、CAM6に格納されているCAMエントリ
の何れかを削除する。続いて、経路表作成部5は、プレ
フィクス“N”をCAM6にエントリとして格納する。
或いは、経路表作成部5は、プレフィクス“N”のう
ち、最上位ビットから所定ビットまでをCAM6に格納
し、且つ所定ビットから最下位ビットまでに対応するノ
ード(エントリ)をRAM7に格納(追加)する。
When the difference δ does not satisfy the condition (step S13; No), the routing table creator 5 rewrites the entry of the CAM 6 (step S14). That is, the routing table creation unit 5 deletes one of the CAM entries stored in the CAM 6. Subsequently, the routing table creation unit 5 stores the prefix “N” as an entry in the CAM 6.
Alternatively, the routing table creator 5 stores the prefix “N” from the most significant bit to a predetermined bit in the CAM 6 and stores the node (entry) corresponding to the predetermined bit to the least significant bit in the RAM 7 ( to add.

【0084】上記処理によると、プレフィクス“N”に
関するRAMツリー17の段数が減少する。従って、ア
ドレス検索部9によるRAM7のアクセス回数が減少す
る。このため、アドレス検索部9がプレフィクス“N”
に対応する次ホップアドレスを宛先IPアドレスに対応
する次ホップアドレスとして取得するために必要な時間
が許容時間Tmaxを超えてしまうことが防止される。
According to the above processing, the number of stages of the RAM tree 17 for the prefix “N” is reduced. Therefore, the number of accesses to the RAM 7 by the address search unit 9 decreases. Therefore, the address search unit 9 sets the prefix “N”
The time required to acquire the next hop address corresponding to the destination IP address as the next hop address corresponding to the destination IP address is prevented from exceeding the allowable time Tmax.

【0085】経路表作成部5は、CAM6からCAMエ
ントリを削除する場合には、少なくとも以下の方法の何
れかを用いて削除すべきCAMエントリを選択する。 (1)ランダムでCAMエントリを選択 (2)有効長が短い順でCAMエントリを選択 (3)有効長が長い順でCAMエントリを選択 (4)リンクされたRAMツリーが短い順でCAMエント
リを選択 上記(3)の方法を使用する場合には、経路表作成部5
は、ホストアドレスのエントリである(/32)のCAM
エントリを選択することができる。上記(4)の方法を使
用する場合には、CAMエントリとリンクで接続されて
いるRAMエントリからのRAMツリー長を比較し、R
AMツリー長が短い方のCAMエントリを削除する。
When deleting a CAM entry from the CAM 6, the routing table creation unit 5 selects a CAM entry to be deleted using at least one of the following methods. (1) Select a CAM entry at random. (2) Select a CAM entry in the order of the shortest effective length. (3) Select a CAM entry in the order of the longest effective length. (4) Select a CAM entry in the shortest order of the linked RAM tree. Selection When the method (3) is used, the routing table creation unit 5
Is the CAM of (/ 32) which is the entry of the host address
You can select an entry. When using the above method (4), the CAM entry is compared with the RAM tree length from the RAM entry connected by the link, and R
The CAM entry with the shorter AM tree length is deleted.

【0086】例えば、図8に示す例では、経路表作成部
5は、プレフィクス“96/3”のRAMエントリのノ
ードを起点とするRAMツリーと、プレフィクス“96
/5”のRAMエントリのノードを起点とするRAMツ
リーとを比較し、“96/5”のRAMエントリのノー
ドの方がRAMツリーが短いため、当該RAMエントリ
に対応する“96/5”のCAMエントリを削除する。
For example, in the example shown in FIG. 8, the routing table creator 5 creates the RAM tree starting from the node of the RAM entry with the prefix “96/3” and the prefix “96/3”.
Compared with the RAM tree starting from the node of the “/ 5/5” RAM entry, the node of the “96/5” RAM entry has a shorter RAM tree, so that the “96/5” corresponding to the RAM entry has the shorter length. Delete the CAM entry.

【0087】経路表作成部5は、上記(4)の方法を用い
た選択処理を実施するため、RAMエントリ上,又は図
示せぬ作業メモリの対応する場所に、CAMエントリと
リンクされたRAMツリーの段数を書き込む。そして、
経路表作成部5は、上記(4)の方法でCAMエントリを
削除する場合に、予め書き込んだ段数を参照し、最も短
いRAMツリーとリンクで接続されたCAMエントリを
選択して削除する。
The routing table creator 5 executes the selection process using the method (4) described above, so that the RAM tree linked to the CAM entry is placed on the RAM entry or in a corresponding location in the working memory (not shown). Write the number of stages. And
When deleting a CAM entry by the method (4), the routing table creation unit 5 refers to the previously written stage number, selects and deletes the CAM entry connected to the shortest RAM tree by a link.

【0088】図7は、CAM6にエントリを追加するこ
とでRAMツリー17の段数を減らす処理例を示す図で
ある。図7では、CAM6AのエントリA’(符号25)
と、ノード26(エントリA),ノード27(エントリ
B),ノード28(エントリM),及びノード29(エント
リX)とからなるRAMツリー17Aとによってプレフ
ィクス“M”が登録されている。このようなルーティン
グテーブル20Aに対し、新規のプレフィクス“N”を
登録する場合を考える。
FIG. 7 is a diagram showing an example of processing for reducing the number of stages in the RAM tree 17 by adding an entry to the CAM 6. In FIG. 7, the entry A ′ of the CAM 6A (reference numeral 25)
The prefix "M" is registered by a RAM tree 17A including a node 26 (entry A), a node 27 (entry B), a node 28 (entry M), and a node 29 (entry X). Consider a case where a new prefix “N” is registered in such a routing table 20A.

【0089】この場合において、例えば、以下のように
仮定する。即ち、ノード29(エントリX)の後段にノー
ド30(エントリY)を追加すれば、プレフィクス“N”
をルーティングテーブル20Aに登録することができ
る。しかし、ノード30が追加されると、RAMツリー
17Aの段数(RAMへのアクセス回数)が最大アクセス
回数δmaxを超えてしまう。
In this case, for example, the following is assumed. That is, if the node 30 (entry Y) is added after the node 29 (entry X), the prefix “N”
Can be registered in the routing table 20A. However, when the node 30 is added, the number of stages (the number of accesses to the RAM) of the RAM tree 17A exceeds the maximum number of accesses δmax.

【0090】この場合、経路表作成部5は、プレフィク
ス“N”についてのRAMツリー17Aのルート(root)
であるノード26(エントリA)と、追加すべきリーフ(l
eaf)のノード30(エントリY)との中間に位置するノー
ド32(エントリM)に対応するエントリM’(符号31)
をCAM6Aに追加する(ステップS14)。その後、ノ
ード30(エントリY)を追加する(ステップS15)。
In this case, the routing table creation unit 5 sets the root of the RAM tree 17A for the prefix “N”.
, And a leaf to be added (l
eaf), an entry M ′ (reference numeral 31) corresponding to the node 32 (entry M) located in the middle of the node 30 (entry Y)
Is added to the CAM 6A (step S14). Thereafter, the node 30 (entry Y) is added (step S15).

【0091】このようにすれば、ノード30が追加され
ても、プレフィクス“N”に係るRAMツリー17Aの
段数は、ノード30の追加前のほぼ半分になる。これに
よって、RAMへのアクセス回数が最大アクセス回数δ
max未満に抑えられる。また、RAMへのアクセス回数
が減少するので、プレフィクス“N”の検索時間が短縮
される。
In this way, even if the node 30 is added, the number of stages of the RAM tree 17A related to the prefix “N” becomes almost half that before the addition of the node 30. As a result, the number of accesses to the RAM becomes the maximum number of accesses δ
It can be kept below max. Further, since the number of accesses to the RAM is reduced, the search time for the prefix “N” is reduced.

【0092】なお、図7を用いてRAMツリーの段数を
ほぼ半分にする例について説明したが、当該例のように
ルートのノード26からリーフのノード30までに亘っ
て分木がない場合には、ノード29のエントリXやノー
ド30のエントリYに対応するエントリをCAM6Aに
格納すれば、RAMへのアクセス回数をさらに減らすこ
とができる。
Although the example in which the number of stages of the RAM tree is reduced to approximately half has been described with reference to FIG. 7, when there is no branch tree from the root node 26 to the leaf node 30 as in this example, If the entries corresponding to the entry X of the node 29 and the entry Y of the node 30 are stored in the CAM 6A, the number of accesses to the RAM can be further reduced.

【0093】このように、CAMへのエントリの追加に
よってRAMツリーの段数(アクセス回数)を減らす場合
には、他のプレフィクスの検索に影響を与えない範囲
で、可能な限りアクセス回数が減るようなエントリを選
択するのが好ましい。
As described above, when the number of stages of the RAM tree (the number of accesses) is reduced by adding an entry to the CAM, the number of accesses is reduced as much as possible without affecting the search for other prefixes. It is preferable to select an appropriate entry.

【0094】図6に戻って、ステップS15の後、経路
表作成部5は、ルーティングテーブル20に格納された
プレフィクス“N”を、対応する次ホップアドレスと関
連づける。
Returning to FIG. 6, after step S15, the routing table creator 5 associates the prefix “N” stored in the routing table 20 with the corresponding next hop address.

【0095】即ち、対応する次ホップアドレスが既にR
AM7に格納されている場合には、両者は、この次ホッ
プアドレスがプレフィクス“N”に対応する次ホップア
ドレスとしてアドレス検索部9に与えられるように関連
づけられる。このとき、対応する次ホップアドレスがル
ーティングテーブル20に設定されていない場合には、
この次ホップアドレスと当該プレフィクス“N”とが関
連づけられた状態でルーティングテーブル20に格納さ
れる。
That is, if the corresponding next hop address is already R
When stored in the AM 7, the two are related so that the next hop address is given to the address search unit 9 as the next hop address corresponding to the prefix "N". At this time, if the corresponding next hop address is not set in the routing table 20,
The next hop address and the prefix “N” are stored in the routing table 20 in an associated state.

【0096】これによって、プレフィクス“N”を宛先
とするパケットがルーティング機構3に入力された場合
には、アドレス検索部9がプレフィクス“N”に対応す
る次ホップアドレスを取得し、パケットが次ホップアド
レスへ転送される。上記処理が終了すると、処理がステ
ップS4へ戻り、経路表作成部5は、ルーティングプロ
トコル処理部4から受け取った他のプレフィクスについ
て上記したステップS5〜ステップS15の処理を行
う。
Thus, when a packet destined for the prefix "N" is input to the routing mechanism 3, the address search unit 9 acquires the next hop address corresponding to the prefix "N", and Forwarded to next hop address. When the above process is completed, the process returns to step S4, and the routing table creating unit 5 performs the above-described processes of steps S5 to S15 for another prefix received from the routing protocol processing unit 4.

【0097】〈CAMエントリの削除〉経路表作成部5
は、ルーティングテーブル20の更新処理において、C
AM6(又はCAM6A)のエントリが不足した場合に
は、強制的に何れかのCAMエントリを削除する。以
下、CAMエントリの削除処理について説明する。
<Deletion of CAM entry> Routing table creation unit 5
In the update process of the routing table 20, C
When the entry of AM6 (or CAM6A) runs short, one of the CAM entries is forcibly deleted. Hereinafter, the process of deleting the CAM entry will be described.

【0098】CAM6のエントリが強制的に削除される
場合には、CAMエントリが削除された後に実施される
プレフィクスの検索に支障がないことが確認されなけれ
ばならない。このため、経路表作成部5は、或るCAM
エントリを強制的に削除する場合には、削除しようとす
るCAMエントリのCAMアドレスで指し示されるRA
Mアドレスを起点とするRAMツリーが他のCAMエン
トリ(例えば、削除対象のCAMエントリに保持された
プレフィクスよりも短いプレフィクスを保持したCAM
エントリ)によっても検索することができ、且つ当該他
のCAMエントリとリンクされているノードから数えた
上記RAMツリーの段数が最大アクセス回数δmaxを超
えないことを確認する。
When the entry of the CAM 6 is forcibly deleted, it must be confirmed that there is no problem in the prefix search performed after the CAM entry is deleted. For this reason, the routing table creation unit 5
When the entry is forcibly deleted, the RA indicated by the CAM address of the CAM entry to be deleted is used.
If the RAM tree starting from the M address has another CAM entry (for example, a CAM holding a prefix shorter than the prefix held in the CAM entry to be deleted)
Entry), and confirm that the number of stages in the RAM tree counted from the node linked to the other CAM entry does not exceed the maximum access count δmax.

【0099】図8は、強制的なCAMエントリの削除処
理の例を示す図である。図8に示すように、CAM6B
は、“96/3”及び“96/5”のCAMエントリを
記憶しており、経路表作成部5が、例えば“96/5”
のCAMエントリを削除すると仮定する。この場合、経
路表作成部5は、以下の手順により削除可能なことを確
認する。
FIG. 8 is a diagram showing an example of forcible CAM entry deletion processing. As shown in FIG.
Stores the CAM entries of “96/3” and “96/5”, and the routing table creating unit 5 stores the CAM entries of “96/5”, for example.
CAM entry is deleted. In this case, the routing table creator 5 confirms that it can be deleted by the following procedure.

【0100】即ち、経路表作成部5は、削除しようとす
るCAMエントリ“96/5”より短いプレフィクスの
CAMエントリをCAM6Bから探す。この例では、C
AMエントリ“96/3”が見つかる。次に、経路表作
成部5は、CAMエントリ“96/3”をルート(root)
とするRAMツリーの全てが最大アクセス回数δmaxを
超えないことをチェックする。この場合、プレフィクス
“96/3”のRAMエントリのノードからプレフィク
ス“99/8”のRAMエントリのノードに到るRAM
ツリーの段数を数え、段数が最大アクセス回数δmaxを
超えないことを確認する。
That is, the routing table creation unit 5 searches the CAM 6B for a CAM entry having a prefix shorter than the CAM entry “96/5” to be deleted. In this example, C
AM entry "96/3" is found. Next, the routing table creation unit 5 routes the CAM entry “96/3” to the root.
Check that all the RAM trees do not exceed the maximum access count δmax. In this case, the RAM from the node of the RAM entry with the prefix “96/3” to the node of the RAM entry with the prefix “99/8”
Count the number of levels in the tree and confirm that the number does not exceed the maximum access count δmax.

【0101】〈RAMエントリの削除〉次に、経路表作
成部5によるRAMエントリの削除処理について説明す
る。図9は、RAMエントリの削除処理の例を示す図で
ある。図9において、経路表作成部5は、プレフィクス
“99/8”のRAMエントリ(ノード32)を、削除し
ようとしている。“99/8”のRAMエントリのCA
M6上の起点は、プレフィクス“96/4”のエントリ
(符号38)である。また、図9中の各ノード33,34,
35のRAMエントリは実体のない作業用のエントリで
あり、各ノード32,36,37のRAMエントリは、実
体を有するRAMエントリである。
<Deletion of RAM Entry> Next, a process of deleting a RAM entry by the routing table creation unit 5 will be described. FIG. 9 is a diagram illustrating an example of a RAM entry deletion process. In FIG. 9, the routing table creation unit 5 is about to delete the RAM entry (node 32) having the prefix “99/8”. CA of RAM entry of “99/8”
The starting point on M6 is the entry of prefix “96/4”
(Reference numeral 38). Further, each of the nodes 33 and 34 in FIG.
The RAM entry 35 is a working entry having no substance, and the RAM entries of the nodes 32, 36, and 37 are RAM entries having a substance.

【0102】最初に、経路表作成部5は、ノード32に
子ノードがないことを確認する。次に、経路表作成部5
は、ノード32の親ノードに相当する“96/6”のノ
ード33を参照する。ノード33の子ノードはノード3
2のみであるので、経路表作成部5は、ノード33
(“96/6”のRAMエントリ)を削除可能と判断す
る。
First, the routing table creation unit 5 confirms that the node 32 has no child nodes. Next, the routing table creation unit 5
Refers to the node 33 of “96/6” corresponding to the parent node of the node 32. The child node of node 33 is node 3
2, only the routing table creation unit 5
("96/6" RAM entry) is determined to be deleteable.

【0103】次に、経路表作成部5は、ノード33の親
ノードに相当するノード34を参照する。ノード34の
子ノードはノード33のみであるので、経路表作成部5
は、ノード34(“96/5”のエントリ)も削除可能と
判断する。
Next, the routing table creation unit 5 refers to the node 34 corresponding to the parent node of the node 33. Since the child node of the node 34 is only the node 33, the routing table creation unit 5
Determines that the node 34 (the entry of “96/5”) can also be deleted.

【0104】次に、経路表作成部5は、ノード34の親
ノードに相当するノード35を参照する。ノード35の
子ノードはノード34のみであるので、経路表作成部5
は、ノード35(“96/4”のエントリ)を削除可能と
判断する。また、ノード35は、CAMエントリ38と
リンクしているので、CAMエントリ38も削除可能と
判断する。
Next, the routing table creating section 5 refers to the node 35 corresponding to the parent node of the node 34. Since the child node of the node 35 is only the node 34, the routing table creation unit 5
Determines that the node 35 (the entry of “96/4”) can be deleted. Since the node 35 is linked to the CAM entry 38, the node 35 determines that the CAM entry 38 can be deleted.

【0105】次に、経路表作成部5は、ノード35の親
ノードに相当するノード36を参照する。ノード36
は、ノード34の他にノード37(“112/4”のエ
ントリ)を子ノードとするので、経路表作成部5は、ノ
ード36(“96/3”のエントリ)を削除できないと判
断する。
Next, the routing table creation unit 5 refers to the node 36 corresponding to the parent node of the node 35. Node 36
Makes the node 37 (the entry of "112/4") a child node in addition to the node 34, so the routing table creation unit 5 judges that the node 36 (the entry of "96/3") cannot be deleted.

【0106】すると、経路表作成部5は、削除可能と判
断したノード32〜35及びCAMエントリ38を削除
する。このようにして、不要なRAMエントリ及びCA
Mエントリが削除される。
Then, the routing table creator 5 deletes the nodes 32 to 35 and the CAM entry 38 which have been judged to be deletable. In this way, unnecessary RAM entries and CA
The M entry is deleted.

【0107】上記した削除処理を経路表作成部5が実行
するためには、或るRAMエントリ(ノード)がCAMエ
ントリとリンクされているか否かの情報が予め保持され
ていることを要する。このため、各ノードのRAMエン
トリには、CAMエントリとのリンクの有無を示すビッ
トが用意され、CAMエントリとのリンクがある場合に
は、“0”と“1”との一方が設定され、リンクがない
場合には、“0”と“1”との他方が設定される。
In order for the routing table creation unit 5 to execute the above-described deletion processing, it is necessary that information as to whether a certain RAM entry (node) is linked to a CAM entry is held in advance. Therefore, a bit indicating the presence or absence of a link with the CAM entry is prepared in the RAM entry of each node, and if there is a link with the CAM entry, one of “0” and “1” is set, If there is no link, the other of “0” and “1” is set.

【0108】経路表作成部5は、上記削除処理におい
て、削除か否かの判断の対象となっているRAMエント
リに設定されたビットを参照し、リンクが設定されてい
ることを示すビットを有するRAMエントリを削除する
場合には、当該RAMエントリにリンクされているCA
Mエントリも削除する。
The routing table creator 5 refers to the bit set in the RAM entry to be determined whether or not to delete in the above-described deletion processing, and has a bit indicating that a link is set. When deleting a RAM entry, the CA linked to the RAM entry is deleted.
The M entry is also deleted.

【0109】第1実施形態によると、ルーティングテー
ブル20がCAM6とRAM7とを有し、プレフィクス
がCAM6とRAM7とに跨って格納される。このた
め、RAMツリーのみを用いたルーティングに比べてル
ーティングに要する時間を短縮することができる。ま
た、CAM6とRAM7とを併用することで、CAM6
飲みを用いる場合に比べて多くのプレフィクス(のエン
トリ)をルーティングテーブル20に格納することがで
きる。
According to the first embodiment, the routing table 20 has the CAM 6 and the RAM 7, and the prefix is stored across the CAM 6 and the RAM 7. For this reason, the time required for routing can be reduced as compared with the routing using only the RAM tree. Also, by using the CAM 6 and the RAM 7 together, the CAM 6
More prefixes (entries) can be stored in the routing table 20 than when drinking is used.

【0110】さらに、経路表作成部5が、CAM6の利
用率ηr,RAMの利用率ηc,差分δ,最大アクセス回
数δmax,RAMツリー1回のアクセス時間τr,パケッ
トのルーティングの最大許容時間Tmaxを用いて新規の
プレフィクスの登録処理(ルーティングテーブル20の
更新処理)を行う。これによって、プレフィクスを最適
な状態でルーティングテーブル20に格納することがで
きる。このため、CAM6のオーバーフローを防止しつ
つ、RAMへのアクセス回数(RAMツリー17の段数)
を可能な限り減らすことでルーティングの高速化を図る
ことができる。
Further, the routing table creator 5 determines the utilization rate ηr of the CAM 6, the utilization rate ηc of the RAM, the difference δ, the maximum number of accesses δmax, the access time τr of one RAM tree, and the maximum allowable time Tmax of packet routing. A new prefix registration process (update process of the routing table 20) is performed using the new prefix. Thus, the prefix can be stored in the routing table 20 in an optimum state. Therefore, the number of accesses to the RAM (the number of stages in the RAM tree 17) is prevented while preventing the CAM 6 from overflowing.
Is reduced as much as possible, so that high-speed routing can be achieved.

【0111】このため、高速且つ大容量のルーティング
テーブルを構成することができる。
Thus, a high-speed and large-capacity routing table can be configured.

【0112】〈第2実施形態〉次に、本発明の第2実施
形態を説明する。第2実施形態は、第1実施形態と共通
点を有するので、相違点についてのみ説明する。第2実
施形態は、本発明によるパケットの宛先情報管理装置
を、バーチャル・プライベート・ネットワーク(VP
N:Virtual Private Network)を構成するエッジルータ
に適用したものである。
<Second Embodiment> Next, a second embodiment of the present invention will be described. The second embodiment has common points with the first embodiment, and therefore only different points will be described. In the second embodiment, a packet destination information management device according to the present invention is provided with a virtual private network (VP).
N: Virtual Private Network).

【0113】VPNは、インターネット上で仮想的な私
設ネットワークをつくる技術である。図10は、VPN
の例を示す図である。図10に示すように、ISP(Int
ernet Service Provider)のネットワーク51中に、各
ユーザ(ここでは企業Aおよび企業B)が専用に利用でき
るVPN52,53が提供される。
The VPN is a technology for creating a virtual private network on the Internet. FIG.
It is a figure showing the example of. As shown in FIG. 10, the ISP (Int
In the network 51 of the Internet Service Provider (VPN), VPNs 52 and 53 that can be exclusively used by each user (here, the company A and the company B) are provided.

【0114】企業Aの各サイト(端末装置)から送出され
たパケットは、企業AのVPN52を通じてA社のみに
伝わり、企業B等の他社に漏れない。また、企業AのV
PN52には、企業B等の他社からのパケットも流れ込
まない。企業BのVPN53についてもVPN52と同
様である。このような仮想的な専用線を、ISPのネッ
トワーク51の中にいくつも共存させ、設備を共用する
ことによって安価な接続を提供する。
The packet transmitted from each site (terminal device) of company A is transmitted only to company A via company A's VPN 52 and is not leaked to other companies such as company B. In addition, V of company A
Packets from other companies such as company B do not flow into PN 52. The VPN 53 of the company B is the same as the VPN 52. A number of such virtual dedicated lines coexist in the ISP network 51 and inexpensive connections are provided by sharing the equipment.

【0115】通常、企業Aと企業Bの利用するアドレス
は独立に決められるので、同じアドレスが使われる可能
性がある。そのため、各エッジルータ54,55は、V
PN52又はVPN53にパケットを転送する場合に
は、どの企業網のパケットかを示すVPN−idと呼ば
れる識別子を、IPアドレスと共にパケットに付加す
る。
Normally, the addresses used by the company A and the company B are determined independently, so that the same address may be used. Therefore, each of the edge routers 54 and 55
When transferring a packet to the PN 52 or the VPN 53, an identifier called a VPN-id indicating which corporate network the packet belongs to is added to the packet together with the IP address.

【0116】各エッジルータ54,55の構成は、図1
に示したルータ1とほぼ同じ構成を有しているので説明
を省略する。図11は、各エッジルータ54,55のル
ーティング機構3(図1参照)に設けられたルーティング
テーブル20Bの例を示す図である。
The structure of each of the edge routers 54 and 55 is shown in FIG.
The configuration is almost the same as that of the router 1 shown in FIG. FIG. 11 is a diagram showing an example of the routing table 20B provided in the routing mechanism 3 (see FIG. 1) of each of the edge routers 54 and 55.

【0117】図11に示すように、CAM6Dには、V
PN−idとプレフィクスとの組み合わせで構成される
拡張プレフィクスのエントリが格納されている。拡張プ
レフィクスは、VPN−idをなすビット列とプレフィ
クスをなすビット列とが直列に連結された連続するビッ
ト列である。
As shown in FIG. 11, CAM6D has V
An entry of an extended prefix composed of a combination of a PN-id and a prefix is stored. The extension prefix is a continuous bit string in which a bit string forming a VPN-id and a bit string forming a prefix are connected in series.

【0118】図11では、説明のため、“VPN−i
d:プレフィクス”を、“0:A”,“1:B”,“2:
C”と表記しているが、実際には、可変長のビット列で
ある。この例では、VPN−id=1は、企業AのVP
N−idであり、VPN−id=2は、企業BのVPN
−idである。さらに、VPN−id=0は、公衆イン
ターネット用の識別子としての特殊なVPN識別子であ
り、VPNを使用せずにISPのネットワーク51を利
用する者に対して割り当てられている。
In FIG. 11, “VPN-i
d: prefix ”is changed to“ 0: A ”,“ 1: B ”,“ 2:
C "is actually a variable-length bit string. In this example, VPN-id = 1 is the VP of the company A.
N-id, VPN-id = 2 is the VPN of company B
-Id. Further, VPN-id = 0 is a special VPN identifier as an identifier for the public Internet, and is assigned to a person who uses the ISP network 51 without using VPN.

【0119】以上の点を除き、CAM6D及びRAMツ
リー17Dの構成,経路作成部5による処理,アドレス
検索部9によるルーティング処理は、第1実施形態と同
じであるので説明を省略する。
Except for the points described above, the configuration of the CAM 6D and the RAM tree 17D, the processing by the path creation unit 5, and the routing processing by the address search unit 9 are the same as those in the first embodiment, and therefore description thereof is omitted.

【0120】第2実施形態によれば、CAM6Dのコン
テンツとして、IPアドレスの他にVPN識別子(VP
N−id)が追加された拡張プレフィクスが用いられ、
VPNを意識することなくCAMエントリ及びRAMツ
リーが構成されている。これにより、CAM6Dへのア
クセスの追加及びRAM7のデータ追加なしに、VPN
毎にルーティング検索を分離することができる。
According to the second embodiment, as the contents of the CAM 6D, in addition to the IP address, the VPN identifier (VP)
N-id) is used for the extended prefix,
The CAM entry and the RAM tree are configured without being aware of the VPN. As a result, without adding access to the CAM 6D and adding data to the RAM 7, the VPN
The routing search can be separated for each.

【0121】また、特別なVPN識別子(例えば、VP
N−id=0)を公衆インターネット用の識別子とする
ことで、VPN及び非VPNのトラフィックを同じルー
ティングテーブル20Bで検索することができる。
Further, a special VPN identifier (for example, VP
By using (N-id = 0) as an identifier for the public Internet, VPN and non-VPN traffic can be searched in the same routing table 20B.

【0122】〔付記〕本発明は、以下のように特定する
ことができる。 (付記1)パケットの経路を選択するためのパケットの
宛先情報を管理する装置であって、第1メモリと、前記
第1メモリよりも情報の検索速度が遅く且つ集積度が高
い第2メモリと、前記宛先情報が前記第1メモリと前記
第2メモリとに跨がる状態で格納された経路表を作成す
る作成部と、を備えたパケットの宛先情報管理装置。 (付記2)前記第1メモリの使用率の閾値を記憶した閾
値記憶部をさらに備え、前記作成部は、前記第1メモリ
の使用率を取得し、取得した使用率が前記閾値記憶部に
記憶された閾値未満である場合には、前記経路表に格納
すべき宛先情報を前記第1メモリのみに格納する、付記
1記載のパケットの宛先情報管理装置。 (付記3)前記経路表に格納された宛先情報に対応する
出力ルートの情報を得る場合の最大許容時間を記憶した
許容時間記憶部をさらに備え、前記作成部は、前記最大
許容時間内で前記経路表から前記パケットの宛先情報が
検索され、検索された宛先情報に対応する出力ルートの
情報が取得されるように、前記宛先情報を前記第1メモ
リと前記第2メモリとに跨がる状態で格納する、付記1
又は2記載のパケットの宛先情報管理装置。 (付記4)前記最大許容時間内で可能な前記第2メモリ
への最大アクセス回数を記憶したアクセス回数記憶部を
さらに備え、前記作成部は、前記経路表に格納された宛
先情報の検索に必要な前記第2メモリへのアクセス回数
が前記最大アクセス回数以上となる場合には、前記アク
セス回数が前記最大アクセス回数未満となるように、前
記第2メモリに格納された、又は格納される予定の宛先
情報を前記第1メモリに格納する付記3記載のパケット
の宛先情報管理装置。 (付記5)前記宛先情報は、所定長のビット列で構成さ
れ、前記作成部は、前記ビット列の最上位ビットから所
定ビットまでを前記第1メモリに格納し、前記所定ビッ
トから最下位ビットまでを前記第2メモリに格納する、
付記1記載のパケットの宛先情報管理装置。 (付記6)前記宛先情報は、パケットの宛先IPネット
ワークアドレスである、付記1記載のパケットの宛先情
報管理装置。 (付記7)前記宛先情報は、バーチャル・プライベート
・ネットワークの識別子と、パケットの宛先IPネット
ワークアドレスとの組み合わせである、付記1記載のパ
ケットの宛先情報管理装置。 (付記8)前記作成部は、前記識別子を前記第1メモリ
のみに格納する、付記7記載のパケットの宛先情報管理
装置。 (付記9)パケットの宛先情報が第1メモリとこの第1
のメモリよりも情報の検索速度が遅く且つ集積度が高い
第2メモリとに跨る状態で格納された経路表と、入力さ
れたパケットに対応する宛先情報を前記経路表から検索
し、検索した宛先情報に対応する出力ルートの情報を取
得する検索部と、を備えたパケットの経路選択装置。 (付記10)パケットの経路を選択するためのパケット
の宛先情報を管理装置によって管理する方法であって、
前記管理装置は、前記宛先情報が第1メモリとこの第1
メモリよりも情報の検索速度が遅く且つ集積度が高い第
2メモリとに跨がる状態で格納された経路表を作成す
る、ことを含むパケットの宛先情報管理方法。 (付記11)前記管理装置は、前記第1メモリの使用率
の閾値を記憶し、記憶された前記第1メモリの使用率を
取得し、取得した使用率が前記閾値記憶部に記憶された
閾値未満である場合には、前記経路表に格納すべき宛先
情報を前記第1メモリのみに格納する、付記10記載の
パケットの宛先情報管理方法。 (付記12)前記管理装置は、前記経路表に格納された
宛先情報に対応する出力ルートの情報を得る場合の最大
許容時間を記憶し、前記最大許容時間内で前記経路表か
ら前記パケットの宛先情報を検索し、検索した宛先情報
に対応する出力ルートの情報が取得されるように、前記
宛先情報を前記第1メモリと前記第2メモリとに跨がる
状態で格納する、付記10又は11記載のパケットの宛
先情報管理方法。 (付記13)前記管理装置は、前記最大許容時間内で可
能な前記第2メモリへの最大アクセス回数を記憶し、前
記経路表に格納された宛先情報の検索に必要な前記第2
メモリへのアクセス回数が前記最大アクセス回数以上と
なる場合には、前記アクセス回数が前記最大アクセス回
数未満となるように、前記第2メモリに格納された、又
は格納される予定の宛先情報を前記第1メモリに格納す
る付記12記載のパケットの宛先情報管理方法。 (付記14)前記宛先情報は、所定長のビット列で構成
され、前記管理装置は、前記ビット列の最上位ビットか
ら所定ビットまでを前記第1メモリに格納し、前記所定
ビットから最下位ビットまでを前記第2メモリに格納す
る、付記10記載のパケットの宛先情報管理方法。 (付記15)前記宛先情報は、パケットの宛先IPネッ
トワークアドレスである、付記10記載のパケットの宛
先情報管理方法。 (付記16)前記宛先情報は、バーチャル・プライベー
ト・ネットワークの識別子と、パケットの宛先IPネッ
トワークアドレスとの組み合わせである、付記10記載
のパケットの宛先情報管理方法。 (付記17)前記管理装置は、前記識別子を前記第1メ
モリのみに格納する、付記16記載のパケットの宛先情
報管理方法。 (付記18)パケットの経路選択装置によってパケット
の経路を選択する方法であって、前記経路選択装置は、
パケットの宛先情報が第1メモリとこの第1のメモリよ
りも情報の検索速度が遅く且つ集積度が高い第2メモリ
とに跨る状態で格納された経路表を作成し、入力された
パケットに対応する宛先情報を前記経路表から検索し、
検索した宛先情報に対応する出力ルートの情報を取得す
る、ことを含むパケットの経路選択方法。
[Supplementary Notes] The present invention can be specified as follows. (Supplementary Note 1) An apparatus for managing destination information of a packet for selecting a path of a packet, comprising: a first memory; and a second memory having a lower retrieval speed and a higher degree of integration than the first memory. A destination information management device for a packet, comprising: a creation unit that creates a routing table in which the destination information is stored so as to extend over the first memory and the second memory. (Supplementary Note 2) The apparatus further includes a threshold storage unit that stores a threshold of the usage rate of the first memory, wherein the creating unit obtains the usage rate of the first memory, and stores the obtained usage rate in the threshold storage unit. 2. The destination information management device for packets according to claim 1, wherein the destination information to be stored in the routing table is stored only in the first memory when the value is less than the threshold. (Supplementary Note 3) The apparatus further includes an allowable time storage unit that stores a maximum allowable time when obtaining information on an output route corresponding to the destination information stored in the routing table, wherein the creating unit is configured to perform the operation within the maximum allowable time. A state in which the destination information is straddled between the first memory and the second memory so that destination information of the packet is searched from a routing table and information of an output route corresponding to the searched destination information is obtained. Appendix 1
Or the destination information management device for packets described in 2. (Supplementary Note 4) The information processing apparatus further includes an access count storage unit that stores a maximum access count to the second memory that is possible within the maximum allowable time, wherein the creation unit is required to search for destination information stored in the routing table. If the number of accesses to the second memory is greater than or equal to the maximum number of accesses, the number of accesses is stored in or is scheduled to be stored in the second memory such that the number of accesses is less than the maximum number of accesses. 4. The packet destination information management device according to claim 3, wherein the destination information is stored in the first memory. (Supplementary Note 5) The destination information is composed of a bit string of a predetermined length, and the creation unit stores from the most significant bit of the bit string to a predetermined bit in the first memory, and stores the bit from the predetermined bit to the least significant bit. Storing in the second memory;
A destination information management device for a packet according to supplementary note 1. (Supplementary note 6) The packet destination information management device according to supplementary note 1, wherein the destination information is a destination IP network address of the packet. (Supplementary note 7) The packet destination information management device according to supplementary note 1, wherein the destination information is a combination of a virtual private network identifier and a packet destination IP network address. (Supplementary note 8) The packet destination information management device according to supplementary note 7, wherein the creating unit stores the identifier only in the first memory. (Supplementary Note 9) The destination information of the packet is the first memory and the first memory.
A routing table stored in a state that the information retrieval speed is lower than that of the second memory and the second memory with a higher degree of integration is stored, and destination information corresponding to the input packet is retrieved from the routing table, and the retrieved destination is retrieved. A packet route selection device comprising: a search unit that acquires information on an output route corresponding to the information. (Supplementary Note 10) A method of managing destination information of a packet for selecting a route of the packet by a management device,
The management device may store the destination information in a first memory and the first memory.
A destination information management method for a packet, comprising: creating a routing table stored over a second memory having a lower information search speed and a higher degree of integration than a memory. (Supplementary Note 11) The management device stores a threshold of the usage rate of the first memory, acquires the stored usage rate of the first memory, and stores the acquired usage rate in the threshold storage unit. 11. The packet destination information management method according to claim 10, wherein the destination information to be stored in the routing table is stored only in the first memory when the number is less than the number. (Supplementary Note 12) The management device stores a maximum allowable time for obtaining information on an output route corresponding to the destination information stored in the routing table, and stores the destination of the packet from the routing table within the maximum allowable time. Additional information 10 or 11 in which information is retrieved and the destination information is stored in a state of straddling the first memory and the second memory so that information on an output route corresponding to the retrieved destination information is obtained. The destination information management method of the described packet. (Supplementary Note 13) The management device stores a maximum number of accesses to the second memory that is possible within the maximum allowable time, and stores the maximum number of accesses to the second memory necessary for searching for the destination information stored in the routing table.
When the number of accesses to the memory is equal to or more than the maximum number of accesses, the destination information stored in or scheduled to be stored in the second memory is set so that the number of accesses is less than the maximum number of accesses. The destination information management method for packets described in Supplementary Note 12 stored in the first memory. (Supplementary Note 14) The destination information is composed of a bit string of a predetermined length, and the management device stores from the most significant bit of the bit string to a predetermined bit in the first memory, and stores the bit from the predetermined bit to the least significant bit. 11. The method according to claim 10, wherein the destination information is stored in the second memory. (Supplementary note 15) The packet destination information management method according to supplementary note 10, wherein the destination information is a destination IP network address of the packet. (Supplementary note 16) The packet destination information management method according to supplementary note 10, wherein the destination information is a combination of a virtual private network identifier and a packet destination IP network address. (Supplementary note 17) The packet destination information management method according to supplementary note 16, wherein the management device stores the identifier only in the first memory. (Supplementary Note 18) A method of selecting a packet route by a packet route selection device, wherein the route selection device comprises:
Creates a routing table in which destination information of a packet is stored over a first memory and a second memory having a lower information retrieval speed and a higher degree of integration than the first memory, and corresponds to an input packet. Searching for the destination information to be performed from the routing table,
A method of selecting a packet route, including obtaining information on an output route corresponding to the searched destination information.

【0123】[0123]

【発明の効果】本発明によれば、CAM方式で作成され
たルーティングテーブルよりも多くのプレフィクスを保
持することができ、且つRAMツリー方式で作成された
ルーティングテーブルよりも高速にプレフィクスを検索
することができる。
According to the present invention, it is possible to hold more prefixes than a routing table created by the CAM system, and to search for prefixes faster than a routing table created by the RAM tree system. can do.

【図面の簡単な説明】[Brief description of the drawings]

【図1】ルータの構成図FIG. 1 is a configuration diagram of a router.

【図2】CAMの構成図FIG. 2 is a configuration diagram of a CAM.

【図3】ノード(エントリ)の追加処理の説明図FIG. 3 is an explanatory diagram of processing for adding a node (entry).

【図4】ルーティングテーブルの説明図FIG. 4 is an explanatory diagram of a routing table.

【図5】プレフィクス追加の処理を示すフローチャートFIG. 5 is a flowchart showing a process of adding a prefix.

【図6】プレフィクス追加の処理を示すフローチャートFIG. 6 is a flowchart showing a process of adding a prefix.

【図7】RAMツリーの段数を減らす処理の説明図FIG. 7 is an explanatory diagram of a process for reducing the number of stages in a RAM tree.

【図8】CAMエントリ削除の例を示す図FIG. 8 is a diagram showing an example of CAM entry deletion.

【図9】RAMエントリ削除の例を示す図FIG. 9 is a diagram showing an example of RAM entry deletion.

【図10】VPNの説明図FIG. 10 is an explanatory diagram of a VPN.

【図11】ルーティングテーブルの説明図FIG. 11 is an explanatory diagram of a routing table.

【図12】従来技術の説明図FIG. 12 is an explanatory diagram of a conventional technique.

【図13】従来技術の説明図FIG. 13 is an explanatory diagram of a conventional technique.

【図14】従来技術の説明図FIG. 14 is an explanatory diagram of a conventional technique.

【符号の説明】[Explanation of symbols]

1 ルータ 2 インターフェイスカード 3 ルーティング機構 4 ルーティングプロトコル処理部 5 ルート計算・経路表作成部 6 CAM 7 RAM 8 ヘッダ抽出部 9 アドレス検索部 10 転送処理部 12 データアレイ/マスクアレイ 13 プライオリティ・エンコーダ 14 補助RAM 17 RAMツリー 20 ルーティングテーブル Reference Signs List 1 router 2 interface card 3 routing mechanism 4 routing protocol processing unit 5 route calculation / routing table preparation unit 6 CAM 7 RAM 8 header extraction unit 9 address search unit 10 transfer processing unit 12 data array / mask array 13 priority encoder 14 auxiliary RAM 17 RAM tree 20 Routing table

───────────────────────────────────────────────────── フロントページの続き Fターム(参考) 5K030 GA01 GA06 HA08 HB29 HD03 HD09 KA01 KA05 KA13 LB05 LE03 MA13  ──────────────────────────────────────────────────続 き Continued on the front page F term (reference) 5K030 GA01 GA06 HA08 HB29 HD03 HD09 KA01 KA05 KA13 LB05 LE03 MA13

Claims (5)

【特許請求の範囲】[Claims] 【請求項1】パケットの経路を選択するためのパケット
の宛先情報を管理する装置であって、 第1メモリと、 前記第1のメモリより情報の検索速度が遅く且つ集積度
が高い第2メモリと、 前記宛先情報が前記第1メモリと前記第2メモリとに跨
がる状態で格納された経路表を作成する作成部と、を備
えたパケットの宛先情報管理装置。
An apparatus for managing destination information of a packet for selecting a path of a packet, comprising: a first memory; and a second memory having a lower information retrieval speed and a higher degree of integration than the first memory. A destination information management device for a packet, comprising: a creation unit that creates a routing table in which the destination information is stored so as to extend over the first memory and the second memory.
【請求項2】前記第1メモリの使用率の閾値を記憶した
閾値記憶部をさらに備え、 前記作成部は、前記第1メモリの使用率を取得し、取得
した使用率が前記閾値記憶部に記憶された閾値未満であ
る場合には、前記経路表に格納すべき宛先情報を前記第
1メモリのみに格納する請求項1記載のパケットの宛先
情報管理装置。
2. The apparatus according to claim 1, further comprising a threshold storage unit that stores a threshold value of the usage rate of the first memory, wherein the creating unit obtains the usage rate of the first memory, and the obtained usage rate is stored in the threshold storage unit. 2. The packet destination information management device according to claim 1, wherein when the number is less than the stored threshold, the destination information to be stored in the routing table is stored only in the first memory.
【請求項3】前記経路表に格納された宛先情報に対応す
る出力ルートの情報を得る場合の最大許容時間を記憶し
た許容時間記憶部をさらに備え、 前記作成部は、前記最大許容時間内で前記経路表から前
記パケットの宛先情報が検索され、検索された宛先情報
に対応する出力ルートの情報が取得されるように、前記
宛先情報を前記第1メモリと前記第2メモリとに跨がる
状態で格納する請求項1又は2記載のパケットの宛先情
報管理装置。
3. An apparatus according to claim 1, further comprising an allowable time storage unit for storing a maximum allowable time for obtaining information on an output route corresponding to the destination information stored in said routing table, wherein said creating unit stores said maximum allowable time within said maximum allowable time. The destination information is straddled between the first memory and the second memory so that destination information of the packet is retrieved from the routing table and information of an output route corresponding to the retrieved destination information is obtained. 3. The packet destination information management device according to claim 1, wherein the packet is stored in a state.
【請求項4】前記最大許容時間内で可能な前記第2メモ
リへの最大アクセス回数を記憶したアクセス回数記憶部
をさらに備え、 前記作成部は、前記経路表に格納された宛先情報の検索
に必要な前記第2メモリへのアクセス回数が前記最大ア
クセス回数以上となる場合には、前記アクセス回数が前
記最大アクセス回数未満となるように、前記第2メモリ
に格納された、又は格納される予定の宛先情報を前記第
1メモリに格納する請求項3記載のパケットの宛先情報
管理装置。
4. The apparatus according to claim 1, further comprising: an access count storage unit storing a maximum access count to the second memory within the maximum allowable time, wherein the creation unit searches for the destination information stored in the routing table. If the required number of accesses to the second memory is greater than or equal to the maximum number of accesses, the number of accesses is stored or scheduled to be stored in the second memory such that the number of accesses is less than the maximum number of accesses. 4. The apparatus according to claim 3, wherein the destination information is stored in the first memory.
【請求項5】パケットの宛先情報が第1メモリとこの第
1のメモリよりも情報の検索速度が遅く且つ集積度が高
い第2メモリとに跨る状態で格納された経路表と、 入力されたパケットに対応する宛先情報を前記経路表か
ら検索し、検索した宛先情報に対応する出力ルートの情
報を取得する検索部と、を備えたパケットの経路選択装
置。
5. A routing table in which destination information of a packet is stored across a first memory and a second memory having a lower information retrieval speed and a higher degree of integration than the first memory. A packet routing apparatus comprising: a search unit that searches destination information corresponding to a packet from the routing table and obtains information on an output route corresponding to the searched destination information.
JP2001003000A 2001-01-10 2001-01-10 Destination information managing apparatus for packet Withdrawn JP2002208945A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2001003000A JP2002208945A (en) 2001-01-10 2001-01-10 Destination information managing apparatus for packet

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2001003000A JP2002208945A (en) 2001-01-10 2001-01-10 Destination information managing apparatus for packet

Publications (1)

Publication Number Publication Date
JP2002208945A true JP2002208945A (en) 2002-07-26

Family

ID=18871414

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2001003000A Withdrawn JP2002208945A (en) 2001-01-10 2001-01-10 Destination information managing apparatus for packet

Country Status (1)

Country Link
JP (1) JP2002208945A (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2005020525A1 (en) 2003-08-20 2005-03-03 Nippon Telegraph And Telephone Corporation Protocol speed increasing device
JP2010109735A (en) * 2008-10-30 2010-05-13 Iwatsu Electric Co Ltd Router, and method for controlling routing search
US7738465B2 (en) 2003-07-11 2010-06-15 Hitachi, Ltd. Packet forwarding device equipped with statistics collection device and statistics collection method
JP2010226340A (en) * 2009-03-23 2010-10-07 Alaxala Networks Corp Communication device
JP2011124799A (en) * 2009-12-10 2011-06-23 Nec Engineering Ltd Data transfer device
JP2013502020A (en) * 2009-08-16 2013-01-17 コンパス・エレクトロ−オプティカル・システムズ・リミテッド Method and device for improving scalability of longest prefix match
EP3958523A1 (en) 2020-08-20 2022-02-23 Fujitsu Limited Information processing apparatus and packet control method

Cited By (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7738465B2 (en) 2003-07-11 2010-06-15 Hitachi, Ltd. Packet forwarding device equipped with statistics collection device and statistics collection method
WO2005020525A1 (en) 2003-08-20 2005-03-03 Nippon Telegraph And Telephone Corporation Protocol speed increasing device
EP1657859A1 (en) * 2003-08-20 2006-05-17 Nippon Telegraph and Telephone Corporation Protocol speed increasing device
EP1657859A4 (en) * 2003-08-20 2010-12-01 Nippon Telegraph & Telephone Protocol speed increasing device
JP2010109735A (en) * 2008-10-30 2010-05-13 Iwatsu Electric Co Ltd Router, and method for controlling routing search
JP2010226340A (en) * 2009-03-23 2010-10-07 Alaxala Networks Corp Communication device
JP2013502020A (en) * 2009-08-16 2013-01-17 コンパス・エレクトロ−オプティカル・システムズ・リミテッド Method and device for improving scalability of longest prefix match
US9049157B1 (en) 2009-08-16 2015-06-02 Compass Electro-Optical Systems Ltd Method and device for improving scalability of longest prefix match
JP2011124799A (en) * 2009-12-10 2011-06-23 Nec Engineering Ltd Data transfer device
EP3958523A1 (en) 2020-08-20 2022-02-23 Fujitsu Limited Information processing apparatus and packet control method
US11637767B2 (en) 2020-08-20 2023-04-25 Fujitsu Limited Information processing apparatus and packet control method

Similar Documents

Publication Publication Date Title
CA2434876C (en) Method and apparatus for ternary content addressable memory (tcam) table management
US7426518B2 (en) System and method for efficiently searching a forwarding database that is split into a bounded number of sub-databases having a bounded size
US6449256B1 (en) Fast level four switching using crossproducting
US7571156B1 (en) Network device, storage medium and methods for incrementally updating a forwarding database
JP4182977B2 (en) Network system, learning bridge node, learning method and program thereof
US8767757B1 (en) Packet forwarding system and method using patricia trie configured hardware
US20030091043A1 (en) Methods and systems for fast packet forwarding
US20030223421A1 (en) Atomic lookup rule set transition
US7624226B1 (en) Network search engine (NSE) and method for performing interval location using prefix matching
JP2002314571A (en) Classification and tagging rules for switching nodes
JP3543952B2 (en) MPLS packet transfer method and packet switch
US7349427B1 (en) Routing method and apparatus for optimising auto-tunnelling in a heterogeneous network
US20070165543A1 (en) Routing system and route update method
JPH06261078A (en) Table retrieval method and router
JPH11191781A (en) Path retrieval circuit and communication controller
US6850528B1 (en) System and method for maintaining network system information
CN106453091B (en) The equivalent route management method and device of router Forwarding plane
JP2002208945A (en) Destination information managing apparatus for packet
US20030023581A1 (en) Method and system for performing a longest prefix match search
US7590112B2 (en) Packet forwarding apparatus of high speed routing system and routing lookup method using the same
CN115396365B (en) Scale-independent fast route convergence method
JP5182146B2 (en) Route determination program, management apparatus, and network system
JP3228249B2 (en) Router device
EP1657859B1 (en) Protocol speed increasing device
JP3660311B2 (en) Table search apparatus and method, program, and recording medium

Legal Events

Date Code Title Description
A300 Application deemed to be withdrawn because no request for examination was validly filed

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 20080401