JP6148546B2 - Packet transfer apparatus and program - Google Patents

Packet transfer apparatus and program Download PDF

Info

Publication number
JP6148546B2
JP6148546B2 JP2013126102A JP2013126102A JP6148546B2 JP 6148546 B2 JP6148546 B2 JP 6148546B2 JP 2013126102 A JP2013126102 A JP 2013126102A JP 2013126102 A JP2013126102 A JP 2013126102A JP 6148546 B2 JP6148546 B2 JP 6148546B2
Authority
JP
Japan
Prior art keywords
packet
interface
information
flow identifier
value
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
JP2013126102A
Other languages
Japanese (ja)
Other versions
JP2015002437A (en
Inventor
延孝 松本
延孝 松本
林 通秋
通秋 林
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
KDDI Corp
Original Assignee
KDDI Corp
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 KDDI Corp filed Critical KDDI Corp
Priority to JP2013126102A priority Critical patent/JP6148546B2/en
Publication of JP2015002437A publication Critical patent/JP2015002437A/en
Application granted granted Critical
Publication of JP6148546B2 publication Critical patent/JP6148546B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Description

本発明は、複数のインタフェースを有するパケット転送装置における受信パケットの転送技術に関する。   The present invention relates to a transfer technique for received packets in a packet transfer apparatus having a plurality of interfaces.

ネットワークの制御として、オープンフロー技術が注目されている。オープンフロー技術を利用したネットワークにおいて、フローは、例えば、MACアドレス、IPアドレス、ポート番号等の組み合わせで識別され、フロー毎に品質(QoS)制御や経路制御が行われる。オープンフロー・ネットワークでパケットの転送を行うパケット転送装置は、入力パケットのヘッダ情報等からフロー識別子を判定し、判定したフロー識別子と、フロー・テーブルとに基づき当該パケットを出力すべきインタフェースを決定する。例えば、フロー識別子が、送信元及び送信先IPアドレスと、送信元及び送信先ポート番号の組み合わせで特定される場合、これら4つの値を所定順に並べた値がフロー識別子となる。   Open flow technology has attracted attention as a network control. In a network using OpenFlow technology, a flow is identified by a combination of a MAC address, an IP address, a port number, and the like, and quality (QoS) control and path control are performed for each flow. A packet transfer apparatus that transfers a packet in an OpenFlow network determines a flow identifier from header information of an input packet, and determines an interface to output the packet based on the determined flow identifier and a flow table. . For example, when the flow identifier is specified by a combination of a source and destination IP address and a source and destination port number, a value obtained by arranging these four values in a predetermined order is the flow identifier.

なお、フロー・テーブルの各エントリは、ワイルドカード、つまり、フロー識別子の一部又は全部が任意の値となることを許容しているため、1つのフロー識別子が、フロー・テーブル内の複数のエントリと一致することが生じ得る。例えば、フロー識別子が、送信元及び送信先IPアドレスと、送信元及び送信先ポート番号の組み合わせで特定され、図5に示すフロー・テーブルが、パケット転送装置に設定されている場合を考える。なお、図5の"*"は、ワイルドカードであり、フロー識別子の該当する位置の値が任意の値で良いことを示している。また、番号1のエントリは、ディフォルト経路であり、総てのフロー識別子と一致するエントリである。ここで、例えば、送信元IPアドレスが、(X1、X2、X3、X4)であり、送信先IPアドレスが(Y1、Y2、Y3、Y4)のパケットを受信した場合、この受信パケットは、フロー・テーブルの番号1、100、101及び102の4つのエントリと一致することになる。フロー・テーブルの各エントリには優先順位が付与されており、フロー識別子が複数のエントリに一致する場合、最も優先順位の高いエントリに従い出力インタフェースが決定される。例えば、番号1、100、101及び102の4つのエントリのうち、最も優先順位の高いものが番号102のエントリである場合、この受信パケットは、インタフェースIF#3に出力されることになる。   Note that each entry in the flow table is a wild card, that is, it allows a part or all of the flow identifiers to have an arbitrary value, so that one flow identifier has a plurality of entries in the flow table. Can occur to match. For example, consider a case where a flow identifier is specified by a combination of a source and destination IP address and a source and destination port number, and the flow table shown in FIG. 5 is set in the packet transfer apparatus. Note that “*” in FIG. 5 is a wild card and indicates that the value of the corresponding position of the flow identifier may be an arbitrary value. The entry with the number 1 is a default route and is an entry that matches all the flow identifiers. Here, for example, when a packet with a transmission source IP address (X1, X2, X3, X4) and a transmission destination IP address (Y1, Y2, Y3, Y4) is received, Matches the four entries of table numbers 1, 100, 101 and 102. Each entry in the flow table is given a priority. When the flow identifier matches a plurality of entries, the output interface is determined according to the entry with the highest priority. For example, if the entry with the highest priority among the four entries with the numbers 1, 100, 101, and 102 is the entry with the number 102, this received packet is output to the interface IF # 3.

上記の通り、ワイルドカードを許容するフロー・テーブルでは、一致するエントリが複数存在し得るため、一致するエントリの検索と、優先順位の判定に時間がかかるという問題がある。このため、非特許文献1は、ワイルドカードを許容するフロー・テーブル(以下、ワイルドカード型テーブルと呼ぶ。)と、ワイルドカードを使用せず、フロー識別子と出力インタフェースとの関係を示すフロー・テーブル(以下、完全一致型テーブルと呼ぶ。)を設ける構成を開示している。具体的には、非特許文献1は、パケットを受信した場合、まず、完全一致型テーブルにより出力インタフェースを決定し、完全一致型テーブルにエントリが無く、したがって、完全一致型テーブルでは出力インタフェースを決定できない場合に、ワイルドカード型テーブルにより出力インタフェースを決定すると共に、決定した出力インタフェースと受信したパケットのフロー識別子との対応関係を、完全一致型テーブルに追加することを開示している。   As described above, in a flow table that allows wildcards, there may be a plurality of matching entries, and thus there is a problem that it takes time to search for matching entries and to determine priority. For this reason, Non-Patent Document 1 discloses a flow table that permits wild cards (hereinafter referred to as a wild card type table) and a flow table that indicates the relationship between a flow identifier and an output interface without using wild cards. (Hereinafter referred to as an exact match table) is disclosed. Specifically, when Non-Patent Document 1 receives a packet, first, the output interface is determined based on the exact match type table, and there is no entry in the complete match type table. Therefore, the output interface is determined based on the exact match type table. In the case where the output interface is not determined, the output interface is determined by the wild card type table, and the correspondence between the determined output interface and the flow identifier of the received packet is added to the exact match type table.

この構成により、新たなフローに属するパケットが到着した段階では、検索速度の遅いワイルドカード型テーブルが使用されるが、その後、完全一致型テーブルにエントリが追加されると、検索速度の速い完全一致型テーブルにより出力インタフェースが決定されるので、全体としての検索速度が速くなる。   With this configuration, when a packet belonging to a new flow arrives, a wildcard type table with a slow search speed is used. However, when an entry is added to the exact match type table, a perfect match with a fast search speed is complete. Since the output interface is determined by the type table, the overall search speed is increased.

N.Matsumoto,et al.,"LightFlow:Speeding Up GPU−based Flow Switching and Facilitating Maintenance of Flow Table",HPSR2012N. Matsumoto, et al. , "LightFlow: Speeding Up GPU-based Flow Switching and Fatiguing Maintenance of Flow Table", HPSR 2012

しかしながら、非特許文献1に記載の構成においては同じフローに属するパケットの出力順序が、入力順序とは異なることが生じ得る。例えば、図6に示す様に、同一のフローに属するパケットA、B、C、D及びEをその記載順で受信したものとする。なお、このフローのフロー識別子に対するエントリは、完全一致型テーブルには存在しないものとする。第1決定部は、完全一致型テーブルでは出力インタフェースを決定できないため、このフローに属するパケットを、ワイルドカード型テーブルにより出力インタフェースを決定する第2決定部に出力する。ここで、最初に第2決定部に出力されたパケットAの出力インタフェースを第2決定部が決定し、その結果が完全一致型テーブルに反映されるまでに、パケットB、Cも第2決定部に出力されたものとする。   However, in the configuration described in Non-Patent Document 1, the output order of packets belonging to the same flow may be different from the input order. For example, as shown in FIG. 6, it is assumed that packets A, B, C, D and E belonging to the same flow are received in the order of description. It is assumed that the entry for the flow identifier of this flow does not exist in the complete match type table. Since the first determination unit cannot determine the output interface in the exact match type table, the first determination unit outputs the packet belonging to this flow to the second determination unit that determines the output interface based on the wild card type table. Here, until the second determining unit determines the output interface of the packet A first output to the second determining unit and the result is reflected in the complete match type table, the packets B and C are also the second determining unit. Is output.

この場合、その後のパケットD、Eは、検索速度の速い完全一致型テーブルにより出力インタフェースが決定されるため、図6に示す様に、パケットB、CよりパケットD、Eが先に出力され、入力順序とは異なる順序で同一フローに属するパケットが出力されることが生じ得る。   In this case, since the output interface of the subsequent packets D and E is determined by the complete match type table with a high search speed, the packets D and E are output before the packets B and C as shown in FIG. It may occur that packets belonging to the same flow are output in an order different from the input order.

本発明は、出力するインタフェースを決定するための時間が長くなることを防ぎつつ、同一フローに属するパケットを入力順序と同一順序で出力するパケット転送装置を提供するものである。   The present invention provides a packet transfer apparatus that outputs packets belonging to the same flow in the same order as the input order while preventing an increase in the time for determining an interface to output.

本発明の一側面によると、複数のインタフェースを有するパケット転送装置であって、フロー識別子とインタフェースの関係を示す第1情報と、フロー識別子の部分とインタフェースの関係を示す第2情報を保持する保持手段と、受信した第1パケットのヘッダ情報に基づき前記第1パケットのフロー識別子を判定する判定手段と、前記第1パケットのフロー識別子と前記第1情報に基づき前記第1パケットを出力するインタフェースを決定し、決定したインタフェースから前記第1パケットを出力させる第1決定手段と、前記第1決定手段が前記第1パケットを出力するインタフェースを決定できない場合、前記第1パケットのフロー識別子と前記第2情報に基づき前記第1パケットを出力するインタフェースを決定し、決定したインタフェースから前記第1パケットを出力させる第2決定手段と、前記第2決定手段が前記第1パケットを出力するインタフェースを決定した場合、前記第1パケットのフロー識別子と前記第2決定手段が決定したインタフェースとの関係を前記第1情報に追加する様に更新する更新手段と、を備えており、前記第1決定手段は、前記第1情報により前記第1パケットを出力するインタフェースを決定できない場合、前記第1パケットの受信後、前記更新手段が前記第1情報を更新するまでに受信した前記第1パケットと同じフロー識別子の第2パケットについては、前記第2決定手段に出力するインタフェースを決定させず、前記第2決定手段が前記第1パケットを出力するインタフェースを決定して出力させた後に、当該インタフェースから出力させることを特徴とする。 According to one aspect of the present invention, a packet transfer apparatus having a plurality of interfaces, which holds first information indicating a relationship between a flow identifier and an interface, and second information indicating a relationship between a flow identifier portion and an interface Means for determining the flow identifier of the first packet based on the received header information of the first packet; and an interface for outputting the first packet based on the flow identifier of the first packet and the first information. A first determination unit that determines and outputs the first packet from the determined interface; and when the first determination unit cannot determine an interface that outputs the first packet, the flow identifier of the first packet and the second An interface for outputting the first packet is determined based on the information, and the determined interface is determined. Second decision means for outputting the first packet from the source, and when the second decision means decides the interface for outputting the first packet, the flow identifier of the first packet and the second decision means decide Updating means for updating the relationship with the interface so as to be added to the first information, and the first determining means cannot determine an interface for outputting the first packet based on the first information. The second packet having the same flow identifier as the first packet received before the update unit updates the first information after receiving the first packet determines an interface to be output to the second determination unit. let not, after the second determining means is allowed to output to determine the interface that outputs the first packet, out of the relevant interface Characterized in that to.

出力するインタフェースを決定するための時間が長くなることを防ぎつつ、同一フローに属するパケットを入力順序と同一順序で出力することができる。   Packets belonging to the same flow can be output in the same order as the input order while preventing the time for determining the output interface from becoming long.

一実施形態によるパケット転送装置の概略的な構成図。1 is a schematic configuration diagram of a packet transfer device according to an embodiment. FIG. 一実施形態による完全一致型テーブルを示す図。The figure which shows the exact match type | mold table by one Embodiment. 一実施形態によるワイルドカード型テーブルを示す図。The figure which shows the wild card type table by one Embodiment. 一実施形態による待機パケットテーブルを示す図。The figure which shows the waiting | standby packet table by one Embodiment. 一実施形態によるワイルドカード型テーブルを示す図。The figure which shows the wild card type table by one Embodiment. パケット順序の入れ替わりの説明図。Explanatory drawing of a change of packet order.

以下、本発明の例示的な実施形態について図面を参照して説明する。なお、以下の各図においては、実施形態の説明に必要ではない構成要素については図から省略する。   Hereinafter, exemplary embodiments of the present invention will be described with reference to the drawings. In the following drawings, components that are not necessary for the description of the embodiments are omitted from the drawings.

図1は、本実施形態によるパケット転送装置の概略的な構成図である。パケット転送装置1は、複数のインタフェースを有し、各インタフェースで受信したパケットをバッファ部10に保存する。フロー判定部11は、受信パケットのヘッダ情報から当該受信パケットが属するフローのフロー識別子を判定し、判定したフロー識別子11と、当該受信パケットのバッファ部10での保存位置を第1決定部12に出力する。本実施形態では、フロー識別子は、受信パケットが入力されたインタフェースと、受信パケットのヘッダ情報に含まれる送信元及び送信先MACアドレス、送信元及び送信先IPアドレス、送信元及び送信先ポート番号との組み合わせとする。なお、MACアドレスとは、レイヤ2アドレスであり、IPアドレスとはレイヤ3アドレスである。しかしながら、フロー識別子に使用する情報は、上記情報の一部であっても良い。さらに、上記情報の総て又は一部と、他の値、例えば、VLAN(仮想ローカル・エリア・ネットワーク)の識別子等を使用しても良い。   FIG. 1 is a schematic configuration diagram of a packet transfer apparatus according to the present embodiment. The packet transfer apparatus 1 has a plurality of interfaces, and stores packets received by each interface in the buffer unit 10. The flow determination unit 11 determines the flow identifier of the flow to which the received packet belongs from the header information of the received packet, and stores the determined flow identifier 11 and the storage position of the received packet in the buffer unit 10 in the first determination unit 12. Output. In this embodiment, the flow identifier includes an interface to which a received packet is input, a source and destination MAC address, a source and destination IP address, a source and destination port number included in the header information of the received packet. A combination of The MAC address is a layer 2 address, and the IP address is a layer 3 address. However, the information used for the flow identifier may be a part of the information. Further, all or a part of the information and other values such as a VLAN (virtual local area network) identifier may be used.

パケット転送装置の図示しない保持部は、完全一致型テーブル16と、ワイルドカード型テーブル17を保持している。なお、ワイルドカード型テーブル17は、上述した様に、フロー識別子の部分と出力すべきインタフェースの関係を示すエントリを含むもの、つまり、フロー識別子の部分一致により出力すべきインタフェースを決定するための情報である。なお、ここでの部分一致とは、全く一致しない場合、つまり、ディフォルト経路を含むものとする。図3に本実施形態のワイルドカード型テーブル17の例を示す。なお、図3において番号1のエントリはディフォルト経路である。例えば、インタフェース#5で、送信元IPアドレスが、(X1、X2、X3、X4)であり、送信先IPアドレスが(Y1、Y2、Y3、Y4)のパケットを受信した場合、この受信パケットは、番号1、100から103の5つのエントリに該当することになる。例えば、この5つのエントリの中で優先順位が一番高いものが番号102のエントリであると、この受信パケットは、インタフェースIF#3から出力される。なお、ワイルドカード型テーブル17は、パケット転送装置の運用者が設定、或いは、フローの設定を示す他の装置からのシグナリングにより生成される。   A holding unit (not shown) of the packet transfer apparatus holds a complete match type table 16 and a wild card type table 17. As described above, the wild card type table 17 includes an entry indicating the relationship between the flow identifier portion and the interface to be output, that is, information for determining an interface to be output by partial matching of the flow identifier. It is. Note that the partial match here includes a case where there is no match at all, that is, a default route is included. FIG. 3 shows an example of the wild card type table 17 of the present embodiment. In FIG. 3, the entry of number 1 is the default route. For example, when the interface # 5 receives a packet whose source IP address is (X1, X2, X3, X4) and whose destination IP address is (Y1, Y2, Y3, Y4), the received packet is , Numbers 1, 100 to 103 correspond to the five entries. For example, if the highest priority among the five entries is the entry with the number 102, this received packet is output from the interface IF # 3. The wild card type table 17 is set by the operator of the packet transfer apparatus or generated by signaling from another apparatus indicating the flow setting.

一方、完全一致型テーブル16は、フロー識別子と、出力すべきインタフェースとの関係を示すエントリを含むもの、つまり、フロー識別子の完全一致により出力すべきインタフェースを決定するための情報である。図2に本実施形態の完全一致型テーブル16の例を示す。なお、本実施形態においては、一致するエントリの検索を高速化するために、フロー識別子そのものの値と、出力すべきインタフェースとの関係を示すのではなく、フロー識別子のハッシュ関数によるハッシュ値とインタフェースの関係を示すものとしている。つまり、完全一致型テーブル16はハッシュ・テーブルである。なお、異なるフロー識別子が同じハッシュ値になることが確率的に存在するため、本実施形態においては、フロー識別子そのものの値も完全一致型テーブル16に含め、検索後の確認に使用する。さらに、本実施形態において、完全一致型テーブル16は、状態フィールドを有している。この状態フィールドは、"A"、"B"、"C"の3つの値を有する。   On the other hand, the complete match type table 16 includes an entry indicating the relationship between the flow identifier and the interface to be output, that is, information for determining an interface to be output by the complete match of the flow identifier. FIG. 2 shows an example of the exact match type table 16 of the present embodiment. In the present embodiment, in order to speed up the search for matching entries, the relationship between the value of the flow identifier itself and the interface to be output is not shown, but the hash value by the hash function of the flow identifier and the interface The relationship is shown. That is, the exact match table 16 is a hash table. Since there is a probability that different flow identifiers have the same hash value, in this embodiment, the value of the flow identifier itself is also included in the exact match type table 16 and used for confirmation after the search. Furthermore, in this embodiment, the exact match type table 16 has a status field. This status field has three values “A”, “B”, and “C”.

なお、値"A"は、フロー識別子とインタフェースの対応関係を完全一致型テーブル16は有し、よって、完全一致型テーブル16により当該フロー識別子が示すフローに属するパケットの出力インタフェースを決定できることを示している。また、値"B"は、フロー識別子とインタフェースの対応関係が完全一致型テーブル16には含まれておらず、よって、完全一致型テーブル16により当該フロー識別子が示すフローに属するパケットの出力インタフェースを決定できないことを示している。さらに、値"C"は、フロー識別子とインタフェースの対応関係が完全一致型テーブル16には現在含まれていないが、当該フロー識別子とインタフェースの対応関係が完全一致型テーブル16に追加されることを待っている状態であることを示している。例えば、図2の完全一致型テーブル16においては、ハッシュ値がH2及びH100であるフロー識別子の状態フィールドの値は"A"であり、インタフェースIF#2及びIF#1が出力先であることが示されている。これに対して、その状態フィールドの値が"B"及び"C"である、ハッシュ値がH1及びH3であるフロー識別子については、その出力先が示されていない。なお、完全一致型テーブル16へのエントリの追加、削除等の完全一致型テーブル16の更新は、テーブル管理部14が後述する様に行う。   The value “A” indicates that the exact match table 16 has a correspondence relationship between the flow identifier and the interface, and therefore, the output interface of the packet belonging to the flow indicated by the flow identifier can be determined by the exact match table 16. ing. Further, the value “B” does not include the correspondence between the flow identifier and the interface in the exact match table 16, and therefore, the output interface of the packet belonging to the flow indicated by the flow identifier by the exact match table 16. Indicates that it cannot be determined. Further, the value “C” indicates that the correspondence between the flow identifier and the interface is not currently included in the exact match table 16, but the correspondence between the flow identifier and the interface is added to the exact match table 16. It shows that it is waiting. For example, in the exact match table 16 of FIG. 2, the value of the status field of the flow identifier whose hash values are H2 and H100 is “A”, and the interfaces IF # 2 and IF # 1 are output destinations. It is shown. On the other hand, the output destination is not shown for the flow identifiers whose state field values are “B” and “C” and whose hash values are H1 and H3. Note that the update of the complete match type table 16 such as addition and deletion of entries to the complete match type table 16 is performed by the table management unit 14 as described later.

第1決定部12は、フロー判定部11からフロー識別子等の情報を受け取ると、完全一致型テーブル16の状態フィールドから、当該フロー識別子に対応する受信パケットの出力インタフェースを完全一致型テーブル16により決定できるかを判定する。決定できる場合、つまり、当該フロー識別子に対応するエントリの状態フィールドが"A"である場合、第1決定部12は、当該フロー識別子に対応する受信パケットの出力インタフェースを完全一致型テーブル16により決定し、決定した出力インタフェースと、受信パケットのバッファ部10での保存位置を示す出力情報を読出部15に出力する。これに対して、当該フロー識別子に対応するエントリの状態フィールドが"B"である場合、第1決定部12は、フロー判定部11から受け取ったフロー識別子等の情報を第2決定部13に出力する。また、このとき、第1決定部12は、状態フィールドが"B"であるフロー識別子を受け取ったことをテーブル管理部14に通知し、テーブル管理部14は、完全一致型テーブル16の当該フロー識別子に対応するエントリの状態フィールドの値を"C"に変更する。   When receiving information such as a flow identifier from the flow determination unit 11, the first determination unit 12 determines the output interface of the received packet corresponding to the flow identifier from the state field of the complete match type table 16 using the complete match type table 16. Determine if you can. If it can be determined, that is, if the status field of the entry corresponding to the flow identifier is “A”, the first determination unit 12 determines the output interface of the received packet corresponding to the flow identifier by the exact match table 16. Then, output information indicating the determined output interface and the storage position of the received packet in the buffer unit 10 is output to the reading unit 15. On the other hand, when the status field of the entry corresponding to the flow identifier is “B”, the first determination unit 12 outputs the information such as the flow identifier received from the flow determination unit 11 to the second determination unit 13. To do. At this time, the first determination unit 12 notifies the table management unit 14 that the flow identifier whose status field is “B” has been received, and the table management unit 14 then determines the flow identifier of the exact match table 16. The value of the status field of the entry corresponding to is changed to “C”.

第2決定部13は、第1決定部12からフロー識別子等の情報を受け取ると、ワイルドカード型テーブル17により、当該フロー識別子に対応する受信パケットの出力インタフェースを決定し、決定した出力インタフェースと、受信パケットのバッファ部10での保存位置を示す出力情報を読出部15に出力する。また、このとき、第2決定部13は、テーブル管理部14に、当該フロー識別子と決定した出力インタフェースとの関係を通知する。テーブル管理部14は、第2決定部13から通知されたフロー識別子に対応する、完全一致型テーブル16のエントリの出力インタフェースのフィールドに、第2決定部13から通知されたインタフェースを追加し、さらに、当該エントリの状態フィールドを"C"から"A"に変更する。また、この更新を、第1決定部12に通知する。   When receiving information such as a flow identifier from the first determination unit 12, the second determination unit 13 determines an output interface of a received packet corresponding to the flow identifier using the wild card type table 17, and determines the determined output interface; Output information indicating the storage position of the received packet in the buffer unit 10 is output to the reading unit 15. At this time, the second determination unit 13 notifies the table management unit 14 of the relationship between the flow identifier and the determined output interface. The table management unit 14 adds the interface notified from the second determination unit 13 to the output interface field of the entry of the exact match table 16 corresponding to the flow identifier notified from the second determination unit 13, and The status field of the entry is changed from “C” to “A”. In addition, this update is notified to the first determination unit 12.

第1決定部12は、フロー判定部11から受け取ったフロー識別子に対応する、完全一致型テーブル16のエントリの状態フィールドが"C"である場合、フロー判定部11から受け取ったフロー識別子とバッファ部10の保存位置を待機パケットテーブル18として保存する。図4に待機パケットテーブル18の例を示す。待機パケットテーブル18は、フロー識別子毎に、対応するパケットのバッファ部10への保存位置を、その受信順序と共に示すものである。なお、本実施形態においては、完全一致型テーブル16と同様に、フロー識別子そのものの値ではなく、そのハッシュ値を使用する。例えば、図4においては、ハッシュ値がH1であるフロー識別子に属するパケットを、当該フロー識別子に対応する完全一致型テーブル16のエントリの状態フィールドが"C"となった後に4つ受け取り、最初に受け取ったパケットがバッファ部10の位置P1に、2番目に受け取ったパケットがバッファ部10の位置P4に、3番目に受け取ったパケットがバッファ部10の位置P8に、4番目に受け取ったパケットがバッファ部10の位置P20に保持されていることが示されている。   When the status field of the entry in the exact match table 16 corresponding to the flow identifier received from the flow determination unit 11 is “C”, the first determination unit 12 receives the flow identifier and the buffer unit from the flow determination unit 11 The ten storage positions are stored as the standby packet table 18. FIG. 4 shows an example of the standby packet table 18. The standby packet table 18 indicates the storage position of the corresponding packet in the buffer unit 10 for each flow identifier together with the reception order. In the present embodiment, as in the exact match table 16, the hash value is used instead of the value of the flow identifier itself. For example, in FIG. 4, four packets belonging to the flow identifier whose hash value is H1 are received after the state field of the entry of the exact match type table 16 corresponding to the flow identifier becomes “C”. The received packet is at position P1 of the buffer unit 10, the second received packet is at position P4 of the buffer unit 10, the third received packet is at position P8 of the buffer unit 10, and the fourth received packet is buffered. It is shown that the part 10 is held at the position P20.

第1決定部12は、テーブル管理部14が完全一致型テーブル16にフロー識別子に対応する出力インタフェースを追加すると、待機パケットテーブルの当該フロー識別子に対応するエントリに示されるパケットについて、その出力インタフェースと保存位置を含む出力情報を、その受信順に読出部15に出力する。つまり、図4のハッシュ値H1に対応する完全一致型テーブル16のエントリに、出力インタフェースが追加された場合、第1決定部12は、保存位置P1、P4、P8、P20の順で、その出力インタフェースを読出部15に通知する。なお、第1決定部12は、読出部15に通知する出力インタフェースを、テーブル管理部14又は第2決定部13から受け取る。或いは、第1決定部12が、完全一致型テーブル16のテーブル管理部14による更新後に、完全一致型テーブル16を検索して取得しても良い。読出部15は、第1決定部12及び第2決定部13からの出力情報に従い、バッファ部10からパケットをその通知順に読み出して、出力情報で指定されるインタフェースに読み出したパケットを出力する。   When the table management unit 14 adds the output interface corresponding to the flow identifier to the exact match type table 16, the first determination unit 12 sets the output interface for the packet indicated in the entry corresponding to the flow identifier in the standby packet table. The output information including the storage position is output to the reading unit 15 in the order of reception. That is, when an output interface is added to the entry of the exact match type table 16 corresponding to the hash value H1 in FIG. 4, the first determination unit 12 outputs the output in the order of the storage positions P1, P4, P8, and P20. The interface is notified to the reading unit 15. The first determination unit 12 receives an output interface to be notified to the reading unit 15 from the table management unit 14 or the second determination unit 13. Alternatively, the first determination unit 12 may search and acquire the exact match table 16 after the exact match table 16 is updated by the table management unit 14. The reading unit 15 reads packets from the buffer unit 10 in the order of notification in accordance with the output information from the first determination unit 12 and the second determination unit 13, and outputs the read packets to the interface specified by the output information.

以上、新規のフローに属するパケットが到達した場合、その最初のパケットのみが第2決定部13により出力インタフェースの決定が行われ、その後に受信する当該フローに属するパケットについては、第2決定部13が出力インタフェースを決定するまでバッファ部10において保持される。また、その際、受信順序を示す情報として、待機パケットテーブル18を作成して保持しておく。そして、これらバッファ部10に保持されたパケットは、第2決定部13が出力インタフェースを決定すると、その受信順序に従いバッファ部10から読み出されて決定した出力インタフェースに送信される。さらに、それ以後の当該フローに属するパケットについては、第1決定部12が出力インタフェースを決定する。よって、速度の遅い第2決定部13による出力インタフェースの決定は、各フローの最初のパケットのみであり、それ以後のパケットについては、速度の速い第1決定部12が出力インタフェースの決定を行うため、全体としての出力インタフェースの決定速度を短くできる。さらに、同じフローのパケットの出力順序が入力順序と異なることを防ぐことができる。本実施形態においては、第1決定部12によるテーブルの検索処理と、第2決定部13によるテーブルの検索処理を同期させる必要がなく、簡易な回路構成とすることができる。また、第2決定部13が出力インタフェースを決定するまで、バッファ部10に保持されるのは、第2決定部13が出力インタフェースを決定しているフローに属するパケットのみであり、他のフローに属するパケットは影響を受けない。   As described above, when a packet belonging to a new flow arrives, only the first packet is subjected to the determination of the output interface by the second determination unit 13, and the second determination unit 13 Is held in the buffer unit 10 until an output interface is determined. At this time, a standby packet table 18 is created and held as information indicating the reception order. Then, when the second determination unit 13 determines the output interface, the packets held in the buffer unit 10 are read from the buffer unit 10 according to the reception order and transmitted to the determined output interface. Further, for the packets belonging to the flow after that, the first determination unit 12 determines the output interface. Accordingly, the output interface is determined only by the first packet of each flow by the second determination unit 13 having a low speed, and the first determination unit 12 having a high speed determines the output interface for the subsequent packets. As a result, the determination speed of the output interface as a whole can be shortened. Furthermore, it is possible to prevent the output order of packets of the same flow from being different from the input order. In the present embodiment, it is not necessary to synchronize the table search process by the first determination unit 12 and the table search process by the second determination unit 13, and a simple circuit configuration can be achieved. Further, until the second determination unit 13 determines the output interface, only the packets belonging to the flow for which the second determination unit 13 determines the output interface are held in the buffer unit 10, and other flows The packet to which it belongs is not affected.

なお、上記実施形態においては、完全一致型テーブル16に状態フィールドを設けていたが、フロー識別子と状態フィールドとの関係を、完全一致型テーブル16とは異なるテーブルにて管理することもできる。また、上記実施形態においては、バッファ部10において一括して受信パケットをバッファリングし、第1決定部12や、第2決定部13にはフロー識別子及びバッファ部10への保存位置のみを通知していたが、第1決定部12や、第2決定部13に実際のパケットを出力する形態であっても良い。さらに、完全一致型テーブル16については、ハッシュ値ではなく、実際のフロー識別子と、出力インタフェースとの関係を示すものであっても良い。   In the above embodiment, the state field is provided in the exact match type table 16, but the relationship between the flow identifier and the state field can be managed by a table different from the complete match type table 16. Further, in the above embodiment, the received packet is buffered at once in the buffer unit 10, and only the flow identifier and the storage location in the buffer unit 10 are notified to the first determination unit 12 and the second determination unit 13. However, an actual packet may be output to the first determination unit 12 or the second determination unit 13. Further, the exact match table 16 may indicate a relationship between an actual flow identifier and an output interface instead of a hash value.

Claims (6)

複数のインタフェースを有するパケット転送装置であって、
フロー識別子とインタフェースの関係を示す第1情報と、フロー識別子の部分とインタフェースの関係を示す第2情報を保持する保持手段と、
受信した第1パケットのヘッダ情報に基づき前記第1パケットのフロー識別子を判定する判定手段と、
前記第1パケットのフロー識別子と前記第1情報に基づき前記第1パケットを出力するインタフェースを決定し、決定したインタフェースから前記第1パケットを出力させる第1決定手段と、
前記第1決定手段が前記第1パケットを出力するインタフェースを決定できない場合、前記第1パケットのフロー識別子と前記第2情報に基づき前記第1パケットを出力するインタフェースを決定し、決定したインタフェースから前記第1パケットを出力させる第2決定手段と、
前記第2決定手段が前記第1パケットを出力するインタフェースを決定した場合、前記第1パケットのフロー識別子と前記第2決定手段が決定したインタフェースとの関係を前記第1情報に追加する様に更新する更新手段と、
を備えており、
前記第1決定手段は、前記第1情報により前記第1パケットを出力するインタフェースを決定できない場合、前記第1パケットの受信後、前記更新手段が前記第1情報を更新するまでに受信した前記第1パケットと同じフロー識別子の第2パケットについては、前記第2決定手段に出力するインタフェースを決定させず、前記第2決定手段が前記第1パケットを出力するインタフェースを決定して出力させた後に、当該インタフェースから出力させることを特徴とするパケット転送装置。
A packet transfer apparatus having a plurality of interfaces,
Holding means for holding first information indicating a relationship between a flow identifier and an interface, and second information indicating a relationship between a portion of the flow identifier and an interface;
Determining means for determining a flow identifier of the first packet based on the received header information of the first packet;
First determining means for determining an interface to output the first packet based on the flow identifier of the first packet and the first information, and outputting the first packet from the determined interface;
When the first determination unit cannot determine the interface that outputs the first packet, the interface that outputs the first packet is determined based on the flow identifier of the first packet and the second information. Second determining means for outputting the first packet;
When the second determining means determines the interface that outputs the first packet, the relation between the flow identifier of the first packet and the interface determined by the second determining means is updated to be added to the first information Updating means to
With
If the interface for outputting the first packet cannot be determined based on the first information, the first determining unit receives the first packet after the first packet is received until the updating unit updates the first information. For the second packet having the same flow identifier as that of one packet, the interface for outputting to the second determining means is not determined, and after the second determining means determines and outputs the interface for outputting the first packet, A packet transfer apparatus, characterized by being output from the interface.
前記保持手段は、フロー識別子について、当該フロー識別子とインタフェースの関係が前記第1情報に存在することを示す第1の値と、当該フロー識別子とインタフェースの関係が前記第1情報に存在しないことを示す第2の値と、当該フロー識別子とインタフェースの関係が前記第1情報に存在しないが、追加待ちであることを示す第3の値と、を少なくとも示す第3情報をさらに保持しており、
前記第1決定手段は、前記第1パケットのフロー識別子に対する前記第3情報が前記第1の値を示す場合、前記受信したパケットを出力するインタフェースを決定し、
前記第2決定手段は、前記第1パケットのフロー識別子に対する前記第3情報が前記第2の値を示す場合、前記受信したパケットを出力するインタフェースを決定し、
前記更新手段は、前記第1パケットのフロー識別子に対する前記第3情報が前記第2の値を示す場合、当該第3情報を前記第3の値に更新し、前記第2決定手段が前記第1パケットを出力するインタフェースを決定すると、当該第3情報を前記第1の値に更新することを特徴とする請求項1に記載のパケット転送装置。
For the flow identifier, the holding means indicates that a first value indicating that the relationship between the flow identifier and the interface exists in the first information, and that the relationship between the flow identifier and the interface does not exist in the first information. A third value indicating at least a second value indicating, and a third value indicating that the relationship between the flow identifier and the interface does not exist in the first information but is waiting for addition; and
The first determining means determines an interface for outputting the received packet when the third information for the flow identifier of the first packet indicates the first value;
The second determining means determines an interface for outputting the received packet when the third information for the flow identifier of the first packet indicates the second value;
The update means updates the third information to the third value when the third information for the flow identifier of the first packet indicates the second value, and the second determination means sets the first information to the first value. The packet transfer apparatus according to claim 1, wherein when the interface that outputs a packet is determined, the third information is updated to the first value.
前記第1情報は、フロー識別子のハッシュ値とインタフェースの関係を示すハッシュ・テーブルであり、前記第3情報は、前記ハッシュ・テーブルに含まれることを特徴とする請求項2に記載のパケット転送装置。   3. The packet transfer apparatus according to claim 2, wherein the first information is a hash table indicating a relationship between a hash value of a flow identifier and an interface, and the third information is included in the hash table. . 前記第1決定手段は、前記第1情報により前記第1パケットを出力するインタフェースを決定できない場合、前記第2パケットの受信順序を示す第4情報を作成し、前記第2決定手段が前記第1パケットを出力するインタフェースを決定して出力させた後に、前記第4情報が示す受信順序と同じ順番で、前記第2パケットを当該インタフェースから出力させることを特徴とする請求項1から3のいずれか1項に記載のパケット転送装置。   The first determination means creates fourth information indicating the reception order of the second packets when the interface for outputting the first packet cannot be determined by the first information, and the second determination means The interface according to any one of claims 1 to 3, wherein after the interface for outputting a packet is determined and output, the second packet is output from the interface in the same order as the reception order indicated by the fourth information. 2. The packet transfer apparatus according to item 1. 前記第4情報は、前記第2パケットのフロー識別子のハッシュ値に対して、前記第2パケットの受信順序とバッファへの保存位置とを示すハッシュ・テーブルであることを特徴とする請求項4に記載のパケット転送装置。   The fourth information is a hash table indicating a reception order of the second packet and a storage position in a buffer with respect to a hash value of a flow identifier of the second packet. The packet transfer apparatus described. 請求項1から5のいずれか1項に記載のパケット転送装置としてコンピュータを機能させることを特徴とするプログラム。   A program for causing a computer to function as the packet transfer apparatus according to claim 1.
JP2013126102A 2013-06-14 2013-06-14 Packet transfer apparatus and program Active JP6148546B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2013126102A JP6148546B2 (en) 2013-06-14 2013-06-14 Packet transfer apparatus and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2013126102A JP6148546B2 (en) 2013-06-14 2013-06-14 Packet transfer apparatus and program

Publications (2)

Publication Number Publication Date
JP2015002437A JP2015002437A (en) 2015-01-05
JP6148546B2 true JP6148546B2 (en) 2017-06-14

Family

ID=52296716

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2013126102A Active JP6148546B2 (en) 2013-06-14 2013-06-14 Packet transfer apparatus and program

Country Status (1)

Country Link
JP (1) JP6148546B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP6838455B2 (en) 2017-03-24 2021-03-03 住友電気工業株式会社 Switch device, communication control method and communication control program

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3371006B2 (en) * 1993-03-03 2003-01-27 株式会社日立製作所 Table search method and router device
EP2659631A4 (en) * 2010-12-28 2014-06-25 Nec Corp Communication system, forwarding node, received packet process method, and program

Also Published As

Publication number Publication date
JP2015002437A (en) 2015-01-05

Similar Documents

Publication Publication Date Title
US10791066B2 (en) Virtual network
US10659342B2 (en) Flow entry configuration method, apparatus, and system
JP5610247B2 (en) Network system and policy route setting method
US8799507B2 (en) Longest prefix match searches with variable numbers of prefixes
CN110943924B (en) Method for segmenting source routing in a network and storage medium
US20160277297A1 (en) Sdn packet forwarding
US8792494B2 (en) Facilitating insertion of device MAC addresses into a forwarding database
US20140064276A1 (en) Hashing-based routing table management
WO2016150057A1 (en) Method and device for sending access control list (acl)
JP5993817B2 (en) Routing system and method in carrier network
US9590890B2 (en) Transfer apparatus, server, and route changing method
US20210399908A1 (en) Multicast routing
US10038571B2 (en) Method for reading and writing forwarding information base, and network processor
US20150341267A1 (en) Control apparatus, communication apparatus, communication system, switch control method, and program
JP6148546B2 (en) Packet transfer apparatus and program
JP5747997B2 (en) Control device, communication system, virtual network management method and program
US9973411B2 (en) Synchronization of data and control planes of routers
JPWO2014126094A1 (en) COMMUNICATION SYSTEM, COMMUNICATION METHOD, CONTROL DEVICE, CONTROL DEVICE CONTROL METHOD, AND PROGRAM
US10887282B1 (en) Determining synchronization of filter rules (e.g., on iptable filter tables on Linux kernal) across firewall filter application restarts
KR20150023645A (en) Switch device, vlan configuration and management method, and program
WO2015154393A1 (en) Method and apparatus for processing service node ability, service classifier and service controller
JP5674179B1 (en) Apparatus and method for efficient network address translation and application level gateway processing
WO2016183732A1 (en) Data packet forwarding method and network device
JP6418167B2 (en) Network control device, network system, network control method, and program
TWI572169B (en) Packet transmission system, method and non-transitory computer readable storage medium of the same

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20160128

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20161028

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20161111

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20161205

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20170508

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20170519

R150 Certificate of patent or registration of utility model

Ref document number: 6148546

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150