This application is based upon and claims the benefit of priority of the prior Japanese Patent Application No. 2012-227164 filed on Oct. 12, 2012, the entire contents of which are incorporated herein by reference.
Embodiments disclosed herein are related to a frame transfer apparatus and a frame transfer method.
A frame transfer apparatus transferring communication packets or frames, upon receipt of a frame having an unknown destination address copies the received frame and outputs the frame from all of the ports except for the receiving port that received the frame. Such a processing is called a “flooding”.
When a frame transfer apparatus receives a large amount of frames each having an unknown destination address, each of the received frames is copied and output from a plurality of ports, and therefore, congestion occurs in a communication apparatus or a network. As a result, transferring of a frame having a known destination address is affected.
Japanese Laid-Open Patent Publication No. 2010-114724 discloses a technique in which a memory region per unit of port within a forwarding data base (FDB) is dynamically changed depending on communication situation in order to avoid an unnecessary flooding.
According to an aspect of the present disclosure, there is provided a frame transfer apparatus, which includes: a storage unit configured to store an address and a port in association with the address; a receiving unit configured to receive a frame; a switch unit configured to determine an output port based on a destination address of a received frame; and a transmitting unit configured to transmit the received frame, from the output port determined by the switch unit, wherein the switch unit includes a copying unit configured to copy the received frame when the destination address of the received frame has not been stored in the storage unit, and a rate control unit configured to control an output rate of a frame to be copied.
The object and advantages of the invention will be realized and attained by means of the elements and combinations particularly pointed out in the claims.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory and are not restrictive of the invention, as claimed.
First Embodiment
Hereinafter, exemplary embodiments will be described with reference to the accompanying drawings.
The frame transfer apparatus 2 receives a frame transmitted from the user terminal device 3 and transfers the received frame to a designated destination based on address information set in the frame. The frame transmitted from the user terminal device 3 is, for example, a Media Access Control (MAC) frame or an Internet Protocol (IP) packet. When the user terminal device 3 transmits the MAC frame, the frame transfer apparatus 2 performs a frame transfer based on a MAC address set in the MAC frame. When the user terminal device 3 transmits an IP packet, the frame transfer apparatus 2 performs a frame transfer based on an IP address set in the IP packet.
In the following description, a case where a frame transferred by the frame transfer apparatus 2 is a MAC frame is exemplified. But, in the exemplification, the frame transfer apparatus is not intended to be limited applied only to an apparatus which transfers the MAC frame. The frame transfer apparatus described in the present application may be widely applied to a frame transfer apparatus which transfers the frame based on destination information set in the frame.
The line IF card 10 accommodates line ports #1 to #10 to have a function of interfacing with an external device and performs a processing for a received frame and a processing for a frame to be transmitted. A circuit constituting the line IF card 10 may be provided in a detachable module or card. Further, in the present application, a case where each line IF card 10 accommodates ten line ports #1 to #10 is exemplified, but the number of ports accommodated in the line IF card 10 may be other than ten (10). Further, each number of ports accommodated in each line IF card 10 may be either the same or different from one another.
A SW circuit 11 is connected with the line IF card 10 in the frame transfer apparatus 2 to performs a switch processing for the frame transfer between the line IF cards 10, that is, a route determination processing. The SW circuit 11 may be provided as a detachable module or card.
The control circuit 12 is connected with the line IF card 10 and the SW circuit 11 in the frame transfer apparatus 2 to perform setting of each card or module and collecting alarm and statistical information in the frame transfer apparatus 2. The control circuit 12 is also connected with, for example, a control terminal device 5 to receive setting information from the control terminal device 5 and output the collected alarm and statistical information alarm to the control terminal device 5. The control circuit 12 may be provided as a detachable module or card.
Further, the line IF card 10, the SW circuit 11 and the control circuit 12 may be integrally formed with a motherboard or mother card of the frame transfer apparatus 2 without being provided in a detachable fashion. Further, the hardware configuration illustrated in
The line IF card 10a includes a PHY (Physical)/MAC processing unit 20a and a header processing unit 21a. The line IF card 10b includes a PHY/MAC processing unit 20b and a header processing unit 21b.
The SW circuit 11 includes a frame switching unit 30, a MAC table control unit 31, a MAC table 32, a transfer processing control unit 33, a flow table 34, a first rate control unit 35, a first setting table 36, a second rate control unit 36 and a second setting table 38.
The PHY/MAC processing units 20a and 20b each include a circuit which performs a signal processing in a physical layer for terminating the MAC frame and a MAC layer. The header processing units 21a and 21b add an internal frame header to the received MAC frame. In the following description, the MAC frame added with the internal frame header is represented as “internal frame”.
A destination MAC address is set in the MAC DA field 101. A source MAC address is set in the MAC SA field 102. Further, in the following description and drawings, the destination MAC address and the source MAC address may be represented as “MAC DA” and “MAC SA”, respectively.
Ethernet (registered trademark) type code identifying an upper layer protocol is set in the E-TYPE field 103. An upper layer message is set in the PDU field 104. An error detection code is set in the FCS field 105.
A value of “0x8100” indicating a frame added with a tag is set in the TPID field 111. The priority field 112 is a 3-bit field designating a priority and can designate priority from the lowest priority having a value of “0(000)” to the highest priority having a value of “7(111)”.
The DEI field 113 designates a discard priority. A VLAN ID which is an identifier for specifying a user is set in the VLAN ID field 114. In the following description and drawings, the VLAN ID may be represented as “VID”. The VID along with a value of the TPID field 111 may be referred to as a VLAN tag. Further, a plurality of VLAN Tags may be included in plural.
Referring back to
The frame switch unit 30 performs a switch processing in which the internal frame received by the SW circuit 11 is transferred to the line IF card 10 in association with the MAC DA of the MAC frame included in the internal frame. When the MAC DA has not been known in the MAC table 32, the frame switch unit 30 performs a copy processing for flooding the internal frame. Hereinafter, the internal frame is described as “frame” in a description of function and operation of the SW circuit 11.
The MAC table control unit 31 determines whether a MAC DA of the frame received by the SW circuit 11 has been known by a learning process in the MAC table 32.
When an entry is valid, the “valid flag” has a value of “1” and when an entry is invalid, the “valid flag” has a value of “0”. The “IF card number” and the “port number” indicate a port number of the line port and a card number of the line IF card 10 which has received the MAC address of the index as the source MAC address, respectively. The “aging flag” is set to “1” during a learning process of the MAC address, and then, reset to “0” after a predetermined time has elapsed.
For example, a first entry has a MAC address of “xx:xx:xx:xx:xx:01” as the index. The value “1” of the “valid flag” indicates that the entry is valid, and the known card number and port number correspond to “card number #1” and “port number #1”, respectively. Further, in this case, the value of the flag of the entry is “1”.
The MAC address serving as an index may be compressed to the number of bits smaller than the original 48 bits through, such as a hashing operation. Further, the MAC table 32 may be implemented with a Static Random Access Memory (SRAM), a Dynamic Random Access Memory (DRAM), and a Content Addressable Memory (CAM). In a case of the CAM memory, a retrieval key of the CAM memory which uses the MAC address as a base may be used as a memory index. The physical configuration of the MAC table 32 is irrelevant and out of question here.
In a case where the MAC DA has been known by a learning process, the MAC table control unit 31 reads the “IF card number” and the “port number” from the MAC table 32 and sets the “IF card number” and the “port number” in the internal frame header 210 as the destination card number and the destination port number, respectively.
If the value of the aging flag of an entry is “1” when reading-out the entire entry periodically as an aging processing for the MAC table 32, the MAC table control unit 31 resets the value of the aging flag to “0”. When the value of the aging flag of an entry is “0”, the MAC table control unit 31 resets the valid flag of the entry to “0” and makes the entry to be an empty entry.
The MAC table control unit 31 sets a MAC SA of the frame, a port number of the line port and a card number of the line IF card 10 which has received the frame in the MAC table 32 and thus, becomes to know the MAC SA.
Referring to
The first rate control unit 35 controls the frame rate to be subjected to the switch processing and a copy processing by the frame switch unit 30 for each of the plurality of the first flows. Further, the second rate control unit 37 controls the frame rate to be subjected to the switch processing by the frame switch unit 30 for each of the plurality of the second flows. The transfer processing control unit 33 designates the line port to which the frame switch unit 30 transmits a copy of the received frame during the flooding.
The transfer processing control unit 33 references a flow table 34 using a combination of the source card number and the source port number and the VID set in the internal frame header 210 of the received frame as an index.
The “first flow ID” is an identifier identifying one of a plurality of first flows which corresponds to a destination of the received frame to be subjected to the flooding. The “second flow ID” is an identifier identifying one of a plurality of second flows which corresponds to a destination of the received frame.
The “aging time” designates an aging time of the entry of the MAC table 32 in association with a combination of “the source card number” and “the source port number” and the VID as index. The MAC table control unit 31 performs an aging of the MAC table 32 at an interval designated by the “aging time”.
The “frame copy information” designates the line port to which a copy of the received frame is transmitted by the frame switch unit 30 during the flooding. A code CmPn indicates a line port #n of the line IF card 10 having a card number #m, and the copy is transmitted only to a port to which the value of “1” is allocated, and is not transmitted to a port to which the value of “0” is allocated.
For example, a first entry has the source card number indicated as “card number #1”, the source port number indicated as “port number #1”, and VID indicated as “VID #1”. The value “1” of the “valid flag” indicates that the entry is valid.
An identifier of the first flow to which the frame of which the source card number, the source port number and the VID is “card number #1”, “port number #1” and the “VID #1”, respectively, is distributed is “1”. Further, an identifier of the second flow to which the frame is distributed is “1”. During the flooding, the frame is transferred to the line port #2 of the line IF card 10 having a card number #1 (indicated as C1P2 in
The aging time of the entry of the MAC table 32 in which the “card number #1” and the “port number #1” is set is designated as “5 minutes”.
Further, when a plurality of VLAN tags are included in the received frame, a plurality of VIDs may be used in an index. For example, when the flow table 34 is a SRAM or a DRAM memory, a plurality of VIDs may be included to be used in the index.
Further, when the flow table 34 is implemented by the CAM, the source card number, the source port number and the VID may be used as a retrieval key. When a plurality of VLAN tags are included in the received frame, a plurality of VIDs may be used as a retrieval key. Further, when the VLAN tag is not included in the received frame, a portion of the VLAN tag of the retrieval key may be masked to be used as a retrieval key. Further, the physical configuration of the flow table 34 is irrelevant and out of question here.
Referring to
The first rate control unit 35 controls the rate of the first flow in which the received frame of which the MAC DA has not been known in the MAC table 32 is distributed according to a token bucket scheme. The upper limit rate and the burst size used in a token bucket control are designated for each first flow ID in the first setting table 36.
For example, the upper limit rate and the burst size used for the token bucket control of the first flow identified with a first flow ID “1” for the first entry are set to “10 Mbps” and “100 Kbyte”, respectively. Further, in the following description and drawings, the upper limit rate of the first flow may be represented as a “first upper limit rate”.
The first rate control unit 35 supplies tokens to a bucket at a rate not exceeding the first upper limit rate for each flow. An amount of tokens corresponding to a preset burst size may be accumulated in the bucket. The first rate control unit 35 takes out tokens corresponding to the number of bytes which amounts to a packet length of the received frame from the bucket.
In a case where the number of tokens within the bucket becomes less than “0” when the tokens are taken out from the bucket, the total of the first flow rate is regarded as exceeding the first upper limit rate and thus, the tokens are not taken out from the bucket and the received frame is discarded. In a case where the number of remaining tokens is “0” or more even when tokens are taken out from the bucket, the total of the first flow rate is regarded as not exceeding the first upper limit rate and thus, the tokens are taken out from the bucket and the received frame is not discarded.
The received frame where the rate is controlled by the first rate control unit 35 and the received frame where the MAC DA has been known by a learning process in the MAC table 32 are distributed to a plurality of second flows using the second flow ID. Both the received frame where rate is controlled by the first rate control unit 35 and the received frame where the MAC DA has been known by a learning process in the MAC table 32 may coexist in the same second frame. The second rate control unit 37 controls a rate of the second flow in a token bucket scheme. The upper limit rate and burst size used in the token bucket control of the second flow are designated for each second flow ID in the second setting table 38.
For example, the upper limit rate and the burst size used for token bucket control of the first flow identified with a second flow ID “1” for the first entry are set to “10 Mbps” and “100 Kbyte”, respectively. Further, in the following description and drawings, the upper limit rate of the second flow may be indicated as a “second upper limit rate”.
Further, the token bucket control by the second rate control unit 37 is the same as that by the first rate control unit 35. The received frame not discarded during the rate control by the first rate control unit 35 and the second rate control unit 37 is input to the frame switch unit 30. Further, the first upper limit rate or the second upper limit rate needs to be set to be equal to or larger than the physical rate of the receiving port in order for the first rate control unit 35 or the second rate control unit 37 not to discard the frames.
When the MAC DA of the received frame has not been known, the frame switch unit 30 copies the received frame, and transfers the copied frame to the line IF card 10 which accommodates a designated line port according to the frame copy information. When the MAC DA has been known by a learning process, the frame switch unit 30 transfers the received frame to the line IF card 10 designated with an IF card number stored in the MAC table 32 in association with the MAC DA.
When the SW circuit 11 receives a frame, the MAC table control unit 31 conducts a learning process for the MAC SA of the received frame at operation AA. At operation AB, the transfer processing control unit 33 references the flow table 34 to read a first flow ID, a second flow ID and frame copy information.
At operation AC, the MAC table control unit 31 retrieves the MAC DA of the received frame from the MAC table 32. When the MAC DA has been known by a learning process (“YES” at operation AD), the process proceeds to operation AI. When the MAC DA has not been known (“NO” at operation AD), the process proceeds to operation AE.
At operation AE, the first rate control unit 35 determines whether the rate of the first flow to which the received frame allocated is equal to or less than the first upper limit rate. When it is determined that the rate of the first flow is equal to or less than the first upper limit rate (“YES” at operation AE), the process proceeds to operation AG. When it is determined that the rate of the first flow is not equal to or less than the first upper limit rate (“NO” at operation AE), the process proceeds to operation AF. At operation AF, the first rate control unit 35 discards the received frame. Thereafter, the operational process of the SW circuit 11 for the received frame ends.
At operation AG, the second rate control unit 37 determines whether the rate of the second flow to which the received frame allocated is equal to or less than the second upper limit rate. When it is determined that the rate of the second flow is equal to or less than the second upper limit rate (“YES” at operation AG), the process proceeds to operation AH. When it is determined that the rate of the second flow is not equal to or less than the second upper limit rate (“NO” at operation AG), the process proceeds to operation AF.
At operation AH, the frame switch unit 30 copies the received frame and transfers the copied frame to the line IF card 10 which accommodates a designated line port according to the frame copy information. Thereafter, the operational process of the SW circuit 11 for the received frame ends.
At operation AI, the second rate control unit 37 determines whether the rate of the second flow to which the received frame is allocated is equal to or less than the second upper limit rate. When it is determined that the rate of the second flow is equal to or less than the second upper limit rate (“YES” at operation AI), the process proceeds to operation AK. When it is determined that the rate of the second flow is not equal to or less than the second upper limit rate (“NO” at operation AI), the process proceeds to operation AJ.
At operation AJ, the second rate control unit 37 discards the received frame. Thereafter, the operational process of the SW circuit 11 for the received frame ends. At operation AK, the frame switch unit 30 transfers the received frame to the line IF card 10 according to the MAC table 32. Thereafter, the operational process of the SW circuit 11 for the received frame ends.
According to the present embodiment, when the MAC DA of the received frame has not been known, it becomes possible to control the rate of the received frame to be subjected to the flooding before the frame is copied. Accordingly, the number of frames broadcasted due to the flooding may be reduced and thus, the influence that other traffic suffers due to the network congestion is reduced.
Further, the rate of the received frame to be subjected to the flooding is controlled before the frame is copied and thus, the number of copies of frame in the frame transfer apparatus is reduced. Therefore, congestion within the frame transfer apparatus is decreased. Further, a processing load of the frame transfer apparatus is reduced due to the reduction of the copy processing.
Further, in the present embodiment, the received frame is distributed to a plurality of first flows and a plurality of second flows according to the VID, and the rate of the received frame is controlled by the first rate control unit 35 and the second rate control unit 37. Accordingly, it is possible to suppress a traffic being flooded first and comprehensively control the flow rate including the flooding traffic and non-flooding traffic.
Further, any first flow ID and second flow ID are allocated to the line port and the VID using the flow table 34 and thus, it becomes possible to freely gather any line port and the VID to perform a rate control.
Second Embodiment
In the present embodiment, the first rate control unit 35 performs a rate control of the first flow according to the number of times that the frame is to be copied specified by the frame copy information in the flow table 34. For example, when the rate produced by multiplication of the rate of the first flow by the number of times that the frame is to be copied exceeds the first upper limit rate, the first rate control unit 35 may discards the received frame.
For example, the first rate control unit 35 may perform the token bucket control according to the number of times that the frame is to be copied. In a case where the number of tokens within the bucket becomes less than “0” when the tokens corresponding to a value produced by multiplication of the number of bytes which amounts to the length of packet of the received frame and the number of times that the frame is to be copied are taken out, the first rate control unit 35 may determine that the total sum of the rates of the first flows exceeds the first upper limit rate.
According to the present embodiment, it becomes possible to perform a rate control with respect to the traffic to be flooded according to the number of copies of frame and thus, it becomes possible to more efficiently reduce the number of frames to be flooded. Further, similarly to the third embodiment described below, a rate control of the first flow may be conducted according to the number of times that the frame is to be copied.
Third Embodiment
In the present embodiment, the first upper limit rate and the second upper limit rate varies according to the priority of the received frame.
In the following description, the priority designated in the priority field 112 may be represented as “VLAN priority”. The respective VLAN priorities having values of “0(000)” to “7(111)” may be represented as the “VLAN priority #0” to “VLAN priority #1”, respectively. A priority in the frame transfer apparatus 2 used for conversion of the first upper limit rate and the second upper limit rate may be represented as “internal priority”. The internal priority may be designated as three stages of priority, for example, “high priority”, “intermediate priority” and “low priority”.
Any class conversion ID is allocated to each combination of the source card number, the source port number and the VID by the flow table 34 and thus, the VLAN priority may be converted into the internal priority using a different conversion rule for each flow or user.
According to the present embodiment, it becomes possible to suppress the flooding traffic according to the priority of the received frame, or the priority designated according to each flow or user.
All examples and conditional language recited herein are intended for pedagogical purposes to aid the reader in understanding the invention and the concepts contributed by the inventor to furthering the art, and are to be construed as being without limitation to such specifically recited examples and conditions, nor does the organization of such examples in the specification relate to a showing of the superiority and inferiority of the invention. Although the embodiments of the present invention have been described in detail, it should be understood that the various changes, substitutions, and alterations could be made hereto without departing from the spirit and scope of the invention.
Number | Date | Country | Kind |
---|---|---|---|
2012-227164 | Oct 2012 | JP | national |
Number | Name | Date | Kind |
---|---|---|---|
6175571 | Haddock et al. | Jan 2001 | B1 |
20120209941 | Yamamoto | Aug 2012 | A1 |
Number | Date | Country |
---|---|---|
2005-167881 | Jun 2005 | JP |
2009-239836 | Oct 2009 | JP |
2010-114724 | May 2010 | JP |
2012-114646 | Jun 2012 | JP |
Number | Date | Country | |
---|---|---|---|
20140105020 A1 | Apr 2014 | US |