Communication device, communication method, and communication program
The communication device addresses the challenge of handling large packet flows by dynamically adjusting hardware entries based on processing effectiveness, prioritizing high-weight flows for hardware processing, thereby improving system throughput and reducing software processing loads.
Patent Information
- Application Number
- PCT/JP2023/006076
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2023-02-20
- Publication Date
- 2024-08-29
AI Technical Summary
Conventional communication systems struggle to handle large packet flows due to hardware processing limitations, leading to reduced throughput and increased software processing loads, especially when IoT devices occupy hardware entries intended for low-communication flows, causing high-capacity communications like camera images to be processed by software.
A communication device that acquires packets and hardware entry information, determines whether hardware processing is available, calculates a weight value for each packet based on processing effectiveness, and dynamically adjusts hardware entries by prioritizing high-weight flows for hardware processing and deleting low-weight entries when the hardware limit is exceeded, ensuring efficient packet processing.
This approach enhances system throughput by prioritizing hardware processing for effective flows, reducing CPU usage and power consumption, and effectively handling large packet flows by optimizing entry management and processing distribution between hardware and software.
Smart Images

Figure JP2023006076_29082024_PF_FP_ABST
Abstract
Description
Communication device, communication method, and communication program
[0001] The present invention relates to a communication device, a communication method, and a communication program.
[0002] Conventionally, packet processing has been implemented in two ways: by software using a CPU, etc., and by hardware using ASICs, NPUs, FPGAs, etc. Stateful packet processing is difficult to implement in hardware, so it is flexibly implemented in software.
[0003] In a packet processing system consisting of hardware and software processing, a technology has been proposed that enables high-speed packet transfer by adding the contents of stateful packet processing processed by software (e.g., NAT processing) to an entry held by the hardware, and processing subsequent packets in hardware.
[0004] “5 Port 10 / 100 Hardware NAT / NAPT Router,” IC plus, 2008.<URL:http: / / www.image.micros.com.pl / _dane_techniczne_auto / uiip3210.pdf>
[0005] However, conventional technologies have had the problem of being unable to handle large amounts of packet flows. For example, because there is a limit to the number of packet flow entries that can be processed by hardware, if the packet flows from IoT terminals, which are numerous but do not generate much communication, occupy the hardware processing entries, high-volume communication such as camera images that should be processed by hardware will be processed by software, resulting in a decrease in overall system throughput and an increase in the load on software processing.
[0006] The present invention has been made in view of the above, and has as its object to provide a communication device, a communication method, and a communication program that can handle a large amount of packet flow.
[0007] In order to solve the above-mentioned problems and achieve the object, the communication device of the present invention is characterized by having an acquisition unit that acquires a packet and information about a hardware entry indicating the processing target; a first judgment unit that judges whether an entry targeting the packet acquired by the acquisition unit exists in the hardware; a software processing unit that, if the first judgment unit judges that an entry does not exist, forwards the packet acquired by the acquisition unit using software; a calculation unit that calculates a weight value that indicates the degree of effectiveness of the forwarding processing by the hardware based on the packet forwarded by the software processing unit; a second judgment unit that judges whether the number of entries included in the information about the hardware entry exceeds a threshold; and a modification unit that, if the second judgment unit judges that the threshold is not exceeded, adds an entry targeting the packet forwarded by the software processing unit to the hardware, together with the weight value calculated by the calculation unit.
[0008] According to the present invention, it is possible to handle a large amount of packet flow.
[0009] FIG. 1 is a diagram for explaining a conventional technique. FIG. 2 is a diagram for explaining a conventional technique. FIG. 3 is a diagram for explaining a conventional technique. FIG. 4 is a diagram for explaining an overview of a communication device according to an embodiment. FIG. 5 is a diagram showing an example of the functional configuration of a communication device according to an embodiment. FIG. 6 is a diagram for explaining an example of processing performed by a communication device according to an embodiment. FIG. 7 is a diagram for explaining an example of processing performed by a communication device according to an embodiment. FIG. 8 is a diagram for explaining an example of processing performed by a communication device according to an embodiment. FIG. 9 is a flowchart showing an example of a processing flow by a communication device according to an embodiment. FIG. 10 is a diagram showing an example of a computer that executes a communication program.
[0010] Hereinafter, with reference to the drawings, embodiments of a communication device, a communication method, and a communication program according to the present application will be described in detail. Note that the present invention is not limited to these embodiments. In addition, in the description of the drawings, the same parts are denoted by the same reference numerals, and duplicated explanations will be omitted.
[0011] [Overall Overview] First, an overall overview will be described using Figures 1 to 4. Figures 1 to 3 are diagrams for explaining the prior art. Figure 4 is a diagram for explaining an overview of a communication device.
[0012] The present invention relates to a system that performs stateful packet processing for communications in which various flows coexist in a device configured with hardware processing and software processing, as shown in Fig. 1. Here, stateful processing refers to processing based on session information (destination address, port, TTL, etc.) such as NAPT, FW, and load balance, and is performed by software to perform, for example, free / busy management.
[0013] Therefore, in the present invention, when a large number of sessions occur, efficient processing is possible by combining software and hardware processing.
[0014] In conventional stateful packet processing, software processing and hardware processing are performed in the following manner, as shown in Figure 2. First, for a packet arriving in the system, the presence or absence of an entry in the hardware processing unit is confirmed. Next, packets that do not match an entry are transferred to software processing for packet processing. The results of the software processing are then added to the entry in the hardware.
[0015] By doing this, subsequent packets will hit the entry and be processed by hardware, enabling faster packet processing.
[0016] However, the conventional technology has a problem of being unable to handle a large amount of packet flow, as shown in Figure 3. For example, there is a limit to the number of entries that can be processed by hardware, and when a session that exceeds the number of entries that can be processed arrives, the packets are discarded or processing continues using software with low processing performance. In addition, for example, if a terminal that does not generate much communication (such as an IoT terminal) occupies the hardware processing entries, large-volume communication (such as camera footage) that starts communication later will be processed by software, resulting in a decrease in performance.
[0017] Therefore, in this invention, when a new entry is added to the hardware, the effect of the hardware processing is also registered as a weight value (Weight), as shown in Figure 4. Also, when a new entry is added to the hardware, if the number of entries in the hardware exceeds the limit, flows with small weight values (low hardware effect) are deleted from the entry. Also, if a free entry occurs in the hardware side, flows with large weight values in the software are transferred to hardware processing.
[0018] This invention makes it possible to prioritize hardware processing of flows that are most effective in hardware processing for communications involving a mixture of various flows, thereby improving the throughput of the entire system and reducing CPU utilization and power consumption by reducing software processing.
[0019] [Configuration of Communication Device] Next, the configuration of communication device 100 will be described with reference to Fig. 5. As shown in Fig. 5, communication device 100 has a communication unit 110, a control unit 120, and a storage unit 130. Note that these units may be held in a distributed manner by multiple devices. The processing of these units will be described below.
[0020] The communication unit 110 is realized by a network interface card (NIC) or the like, and enables communication between the control unit 120 and an external device via a telecommunication line such as a local area network (LAN) or the Internet. For example, the communication unit 110 enables communication between the external device and the control unit 120.
[0021] The storage unit 130 is realized by a semiconductor memory element such as RAM (Random Access Memory) or flash memory, or a storage device such as a hard disk or optical disk. The information stored in the storage unit 130 includes, for example, packet information, entry information, a routing table, and other information necessary for packet processing. Here, the packet information includes information such as the packet header (5 tuples, TCP header, DSCP value / TOS value), payload, packet length, bandwidth used, packet count value, CPU usage rate, and communication volume per unit. Furthermore, the entry information includes information such as the pre-translation IP, pre-translation port, post-translation IP, post-translation port, and weight value. Note that the information stored in the storage unit 130 is not limited to the examples described above.
[0022] The control unit 120 is realized using a CPU (Central Processing Unit), an NP (Network Processor), an FPGA (Field Programmable Gate Array), or the like, and executes a processing program stored in memory. As shown in Fig. 5, the control unit 120 has an acquisition unit 121, a first determination unit 122, a software processing unit 123, a hardware processing unit 124, a calculation unit 125, a second determination unit 126, a third determination unit 127, and a change unit 128. Each unit of the control unit 120 will be described below.
[0023] The acquisition unit 121 acquires packets and hardware entry information indicating targets of processing by the hardware. Here, the entry information includes information such as the number of entries and a weight value for each entry. For example, the acquisition unit 121 acquires packets that require stateful processing, the number of hardware entries, and a weight value for each hardware entry.
[0024] The acquiring unit 121 also acquires information about software entries that indicate targets of processing by the software, such as packets that require stateful processing, the number of hardware entries, a weight value for each hardware entry, and a weight value for each software entry.
[0025] The first determination unit 122 determines whether an entry for processing the packet acquired by the acquisition unit 121 exists in the hardware. For example, the first determination unit 122 determines whether information targeted by the packet acquired by the acquisition unit 121 exists in a session information table. Note that although NAPT (Network Address Port Translation) has been exemplified as the packet forwarding process, the processing target of the present invention is not limited to this.
[0026] When the first determination unit 122 determines that the packet does not exist, the software processing unit 123 performs a software forwarding process on the packet acquired by the acquisition unit 121. For example, when the first determination unit 122 determines that the packet does not exist, the software processing unit 123 converts the address port of the packet acquired by the acquisition unit 121 and forwards it.
[0027] When the first determination unit 122 determines that the packet exists, the hardware processing unit 124 performs a forwarding process by hardware on the packet acquired by the acquisition unit 121. For example, when the first determination unit 122 determines that the packet exists, the hardware processing unit 124 performs a forwarding process on the packet acquired by the acquisition unit 121 based on a routing table.
[0028] The calculation unit 125 calculates a weight value indicating the degree of effectiveness of the forwarding process by hardware, based on the packets acquired by the acquisition unit 121. For example, the calculation unit 125 calculates the weight value indicating the degree of effectiveness of the forwarding process by hardware, using information such as the communication volume per unit time, packet header, payload, packet length, bandwidth used, packet count value, and CPU usage rate of the packets acquired by the acquisition unit 121 and forwarded by the software processing unit 123.
[0029] Furthermore, for example, the calculation unit 125 calculates a weight value indicating the degree of effectiveness of the forwarding process by hardware using information such as the communication volume per unit time, packet header, payload, packet length, bandwidth used, packet count value, and CPU usage rate of the packets acquired by the acquisition unit 121 and forwarded by the hardware processing unit 124.
[0030] When calculating the weight value, the calculation unit 125 may use each piece of information alone or in combination. Furthermore, the calculation unit 125 may dynamically recalculate the weight value not only when the software processing unit 123 processes the packet for the first time, but also continuously while the packet is being processed.
[0031] The second determination unit 126 determines whether the number of entries included in the hardware entry information exceeds a threshold. For example, the second determination unit 126 compares the number of entries "X" included in the hardware entry information with a threshold "Y," and determines that the threshold is exceeded if X>Y. Note that the second determination unit 126 can use a predetermined threshold depending on the purpose.
[0032] If the second determination unit 126 determines that the weight value exceeds the threshold, the third determination unit 127 determines whether the weight value calculated by the calculation unit 125 is greater than the weight value of the entry with the smallest weight value among the entry information of the hardware. For example, if the second determination unit 126 determines that the weight value exceeds the threshold, the third determination unit 127 compares the weight value "X" calculated by the calculation unit 125 with the weight value "Y" of the entry with the smallest weight value in the hardware, and if X>Y, determines that the weight value is greater than the entry with the smallest weight value.
[0033] When the second determination unit 126 determines that the threshold value is not exceeded, the change unit 128 adds to the hardware an entry for the packet forwarded by the software processing unit 123 and the weight value calculated by the calculation unit 125. For example, when the second determination unit 126 determines that the threshold value is not exceeded, the change unit 128 adds to the hardware an entry that combines the contents forwarded by the software processing unit 123 and the weight value calculated by the calculation unit 125.
[0034] Furthermore, the change unit 128 adds to the hardware the entry with the largest weight value calculated by the calculation unit 125 from among the entry information of the software. For example, the change unit 128 refers to the entry information of the software stored in the storage unit 130, and adds to the storage unit 130 the entry with the largest weight value calculated by the calculation unit 125 as an entry of the hardware. At this time, the change unit 128 may delete from the software the entry that was added to the hardware.
[0035] In addition, if the third determination unit 127 determines that the weight value is greater than the smallest entry, the modification unit 128 deletes the entry with the smallest weight value from the hardware entry information and adds to the hardware an entry that targets the packet forwarded by the software processing unit 123.
[0036] For example, if the third determination unit 127 determines that the weight value is greater than the smallest entry, the modification unit 128 deletes the entry with the smallest weight value from the hardware entry information stored in the memory unit 130, and adds to the memory unit 130 an entry that targets the packet forwarded by the software processing unit 123 as a hardware entry.
[0037] [Processing by Communication Device] Next, processing by communication device 100 will be described with reference to Fig. 6 and Fig. 7. Fig. 6 and Fig. 7 are diagrams for explaining notification processing by communication device 100.
[0038] 6, in an example in which the calculation unit 125 calculates the weight value from the communication volume, the conversion information is added to the session information table after the first packet is subjected to NAPT processing by the software processing unit 123. At this time, the weight value in the table is updated as needed to a value calculated from the communication volume per unit time (PPS (Packet Per Second)).
[0039] 7, the calculation unit 125 may dynamically recalculate the weight value not only when the software processing unit 123 processes a packet for the first time, but also continuously while the packet is being processed. For example, the calculation unit 125 may monitor the bandwidth of each entry from the packet counter value as needed, recalculate the weight value, and then update the weight value of the entry. This allows the weight value to be recalculated in a timely manner and appropriate measures to be taken even when the characteristics of the flow change over time.
[0040] Next, if the limit value of the hardware flow is exceeded, processing is performed by the software processing unit 123. At this time, if the weight value is larger than the weight value of the smallest entry among the hardware entries, the change unit 128 deletes the entry that processes the flow from the hardware entries and transfers the deleted entry to processing by the software processing unit 123.
[0041] The change unit 128 may delete entries of hardware that have not been used for a certain period of time. For example, the change unit 128 may delete entries of hardware that have a weight value of 0.
[0042] In this example, the weight value is calculated from the communication volume, but the calculation unit 125 can calculate the weight value indicating the degree of effectiveness of the transfer process by hardware using information such as the communication volume per unit time of packets, packet header, payload, packet length, bandwidth used, packet count value, CPU usage rate, etc. Furthermore, when calculating the weight value, the calculation unit 125 may use each piece of information alone or in combination.
[0043] The calculation unit 125 may also determine the type of communication from each piece of information and calculate the weight value. For example, the calculation unit 125 may determine that communication using the protocol UDP / 12000 is video traffic from the 5-tuple information in the packet header, and calculate a large weight value.
[0044] On the other hand, if the bandwidth used is 128 kbps or less and the packet length is always constant at 100 bytes, the communication may be determined to be communication from an IoT device such as a sensor, and a small weight value may be calculated. The calculation unit 125 may also monitor the increase or decrease in packet count per unit time and use the size of the packet count as the weight value. This allows the calculation of a weight value such that the more communication a device is performing, the higher the priority of hardware processing.
[0045] Next, the processing by the communication device 100 will be described in detail using Figure 8. The packet sorting unit searches whether the input packet hits a hardware entry, and if so, sorts it to a hardware packet processing unit, or if not, sorts it to a software packet processing unit. The SW (software) packet processing unit processes the packet itself and adds the processing result (the translation destination address in the case of NAPT) to the hardware entry or software entry.
[0046] The packet flow monitoring unit monitors the packet flow rate and the like, and passes the result to the weight value calculation unit, which calculates the weight (weight value) and changes the weight value of the entry.
[0047] The HW-SW entry exchange unit compares the weight values and swaps the software and hardware entries when the HW entries are overflowing. SW entries are entries for processing on software, and are stored in memory space in the OS, for example. HW entries are entries for processing on hardware.
[0048] The SW entry search and operation unit searches, adds, deletes, and modifies software entries through CRUD processing. Similarly, the HS entry search and operation unit searches, adds, deletes, and modifies hardware entries through CRUD processing. Note that each of the functional units shown in Figure 8 can function on software.
[0049] [Flowchart] Next, the flow of processing by the communication device 100 will be described using Figure 9. Note that the following steps S101 to S110 may be executed in a different order. Also, some of the following steps S101 to S110 may be omitted.
[0050] First, the acquisition unit 121 acquires a packet and information on a hardware entry indicating a target for processing by the hardware (step S101). For example, the acquisition unit 121 acquires a packet that requires stateful processing, the number of hardware entries, and a weight value for each hardware entry.
[0051] Next, the first determination unit 122 determines whether an entry for processing the packet acquired by the acquisition unit 121 exists in the hardware (step S102). For example, the first determination unit 122 determines whether information for processing the packet acquired by the acquisition unit 121 exists in the session information table.
[0052] Here, if the first determination unit 122 determines that the packet exists in the acquisition unit 121 (step S102 "YES"), the hardware processing unit 124 performs forwarding processing of the packet acquired by the acquisition unit 121 (step S103).
[0053] On the other hand, if the first determination unit 122 determines that the packet does not exist in the acquisition unit 121 (step S102 "NO"), the software processing unit 123 performs a forwarding process for the packet acquired by the acquisition unit 121 (step S104).
[0054] Next, the calculation unit 125 calculates a weight value indicating the degree of effectiveness of the forwarding process by hardware, based on the packets acquired by the acquisition unit 121 (step S105). For example, the calculation unit 125 calculates the weight value indicating the degree of effectiveness of the forwarding process by hardware, using the communication volume per unit time of the packets acquired by the acquisition unit 121 and forwarded by the software processing unit 123.
[0055] Next, the second determining unit 126 determines whether the number of entries included in the hardware entry information exceeds a threshold value (step S106).
[0056] At this time, if the second judgment unit 126 determines that the threshold is not exceeded (step S106 "NO"), the modification unit 128 adds to the hardware an entry for the packet forwarded by the software processing unit 123 and the weight value calculated by the calculation unit 125 (step S107).
[0057] On the other hand, if the second judgment unit 126 judges that the weight value exceeds the threshold value (step S106 "YES"), the third judgment unit 127 then judges whether the weight value calculated by the calculation unit 125 is greater than the entry with the smallest weight value among the hardware entry information (step S108).
[0058] At this time, if the third judgment unit 127 judges that the weight value is greater than the smallest entry (step S108 "YES"), the change unit 128 deletes the entry with the smallest weight value from the hardware entry information (step S109), and adds to the hardware an entry targeting the packet forwarded by the software processing unit 123 (step S110).
[0059] On the other hand, if the third determination unit 127 determines that the weight value is not greater than the smallest entry (step S108 "NO"), the processing by the communication device 100 ends.
[0060] [Effects] The communication device 100 according to the embodiment includes an acquisition unit 121 that acquires a packet and information about a hardware entry that indicates the target of processing by the hardware; a first determination unit 122 that determines whether an entry targeting the packet acquired by the acquisition unit 121 exists in the hardware; a software processing unit 123 that, when the first determination unit 122 determines that no entry exists, forwards the packet acquired by the acquisition unit 121 by software; a calculation unit 125 that calculates a weight value that indicates the degree of effectiveness of the forwarding processing by the hardware, based on the packet acquired by the acquisition unit 121; a second determination unit 126 that determines whether the number of entries included in the information about the hardware entry exceeds a threshold; and a modification unit 128 that, when the second determination unit 126 determines that the number of entries does not exceed the threshold, adds, to the hardware, the entry targeting the packet forwarded by the software processing unit 123 and the weight value calculated by the calculation unit 125.
[0061] As a result, the communication device 100 adds an entry to the hardware along with the calculated weight value, and prioritizes hardware processing of flows that are most effective in hardware processing, thereby improving the throughput of the entire system and enabling it to handle large amounts of packet flows.
[0062] The communication device 100 according to the embodiment further includes a hardware processing unit 124 that, when the first determining unit 122 determines that a packet exists, transfers the packet acquired by the acquiring unit 121 using hardware.
[0063] As a result, the communication device 100 adds an entry to the hardware along with the calculated weight value, and prioritizes hardware processing of flows that are most effective in hardware processing, thereby improving the throughput of the entire system and enabling it to handle large amounts of packet flows.
[0064] In the communication device 100 according to the embodiment, the acquisition unit 121 further acquires information about software entries that indicate the processing target of the software, and the modification unit 128 adds to the hardware the entry from the software entry information that has the largest weight value calculated by the calculation unit 125.
[0065] As a result, the communication device 100 adds an entry to the hardware along with the calculated weight value, and prioritizes hardware processing of flows that are most effective in hardware processing, thereby improving the throughput of the entire system and enabling it to handle large amounts of packet flows.
[0066] The communication device 100 according to the embodiment further includes a third determination unit 127 that, when the second determination unit 126 determines that the weight value calculated by the calculation unit 125 exceeds the threshold, determines whether the weight value calculated by the calculation unit 125 is greater than the entry with the smallest weight value among the entry information of the hardware, and, when the third determination unit 127 determines that the weight value is greater than the smallest entry, the modification unit 128 deletes the entry with the smallest weight value among the entry information of the hardware, and adds to the hardware an entry for the packet forwarded by the software processing unit 123.
[0067] As a result, the communication device 100 adds an entry to the hardware along with the calculated weight value, and prioritizes hardware processing of flows that are most effective in hardware processing, thereby improving the throughput of the entire system and enabling it to handle large amounts of packet flows.
[0068] [Program] A program written in a computer-executable language may be created to execute the processes performed by the communication device 100 described in the above embodiment. In this case, the same effects as those of the above embodiment can be achieved by having a computer execute the program. Furthermore, such a program may be recorded on a computer-readable recording medium, and the program recorded on the recording medium may be read and executed by a computer to achieve the same processes as those of the above embodiment.
[0069] Fig. 10 is a diagram showing an example of a computer that executes a communication program. As shown in Fig. 10, the computer 1000 includes, for example, a memory 1010, a CPU 1020, a hard disk drive interface 1030, a disk drive interface 1040, a serial port interface 1050, a video adapter 1060, and a network interface 1070. These components are connected by a bus 1080.
[0070] The memory 1010 includes a ROM (Read Only Memory) 1011 and a RAM 1012. The ROM 1011 stores a boot program such as a BIOS (Basic Input Output System). The hard disk drive interface 1030 is connected to a hard disk drive 1090. The disk drive interface 1040 is connected to a disk drive 1100. A removable storage medium such as a magnetic disk or optical disk is inserted into the disk drive 1100. The serial port interface 1050 is connected to a mouse 1110 and a keyboard 1120, for example. The video adapter 1060 is connected to a display 1130, for example.
[0071] 10, the hard disk drive 1090 stores, for example, an OS 1091, an application program 1092, a program module 1093, and program data 1094. The tables described in the above embodiments are stored in the hard disk drive 1090 or the memory 1010, for example.
[0072] The communication program is stored in the hard disk drive 1090 as a program module in which instructions to be executed by the computer 1000 are written. Specifically, the hard disk drive 1090 stores a program module 1093 in which each process executed by the computer 1000 described in the above embodiment is written.
[0073] Furthermore, data used for information processing by the communication program is stored as program data, for example, in the hard disk drive 1090. Then, the CPU 1020 reads the program module 1093 and program data 1094 stored in the hard disk drive 1090 into the RAM 1012 as necessary, and executes each of the above-described procedures.
[0074] The program module 1093 and program data 1094 related to the communication program are not limited to being stored in the hard disk drive 1090, but may be stored in a removable storage medium, for example, and read by the CPU 1020 via the disk drive 1100. Alternatively, the program module 1093 and program data 1094 related to the control program may be stored in another computer connected via a network such as a LAN (Local Area Network) or a WAN (Wide Area Network), and read by the CPU 1020 via the network interface 1070.
[0075] [Others] Various embodiments have been described in detail in this specification with reference to the drawings, but these embodiments are examples and are not intended to limit the present invention to these embodiments. The features described in this specification can be realized in various ways, including various modifications and improvements based on the knowledge of those skilled in the art.
[0076] Furthermore, the above-mentioned "module (-er suffix, -or suffix)" can be read as a unit, a means, a circuit, etc. For example, a communication module, a control module, and a storage module can be read as a communication unit, a control unit, and a storage unit, respectively.
[0077] REFERENCE SIGNS LIST 100 Communication device 110 Communication unit 120 Control unit 121 Acquisition unit 122 First determination unit 123 Software processing unit 124 Hardware processing unit 125 Calculation unit 126 Second determination unit 127 Third determination unit 128 Change unit 130 Storage unit
Claims
1. A communications device comprising: an acquisition unit that acquires a packet and information about a hardware entry that indicates the target of processing by the hardware; a first determination unit that determines whether an entry for processing the packet acquired by the acquisition unit exists in the hardware; a software processing unit that, if the first determination unit determines that an entry does not exist, forwards the packet acquired by the acquisition unit using software; a calculation unit that calculates a weight value that indicates the degree of effectiveness of the forwarding process by the hardware based on the packet acquired by the acquisition unit; a second determination unit that determines whether the number of entries included in the information about the hardware entry exceeds a threshold; and a modification unit that, if the second determination unit determines that the threshold is not exceeded, adds an entry for the packet forwarded by the software processing unit and the weight value calculated by the calculation unit to the hardware.
2. A communication device according to claim 1, further comprising a hardware processing unit that, when the first determination unit determines that a packet exists, transfers the packet acquired by the acquisition unit using hardware.
3. The communication device described in claim 1, characterized in that the acquisition unit further acquires information about the software's entries indicating the processing target of the software, and the modification unit adds to the hardware the entry of the software's entry information that has the largest weight value calculated by the calculation unit.
4. The communication device described in claim 1, further comprising a third judgment unit which, when the second judgment unit judges that the threshold value is exceeded, judges whether the weight value calculated by the calculation unit is greater than an entry with a smallest weight value among the entry information of the hardware, and when the third judgment unit judges that the weight value is greater than the smallest entry, the modification unit deletes the entry with the smallest weight value among the entry information of the hardware, and adds to the hardware an entry for packets forwarded by the software processing unit.
5. A communication method executed by a computer, comprising: an acquisition step of acquiring a packet and information on a hardware entry indicating a processing target; a first judgment step of judging whether an entry targeting the packet acquired by the acquisition step exists in the hardware; a software processing step of forwarding the packet acquired by the acquisition step by software if it is judged by the first judgment step that an entry does not exist; a calculation step of calculating a weight value indicating the degree of effectiveness of the forwarding process by the hardware based on the packet forwarded by the software processing step; a second judgment step of judging whether the number of entries included in the information on the hardware entry exceeds a threshold; and a modification step of adding, to the hardware, the entry targeting the packet forwarded by the software processing step and the weight value calculated by the calculation step if it is judged by the second judgment step that the threshold is not exceeded.
6. A communication program for causing a computer to function as the communication device according to any one of claims 1 to 4.
Citation Information
Patent Citations
Software and hardware packet flow forwarding routers or switches and methods
JP2006505188A
Router, and method for controlling routing search
JP2010109735A
Load distribution system and load distribution method
WO2020036162A1
