JP3292241B2 - Table creation search device - Google Patents

Table creation search device

Info

Publication number
JP3292241B2
JP3292241B2 JP32887098A JP32887098A JP3292241B2 JP 3292241 B2 JP3292241 B2 JP 3292241B2 JP 32887098 A JP32887098 A JP 32887098A JP 32887098 A JP32887098 A JP 32887098A JP 3292241 B2 JP3292241 B2 JP 3292241B2
Authority
JP
Japan
Prior art keywords
row
data
stored
index
bit data
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.)
Expired - Fee Related
Application number
JP32887098A
Other languages
Japanese (ja)
Other versions
JP2000151617A (en
Inventor
稔 橋本
靖 石井
Original Assignee
株式会社アバールデータ
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 株式会社アバールデータ filed Critical 株式会社アバールデータ
Priority to JP32887098A priority Critical patent/JP3292241B2/en
Publication of JP2000151617A publication Critical patent/JP2000151617A/en
Application granted granted Critical
Publication of JP3292241B2 publication Critical patent/JP3292241B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Small-Scale Networks (AREA)

Description

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

【0001】[0001]

【発明の属する技術分野】本願発明は、例えばMAC
(Media Access Control)アドレ
スのようなデータを格納していきMACアドレステーブ
ルのようなテーブルを作るテーブル作成装置および上記
のようなテーブル作成装置を用いて作ったテーブルとデ
ータ配列が同一のテーブルから特定のデータ(例えば、
特定のMACアドレス)を検索するテーブル検索装置に
関する。
[0001] The present invention relates to, for example, a MAC.
(Media Access Control) A table creation device that stores data such as an address and creates a table such as a MAC address table, and specifies a table having the same data array as a table created using the table creation device as described above. Data (for example,
The present invention relates to a table search device for searching for a specific MAC address.

【0002】[0002]

【従来の技術】例えばLAN(Local Area
Network)において、接続する各ホストのMAC
アドレスに基づいて、各ホストの送受信回数の集計等を
実行して当該LANを管理する従来のネットワーク管理
装置では、図7に示すようなMACアドレステーブルを
備えている。当該MACアドレステーブルは、多数の行
からなり、各行には、当該LANに接続されているホス
トのMACアドレス(同図ではa、b、c、……と示さ
れている)が格納されるMACアドレスエリアMAと、
当該ホストの例えば送受信回数の集計データ等が記憶さ
れる管理データエリアDA(この管理データエリアDA
は、正確には、更に多数の小エリアに分かれており、そ
れぞれには、対応する上記集計データ等が1つずつ記憶
される)とからなる。そして、LANにホストが追加接
続される度に、当該ホストに対して上記MACアドレス
テーブル中の空いている行が与えられ、その行のMAC
アドレスエリアMAにそのホストのMACアドレスが格
納され、以後は、当該ホストに係る上記集計データ等が
その行の管理データエリアDAに記憶されていく。
2. Description of the Related Art For example, a LAN (Local Area)
Network), the MAC of each host to be connected
A conventional network management apparatus that manages the LAN by executing the totalization of the number of times of transmission and reception of each host based on the address has a MAC address table as shown in FIG. The MAC address table is composed of a number of rows, and each row stores a MAC address (shown as a, b, c,... In the figure) of a host connected to the LAN. Address area MA,
For example, a management data area DA (for example, management data area DA) in which total data of the number of transmissions and receptions of the host is stored.
Is more precisely divided into a large number of small areas, each of which stores the corresponding aggregation data and the like one by one). Each time a host is additionally connected to the LAN, the host is given a vacant row in the MAC address table,
The MAC address of the host is stored in the address area MA, and thereafter, the total data and the like relating to the host are stored in the management data area DA of the row.

【0003】上記のようなMACアドレステーブルの管
理データエリアDAへ特定のホストの上記集計データ等
を更新記憶するために、当該ホストのMACアドレスが
格納されている行を得るためには(すなわち、当該ホス
トのMACアドレスがMACアドレスエリアMAに格納
されている行を得るためには)、当該テーブルの最初の
行から最後の行の方へ向って1行ずつ、順次、格納され
ているMACアドレスと当該ホストのMACアドレスと
を比較し、一致しているかを判断する処理を、両MAC
アドレスが一致するまで続ける。
In order to update and store the above-mentioned total data and the like of a specific host in the management data area DA of the MAC address table as described above, it is necessary to obtain a row in which the MAC address of the host is stored (ie, In order to obtain a row in which the MAC address of the host is stored in the MAC address area MA), the MAC address stored in the table sequentially from the first row to the last row, one row at a time. Is compared with the MAC address of the host to determine whether they match.
Continue until the addresses match.

【0004】[0004]

【発明が解決しようとする課題】しかし、前述のような
方法でデータ(上記の例でいうならMACアドレス)を
格納していきテーブルを作成して、上記のような方法で
当該テーブルから特定のデータを検索するのでは、テー
ブルの最初の方に格納されているデータ(前記図7のM
ACアドレステーブルでいうなら同図に示すデータa,
b或いはc等)を検索する場合には、検索時間は短くな
るが、テーブルの最後の方に格納されているデータ(前
記図7でいうなら同図に示すデータr等)を検索する場
合には、検索時間は長くなる。そして、当該テーブルに
格納されているデータ数が多くなる程(前記例でいうな
ら、LANに接続するホストが多くなりMACアドレス
数が多くなる程)、当該検索時間は一般に長くなること
になる。
However, a table is created by storing data (in the above example, a MAC address) by the above-described method, and a specific table is created from the table by the above-described method. To search for data, the data stored at the beginning of the table (M in FIG. 7)
In the AC address table, data a,
In the case of searching for b or c), the search time is short, but when searching for data stored at the end of the table (such as the data r shown in FIG. 7 in FIG. 7). Increases the search time. Then, as the number of data stored in the table increases (in the above example, the number of hosts connected to the LAN increases and the number of MAC addresses increases), the search time generally increases.

【0005】本願発明は、上述のような事情に鑑みてな
されたものであり、格納されるデータの数が増加して
も、そのデータの検索時間が長くならないデータ配列の
テーブルを作るテーブル作成装置および当該テーブルか
らデータを短時間で検索するテーブル検索装置の提供を
目的とする。
SUMMARY OF THE INVENTION The present invention has been made in view of the above-described circumstances, and even if the number of stored data increases, a table creating apparatus for creating a data array table that does not increase the search time for the data. It is another object of the present invention to provide a table search device for searching data from the table in a short time.

【0006】[0006]

【課題を解決するための手段】請求項1の発明では、順
次送られてくるmビットデータ(ただし、mビットの全
てが0となっているデータは除かれている)を、後述の
テーブル記憶手段内のテーブルに格納していくテーブル
作成装置を以下のように構成した。すなわち、それぞれ
その行を特定する行番号が与えられている2のn(ただ
しn<m)乗個の行からなり、当該各行は、少なくて
も、上記mビットデータが格納されるデータ格納エリア
と後述のインデックスが格納されるインデックスエリア
とを有するメインテーブルと、それぞれその行を特定す
る行番号が与えられている多数(実際に利用される上記
mビットデータの個数程度)の行からなり、当該各行
は、少なくても、上記mビットデータが格納されるデー
タ格納エリアと後述のインデックスが格納されるインデ
ックスエリアとを有するサブテーブルを備えているテー
ブル記憶手段と、上記mビットデータが送られてくる度
に、送られてきた当該mビットデータから、上位a(た
だしaは予じめ定められた0以上の数)ビットを除き、
更に下位b(ただしbは予じめ定められている0以上の
数)ビットを除いて得られたn(従ってn=m−a−
b)ビットデータを読込み、当該nビットデータに対応
する上記行番号を求め、その上で当該行番号が与えられ
ている上記メインテーブル中の行のデータ格納エリアに
は、既に以前に送られてきたmビットデータが格納され
ているか否かを判断する第1判断手段と、上記第1判断
手段が否定的判断をしたときに、上記第1判断手段の判
断対象となったメインテーブル中の行のデータ格納エリ
アに、今回送られてきたmビットデータを格納する第1
格納手段と、上記第1判断手段が肯定的判断をしたとき
に、既に格納されているmビットデータは、今回送られ
てきたmビットデータと等しいデータか否かを判断する
第2判断手段と、上記第2判断手段が否定的判断をした
ときに、上記第1判断手段の判断対象となったメインテ
ーブル中の行の上記インデックスエリアには、既にイン
デックスが格納されているか否かを判断する第3判断手
段と、上記第3判断手段が否定的判断をしたときに、上
記サブテーブル中の行で、未だ上記mビットデータが格
納されていない行を見つけて、その行のデータ格納エリ
アに今回送られてきたmビットデータを格納する第2格
納手段と、上記第2格納手段が上記格納処理を終えたと
きに、当該格納処理が行なわれたデータ格納エリアが属
する行の行番号を、上記第3判断手段の判断対象であっ
たメインテーブル中の行のインデックスエリアにインデ
ックスとして格納する第3格納手段と、上記第3判断手
段が肯定的判断をしたときに、当該判断対象となったメ
インテーブル中の行の上記インデックスエリアにインデ
ックスとして格納されていた行番号に基づいて、当該行
番号が与えられているサブテーブル中の行を捜し、当該
行のデータ格納エリアに既に格納されているmビットデ
ータは、今回送られてきたmビットデータと同一のデー
タか否かを判断する第4判断手段と、上記第4判断手段
が否定的判断をしたとき、又は後述の第6判断手段が否
定的判断をしたときに、それぞれ第4判断手段又は第6
判断手段の判断の対象となったサブテーブル中の行のイ
ンデックスエリアにインデックスが格納されているか否
かを判断する第5判断手段と、上記第5判断手段が肯定
的判断をしたときに、判断の対象となったインデックス
エリアにインデックスとして格納されているサブテーブ
ルの行番号に基づき、当該行番号が与えられているサブ
テーブル中の行を捜し、当該行のデータ格納エリアに格
納されているmビットデータは、今回送られてきたmビ
ットデータと同一のデータか否かを判断する第6判断手
段と、上記第5判断手段が否定的判断をしたときに、サ
ブテーブル中の行でその行のデータ格納エリアに、未だ
mビットデータが格納されていない行を捜し、当該行の
データ格納エリアに今回送られてきたmビットデータを
格納する第4格納手段と、上記第4格納手段が上記格納
処理を終えたときに、当該第4格納手段による格納が行
なわれたサブテーブル中の行の行番号をインデックスと
して、上記第5判断手段が、直前に、判断の対象とした
インデックスエリアに格納する第5格納手段とを備える
構成とした。
According to the first aspect of the present invention, m-bit data sequentially transmitted (however, data in which all of m bits are 0 are excluded) is stored in a table, which will be described later. The table creating apparatus for storing the data in the table in the means is configured as follows. That is, it is composed of 2 n (where n <m) power rows each having a row number specifying the row, and each row is at least a data storage area for storing the m-bit data. And a main table having an index area in which an index described later is stored, and a large number of rows (about the number of m-bit data actually used) each provided with a row number specifying the row. Each row is a table storage means having a sub-table having at least a data storage area for storing the m-bit data and an index area for storing an index described later. Each time it arrives, the higher-order a (where a is a predetermined number of 0 or more) bits are removed from the transmitted m-bit data,
Further, n obtained by excluding lower-order b (where b is a predetermined number of 0 or more) bits (thus n = ma-
b) The bit data is read, the line number corresponding to the n-bit data is obtained, and then the data is already sent to the data storage area of the line in the main table to which the line number is given. First determining means for determining whether or not the stored m-bit data is stored; and, when the first determining means makes a negative determination, a row in the main table which has been determined by the first determining means. In the first data storage area, the m-bit data transmitted this time is stored.
A storage means, and a second determination means for determining whether or not the already stored m-bit data is equal to the m-bit data transmitted this time when the first determination means makes a positive determination. When the second determination means makes a negative determination, it is determined whether or not an index has already been stored in the index area of the row in the main table which has been determined by the first determination means. When the third judging means and the third judging means make a negative judgment, a row in the sub-table in which the m-bit data is not yet stored is found, and the row is stored in the data storage area of the row. The second storage means for storing the m-bit data transmitted this time, and when the second storage means has completed the storage processing, the row number of the row to which the data storage area in which the storage processing has been performed belongs is entered. The third storage means for storing as an index in the index area of the row in the main table which has been determined by the third determination means, and the third determination means has been determined when the third determination means has made a positive determination. Based on the row number stored as an index in the index area of the row in the main table, a row in the sub-table to which the row number is given is searched, and the row is already stored in the data storage area of the row. The fourth determination means for determining whether or not the m-bit data is the same data as the m-bit data transmitted this time, and when the fourth determination means makes a negative determination, or when the sixth determination means described later When a negative judgment is made, the fourth judgment means or the sixth judgment
Fifth determining means for determining whether or not an index is stored in the index area of the row in the sub-table which has been determined by the determining means; and determining when the fifth determining means makes a positive determination. Based on the row number of the sub-table stored as an index in the target index area, a row in the sub-table to which the row number is given is searched, and m stored in the data storage area of the row is searched. The bit data is determined by a sixth determining means for determining whether or not the data is the same as the m-bit data transmitted this time. In the data storage area of which no m-bit data is stored yet, and storing the m-bit data transmitted this time in the data storage area of the row. And when the fourth storage means has completed the storage processing, the fifth determination means uses the row number of the row in the sub-table in which the storage was performed by the fourth storage means as an index, and And a fifth storage unit for storing in the index area to be determined.

【0007】請求項2の発明では、請求項1記載のテー
ブル作成装置以下の各手段を追加した。即ち、上記第1
格納手段が格納処理を終えたときに、当該格納に応じた
所定の処理を実行する第1処理手段と、上記第2判断手
段が肯定的判断をしたときに、既に格納されているmビ
ットデータと同一のデータが更にもう一度送られてきた
ことに応じた所定の処理を実行する第2処理手段と、上
記第3格納手段が上記格納処理を終えたときに、上記第
2格納手段による処理に応じた所定の処理を実行する第
3処理手段と、上記第4判断手段が肯定的判断をしたと
きに、すでに格納されているmビットデータと同一のデ
ータが更にもう一度送られてきたことに応じた所定の処
理を実行する第4処理手段と、上記第6判断手段が肯定
的判断をしたときに、既に格納されているmビットデー
タと同一のデータが更にもう一度送られてきたことに応
じた所定の処理を実行する第5処理手段と、上記第5格
納手段による格納処理が終了したときに、当該格納に応
じた所定の処理を実行する第6処理手段とが追加される
構成とした。
[0007] In the second aspect of the present invention, each means below the table creating apparatus according to the first aspect is added. That is, the first
First processing means for executing a predetermined processing according to the storage when the storage means has completed the storage processing, and m-bit data already stored when the second determination means makes a positive determination. Second processing means for executing a predetermined process in response to the same data being sent once more, and processing by the second storage means when the third storage means has completed the storage processing. A third processing means for executing a predetermined process in response to the third data, and when the same data as the already stored m-bit data has been sent again when the fourth determining means makes a positive determination. The fourth processing means for executing the predetermined processing, and when the same data as the already stored m-bit data has been sent again when the sixth determination means makes a positive determination. Predetermined processing A fifth processing means for line, when the storing process according to the fifth storage means is completed, and a configuration in which the sixth processing means for executing a predetermined process corresponding to the storage is added.

【0008】請求項3の発明では、上記請求項1又は請
求項2記載のテーブル作成装置で作成されたテーブルと
同一のデータ配列になっているテーブルから当該テーブ
ルに格納されている特定のmビットデータを検索するテ
ーブル検索装置を以下のように構成した。すなわち、検
索すべきmビットデータが指定される度に、当該mビッ
トデータに係る前記nビットデータを読込み、当該nビ
ットデータに対応する前記行番号が与えられているメイ
ンテーブル中の行の前記データ格納エリアには、検索す
べきmビットデータが格納されているか否かを判断する
格納データ判別手段と、上記格納データ判別手段が否定
的判断をしたときに又は後述のデータ格納済判断手段が
否定的判断をしたときに、先の判断で判別対象としたデ
ータ格納エリアの属する行のインデックスエリアには、
インデックスが格納されているか否かを判断するインデ
ックス格納済判断手段と、上記インデックス格納判断手
段が肯定的判断をしたときに、当該インデックス格納判
断手段が判断対象としたインデックスエリアに格納され
ているインデックスに対応する行番号が与えられている
サブテーブル中の行には、検索すべきmビットデータが
格納されているかを判断するデータ格納済判断手段と、
上記格納データ判別手段が肯定的判断をしたとき又は上
記データ格納済判断手段が肯定的判断をしたときに、検
索すべきmビットデータを検索できたときに行なう所定
の処理(例えば、上記検索すべきmビットデータに対応
づけられて、同一行の他のエリアに格納されているデー
タの読出し処理等)を実行する所定処理実行手段とを備
える構成とした。
According to a third aspect of the present invention, a table having the same data array as a table created by the table creating apparatus according to the first or second aspect is used to store a specific m bit stored in the table. A table search device for searching data is configured as follows. That is, every time the m-bit data to be searched is designated, the n-bit data related to the m-bit data is read, and the n-bit data of the row in the main table to which the row number corresponding to the n-bit data is given is read. In the data storage area, stored data determining means for determining whether or not m-bit data to be searched is stored, and when the stored data determining means makes a negative determination or when data stored determination means described later is used. When a negative determination is made, the index area of the row to which the data storage area determined in the previous determination belongs,
An index storage determining unit for determining whether or not an index is stored; and an index stored in an index area determined by the index storage determining unit when the index storage determining unit makes a positive determination. A data stored determination means for determining whether m-bit data to be searched is stored in a row in the sub-table given a row number corresponding to
A predetermined process to be performed when m-bit data to be retrieved can be retrieved when the stored data discriminating unit makes a positive determination or when the data stored determination unit makes a positive determination (for example, A predetermined process executing means for executing a process of reading data stored in another area of the same row in association with exponent m-bit data.

【0009】[0009]

【発明の実施の形態】以下、図面に示す実施の形態に基
づいて、本願発明を具体的に説明する。なお、本実施の
形態は、LANのネットワーク管理装置のMACアドレ
ステーブル作成部およびこのテーブルの検索部に本願発
明を適用したものである。
DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS Hereinafter, the present invention will be specifically described based on embodiments shown in the drawings. In the present embodiment, the present invention is applied to a MAC address table creation unit and a search unit for the MAC address table of a LAN network management device.

【0010】本発明が適用されているテーブル作成部
(装置)およびテーブル検索部(装置)を備えるネット
ワーク管理装置1の構成は、図1に示すようになってい
る。すなわち当該ネットワーク管理装置1は、CPU2
を中心とし、これに後述のメインテーブルMTおよびサ
ブテーブルST等が記憶されているRAM4、当該ネッ
トワーク管理装置1の各種動作を指示するプログラム等
を固定的に記憶しているROM3およびLANコントロ
ーラ5とが接続する構成となっている。そしてLANコ
ントローラ5は、LANケーブル6に接続されている。
FIG. 1 shows the configuration of a network management apparatus 1 including a table creation unit (apparatus) and a table search unit (apparatus) to which the present invention is applied. That is, the network management device 1 includes the CPU 2
And a ROM 3 and a LAN controller 5 in which a main table MT and a sub table ST, which will be described later, are stored, a program for instructing various operations of the network management apparatus 1 and the like are fixedly stored. Are connected. The LAN controller 5 is connected to a LAN cable 6.

【0011】本実施の形態では、前記MACアドレステ
ーブルをメインテーブルMTとサブテーブルSTとの2
つのテーブルに分けているが、図2の(a)は前者の構
成を示すもので、同図の(b)は後者の構成を示すもの
である。メインテーブルMTは、図2の(a)に示すよ
うに、相対行アドレス(基底行アドレスをDとしてい
る)0から65535の1つがそれぞれ与えられている
65536行からなり(なお65536行とするのは、
本実施の形態では、48ビットデータのMACアドレス
の下位2バイトすなわち16ビットからなるデータを前
記nビットデータとしており、この16ビットからなる
データは2の16乗通り、すなわち65536通り存在
し得るので、それらの各データに1行を与えるためであ
る)、そして各行はMACアドレスエリアMA、インデ
ックスエリアIAおよび管理データエリアDAを有して
いる。MACアドレスエリアMAはMACアドレスが格
納されるエリアであり、インデックスエリアIAは、こ
のメインテーブルのその行とサブテーブル中の1つの行
を関連づけるインデックスが格納されるエリアであり、
管理データエリアDAは、更に多数の小エリアに分かれ
ており、それらの各小エリアには、特定のホスト(その
行のMACアドレスエリアMAにMACアドレスが格納
されているホスト)のパケット送信回数、パケット受信
回数等のデータが格納されていく。
In this embodiment, the MAC address table is divided into a main table MT and a sub table ST.
FIG. 2A shows the former configuration, and FIG. 2B shows the latter configuration. As shown in FIG. 2A, the main table MT is composed of 65536 rows to which one of relative row addresses (base row address is set to D) 0 to 65535 is given (note that 65536 rows are used). Is
In the present embodiment, the lower 2 bytes of the MAC address of 48-bit data, that is, data consisting of 16 bits, is used as the n-bit data, and the data consisting of 16 bits can be represented by 2 to the 16th power, that is, 65536 ways. , One row for each of these data), and each row has a MAC address area MA, an index area IA, and a management data area DA. The MAC address area MA is an area for storing a MAC address, and the index area IA is an area for storing an index for associating that row of the main table with one row in the sub-table,
The management data area DA is further divided into a number of small areas. Each of the small areas includes the number of packet transmissions of a specific host (a host whose MAC address is stored in the MAC address area MA of the row), Data such as the number of packet receptions is stored.

【0012】また、同図(b)に示すサブテーブルST
は、当該ネットワーク管理装置が接続されているLAN
に、接続される可能性があるホストの台数すなわち20
0台にそれぞれ1行が与えられる200行からなり、各
行は、メインテーブルMTと同様にMACアドレスエリ
アMA、インデックスエリアIAおよび管理データエリ
アDAからなっている。なお当該サブテーブルSTのイ
ンデックスエリアIAには、メインテーブルMTのイン
デックスエリアIAと異なり、サブテーブル内の他の行
と関連づけるインデックスが格納される。
The sub-table ST shown in FIG.
Is the LAN to which the network management device is connected.
, The number of hosts that may be connected, ie, 20
Each row is composed of 200 rows in which one row is given to 0 units. Each row is composed of a MAC address area MA, an index area IA, and a management data area DA, like the main table MT. Note that, unlike the index area IA of the main table MT, the index area IA of the sub table ST stores an index associated with another row in the sub table.

【0013】次に、以上のように構成された本実施の形
態の動作を説明する。本実施の形態に係るネットワーク
管理装置は、いずれかのホストからLANにパケットが
送出されるたびに、そのパケットを取込み、いずれのホ
ストからいずれのホストに送られるものかを検知し、そ
れらホストのパケット送信回数やパケット受信回数等の
各集計等を、前記メインテーブルMTやサブテーブルS
Tの管理データエリアDAの計数値を更新することによ
り行なっていく。しかし、両テーブルへのデータの格納
動作や、両テーブルからのMACアドレスの検索動作に
関しては、上記いずれのデータの集計等に際しても、概
ね同じである。そこで、以下の動作説明では、パケット
が送られてくる度に行なわれるその送信元ホストの送信
回数を上記両テーブルを利用して集計(カウント)する
動作および当該集計結果を両テーブルから読出する際の
動作を、例にして、図3〜図6のフローチャートを参照
しながら説明する。また以下では、48ビットのデータ
であるMACアドレスを、便宜上、そのビット配列を保
ったままで4ビットずつに分けて当該各4ビットを16
進数で表す2進化16進数として表示する。
Next, the operation of the present embodiment configured as described above will be described. The network management device according to the present embodiment captures the packet every time a packet is sent from any host to the LAN, detects which host sends it to which host, and detects The totals such as the number of times of packet transmission and the number of times of packet reception are stored in the main table MT and the sub table S.
The update is performed by updating the count value of the management data area DA of T. However, the operation of storing data in both tables and the operation of searching for a MAC address from both tables are almost the same when totaling any of the above data. Therefore, in the following description of the operation, the operation of totaling (counting) the number of transmissions of the transmission source host performed each time a packet is transmitted using both tables and reading the totaling result from both tables Will be described with reference to the flowcharts of FIGS. 3 to 6 as an example. In the following, for convenience, a MAC address, which is 48-bit data, is divided into 4 bits while maintaining the bit arrangement, and each of the 4 bits is divided into 16 bits.
It is displayed as a binary-coded hexadecimal number.

【0014】(A)、先ず、メインテーブルMTおよび
サブテーブルSTに1つもMACアドレスが格納されて
いない状態(各行の各エリアには全て0が格納されてい
る)でパケットが送られてきて、その送信元ホストのM
ACアドレスが111000ff0002であった場合
を例とし、そのときの動作を説明する。この場合、図3
のステップS1で上記MACアドレスの下位16ビット
データすなわち0002に対応する相対行アドレス2
(すなわち行アドレス(D+2))を求めて、然る後に
ステップS2に進む。そしてこのステップS2では、メ
インテーブルMT中の相対行アドレス2の行のMACア
ドレスエリアMAには、未だMACアドレスが格納され
ていないことを判断して、ステップS3に進み、上記M
ACアドレスエリアMAに上記MACアドレス1110
00ff0002を格納する。その後、ステップS4に
進み、上記行の管理データエリアDA中の小エリアで送
信回数を記憶しておくエリア(以下、送信回数エリアと
いう)に1を記憶しておく。これでMACアドレス11
1000ff0002のホストがパケットを1回送信し
たことを記録したことになる。
(A) First, a packet is sent in a state where no MAC address is stored in the main table MT and the sub table ST (all 0s are stored in each area of each row). M of the source host
The operation when the AC address is 111000ff0002 will be described as an example. In this case, FIG.
In step S1, the relative row address 2 corresponding to the lower 16-bit data of the MAC address, that is, 0002
(That is, the row address (D + 2)) is obtained, and then the process proceeds to step S2. In this step S2, it is determined that the MAC address has not yet been stored in the MAC address area MA of the row of the relative row address 2 in the main table MT, and the process proceeds to step S3.
The MAC address 1110 is stored in the AC address area MA.
00ff0002 is stored. Thereafter, the process proceeds to step S4, where 1 is stored in an area for storing the number of times of transmission (hereinafter, referred to as a number-of-times-of-transmission area) in the small area in the management data area DA of the above row. With this, MAC address 11
This means that the host of 1000ff0002 has transmitted the packet once.

【0015】(B)、次に、上記パケットが送られて来
た後に、同一ホストからパケットが送られてきた場合を
例とし、そのときの動作について説明する。この場合、
前記同様にして、図3のステップS1で相対行アドレス
2を求め、ステップS2に進むが、今回は、既に相対行
アドレス2の行のMACアドレスエリアMAにはMAC
アドレスが格納されていると判断し、当該ステップS2
からステップS5に進み、当該ステップS5で、既に格
納されているMACアドレスは今回の送信元ホストMA
Cアドレスと同じであることを確認して、ステップS4
に進む。ステップS4では前記管理データエリアDAの
送信回数エリアの送信回数データを1だけ大きいものに
更新する。
(B) Next, an operation in a case where a packet is transmitted from the same host after the packet is transmitted will be described as an example. in this case,
In the same manner as described above, the relative row address 2 is obtained in step S1 of FIG. 3, and the process proceeds to step S2.
It is determined that the address is stored, and the process proceeds to step S2.
The process proceeds from step S5 to step S5, where the MAC address already stored is the current transmission source host MA.
After confirming that the address is the same as the C address, step S4
Proceed to. In step S4, the transmission count data in the transmission count area of the management data area DA is updated to one larger by one.

【0016】(C)、次に上記(B)の動作の後にMA
Cアドレスが100011af0001のホストからの
最初のパケットが送られてきたときを例とし、そのとき
の動作に説明する。この場合は、上記(A)の場合と概
ね同様の動作がなされ、メインテーブルMTの相対行ア
ドレス1の行のMACアドレスエリアMAに上記送信元
MACアドレス100011af0001が格納され当
該行の管理データエリアDAの送信回数エリアに1が記
憶される。
(C) Then, after the above operation (B), MA
The operation when the first packet is sent from the host with the C address of 1000011af0001 will be described as an example. In this case, substantially the same operation as in the case of (A) is performed, and the source MAC address 100011af0001 is stored in the MAC address area MA of the row of the relative row address 1 in the main table MT, and the management data area DA of the row is stored. Is stored in the number-of-times-of-transmission area.

【0017】(D)、上記(C)の動作の以後に(直後
に限らないが、その間、下位側16ビットが同一のMA
Cアドレスのパケットは送られてきてないたことにす
る)、(C)の場合の送信元MACアドレスと下位側1
6ビットが同一のMACアドレス100011de00
01のホストからパケットが送られてきたときを例と
し、そのときの動作を説明する。この場合、図3のステ
ップS1で相対行アドレス1を求め、ステップS2でメ
インテーブルMT中の当該相対行アドレス1の行のMA
CアドレスエリアMAに既にMACアドレス(すなわち
上記(C)の動作で格納した100011af000
1)が格納されていることを確認してステップS5に進
む。ステップS5では、上記既に格納されているMAC
アドレスが、今回送られてきたMACアドレスと異なる
ことを検知し、図4のステップS7に進む。そしてこの
ステップS7では、上記相対行アドレス1の行のインデ
ックスエリアIAにインデックス(サブテーブルSTの
相対行アドレス)が未だ格納されていないことを確認し
て、ステップS8に進み、サブテーブルSTのいずれか
の行で未だその行のMACアドレスエリアMAにMAC
アドレスが格納されていない行を見つけ、その行、例え
ば相対行アドレス1(すなわち行アドレス(E+1))
の行のMACアドレスエリアMAに今回の送信元MAC
アドレス100011de0001を格納する(図2の
(b)の行アドレス(E+1)の行を参照)。次いでス
テップS9に進んで、上記メインテーブルMTの相対行
アドレス1の行のインデックスエリアIAに、上記サブ
テーブルST中の行で上記送信元MACアドレスを格納
した行の相対行アドレス1を格納しておく(図2の
(a)の相対行アドレス1のインデックスエリアIA参
照)。続くステップS10では、サブテーブルSTの相
対行アドレス1の行の管理データエリアDAにある送信
回数エリアに1を記憶して、MACアドレス10001
1de0001のホストからの送信が1回あった旨を記
録する。
(D) After the operation of (C) (but not limited to immediately after), the lower 16 bits of the same MA
It is assumed that the packet of the C address has not been sent), and in the case of (C), the source MAC address and the lower 1
MAC address 100011de00 with the same 6 bits
The operation when the packet is sent from the host No. 01 will be described as an example. In this case, the relative row address 1 is determined in step S1 of FIG. 3, and the MA of the row of the relative row address 1 in the main table MT is determined in step S2.
In the C address area MA, the MAC address (that is, 1000011af000 stored in the operation of the above (C)) is used.
After confirming that 1) is stored, the process proceeds to step S5. In step S5, the already stored MAC
It is detected that the address is different from the MAC address transmitted this time, and the process proceeds to step S7 in FIG. In this step S7, it is confirmed that the index (the relative row address of the sub-table ST) is not yet stored in the index area IA of the row of the relative row address 1, and the process proceeds to step S8, where The MAC address area MA on that line is still
Find a row where no address is stored, and find that row, eg, relative row address 1 (ie row address (E + 1))
The source MAC of this time is stored in the MAC address area MA of the row
The address 100011de0001 is stored (see the row of the row address (E + 1) in FIG. 2B). Next, proceeding to step S9, the relative row address 1 of the row in the sub-table ST where the source MAC address is stored is stored in the index area IA of the row of the relative row address 1 of the main table MT. (Refer to the index area IA of the relative row address 1 in FIG. 2A). In the following step S10, 1 is stored in the transmission count area in the management data area DA of the row of the relative row address 1 in the sub table ST, and the MAC address 10001 is stored.
It records that there is one transmission from the host of 1de0001.

【0018】(E)、上記の(D)の動作が終了した
後、先ず送信元MACアドレスが110011ff00
00のパケットが送られてき、次にMACアドレスの下
位16ビットが0000でないパケットが何個か送られ
てきて、その後に送信元MACアドレスが1100ff
110000のパケットが送られてきて、その次に送信
元MACアドレスが11aabbf10000のパケッ
トが送られてきたとして、即ち、下位16ビットが00
00となっている上記3個のMACアドレスがそれぞれ
送信元MACアドレスとなっているパケットが送られて
きたとし、そのときの動作を説明する。
(E) After the above operation (D) is completed, first, the source MAC address is set to 110011ff00.
00 packets are sent, then some packets whose lower 16 bits of the MAC address are not 0000 are sent, and then the source MAC address is 1100ff
It is assumed that a packet of 110000 is transmitted, and then a packet of a source MAC address of 11aabbf10000 is transmitted.
It is assumed that a packet in which the three MAC addresses of 00 are the source MAC addresses has been sent, and the operation at that time will be described.

【0019】先ず送信元MACアドレスが110011
ff0000のパケットが送られてきたときは、前記
(A)の場合と概ね同様の動作(図3のステップS1〜
S4)がなされる。これにより、メインテーブルMTの
相対行アドレス0の行のMACアドレスエリアMAに該
当MACアドレスが格納され(図2の(a)の行アドレ
ス(D+0)の行を参照)、当該相対行アドレス0の行
の管理データエリアDAの送信回数エリアに1が記憶さ
れる。次いで送信元MACアドレスが上記1100ff
110000のパケットが送られてきたときは、上記
(D)の場合と概ね同様であり、先ず図3のステップS
1で相対行アドレス0を求め、ステップS2ではメイン
テーブルMTの当該相対行アドレス0の行のMACアド
レスエリアMAには既に前記MACアドレス11001
1ff0000が格納されていることを検知し、ステッ
プS5で当該MACアドレスは今回の送信元MACアド
レスと同一でないことを検知し、図4のステップS7で
上記メインテーブルMTの相対行アドレス0の行のイン
デックスエリアIAには、インデックスが格納されてい
ないことを検出し、ステップS8でサブテーブルSTの
未使用の行、例えば相対行アドレス2の行のMACアド
レスエリアMAに今回の送信元MACアドレス1100
ff110000に格納し(図2の(b)の相対行アド
レス2の行のMACアドレスエリアMA参照)、ステッ
プS9で上記メインテーブルMTの相対行アドレス0の
行のインデックスエリアIAに上記サブテーブルSTの
相対行アドレス2を格納し(図2の(a)の相対行アド
レス0の行のインデックスエリアIA参照)、ステップ
S10でサブテーブルSTの相対行アドレス2の行の管
理データエリアDAの送信数エリアに1が記憶される。
First, the source MAC address is 110011.
When the packet of ff0000 is sent, the operation is substantially the same as that of the case (A) (steps S1 to S1 in FIG. 3).
S4) is performed. As a result, the corresponding MAC address is stored in the MAC address area MA of the row of the relative row address 0 of the main table MT (see the row of the row address (D + 0) in FIG. 1 is stored in the transmission count area of the management data area DA of the row. Next, the source MAC address is 1100ff
When the packet of 110000 is sent, it is almost the same as the case of the above (D).
1, the relative row address 0 is obtained. In step S2, the MAC address 11001 is already stored in the MAC address area MA of the row of the relative row address 0 in the main table MT.
1ff0000 is stored, it is detected in step S5 that the MAC address is not the same as the current transmission source MAC address, and in step S7 of FIG. It is detected that the index is not stored in the index area IA, and in step S8, the current transmission source MAC address 1100 is stored in an unused row of the sub table ST, for example, the MAC address area MA of the row of the relative row address 2.
ff110000 (see the MAC address area MA of the row with the relative row address 2 in FIG. 2B), and in step S9, the sub-table ST is stored in the index area IA of the row with the relative row address 0 of the main table MT. The relative row address 2 is stored (see the index area IA of the row with the relative row address 0 in FIG. 2A), and in step S10, the transmission number area of the management data area DA of the row with the relative row address 2 in the sub table ST Is stored in the memory.

【0020】次いで上記11aabbf10000が送
られてきたときは以下のようになる。すなわち図3のス
テップS1で相対行アドレス0を求め、ステップS2で
メインテーブルMTの当該相対行アドレス0の行のMA
CアドレスエリアMAにはすでにMACアドレスが格納
されているのを検知し、次のステップS5では上記行の
MACアドレスエリアMAに格納されているMACアド
レスは上記11aabbf0000ではないことを検知
する。次の図4のステップS7ではメインテーブルMT
の相対行アドレス0の行のインデックスエリアIAにイ
ンデックス2が格納されていることを検知し、次のステ
ップS11では、上記インデックス2に対応する相対行
アドレス2が与えられているサブテーブルST中の行の
MACアドレスエリアMAに格納されているMACアド
レスは今回の送信元MACアドレス11aabb100
00と同一ではないことを検出して、図5のステップS
13に進む。このステップS13では上記相対行アドレ
ス2が与えられているサブテーブルSTの行のインデッ
クスエリアIAにはインデックスが格納されていないと
判断して、ステップS15に進み、未だMACアドレス
エリアMAにMACアドレスが格納されていないサブテ
ーブルST中の行、例えば相対行アドレス3の行に上記
今回のMACアドレスを格納する(図2の(b)の相対
行アドレス3の行参照)。然る後、ステップS16では
サブテーブルSTにおける上記相対行アドレス3をイン
デックスとして、サブテーブルSTの相対行アドレス2
の行のインデックスエリアIAに格納する(図2の
(b)の相対行アドレス2の行のインデックスエリアI
A参照)。そして最後にステップS17で上記サブテー
ブルSTの相対行アドレス3の行の管理データエリアD
Aの送信回数エリアに1を記憶する。
Next, when 11aabbbf10000 is sent, the operation is as follows. That is, the relative row address 0 is obtained in step S1 of FIG. 3, and the MA of the row of the relative row address 0 in the main table MT is determined in step S2.
It is detected that the MAC address has already been stored in the C address area MA, and in the next step S5, it is detected that the MAC address stored in the MAC address area MA in the above row is not the 11aabbf0000. In the next step S7 in FIG.
It is detected that the index 2 is stored in the index area IA of the row with the relative row address 0, and in the next step S11, the sub table ST in the sub table ST to which the relative row address 2 corresponding to the index 2 is given. The MAC address stored in the MAC address area MA of the row is the source MAC address 11aabb100 of this time.
00 is not the same as that in step S in FIG.
Proceed to 13. In step S13, it is determined that the index is not stored in the index area IA of the row of the sub-table ST to which the relative row address 2 is given, and the process proceeds to step S15, where the MAC address is not yet stored in the MAC address area MA. The MAC address of this time is stored in a row in the sub-table ST that is not stored, for example, the row of the relative row address 3 (see the row of the relative row address 3 in FIG. 2B). Thereafter, in step S16, the relative row address 2 in the sub-table ST is set using the relative row address 3 in the sub-table ST as an index.
Is stored in the index area IA of the row of the row (the index area I of the row at the relative row address 2 in FIG.
A). Finally, in step S17, the management data area D of the row having the relative row address 3 in the sub-table ST is set.
1 is stored in the transmission count area of A.

【0021】(F)、上記(E)の動作の後に、更に送
信元MACアドレスが333226720000すなわ
ち下位側16ビットが上記同様に0000となっている
パケットが送られてきたときは、前記と概ね同様の動作
(ステップS1、S2、S5、S7、S11)の後に図
5のステップS13に進み、このステップSでサブテー
ブルSTの相対行アドレス2の行のインデックスエリア
IAにはインデックス3が格納されていることを検知
し、ステップS14に進み、上記インデックス3に対応
する相対行アドレス3が与えられているサブテーブルS
T中の行のMACアドレスエリアMAの送信元MACア
ドレスと、上記今回の送信元MACアドレスは等しくな
いことを検出し、その上でステップS13に戻る。そし
てこのステップS13で上記相対行アドレス3が与えら
れている行のインデックスエリアIAにインデックスが
未だ格納されていないことを確認し、ステップS15で
サブテーブルST中の未使用の行、例えば相対行アドレ
ス4の行に今回の送信元MACアドレスを格納し、ステ
ップS16では上記相対行アドレス3が与えられている
行のインデックスエリアIAにインデックスとして上記
相対行アドレス4を格納し、更にステップS17で、上
記相対行アドレス4の行の管理データエリアDAの送信
回数エリアに1を記憶する。
(F) After the operation of (E) above, if a packet whose source MAC address is 33322670000, that is, the lower 16 bits are 0000 in the same manner as described above, is transmitted, the above is substantially the same as above. After the operation (steps S1, S2, S5, S7, S11), the process proceeds to step S13 in FIG. 5. In this step S, the index 3 is stored in the index area IA of the row of the relative row address 2 of the sub-table ST. The process proceeds to step S14, and the sub table S to which the relative row address 3 corresponding to the index 3 is given
It is detected that the transmission source MAC address of the MAC address area MA of the row in T is not equal to the current transmission source MAC address, and the process returns to step S13. In step S13, it is confirmed that the index has not been stored in the index area IA of the row to which the relative row address 3 is given. In step S15, an unused row in the sub-table ST, for example, the relative row address is used. In step S16, the relative MAC address is stored in the index area IA of the row to which the relative row address 3 is given. In step S17, the relative MAC address is stored. 1 is stored in the transmission count area of the management data area DA of the row with the relative row address 4.

【0022】(G)、上記(F)の動作の後に、この
(F)の動作での送信元MACアドレスと同一のMAC
アドレス333226720000が送信元MACアド
レスとして送られてきたときは以下のような動作が行な
われる。ステップS1、S2、S5、S7、S11、S
13、S14では上記(F)での場合と概ね同様の処理
が行なわれ、その後ステップS14からステップS13
に戻り、ここでサブテーブルSTの相対行アドレス3の
行のインデックスエリアIAにはインデックス4が格納
されていることを検出し、再度、ステップS14に戻っ
て、上記インデックス4に対応する相対行アドレス4が
与えられている行のMACアドレスエリアMAに格納さ
れているMACアドレスは今回の送信元MACアドレス
と等しいことを検出して、ステップS17に進んで、サ
ブテーブルSTの上記相対行アドレス4の行の管理デー
タエリアDAの送信回数エリアの送信回数を1だけ大き
い2にする。
(G) After the operation (F), the same MAC address as the source MAC address in the operation (F) is used.
When the address 33322620000 is sent as the source MAC address, the following operation is performed. Steps S1, S2, S5, S7, S11, S
In steps S13 and S14, substantially the same processing as in the case of the above (F) is performed.
And here, it is detected that the index 4 is stored in the index area IA of the row of the relative row address 3 of the sub-table ST, and the process returns to step S14 again to return to the relative row address corresponding to the above index 4. 4 is detected, it is detected that the MAC address stored in the MAC address area MA of the row assigned to the row is equal to the current transmission source MAC address. The number of transmissions in the number-of-transmissions area of the management data area DA of the row is increased by one to two.

【0023】(H)、既にサブテーブルSTに格納して
いるMACアドレス100011de0001が、再
度、送信元MACアドレスとして送られてきたときの動
作は以下のようになる。すなわちステップS1で相対行
アドレス1を求め、ステップS2でメインテーブルMT
の相対行アドレス1の行のMACアドレスエリアMAに
は既にMACアドレスが格納されていることを確認し、
ステップS5で格納されているのは今回の送信元MAC
アドレスではないことを検出し、ステップS7でメイン
テーブルMTの相対行アドレス1の行のインデックスエ
リアIAにはインデックスが格納されていることを検出
し、ステップS11で当該インデックスに対応する相対
行アドレス1が与えられているサブテーブルST中の行
のMACアドレスエリアMAに格納されているMACア
ドレスは、今回の送信元MACアドレスに等しいことを
検出してステップS12に進み、上記相対行アドレス1
の行の管理データエリアDAの送信回数エリアの送信回
数を1だけ大きいものにしておく。
(H) The operation when the MAC address 100011de0001 already stored in the sub-table ST is sent again as the source MAC address is as follows. That is, the relative row address 1 is determined in step S1, and the main table MT is determined in step S2.
Confirm that the MAC address has already been stored in the MAC address area MA of the row having the relative row address 1 of
What is stored in step S5 is the current transmission source MAC
In step S7, it is detected that an index is stored in the index area IA of the row of the relative row address 1 in the main table MT. In step S11, the relative row address 1 corresponding to the index is detected. , The MAC address stored in the MAC address area MA of the row in the sub-table ST is equal to the current transmission source MAC address, and the process proceeds to step S12, where the relative row address 1
The number of transmissions in the number-of-transmissions area of the management data area DA of the row is increased by one.

【0024】以下、上記(A)〜(H)の動作例と概ね
同様な動作を繰返して、上記メインテーブルMTおよび
サブテーブルSTに各MACアドレスごとに(すなわ
ち、各ホストごとに)各種データを集計していくことに
なる。
Hereinafter, operations substantially similar to the above-described operation examples (A) to (H) are repeated, and various data are stored in the main table MT and the sub-table ST for each MAC address (that is, for each host). It will be counted.

【0025】次に以上のようにして、各MACアドレス
毎に各種データを集計した後に、これら両テーブルから
特定ホストについての上記集計データを読取る際の動作
例を示す。
Next, an example of the operation of reading the above-mentioned total data for a specific host from both tables after totaling various data for each MAC address as described above will be described.

【0026】(1)、先ず、MACアドレス10001
1af0001が与えられているホストについての各種
データを検索する場合の動作を説明する。最初に図6の
ステップS20で上記MACアドレスの下位2バイト
(すなわち16ビット)0001に対応する相対行アド
レス1を求め、その後にステップS21に進み、メイン
テーブルMT中の相対行アドレス1の行のMACアドレ
スエリアMAに上記MACアドレスが格納されているこ
とを確認して(図2の(a)の相対行アドレス1の行を
参照)、ステップS22で当該相対行アドレス1の行の
管理データエリアDAより各種データを読出すことにな
る。
(1) First, MAC address 10001
The operation in the case of searching for various data for the host given 1af0001 will be described. First, in step S20 of FIG. 6, a relative row address 1 corresponding to the lower 2 bytes (ie, 16 bits) 0001 of the MAC address is obtained, and thereafter, the process proceeds to step S21, where the row of the relative row address 1 in the main table MT is determined. After confirming that the MAC address is stored in the MAC address area MA (see the row of the relative row address 1 in FIG. 2A), the management data area of the row of the relative row address 1 is determined in step S22. Various data will be read from DA.

【0027】(2)、次にMACアドレス333226
720000が与えられているホストについての各種デ
ータを検索する場合の動作を説明する。先ず、図6のス
テップS20で、上記同様にして相対行アドレス0を求
め、続くステップS21でメインテーブルMTの相対行
アドレス0の行のMACアドレスエリアMAに上記MA
Cアドレスが格納されていないことを判断し(図2の
(a)の相対行アドレス0の行を参照)、次いでステッ
プS23で上記相対行アドレス0の行のインデックスエ
リアIAにインデックスが格納されていることを検知す
る。その後、ステップS24に進み、上記インデックス
エリアIAに格納されているインデックスに対応する相
対行アドレス2が与えられているサブテーブルSTの行
のMACアドレスエリアMAには上記MACアドレス3
33226720000が格納されていない(図2の
(b)の相対行アドレス2の行を参照)ことを判断し
て、ステップS23に戻る。そしてこのステップS23
で上記相対行アドレス2の行のインデックスエリアIA
にはインデックスが格納されていることを確認して、次
のステップS24では当該インデックスエリアIAに格
納されているインデックスに対応する相対行アドレス3
の行のMACアドレスエリアMAに上記MACアドレス
が格納されていない(図2の(b)の相対行アドレス3
の行を参照)ことを確認し、ステップS23に戻る。そ
してこのステップSで上記相対行アドレス3の行のイン
デックスエリアIAにインデックスが格納されているこ
とを確認して、続くステップS24で当該インデックス
に対応する相対行アドレス4の行のMACアドレスエリ
アMAに上記MACアドレス333226720000
が格納されていることを判断し(図2の(b)の相対行
アドレス4の行を参照)、ステップS22に進み、上記
相対行アドレス4の行の管理データエリアDAより各種
データを読出すことになる。
(2) Next, the MAC address 333226
The operation in the case of searching for various data for the host given 720000 will be described. First, in step S20 of FIG. 6, the relative row address 0 is obtained in the same manner as described above, and in the following step S21, the MA address is stored in the MAC address area MA of the row of the relative row address 0 in the main table MT.
It is determined that the C address is not stored (see the row of the relative row address 0 in FIG. 2A). Then, in step S23, the index is stored in the index area IA of the row of the relative row address 0. Detect that Thereafter, the process proceeds to step S24, where the MAC address area MA of the row of the sub-table ST to which the relative row address 2 corresponding to the index stored in the index area IA is given is the MAC address 3
It is determined that 33226720,000 is not stored (refer to the row of the relative row address 2 in FIG. 2B), and the process returns to step S23. And this step S23
Is the index area IA of the row of the relative row address 2
Is stored in the index area IA, and in the next step S24, the relative row address 3 corresponding to the index stored in the index area IA is checked.
The above MAC address is not stored in the MAC address area MA of the row (3) in FIG.
Is confirmed), and the process returns to step S23. Then, in this step S, it is confirmed that the index is stored in the index area IA of the row of the relative row address 3, and in the subsequent step S24, the MAC address area MA of the row of the relative row address 4 corresponding to the index is stored. The above MAC address 333226720000
Is stored (refer to the row of relative row address 4 in FIG. 2B), and the process proceeds to step S22 to read various data from the management data area DA of the row of relative row address 4. Will be.

【0028】なお、上記ステップS23で否定的判断が
なされたときは、検索対象となっているホストについて
のデータがメインテーブルMTおよびサブテーブルST
のいずれにも集計されていないことになる。
If a negative determination is made in step S23, the data on the host to be searched is stored in the main table MT and the sub table ST.
Are not counted in any of the above.

【0029】上記のように本実施の形態では、テーブル
の各行を一行ずつ順次、点検する検索法でなく、メイン
テーブルMTの相対行アドレスやインデックスを利用
し、テーブルの行を飛び飛びに点検していくので検索時
間を大幅に短縮化できる。
As described above, in the present embodiment, instead of the search method of sequentially checking each row of the table one line at a time, a relative row address or an index of the main table MT is used to check the rows of the table at intervals. The search time can be greatly reduced.

【0030】なお、本実施の形態は、MACアドレス毎
に各種データをそれぞれ集計し、その集計データをMA
Cアドレスで検索するものであるが、本願発明は、これ
に限定されず、MACアドレス以外の例えばIPアドレ
ス毎にデータを集計、検索するものに適用してもよい。
また、各種データを集計せず、メインテーブルMT、サ
ブテーブルSTにMACアドレス或いはIPアドレス等
を登録するだけのものにも適用可能なことは無論であ
る。
In this embodiment, various types of data are totaled for each MAC address, and the total
Although the search is performed using the C address, the present invention is not limited to this. The present invention may be applied to a device that aggregates and searches data for each IP address other than the MAC address, for example.
Further, it is needless to say that the present invention can be applied to the case where the MAC address or the IP address is simply registered in the main table MT and the sub table ST without collecting various data.

【0031】[0031]

【発明の効果】以上、詳述したように本願発明によれ
ば、格納されるデータの数が増加しても、そのデータの
検索時間が長くならないデータ配列のテーブルを作るテ
ーブル作成装置および当該テーブルからデータを短時間
で検索するテーブル検索装置の提供を可能とする。
As described above in detail, according to the present invention, even if the number of stored data is increased, a table creating apparatus for creating a table of a data array that does not increase the search time of the data, and the table It is possible to provide a table search device for searching data from a short time.

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

【図1】本願発明の実施の形態に係るネットワーク管理
装置の構成を示す図である。
FIG. 1 is a diagram showing a configuration of a network management device according to an embodiment of the present invention.

【図2】本願発明の実施の形態で作成されるテーブルの
構成を示す図である。
FIG. 2 is a diagram showing a configuration of a table created in an embodiment of the present invention.

【図3〜5】上記実施の形態での送信元ホストの送信回
数集計処理を示すフローチャートである。
FIG. 3 to FIG. 5 are flowcharts showing transmission number counting processing of a transmission source host in the above embodiment.

【図6】上記実施の形態での集計データの検索処理を示
すフローチャートである。
FIG. 6 is a flowchart showing a process of searching for total data in the embodiment.

【図7】従来のテーブル検索処理を説明するための図で
ある。
FIG. 7 is a diagram for explaining a conventional table search process.

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

1 ネットワーク管理装置 2 CPU 3 ROM 4 RAM 5 LANコントローラ 6 LANケーブル MA MACアドレスエリア DA 管理データエリア MT メインテーブル ST サブテーブル IA インデックスエリア Reference Signs List 1 network management device 2 CPU 3 ROM 4 RAM 5 LAN controller 6 LAN cable MA MAC address area DA management data area MT main table ST sub table IA index area

Claims (3)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】 順次送られてくるmビットデータ(ただ
し、mビットの全てが0となっているデータは除かれて
いる)を、後述のテーブル記憶手段内のテーブルに格納
していくテーブル作成装置であって、 それぞれその行を特定する行番号が与えられている2の
n(ただしn<m)乗個の行からなり、当該各行は、少
なくても、上記mビットデータが格納されるデータ格納
エリアと後述のインデックスが格納されるインデックス
エリアとを有するメインテーブルと、それぞれその行を
特定する行番号が与えられている多数(実際に利用され
る上記mビットデータの個数程度)の行からなり、当該
各行は、少なくても、上記mビットデータが格納される
データ格納エリアと後述のインデックスが格納されるイ
ンデックスエリアとを有するサブテーブルを備えている
テーブル記憶手段と、 上記mビットデータが送られてくる度に、送られてきた
当該mビットデータから、上位a(ただしaは予じめ定
められた0以上の数)ビットを除き、更に下位b(ただ
しbは予じめ定められている0以上の数)ビットを除い
て得られたn(従ってn=m−a−b)ビットデータを
読込み、当該nビットデータに対応する上記行番号を求
め、その上で当該行番号が与えられている上記メインテ
ーブル中の行のデータ格納エリアには、既に以前に送ら
れてきたmビットデータが格納されているか否かを判断
する第1判断手段と、 上記第1判断手段が否定的判断をしたときに、上記第1
判断手段の判断対象となったメインテーブル中の行のデ
ータ格納エリアに、今回送られてきたmビットデータを
格納する第1格納手段と、 上記第1判断手段が肯定的判断をしたときに、既に格納
されているmビットデータは、今回送られてきたmビッ
トデータと等しいデータか否かを判断する第2判断手段
と、 上記第2判断手段が否定的判断をしたときに、上記第1
判断手段の判断対象となったメインテーブル中の行の上
記インデックスエリアには、既にインデックスが格納さ
れているか否かを判断する第3判断手段と、 上記第3判断手段が否定的判断をしたときに、上記サブ
テーブル中の行で、未だ上記mビットデータが格納され
ていない行を見つけて、その行のデータ格納エリアに今
回送られてきたmビットデータを格納する第2格納手段
と、 上記第2格納手段が上記格納処理を終えたときに、当該
格納処理が行なわれたデータ格納エリアが属する行の行
番号を、上記第3判断手段の判断対象であったメインテ
ーブル中の行のインデックスエリアにインデックスとし
て格納する第3格納手段と、 上記第3判断手段が肯定的判断をしたときに、当該判断
対象となったメインテーブル中の行の上記インデックス
エリアにインデックスとして格納されていた行番号に基
づいて、当該行番号が与えられているサブテーブル中の
行を捜し、当該行のデータ格納エリアに既に格納されて
いるmビットデータは、今回送られてきたmビットデー
タと同一のデータか否かを判断する第4判断手段と、 上記第4判断手段が否定的判断をしたとき、又は後述の
第6判断手段が否定的判断をしたときに、それぞれ第4
判断手段又は第6判断手段の判断の対象となったサブテ
ーブル中の行のインデックスエリアにインデックスが格
納されているか否かを判断する第5判断手段と、 上記第5判断手段が肯定的判断をしたときに、判断の対
象となったインデックスエリアにインデックスとして格
納されているサブテーブルの行番号に基づき、当該行番
号が与えられているサブテーブル中の行を捜し、当該行
のデータ格納エリアに格納されているmビットデータ
は、今回送られてきたmビットデータと同一のデータか
否かを判断する第6判断手段と、 上記第5判断手段が否定的判断をしたときに、サブテー
ブル中の行でその行のデータ格納エリアに、未だmビッ
トデータが格納されていない行を捜し、当該行のデータ
格納エリアに今回送られてきたmビットデータを格納す
る第4格納手段と、 上記第4格納手段が上記格納処理を終えたときに、当該
第4格納手段による格納が行なわれたサブテーブル中の
行の行番号をインデックスとして、上記第5判断手段
が、直前に、判断の対象としたインデックスエリアに格
納する第5格納手段と、 を備えることを特徴とするテーブル作成装置。
1. A table for storing sequentially transmitted m-bit data (however, data in which all m bits are 0) is stored in a table in a table storage means described later. The apparatus is composed of 2 n (where n <m) power rows each having a row number specifying the row, and each row stores at least the m-bit data. A main table having a data storage area and an index area for storing an index described later, and a large number of rows (about the number of m-bit data actually used) each having a row number specifying the row. Each row includes at least a data storage area for storing the m-bit data and an index area for storing an index described later. A table storing means having a table, and each time the m-bit data is sent, the higher-order a (where a is a predetermined number of 0 or more) bits from the sent m-bit data , And read out n (thus n = mab) bit data obtained by excluding lower-order b (where b is a predetermined number of 0 or more) bits, and The corresponding row number is obtained, and the data storage area of the row in the main table to which the row number is given is used to determine whether or not the previously transmitted m-bit data is already stored. A first judging means for judging, the first judging means when the first judging means makes a negative judgment;
A first storage unit for storing the m-bit data transmitted this time in a data storage area of a row in the main table which has been determined by the determination unit; Second determining means for determining whether or not the already stored m-bit data is equal to the m-bit data transmitted this time; and when the second determining means makes a negative determination, the first
Third determining means for determining whether or not an index is already stored in the index area of the row in the main table which has been determined by the determining means; and when the third determining means makes a negative determination. A second storage means for finding a row in the sub-table in which the m-bit data is not yet stored, and storing the currently transmitted m-bit data in a data storage area of the row; When the second storage means has completed the storage processing, the row number of the row to which the data storage area in which the storage processing has been performed belongs is indicated by the index of the row in the main table which was determined by the third determination means. Third storage means for storing an index in the area; and when the third determination means makes a positive determination, the index of the row in the main table which is the determination target is determined. Based on the row number stored as an index in the index area, a row in the subtable to which the row number is assigned is searched, and the m-bit data already stored in the data storage area of the row is transmitted this time. A fourth determining means for determining whether or not the data is the same as the m-bit data received; when the fourth determining means makes a negative determination, or when a sixth determining means described later makes a negative determination, 4th each
A fifth determining means for determining whether or not an index is stored in an index area of a row in the sub-table which has been determined by the determining means or the sixth determining means; and the fifth determining means makes a positive determination. Then, based on the row number of the sub-table stored as an index in the index area subject to the determination, a row in the sub-table given the row number is searched, and the data is stored in the data storage area of the row. Sixth determining means for determining whether or not the stored m-bit data is the same data as the m-bit data transmitted this time; and when the fifth determining means makes a negative determination, In the row where no m-bit data is stored yet in the data storage area of the row, and the m-bit data transmitted this time to the data storage area of the row. A fourth storage unit for storing, and when the fourth storage unit has completed the storage processing, the fifth determination is performed by using, as an index, a row number of a row in the sub-table that has been stored by the fourth storage unit. Means for storing immediately before in the index area subject to the determination, a fifth storage means.
【請求項2】 上記第1格納手段が格納処理を終えたと
きに、当該格納に応じた所定の処理を実行する第1処理
手段と、 上記第2判断手段が肯定的判断をしたときに、既に格納
されているmビットデータと同一のデータが更にもう一
度送られてきたことに応じた所定の処理を実行する第2
処理手段と、 上記第3格納手段が上記格納処理を終えたときに、上記
第2格納手段による処理に応じた所定の処理を実行する
第3処理手段と、 上記第4判断手段が肯定的判断をしたときに、すでに格
納されているmビットデータと同一のデータが更にもう
一度送られてきたことに応じた所定の処理を実行する第
4処理手段と、 上記第6判断手段が肯定的判断をしたときに、既に格納
されているmビットデータと同一のデータが更にもう一
度送られてきたことに応じた所定の処理を実行する第5
処理手段と、 上記第5格納手段による格納処理が終了したときに、当
該格納に応じた所定の処理を実行する第6処理手段と、 を備えることを特徴とする請求項1記載のテーブル作成
装置。
2. When the first storage means completes a storage process, a first processing means for executing a predetermined process according to the storage, and when the second determination means makes a positive determination, A second process for executing a predetermined process in response to the same data as the already stored m-bit data being sent once more
Processing means; third processing means for executing predetermined processing according to processing by the second storage means when the third storage means has completed the storage processing; and affirmative determination by the fourth determination means The fourth processing means for executing a predetermined process in response to the same data as the already stored m-bit data being sent again, and the sixth determination means making a positive determination. Then, a predetermined process corresponding to the fact that the same data as the already stored m-bit data has been sent again is executed.
2. The table creating apparatus according to claim 1, further comprising: a processing unit; and a sixth processing unit configured to execute a predetermined process according to the storage when the storage process by the fifth storage unit is completed. .
【請求項3】 上記請求項1又は請求項2記載のテーブ
ル作成装置で作成されたテーブルと同一のデータ配列に
なっているテーブルから当該テーブルに格納されている
特定のmビットデータを検索するテーブル検索装置であ
って、 検索すべきmビットデータが指定される度に、当該mビ
ットデータに係る前記nビットデータを読込み、当該n
ビットデータに対応する前記行番号が与えられているメ
インテーブル中の行の前記データ格納エリアには、検索
すべきmビットデータが格納されているか否かを判断す
る格納データ判別手段と、 上記格納データ判別手段が否定的判断をしたときに又は
後述のデータ格納済判断手段が否定的判断をしたとき
に、先の判断で判別対象としたデータ格納エリアの属す
る行のインデックスエリアには、インデックスが格納さ
れているか否かを判断するインデックス格納済判断手段
と、 上記インデックス格納判断手段が肯定的判断をしたとき
に、当該インデックス格納判断手段が判断対象としたイ
ンデックスエリアに格納されているインデックスに対応
する行番号が与えられているサブテーブル中の行には、
検索すべきmビットデータが格納されているかを判断す
るデータ格納済判断手段と、 上記格納データ判別手段が肯定的判断をしたとき又は上
記データ格納済判断手段が肯定的判断をしたときに、検
索すべきmビットデータを検索できたときに行なう所定
の処理を実行する所定処理実行手段と、 を備えることを特徴とするテーブル検索装置。
3. A table for retrieving specific m-bit data stored in a table having the same data array as a table created by the table creating apparatus according to claim 1 or 2. A search device that reads the n-bit data related to the m-bit data each time the m-bit data to be searched is specified;
Storage data determining means for determining whether or not m-bit data to be searched is stored in the data storage area of a row in the main table to which the row number corresponding to the bit data is assigned; When the data discriminating unit makes a negative judgment, or when the data storage judging unit described later makes a negative judgment, the index is set in the index area of the row to which the data storage area that has been judged in the previous judgment belongs. An index storage determining unit for determining whether or not the index is stored; and an index stored in the index area determined by the index storage determining unit when the index storage determining unit makes a positive determination. The row in the subtable given the row number
A data storage completion determining means for determining whether or not m-bit data to be searched is stored; and a search when the stored data determination means makes a positive determination or the data storage completion determination means makes a positive determination. A predetermined process executing means for executing a predetermined process to be performed when m-bit data to be retrieved can be retrieved.
JP32887098A 1998-11-04 1998-11-04 Table creation search device Expired - Fee Related JP3292241B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP32887098A JP3292241B2 (en) 1998-11-04 1998-11-04 Table creation search device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP32887098A JP3292241B2 (en) 1998-11-04 1998-11-04 Table creation search device

Publications (2)

Publication Number Publication Date
JP2000151617A JP2000151617A (en) 2000-05-30
JP3292241B2 true JP3292241B2 (en) 2002-06-17

Family

ID=18215023

Family Applications (1)

Application Number Title Priority Date Filing Date
JP32887098A Expired - Fee Related JP3292241B2 (en) 1998-11-04 1998-11-04 Table creation search device

Country Status (1)

Country Link
JP (1) JP3292241B2 (en)

Also Published As

Publication number Publication date
JP2000151617A (en) 2000-05-30

Similar Documents

Publication Publication Date Title
US6751627B2 (en) Method and apparatus to facilitate accessing data in network management protocol tables
EP2159708A1 (en) Method for selecting hash function, method for storing and searching routing table and devices thereof
US20010028651A1 (en) Cache table management device for router and program recording medium thereof
WO1988006822A1 (en) Distributed local-area-network monitoring system
CN102739520B (en) Checking method and checking device
JP4059388B2 (en) Apparatus and method for identifying protocol pattern in protocol data unit
KR101411321B1 (en) Method and apparatus for managing neighbor node having similar characteristic with active node and computer readable medium thereof
US20030223456A1 (en) Apparatus and method for steering a communication to an open stream
JP2000196672A (en) Inter-network repeater
JP3292241B2 (en) Table creation search device
JPH10210066A (en) Data base for judging internet work repeating destination and method for constructing data base
CN109039911B (en) Method and system for sharing RAM based on HASH searching mode
JP4890916B2 (en) Management method of communication apparatus connected to network, apparatus recognition apparatus, and computer program
CN107870925B (en) Character string filtering method and related device
US7159019B2 (en) Information collection apparatus and method
JP4048861B2 (en) Address search device
JP2000209216A (en) Address management method and device, and recording medium thereof
JP2005051661A (en) Wireless lan terminal
CA2064957A1 (en) Method and apparatus for performing pattern search functions
KR100378599B1 (en) Routing Table Lookup Using Indirected RAM Indexing
JP3570606B2 (en) Data retrieval apparatus and method
JPH0669928A (en) Routing system
JP2003036269A (en) Information processor, information processing method, and recording medium recorded with information processing program
JPH0832613A (en) Retrieval device for route selection information
CN109818861A (en) Realize the method and device of message flooding

Legal Events

Date Code Title Description
LAPS Cancellation because of no payment of annual fees