(19)
(11) EP 2 568 690 B1

(12) EUROPEAN PATENT SPECIFICATION

(45) Mention of the grant of the patent:
18.03.2015 Bulletin 2015/12

(21) Application number: 12739728.9

(22) Date of filing: 09.01.2012
(51) International Patent Classification (IPC): 
H04L 29/10(2006.01)
H04L 12/46(2006.01)
H04L 12/24(2006.01)
H04L 29/12(2006.01)
(86) International application number:
PCT/CN2012/070129
(87) International publication number:
WO 2012/100671 (02.08.2012 Gazette 2012/31)

(54)

METHOD FOR BINDING PHYSICAL NETWORK PORTS, NETWORK CARD AND COMMUNICATION SYSTEM

VERFAHREN ZUR BINDUNG PHYSISCHER NETZWERK-PORTS, NETZWERKKARTE UND KOMMUNIKATIONSSYSTEM

PROCÉDÉ D'ASSOCIATION DE PORTS DE RÉSEAU PHYSIQUES, CARTE DE RÉSEAU ET SYSTÈME DE COMMUNICATION


(84) Designated Contracting States:
AL AT BE BG CH CY CZ DE DK EE ES FI FR GB GR HR HU IE IS IT LI LT LU LV MC MK MT NL NO PL PT RO RS SE SI SK SM TR

(30) Priority: 30.01.2011 CN 201110033471

(43) Date of publication of application:
13.03.2013 Bulletin 2013/11

(73) Proprietor: Huawei Technologies Co., Ltd.
Shenzhen, Guangdong 518129 (CN)

(72) Inventors:
  • ZENG, Yungang
    Shenzhen Guangdong 518129 (CN)
  • PENG, Lin
    Shenzhen Guangdong 518129 (CN)
  • ZHANG, Zhongjun
    Shenzhen Guangdong 518129 (CN)

(74) Representative: Pfenning, Meinig & Partner GbR 
Patent- und Rechtsanwälte Theresienhöhe 11a
80339 München
80339 München (DE)


(56) References cited: : 
EP-B1- 1 297 678
CN-A- 1 556 625
CN-A- 102 137 169
US-A1- 2002 184 387
US-A1- 2006 282 591
CN-A- 1 509 030
CN-A- 101 640 620
US-A1- 2002 071 386
US-A1- 2005 094 633
   
       
    Note: Within nine months from the publication of the mention of the grant of the European patent, any person may give notice to the European Patent Office of opposition to the European patent granted. Notice of opposition shall be filed in a written reasoned statement. It shall not be deemed to have been filed until the opposition fee has been paid. (Art. 99(1) European Patent Convention).


    Description

    FIELD OF THE INVENTION



    [0001] The present invention relates to the field of communications technologies, and in particular, to a method, a network card, and a communication system for binding physical network ports.

    BACKGROUND OF THE INVENTION



    [0002] In the field of communications, in order to improve network quality as well as the reliability and bandwidth of a service, multiple physical network ports of a communication device are usually logically bound together and used as one network device.

    [0003] Referring to FIG. 1, FIG. 1 is a schematic diagram of network port binding in the prior art, and the whole system includes two layers in terms of logical functions: an application layer and a physical layer. The physical layer includes multiple physical network cards (such as a physical network card 0 and a physical network card 1 shown in FIG. 1), and each physical network card has some physical network ports (for example, the physical network card 0 has physical network ports 0 and 1). The physical network ports here not only represent a part of interface components that are on the network card and connected to other physical components, but further include function modules (such as PHY (Physical Layer, physical layer) chips) that process data of the physical network ports. The "physical network port" here may be construed as a function module located on the network card and having a data processing capability, and corresponds to a data channel.

    [0004] Each network port in the network card is virtualized into a virtual network card (which is indicated by Eth plus a digital label here) in the application layer (such as an operating system) through the processing of a driver and relevant software, for example, the physical network port 0 is virtualized into Eth0, and a physical network port 2 is virtualized into Eth2.

    [0005] After the physical network ports are virtualized into virtual network cards, these virtual network cards may be bound to form a network device (the network device is not shown in the figure) through a certain binding policy. Because each virtual network card here corresponds to a physical network port, "binding the virtual network cards" may be construed as "binding the physical network ports" and these two statements are not strictly distinguished here.

    [0006] Binding multiple physical network ports facilitates uniform processing in the application layer, thereby implementing load balancing and redundancy backup.

    [0007] During the implementation of the present invention, the inventor finds that the prior art at least has the following defects:

    In the prior art, in the binding of the application layer, binding is performed on the network ports only once, for example, once a load balancing mode is used for binding, a redundancy backup mode cannot be used. While in a practical application, to better meet service demands, binding usually needs to be performed twice on the network ports, for example, redundancy backup is implemented for two network port groups and load balancing is implemented for multiple network ports in each group. Therefore, the prior art fails to implement the requirement of binding twice, thereby failing to better meet the service demands.



    [0008] US2005/094633A1 relates routing data traffic within a communications networking system. In particular, it discloses that a logical port of a switch that comprises a collection of one or more physical ports, regardless of the location of the physical port on the switch.

    [0009] US2002/071386A1 relates to providing failover for channel based communications. In particular, it discloses that a virtual to physical port map is used to map each virtual port to a physical port, this map could be reprogrammed to assign new physical port to virtual port when a fabric failure is detected.

    [0010] US2006/282591A1 relates to computer systems with adapters and multiple operating systems. In particular, it discloses that a Virtual HBA in operating system allows the operating system to use one or more ports on any one of the physical HBA. The virtual is linked to a physical port on physical HBA, and there are binding information corresponds the link between the virtual port and the physical port.

    [0011] US2002/184387A1 relates to a method for connecting between networks, a virtual router, and a system for connecting between networks by using this virtual router. In particular, it discloses tha t a logical port could be used to transfer packet.

    SUMMARY OF THE INVENTION



    [0012] The present invention provides a method, a network card, and a communication system for binding physical network ports, so as to implement the requirement of binding twice and better meet service demands. The technical solutions are described as follows:

    A method for binding physical network ports includes:

    creating a virtual port, where the virtual port corresponds to a virtual network card in an application layer and is capable of being bound, in the application layer, with other created virtual ports through an application layer software; the application layer resides in a communication system which includes an application layer and a physical layer; the virtual port is processed by the application layer as a physical port;

    adding multiple physical network ports, which need to be bound, to the created virtual port to perform uniform processing on data of the multiple physical network ports in a certain manner;

    when the link status of the physical network port is a link up status, determining the physical network port as available physical network port; and

    when a packet needs to be received and/or transmitted, selecting one or more physical network ports from the available physical network ports according to a configured mode to receive and/or transmit the packet;

    wherein the selecting one or more physical network ports from the available physical network ports according to the configured mode to receive and/or transmit the packet comprises:

    if the configured mode is a server load balancing mode, searching correspondence between stored quintuples of packets and physical network ports according to a quintuple of the packet to check whether a corresponding physical network port exists; the quintuple of the packet includes a source IP, Internet Protocol, address, a destination IP address, a source port number, a destination port number, and a protocol number of the packet; and

    if the corresponding physical network port exists, receiving and/or transmitting the packet through the found physical port; if no corresponding physical network port exists, selecting a physical network port with minimum traffic from the available physical network ports, and receiving and/or transmitting the packet through the selected physical network port.



    [0013] A network card includes:

    a creation module, configured to create a virtual port, where the virtual port corresponds to a virtual network card in an application layer and is capable of being bound, in the application layer, with other created virtual ports through an application layer software; the application layer resides in a communication system which includes an application layer and a physical layer; the virtual port is processed by the application layer as a physical port;

    an addition module, configured to add multiple physical network ports, which need to be bound to perform uniform processing on data of the multiple physical network ports in a certain manner;

    a determining module, configured to: when the link status of the physical network port is a link up status" determine the physical network port as available physical network ports; and

    a packet transceiver module, configured to: when a packet needs to be received and/or transmitted, select one or more physical network ports from the available physical network ports according to a configured mode to receive and/or transmit the packet;

    wherein the packet transceiver module comprises:

    a seatch unit, configured to: if the configured mode is a server load balancing mode, search

    correspondence between stored quintuples of packets and physical network ports according to a quintuple of the packet to check whether a corresponding physical network port exists; the quintuple of the packet includes a source IP, Internet Protocol, address, a destination IP address, a source port number, a destination port number, and a protocol number of the packet; and

    a selection unit, configured to: if the corresponding physical network port exists, receive and/or transmit the packet through the found physical network port, and if no corresponding physical network port exists, select a physical network port with minimum traffic from the available physical network ports, and receive and/or transmit the packet through the selected physical network port.



    [0014] A communication system includes a CPU (Central Processing Unit, central processing unit) and a network card, where the network card includes multiple physical network ports;
    the CPU runs an application layer program and is configured to process service data; and
    the network card is configured to create a virtual port, where the virtual port corresponds to a virtual network card in an application layer and is capable of being bound, in the application layer, with other created virtual ports through an application layer software, the application layer resides in a communication system which includes an application layer and a physical layer; the virtual port is processed by the application layer as a physical port; add multiple physical network ports, which need to be bound to perform uniform processing on data of the multiple physical network ports in a certain manner; when the link status of the physical network port is a link up status" determine the physical network port as available physical network ports; and when a packet needs to be received and/or transmitted, select one or more physical network ports from the available physical network ports according to a configured mode to receive and/or transmit the packet;
    wherein the selecting one or more physical network ports from the available physical network ports according to the configured mode to receive and/or transmit the packet comprises:

    if the configured mode is a server load balancing mode, searching correspondence between stored quintuples of packets and physical network ports according to a quintuple of the packet to check whether a corresponding physical network port exists; the quintuple of the packet includes a source IP, Internet Protocol, address, a destination IP address, a source port number, a destination port number, and a protocol number of the packet; and

    if the corresponding physical network port exists, receiving and/or transmitting the packet through the found physical port; if no corresponding physical network port exists, selecting a physical network port with minimum traffic from the available physical network ports, and receiving and/or transmitting the packet through the selected physical network port.



    [0015] In the present invention, a virtual port is created, multiple physical network ports that need to be bound are added to the virtual port, and physical network ports in normal communication in the virtual port are determined as available physical network ports. When a packet needs to be received and/or transmitted, one or more physical network ports are selected from the available physical network ports according to a configured mode to receive and/or transmit the packet. The virtual port corresponds to a virtual network card in the application layer and is capable of being bound, in the application layer, with other created virtual ports through an application layer software. In this way, multiple virtual ports are bound into one virtual network card in the application layer, thereby implementing the requirement of binding twice and better meeting the service demands.

    BRIEF DESCRIPTION OF THE DRAWINGS



    [0016] 

    FIG. 1 is a schematic diagram of network port binding in the prior art;

    FIG. 2 is a flow chart of a method for binding physical network ports according to Embodiment 1 of the present invention;

    FIG. 3 is a flow chart of a method for binding physical network ports according to Embodiment 2 of the present invention;

    FIG. 4 is a schematic diagram of network port binding according to Embodiment 2 of the present invention;

    FIG. 5 is a flow chart of a method for binding physical network ports according to Embodiment 3 of the present invention;

    FIG. 6 is a flow chart of a method for binding physical network ports according to Embodiment 3 of the present invention;

    FIG. 7 is a flow chart of a method for binding physical network ports according to Embodiment 3 of the present invention;

    FIG. 8 is schematic diagram of a network card according to Embodiment 4 of the present invention; and

    FIG. 9 is schematic diagram of a communication system according to Embodiment 5 of the present invention.


    DETAILED DESCRIPTION OF THE EMBODIMENTS



    [0017] To make the objectives, technical solutions, and advantages of the present invention more comprehensible, the following describes the embodiments of the present invention in further detail with reference to the accompanying drawings.

    Embodiment 1



    [0018] As shown in FIG. 2, an embodiment of the present invention provides a method for binding physical network ports, which is applied in a network card device and includes:

    Step 101: Create a virtual port, where the virtual port corresponds to a virtual network card in an application layer and is capable of being bound, in the application layer, with other created virtual ports through an application layer software.

    Step 102: Add multiple physical network ports, which need to be bound, to the created virtual port.

    Step 103: When communication of the physical network ports in the virtual port is normal, determine the physical network ports in normal communication as available physical network ports.

    Step 104: When a packet needs to be received and/or transmitted, select one or more physical network ports from the available physical network ports according to a configured mode to receive and/or transmit the packet.



    [0019] In the embodiment of the present invention, a virtual port is created, multiple physical network ports that need to be bound are added to the virtual port, and physical network ports in normal communication are determined as available physical network ports. When a packet needs to be received and/or transmitted, one or more physical network ports are selected from the available physical network ports according to a configured mode to receive and/or transmit the packet. The virtual port corresponds to a virtual network card in the application layer and is capable of being bound, in the application layer, with other created virtual ports through an application layer software. Therefore, multiple virtual ports may also be bound into one network device in the application layer, thereby implementing the requirement of binding twice and better meeting service demands.

    Embodiment 2



    [0020] As shown in FIG. 3, an embodiment of the present invention provides a method for binding physical network ports. A performing subject of this embodiment is a network card of a terminal, and the method includes:

    Step 201: Create a virtual port when a user designates, in the terminal, multiple physical network ports that need to be bound into a virtual port.



    [0021] A physical layer of the terminal includes multiple physical network ports, and when the user needs to bind multiple physical network ports into the virtual port in the terminal, the user designates, in the terminal, the multiple physical network ports that need to be bound. In addition, the user further configures a binding mode in the terminal, and furthermore, the binding mode configured by the user is recorded in the created virtual port. The binding mode may be a load balancing mode, a redundancy backup mode, or an SLB (Server Load Balancing, Server Load Balancing) mode.

    [0022] The "virtual port" here may be regarded as an intermediate processing module between the physical network ports and an application layer. On one hand, the virtual port is configured to bind multiple physical network ports (that is, to perform uniform processing on data of the multiple physical network ports in a certain manner); on the other hand, each virtual port corresponds to a virtual network card in the application layer. Such a case is similar to that each physical port corresponds to a virtual network card in an application layer in the prior art, and the application layer processes each virtual port as a physical port. Therefore, multiple virtual ports (virtual network cards) created in the physical layer may be bound in the application layer through an existing binding method, so as to obtain a network device. It may be seen that, the virtual port has performed binding on the multiple physical network ports once, and the virtual ports are bound once again in the application layer, so that binding the physical network ports twice may be implemented, thereby better meeting service demands.

    [0023] Specifically, when the virtual port here is implemented by software, the virtual port may be implemented by a structure (for example, C-language-based), or an object (for example, object-oriented programming languages, including Java, C++, and so on), or other similar means according to features of different programming languages, which is not limited here.

    [0024] Step 202: Determine, from the multiple physical network ports that need to be bound, physical network ports that exist in the physical layer and are not bound, and add the determined physical network ports to the created virtual port.

    [0025] In this embodiment, it is assumed that the virtual port may include bound physical network ports and available physical network ports. The "available physical network ports" here refer to ports in normal communication and may be used to receive and/or transmit a packet, and may be classified into "available receiving network ports" and "available transmitting network ports" for better management in implementation.

    [0026] In specific implementation, if the virtual port is a structure or an object, the network ports that need to be bound and the available physical network ports are a member variable of the structure or the object, for example, multiple relevant physical network ports may be recorded in a member variable, where a type of the member variable is an array or a linked list. Definitely, other software implementation methods may be used to record the bound physical network ports and available physical network ports, which are not limited in the embodiment of the present invention.

    [0027] Based on the foregoing software implementation method, adding the determined physical network ports to the virtual port means adding relevant identifiers (such as network port numbers, or numbers of PHYs corresponding to the network ports) of the physical network ports to a member variable of a virtual port object.

    [0028] In addition, to better implement dynamic management, when the virtual port is designed, a data structure that is easy to manage may be used to represent relevant network ports, for example, a linked list is used to manage the network ports, so that network ports are conveniently added or deleted.

    [0029] For the convenience of description, specific software implementation of the bound physical network ports and the available physical network ports is not described below; instead, it is considered that the virtual port has a "list of physical network ports" and a "list of available physical network ports" (the available physical network ports may be classified into a "list of available receiving network ports" and a "list of available transmitting network ports") in logical sense, where the two lists record the bound physical network ports and the available physical network ports respectively.

    [0030] Step 203: Find physical network ports in normal communication from the physical network ports included in the virtual port, and determine the physical network ports in normal communication as available physical network ports.

    [0031] Specifically, traversing is started from a first physical network port in the virtual port according to the "list of physical network ports", and it is judged whether communication of the traversed physical network port is normal. If the communication is normal, it is determined that the traversed physical network port is an available physical network port, and if a physical network port not traversed exists, a next physical network port is traversed. If the communication is abnormal and a physical network port not traversed exists, a next physical network port is traversed. Through the foregoing process, the available physical network ports may be determined and the determined available physical network ports are added to the list of available physical network ports (or the "list of available receiving network ports" and the "list of available transmitting network ports").

    [0032] Whether communication of network ports is normal may be judged through a link (link) status of each network port. Each physical network port in a physical network card has a link status; if communication of a physical network port is normal, the link status of the physical network port is a link up (link up) status, and if communication of a physical network port is abnormal, the link status of the physical network port is a link down (link down) status.

    [0033] As shown in FIG. 4, multiple physical network ports in the physical layer may be bound into a virtual port (indicated by Vport plus a digital label herein), the bound virtual port is located in a virtual port layer, and each virtual port in the virtual port layer corresponds to a virtual network card in the application layer. An existing binding method may be utilized to perform secondary binding of multiple virtual ports, so as to implement the requirement of binding twice and better meet service demands.

    [0034] Step 204: When a packet needs to be received and/or transmitted, select a physical network port from the available physical network ports in the virtual port according to a configured binding mode of the virtual port, and receive and/or transmit the packet through the selected physical network port.

    [0035] The "binding mode" here may also be recorded in the virtual port as a member variable, and by judging a value of the variable corresponding to the "binding mode", one or more physical network ports are selected according to a certain policy to receive and/or transmit the packet.

    [0036] Specifically, when the binding mode is a load balancing mode, each available physical network port included in the virtual port is selected, and the packet is received and/or transmitted through each selected physical network port.

    [0037] When the binding mode is a redundancy mode, a physical network port is designated from the available physical network ports included in the virtual port. If communication of the designated physical network port is normal, the packet is received and/or transmitted through the designated physical network port, and if communication of the designated physical network port is abnormal, a new physical network port in normal communication is designated from remaining physical network ports, and the packet is received and/or transmitted through the designated physical network port.

    [0038] When the binding mode is an SLB mode, a quintuple is extracted from the packet that needs to be received and/or transmitted. Correspondence between stored quintuples of packets and physical network ports is searched according to the extracted quintuple to check whether a corresponding physical network port exists. If the corresponding physical network port exists, the packet is received and/or transmitted through the found physical network port, and if no corresponding physical network port exists, a physical network port with minimum packet traffic is selected from the available physical network ports included in the virtual port, the packet is received and/or transmitted through the selected physical network port, and the extracted quintuple and the selected physical network port are recorded in the correspondence between quintuples of packets and physical network ports.

    [0039] The quintuple of the packet may include a source IP (Internet Protocol, internet protocol) address, a destination IP address, a source port number, a destination port number, and a protocol number of the packet.

    [0040] Furthermore, physical network ports included in each virtual port in the virtual port layer may also be checked and checking operations on each virtual port may specifically be: checking at regular time whether communication of the physical network ports in the virtual port is normal, if the communication is normal, determining the checked physical network ports as available physical network ports, and if the communication is abnormal, determining the checked physical network ports as unavailable physical network ports, and updating each corresponding list according to a checking result.

    [0041] In the embodiment of the present invention, primary binding of the physical network ports is implemented in the physical network card by creating a virtual port in the physical network card, and at the same time, each created virtual port corresponds to a virtual network card in the application layer. Therefore, binding of the virtual ports may also be implemented in the application layer, finally binding the physical network ports twice is implemented, thereby better meeting service demands.

    [0042] In addition, if a data structure such as a linked list is used to manage the physical network ports, a physical network port that need to be bound may be conveniently and dynamically added or deleted subsequently, thereby better meeting the service demands (for example, the number of the bound physical network ports may be increased when a high-bandwidth service needs to be performed). In addition, such dynamic adjustment is merely to add some members and does not conflict with a service processing process. Therefore, such dynamic adjustment does not interrupt a service and better meets the service demands.

    [0043] In addition, through the embodiment of the present invention, not only balancing and redundancy processing is performed on each physical port by utilizing the virtual port, but also traffic control and ACL (Access Control List, Access Control List) control may be performed on the port, thereby implementing Qos (Quality of Service, quality of service) control based on the virtual port and making the implementation of the Qos control more flexible. For example, a variable for counting transmitting and/or receiving tokens is added to member variables of the virtual port and at the same time, a timing processing function for placing a token into the member variable at regular time is added. A traffic condition is judged subsequently according to a value of the variable for counting transmitting and/or receiving tokens, thereby flexibly implementing the traffic control on the virtual port.

    Embodiment 3



    [0044] Based on the foregoing embodiments, an embodiment of the present invention provides a method for binding physical network ports. In this embodiment, it is taken as an example that a virtual port includes at least a list of physical network ports, a list of available transmitting network ports, and a list of available receiving network ports, and description is provided in several stages, where the list of available transmitting network ports and the list of available receiving network ports may also be generally referred to as a "list of available physical network ports".

    I. Creating stage



    [0045] This stage mainly accomplishes steps such as virtual port creation and initialization. Referring to FIG. 5, this stage includes:

    Step 301: Create a virtual port.



    [0046] When multiple physical network ports designated by a user need to be bound into a virtual port according to a configured binding mode, the virtual port is created. The virtual port includes at least a list of physical network ports, a list of available transmitting network ports, and a list of available receiving network ports. The list of physical network ports is used to record each physical network port that needs to be bound and is included in the virtual port, the list of available transmitting network ports is used to record each physical network port that is used for transmitting a packet and included in the virtual port, and the list of available receiving network ports is used to record each physical network port that is used for receiving a packet and included in the virtual port.

    [0047] Step 302: Add a PHY.

    [0048] It is described in the foregoing that a physical network port may be regarded as a function module, each function module (physical network port) corresponds to a processing chip PHY, and adding a physical network port may also be construed as adding a PHY to the list of physical network ports of the virtual port.

    [0049] Step 303: Add a binding mode.

    [0050] Specifically, a member variable that represents the binding mode is set in the virtual port, and "adding a binding mode to the virtual port" may be construed as "assigning a value, which represents the binding mode, to the variable".

    [0051] Furthermore, before a configured binding mode is recorded, it may be further determined whether a network card supports the binding mode. If a network card supports the binding mode, the binding mode is recorded in the virtual port, and if a network card does not support the binding mode the step of binding the virtual port is ended and storage space occupied by the virtual port is released.

    [0052] The network card may support all binding modes, or only support several binding modes. A network card that only supports several binding modes instead of all binding modes further maintains a list of binding modes, where the list of binding modes is used to record binding modes supported by the network card.

    [0053] Correspondingly, operations of determining whether the network card supports the configured binding mode may be: searching the list of binding modes maintained by the network card to check whether the configured binding mode exists. If the configured binding mode exists, it is determined that the network card supports the configured mode, and if the configured binding mode does not exist, it is determined that the network card does not support the configured binding mode.

    [0054] Step 304: Traverse multiple PHYs in the list of physical network ports and check a link status.

    [0055] In the embodiment of the present invention, it is determined whether communication of a physical network port is normal by checking the link status of the PHY

    [0056] Step 305: Judge whether the status is a link up status; if yes, perform step 306; otherwise, perform step 307.

    [0057] Step 306: Add the corresponding PHY to the list of available transmitting network ports and the list of available receiving network ports.

    [0058] Step 307: Judge whether the PHY is the last one; if yes, perform step 308 to end the process; if not, go on to perform step 304.

    [0059] Through the foregoing steps, the virtual port is created and the PHYs (physical network ports) in normal communication are added to the list of available transmitting network ports and the list of available receiving network ports.

    II. Maintenance stage



    [0060] This stage checks a communication status of each network port (PHY) in the list of available network ports by traversing at regular time, so as to add the network port to or delete the network port from the list of available transmitting/receiving network ports.

    [0061] Referring to FIG. 6, this stage includes the following steps:

    Step 311: Check whether set time is timeout; if yes, perform step 312; if not, keep performing step 311.

    Step 312: Traverse PHYs in the list of available network ports and check a PHY status.

    Step 313: Judge whether the PHY status changes; if yes, perform step 314; if not, go on to perform step 312.

    Step 314: Judge whether the PHY status is link up; if yes, perform step 315; if not, perform step 316.

    Step 315: Add the PHY (physical network port) to the list of available transmitting network ports and the list of available receiving network ports, and perform step 317 subsequently.



    [0062] If the PHY status changes and the current status is link up, it indicates that original communication is abnormal and current communication is normal; therefore, the PHY is added to the list of available transmitting/receiving network ports.

    [0063] Step 316: Delete the PHY (physical network port) from the list of available transmitting network ports and the available receiving network ports, and perform step 317 subsequently.

    [0064] If the PHY status changes and the current status is not link up, it indicates that original communication is normal and current communication is abnormal; therefore, the PHY is deleted from the list of available transmitting/receiving network ports.

    [0065] Step 317: Judge whether the PHY is the last PHY in the list of available network ports; if yes, end the process; if not, go on to perform step 312.

    [0066] Through regular detections, the status of each list may be updated at any time, so as to be adapted to application demands of services.

    III. Data processing stage



    [0067] This stage is a data processing stage, that is, when receiving a packet, the network card completes packet data processing according to a corresponding mode.

    [0068] Referring to FIG. 7, this stage includes the following steps:

    Step 321: Judge whether a packet needs to be received and/or transmitted; if yes, perform step 322; if not, keep performing step 321.

    Step 322: Judge whether a mode is an LB (Load Balancing) mode; if yes, perform step 323; if not, perform step 324.

    Step 323: Perform a load balancing mode operation and end the subsequent process.

    Step 324: Judge whether a mode is a redundancy mode; if yes, perform step 325; if not, perform step 326.

    Step 325: Perform a redundancy mode operation, and end the subsequent process.

    Step 326: Judge whether a mode is an SLB (server load balancing) mode; if yes, perform step 327; if not, end the process.

    Step 327: Perform an SLB (server load balancing) mode operation and end the subsequent process.



    [0069] The sequence of the foregoing judgments is not limited. The judgment of whether the mode is the redundancy mode may be performed before the judgment of whether the mode is the LB mode. The mode may be determined by judging a value of a member variable that represents the mode in the virtual port.

    [0070] Operations of the foregoing involved modes are described respectively in detail below:

    1. LB mode



    [0071] Each physical network port in the list of available receiving network ports in the virtual port is obtained and the packet is received through each of the obtained physical network ports, that is, each physical network port receives data, and in this way the load balancing is implemented.

    2. Redundancy mode



    [0072] A physical network port in normal communication is designated from the list of available transmitting/receiving network ports of the virtual port and the packet is received and/or transmitted (which means received or transmitted, or received and transmitted at the same time) through the designated physical network port.

    [0073] Specifically, a physical network port is designated from the list of available transmitting/receiving network ports of the virtual port, and it is judged whether communication of the designated physical network port is normal; if yes, the packet is received and/or transmitted through the designated physical network port; if not, a new physical network port is designated from remaining physical network ports in the list of available transmitting/receiving network ports and the foregoing process is repeated until a physical network port in normal communication is designated to receive and/or transmit the packet.

    [0074] That is, in the redundancy mode, only one network port is used first and if a problem occurs, another network port is used, thereby implementing the backup.

    3. SLB mode



    [0075] A quintuple of the packet is extracted from the packet and correspondence between stored quintuples of packets and transceiver physical network ports is searched according to the extracted quintuple of the packet.

    [0076] If a corresponding physical network port is found, the packet is received and/or transmitted by utilizing the found physical network port, so as to guarantee that the same flow is received and/or transmitted through the same port.

    [0077] If no corresponding physical network port is found, a physical network port with minimum packet traffic is selected from the lists of available receiving and/or transmitting network ports and the selected physical network port is utilized to receive and/or transmit the packet, thereby implementing the load balancing.

    [0078] In addition, the extracted quintuple of the packet and the selected physical network port may be recorded in the correspondence between quintuples of packets and transceiver physical network ports.

    [0079] Through the embodiment of the present invention, primary binding of each physical network port is implemented on the network card, and at the same time, the virtual ports in the present invention are bound once again in the application layer, so that binding the physical network ports twice is finally implemented, thereby better meeting service demands.

    Embodiment 4



    [0080] As shown in FIG. 8, an embodiment of the present invention provides a network card, which includes:

    a creation module 401, configured to create a virtual port, where the virtual port corresponds to a virtual network card in an application layer and is capable of being bound, in the application layer, with other created virtual ports through an application layer software;

    an addition module 402, configured to add multiple physical network ports, which need to be bound, to the created virtual port;

    a determining module 403, configured to: when communication of the physical network ports in the virtual port is normal, determine the physical network ports in normal communication as available physical network ports; and

    a packet transceiver module 404, configured to: when a packet needs to be received and/or transmitted, select one or more physical network ports from the available physical network ports according to a configured mode to receive and/or transmit the packet.



    [0081] The addition module 402 is specifically configured to determine, from the multiple physical network ports that need to be bound, physical network ports that exist in a physical layer and are not bound, and add the determined physical network ports to the created virtual port.

    [0082] Furthermore, the network card further includes:

    a checking module, configured to check at regular time whether communication of the physical network ports in the virtual port is normal; if the communication is normal, determine the checked physical network ports as available physical network ports; if the communication is abnormal, determine the checked physical network ports as unavailable physical network ports.



    [0083] The packet transceiver module 404 is specifically configured to: if the configured mode is a load balancing mode, receive and/or transmit the packet through the available physical network ports.

    [0084] The packet transceiver module 404 is specifically configured to: if the configured mode is a redundancy backup mode, designate a physical network port from the available physical network ports; if communication of the designated physical network port is normal, receive and/or transmit the packet through the designated physical network port; if the communication of the designated physical network port is abnormal, designate a new physical network port in normal communication from the available physical network ports to receive and/or transmit the packet.

    [0085] The packet transceiver module 404 includes:

    a search unit, configured to: if the configured mode is an SLB mode, search correspondence between stored quintuples of packets and physical network ports according to a quintuple of the packet to check whether a corresponding physical network port exists; and

    a selection unit, configured to: if the corresponding physical network port exists, receive and/or transmit the packet through the found physical network port; if no corresponding physical network port exists, select a physical network port with minimum traffic from the available physical network ports and receive and/or transmit the packet through the selected physical network port.



    [0086] If a physical network port of the virtual port needs to be added, the physical network port that needs to be added is added to the virtual port. If a physical network port of the virtual port needs to be deleted, the physical network port that needs to be deleted is deleted from the virtual port. If a binding mode of the virtual port needs to be changed, the binding mode recorded by the virtual port is updated to the changed binding mode. In this way, the obtained virtual port may change the number and the binding mode of the physical network ports as needed.

    [0087] In the embodiment of the present invention, a virtual port is created in the physical layer, multiple physical network ports that need to be bound are added to the created virtual port, physical network ports in normal communication in the virtual port are found, and the physical network ports in normal communication are determined as available physical network ports. When a packet needs to be received and/or transmitted, the packet may be received and/or transmitted through the available physical network port in the virtual port, where the virtual port corresponds to a virtual network card in the application layer and is capable of being bound, in the application layer, with other created virtual ports through an application layer software. In this way, the requirement of binding the physical network ports twice is implemented, thereby better meeting service demands.

    [0088] It should be noted that, in the embodiment of the present invention, each module is a logical function module and does not represent a concrete hardware module. Each module in the embodiment of the present invention may be implemented on the basis of existing hardware processing units of a network card, which is not elaborated here.

    Embodiment 5



    [0089] As shown in FIG. 9, an embodiment of the present invention provides a communication system, which includes a CPU 501 and a network card 502, where the network card 502 includes multiple physical network ports.

    [0090] The CPU 501 is configured to run application layer programs to process service data.

    [0091] The network card 502 is configured to create a virtual port, where the virtual port corresponds to a virtual network card in an application layer and is capable of being bound, in the application layer, with other created virtual ports through an application layer software; add multiple physical network ports, which need to be bound, to the created virtual port; when communication of the physical network ports in the virtual port is normal, determine the physical network ports in normal communication as available physical network ports; and when a packet that needs to be received and/or transmitted, select one or more physical network ports from the available physical network ports according to a configured mode to receive and/or transmit the packet.

    [0092] In the embodiment of the present invention, a virtual port is created in the physical layer, multiple physical network ports that need to be bound are added to the created virtual port, physical network ports in normal communication in the virtual port are found, and the physical network ports in normal communication are determined as available physical network ports. When a packet needs to be received and/or transmitted, the packet may be received and/or transmitted through the available physical network port in the virtual port, where the virtual port corresponds to a virtual

    [0093] network card in the application layer and is capable of being bound, in the application layer, with other created virtual ports through an application layer software. In this way, the requirement of binding the physical network ports twice is implemented, thereby better meeting service demands.

    [0094] The foregoing functions accomplished by a network card device may be implemented on the basis of a network card hardware device in the prior art, for example, the foregoing functions may be implemented by adding program codes corresponding to the embodiment of the present invention to an existing network card processor. Specifically, logical division of the network card device may be performed according to Embodiment 4. Alternatively, persons skilled in the art may divide (for example, create different function modules through software) function modules of the network card device in other similar manners, thereby implementing the functions of the network card.

    [0095] All or part of the contents in the technical solution provided in the foregoing embodiments may be implemented by software programs, and the software programs are stored in readable storage media such as a computer hard disk, an optical disk, or a floppy disk.

    [0096] The foregoing describes exemplary embodiments of the present invention and is not intended to limit the present invention. Any modification, equivalent replacement, or improvement made to the present invention shall fall within the protection scope of the present invention as defined by the appended claims.


    Claims

    1. A method for binding physical network ports, characterized by comprising:

    creating a virtual port, wherein the virtual port corresponds to a virtual network card in an application layer and is capable of being bound, in the application layer, with other created virtual ports through an application layer software; the application layer resides in a communication system which includes an application layer and a physical layer; the virtual port is processed by the application layer as a physical port;

    adding multiple physical network ports, which need to be bound, to the created virtual port to perform uniform processing on data of the multiple physical network ports in a certain manner;

    when the link status of the physical network port is a link up status, determining the physical network port as available physical network port; and

    when a packet needs to be received and/or transmitted, selecting one or more physical network ports from the available physical network ports according to a configured mode to receive and/or transmit the packet;

    wherein the selecting one or more physical network ports from the available physical network ports according to the configured mode to receive and/or transmit the packet comprises:

    if the configured mode is a server load balancing mode, searching correspondence between stored quintuples of packets and physical network ports according to a quintuple of the packet to check whether a corresponding physical network port exists; the quintuple of the packet includes a source IP, Internet Protocol, address, a destination IP address, a source port number, a destination port number, and a protocol number of the packet; and

    if the corresponding physical network port exists, receiving and/or transmitting the packet through the found physical port; if no corresponding physical network port exists, selecting a physical network port with minimum traffic from the available physical network ports, and receiving and/or transmitting the packet through the selected physical network port.


     
    2. The method according to claim 1, wherein the adding the multiple physical network ports, which need to be bound, to the created virtual port comprises:

    determining, from the multiple physical network ports that need to be bound, physical network ports that exist in a physical layer and are not bound, and adding the determined physical network ports to the created virtual port.


     
    3. The method according to claim 1, after the determining the physical network ports in normal communication as the available physical network ports, further comprising:

    checking at regular time whether communication of the physical network ports in the virtual port is normal;

    if the communication is normal, determining the physical network ports as available physical network ports; and

    if the communication is abnormal, determining the physical network ports as unavailable physical network ports.


     
    4. The method according to claim 1, wherein the selecting one or more physical network ports from the available physical network ports according to the configured mode to receive and/or transmit the packet comprises:

    if the configured mode is a load balancing mode, receiving and/or transmitting the packet through the available physical network ports.


     
    5. The method according to claim 1, wherein the selecting one or more physical network ports from the available physical network ports according to the configured mode to receive and/or transmit the packet comprises:

    if the configured mode is a redundancy backup mode, designating a physical network port from the available physical network ports; and

    if communication of the designated physical network port is normal, receiving and/or transmitting the packet through the designated physical network port; if communication of the designated physical network port is abnormal, designating a new physical network port in normal communication from the available physical network ports to receive and/or transmit the packet.


     
    6. A network card, characterized by comprising:

    a creation module (401), configured to create a virtual port, wherein the virtual port corresponds to a virtual network card in an application layer and is capable of being bound, in the application layer, with other created virtual ports through an application layer software; the application layer resides in a communication system which includes an application layer and a physical layer; the virtual port is processed by the application layer as a physical port;

    an addition module (402), configured to add, to the created virtual port, multiple physical network ports that need to be bound to perform uniform processing on data of the multiple physical network ports in a certain manner;

    a determining module (403), configured to: when the link status of the physical network port is a link up status" determine the physical network port as available physical network port; and
    a packet transceiver module (404), configured to: when a packet needs to be received and/or transmitted, select one or more physical network ports from the available physical network ports according to a configured mode to receive and/or transmit the packet;

    wherein the packet transceiver module comprises:

    a search unit, configured to: if the configured mode is a server load balancing mode, search correspondence between stored quintuples of packets and physical network ports according to a quintuple of the packet to cheek whether a corresponding physical network port exists; the quintuple of the packet includes a source IP, Internet Protocol, address, a destination IP address, a source port number, a destination port number, and a protocol number of the packet; and

    a selection unit, configured to: if the corresponding physical network port exists, receive and/or transmit the packet through the found physical network port, and if no corresponding physical network port exists, select a physical network port with minimum traffic from the available physical network ports, and receive and/or transmit the packet through the selected physical network port.


     
    7. The network card according to claim 6, wherein the addition module (402) is specifically configured to determine, from the multiple physical network ports that need to be bound, physical network ports that exist in a physical layer and are not bound, and add the determined physical network ports to the created virtual port.
     
    8. The network card according to claim 6, further comprising:

    a checking module, configured to check at regular time whether communication of the physical network ports in the virtual port is normal; if the communication is normal, determine the physical network ports as available physical network ports; if the communication is abnormal, determine the physical network ports as unavailable physical network ports.


     
    9. The network card according to claim 6, wherein the packet transceiver module (404) is specifically configured to: if the configured mode is a load balancing mode, receive and/or transmit the packet through the available physical network ports.
     
    10. The network card according to claim 6, wherein the packet transceiver module (404) is specifically configured to: if the configured mode is a redundancy backup mode, designate a physical network port from the available physical network ports; if communication of the designated physical network port is normal, receive and/or transmit the packet through the designated physical network port; if the communication of the designated physical network port is abnormal, designate a new physical network port in normal communication from the available physical network ports to receive and/or transmit the packet.
     
    11. A communication system, characterized by comprising a central processing unit CPU (501) and a network card (502), wherein the network card (502) comprises multiple physical network ports;
    the CPU (501) is configured to run application layer programs to process service data; and
    the network card (502) is configured to create a virtual port, wherein the virtual port corresponds to a virtual network card in an application layer and is capable of being bound, in the application layer, with other created virtual ports through an application layer software, the application layer resides in a communication system which includes an application layer and a physical layer; the virtual port is processed by the application layer as a physical port; add, to the created virtual port, multiple physical network ports, which need to be bound to perform uniform processing on data of the multiple physical network ports in a certain manner; when the link status of the physical network port is a link up status" determine the physical network port as available physical network port; and when a packet needs to be received and/or transmitted, select one or more physical network ports from the available physical network ports according to a configured mode to receive and/or transmit the packet;
    wherein the selecting one or more physical network ports from the available physical network ports according to the configured mode to receive and/or transmit the packet comprises:

    if the configured mode is a server load balancing mode, searching correspondence between stored quintuples of packets and physical network ports according to a quintuple of the packet to check whether a corresponding physical network port exists; the quintuple of the packet includes a source IP, Internet Protocol, address, a destination IP address, a source port number, a destination port number, and a protocol number of the packet; and

    if the corresponding physical network port exists, receiving and/or transmitting the packet through the found physical network port; if no corresponding physical network port exists, selecting a physical network port with minimum traffic from the available physical network ports, and receiving and/or transmitting the packet through the selected physical network port.


     


    Ansprüche

    1. Verfahren zum Binden von physikalischen Netzwerkports, dadurch gekennzeichnet, dass es die folgenden Schritte aufweist:

    Erzeugen eines virtuellen Ports, wobei der virtuelle Port einer virtuellen Netzwerkkarte in einer Anwendungsschicht entspricht und imstande ist, in der Anwendungsschicht mit anderen erzeugten virtuellen Ports durch eine Anwendungsschichtsoftware gebunden zu werden; wobei sich die Anwendungsschicht in einem Kommunikationssystem befindet, das eine Anwendungsschicht und eine physikalische Schicht umfasst; wobei der virtuelle Port durch die Anwendungsschicht als ein physikalischer Port verarbeitet wird;

    Hinzufügen von mehreren physikalischen Netzwerkports, die gebunden werden müssen, zu dem erzeugten virtuellen Port, um in einer bestimmten Weise eine einheitliche Verarbeitung von Daten der mehreren physikalischen Netzwerkports durchzuführen;

    wenn der Verbindungsstatus des physikalischen Netzwerkports ein aktiver Verbindungsstatus ist, Festlegen des physikalischen Netzwerkports als verfügbaren physikalischen Netzwerkport; und

    wenn ein Paket empfangen und/oder gesendet werden muss, Auswählen eines oder mehrerer physikalischer Netzwerkports aus den verfügbaren physikalischen Netzwerkports gemäß einer konfigurierten Betriebsart, um das Paket zu empfangen und/oder zu senden;

    wobei das Auswählen eines oder mehrerer physikalischer Netzwerkports aus den verfügbaren physikalischen Netzwerkports gemäß der konfigurierten Betriebsart, um das Paket zu empfangen und/oder zu senden, aufweist:

    wenn die konfigurierte Betriebsart eine Server-Belastungsausgleichsbetriebsart ist, Suchen nach einer Entsprechung zwischen gespeicherten Quintupeln von Paketen und physikalischen Netzwerkports gemäß einem Quintupel des Pakets, um zu prüfen, ob ein entsprechender physikalischer Netzwerkport vorhanden ist; wobei das Quintupel des Pakets eine Ausgangs-IP-Adresse (Internetprotokoll, IP), eine Ziel-IP-Adresse, eine Ausgangsportnummer, eine Zielportnummer und eine Protokollnummer des Pakets umfasst; und

    wenn der entsprechende physikalische Netzwerkport vorhanden ist, Empfangen und/oder Senden des Pakets durch den gefundenen physikalischen Port; wenn kein entsprechender physikalischer Netzwerkport vorhanden ist, Auswählen eines physikalischen Netzwerkports mit minimalen Verkehr aus den verfügbaren physikalischen Netzwerkports, und Empfangen und/oder Senden des Pakets durch den ausgewählten physikalischen Netzwerkport.


     
    2. Verfahren nach Anspruch 1, wobei das Hinzufügen der mehreren physikalischen Netzwerkports, die gebunden werden müssen, zu dem erzeugten virtuellen Port aufweist:

    Feststellen aus den mehreren physikalischen Netzwerkports, die gebunden werden müssen, von physikalischen Netzwerkports, die in einer physikalischen Schicht vorhanden und nicht gebunden sind, und Hinzufügen der festgestellten physikalischen Netzwerkports zu dem erzeugten virtuellen Port.


     
    3. Verfahren nach Anspruch 1, das nach dem Feststellen der physikalischen Netzwerkports, die sich in normaler Kommunikation befinden, als die verfügbaren physikalischen Netzwerkports ferner aufweist:

    Prüfen zu regelmäßigen Zeiten, ob die Kommunikation der physikalischen Netzwerkports im virtuellen Port normal ist;

    wenn die Kommunikation normal ist, Feststellen der physikalischen Netzwerkports als verfügbare physikalische Netzwerkports; und

    wenn die Kommunikation anormal ist, Feststellen der physikalischen Netzwerkports als nicht verfügbare physikalische Netzwerkports.


     
    4. Verfahren nach Anspruch 1, wobei das Auswählen eines oder mehrerer physikalischer Netzwerkports aus den verfügbaren physikalischen Netzwerkports gemäß der konfigurierten Betriebsart, um das Paket zu empfangen und/oder zu senden, aufweist:

    wenn die konfigurierte Betriebsart eine Belastungsausgleichsbetriebsart ist, Empfangen und/oder Senden des Pakets durch die verfügbaren physikalischen Netzwerkports.


     
    5. Verfahren nach Anspruch 1, wobei das Auswählen eines oder mehrerer physikalischer Netzwerkports aus den verfügbaren physikalischen Netzwerkports gemäß der konfigurierten Betriebsart, um das Paket zu empfangen und/oder zu senden, aufweist:

    wenn die konfigurierte Betriebsart eine Redundanzsicherungsbetriebsart ist, Benennen eines physikalischen Netzwerkports aus den verfügbaren physikalischen Netzwerkports; und

    wenn die Kommunikation des benannten physikalischen Netzwerkports normal ist, Empfangen und/oder Senden des Pakets durch den benannten physikalischen Netzwerkport; wenn die Kommunikation des benannten physikalischen Netzwerkports anormal ist, Benennen eines neuen physikalischen Netzwerkports, der sich in normaler Kommunikation befindet, aus den verfügbaren physikalischen Netzwerkports, um das Paket zu empfangen und/oder zu senden.


     
    6. Netzwerkkarte, dadurch gekennzeichnet, dass sie Folgendes aufweist:

    ein Erzeugungsmodul (401), das konfiguriert ist, einen virtuellen Port zu erzeugen, wobei der virtuelle Port einer virtuellen Netzwerkkarte in einer Anwendungsschicht entspricht und imstande ist, in der Anwendungsschicht mit anderen erzeugten virtuellen Ports durch eine Anwendungsschichtsoftware gebunden zu werden; wobei sich die Anwendungsschicht in einem Kommunikationssystem befindet, das eine Anwendungsschicht und eine physikalische Schicht umfasst; wobei der virtuelle Port durch die Anwendungsschicht als ein physikalischer Port verarbeitet wird;

    ein Hinzufügungsmodul (402), das konfiguriert ist, zu dem erzeugten virtuellen Port mehrere physikalische Netzwerkports hinzuzufügen, die gebunden werden müssen, um in einer bestimmten Weise eine einheitliche Verarbeitung von Daten der mehreren physikalischen Netzwerkports durchzuführen;

    ein Feststellungsmodul (403), das konfiguriert ist, wenn der Verbindungsstatus des physikalischen Netzwerkports ein aktiver Verbindungsstatus ist, den physikalischen Netzwerkport als verfügbaren physikalischen Netzwerkport festzustellen; und

    ein Pakettransceiver-Modul (404), das konfiguriert ist, wenn ein Paket empfangen und/oder gesendet werden muss, einen oder mehrere physikalische Netzwerkports aus den verfügbaren physikalischen Netzwerkports gemäß einer konfigurierten Betriebsart auszuwählen, um das Paket zu empfangen und/oder zu senden;

    wobei das Pakettransceiver-Modul aufweist:

    eine Sucheinheit, die konfiguriert ist, wenn die konfigurierte Betriebsart eine Server-Belastungsausgleichsbetriebsart ist, eine Entsprechung zwischen gespeicherten Quintupeln von Paketen und physikalischen Netzwerkports gemäß einem Quintupel des Pakets zu suchen, um zu prüfen, ob ein entsprechender physikalischer Netzwerkport vorhanden ist; wobei das Quintupel des Pakets eine Ausgangs-IP-Adresse, eine Ziel-IP-Adresse, eine Ausgangsportnummer, eine Zielportnummer und

    eine Protokollnummer des Pakets umfasst; und

    eine Auswahleinheit, die konfiguriert ist, wenn der entsprechende physikalische Netzwerkport vorhanden ist, das Paket durch den gefundenen physikalischen Netzwerkport zu empfangen und/oder zu senden, und wenn kein entsprechender physikalischer Netzwerkport vorhanden ist, einen physikalischen Netzwerkport mit minimalen Verkehr aus den verfügbaren physikalischen Netzwerkports auszuwählen, und das Paket durch den ausgewählten physikalischen Netzwerkport zu empfangen und/oder zu senden.


     
    7. Netzwerkkarte nach Anspruch 6, wobei das Hinzufügungsmodul (402) insbesondere konfiguriert ist, aus den mehreren physikalischen Netzwerkports, die gebunden werden müssen, physikalische Netzwerkports festzustellen, die in einer physikalischen Schicht vorhanden und nicht gebunden sind, und die festgestellten physikalischen Netzwerkports zu dem erzeugten virtuellen Port hinzuzufügen.
     
    8. Netzwerkkarte nach Anspruch 6, die ferner aufweist:

    ein Prüfmodul, das konfiguriert ist, zu regelmäßigen Zeiten zu prüfen, ob die Kommunikation der physikalischen Netzwerkports im virtuellen Port normal ist; wenn die Kommunikation normal ist, die physikalischen Netzwerkports als verfügbare physikalische Netzwerkports festzustellen; wenn die Kommunikation anormal ist, die physikalischen Netzwerkports als nicht verfügbare physikalische Netzwerkports festzustellen.


     
    9. Netzwerkkarte nach Anspruch 6, wobei das Pakettransceiver-Modul (404) insbesondere konfiguriert ist, wenn die konfigurierte Betriebsart eine Belastungsausgleichsbetriebsart ist, das Paket durch die verfügbaren physikalischen Netzwerkports zu empfangen und/oder zu senden.
     
    10. Netzwerkkarte nach Anspruch 6, wobei das Pakettransceiver-Modul (404) insbesondere konfiguriert ist, wenn die konfigurierte Betriebsart eine Redundanzsicherungsbetriebsart ist, einen physikalischen Netzwerkport aus den verfügbaren physikalischen Netzwerkports zu benennen; wenn die Kommunikation des benannten physikalischen Netzwerkports normal ist, das Paket durch den benannten physikalischen Netzwerkport zu empfangen und/oder zu senden; wenn die Kommunikation des benannten physikalischen Netzwerkports anormal ist, einen neuen physikalischen Netzwerkport, der sich in normaler Kommunikation befindet, aus den verfügbaren physikalischen Netzwerkports zu benennen, um das Paket zu empfangen und/oder zu senden.
     
    11. Kommunikationssystem, dadurch gekennzeichnet, dass es eine Zentraleinheit (central processing unit, CPU) (501) und eine Netzwerkkarte (502) aufweist, wobei die Netzwerkkarte (502) mehrere physikalische Netzwerkports aufweist;
    die CPU (501) konfiguriert ist, Anwendungsschichtprogramme auszuführen, um Dienstdaten zu verarbeiten; und
    die Netzwerkkarte (502) konfiguriert ist, einen virtuellen Port zu erzeugen, wobei der virtuelle Port einer virtuellen Netzwerkkarte in einer Anwendungsschicht entspricht und imstande ist, in der Anwendungsschicht mit anderen erzeugten virtuellen Ports durch eine Anwendungsschichtsoftware gebunden zu werden, wobei sich die Anwendungsschicht in einem Kommunikationssystem befindet, das eine Anwendungsschicht und eine physikalische Schicht umfasst; wobei der virtuelle Port durch die Anwendungsschicht als ein physikalischer Port verarbeitet wird; zu dem erzeugten virtuellen Port mehrere physikalische Netzwerkports hinzuzufügen, die gebunden werden müssen, um in einer bestimmten Weise eine einheitliche Verarbeitung von Daten der mehreren physikalischen Netzwerkports durchzuführen; wenn der Verbindungsstatus des physikalischen Netzwerkports ein aktiver Verbindungsstatus ist, den physikalischen Netzwerkport als verfügbaren physikalischen Netzwerkport festzustellen; und wenn ein Paket empfangen und/oder gesendet werden muss, einen oder mehrere physikalische Netzwerkports aus den verfügbaren physikalischen Netzwerkports gemäß einer konfigurierten Betriebsart auszuwählen, um das Paket zu empfangen und/oder zu senden;
    wobei das Auswählen eines oder mehrerer physikalischer Netzwerkports aus den verfügbaren physikalischen Netzwerkports gemäß der konfigurierten Betriebsart, um das Paket zu empfangen und/oder zu senden, aufweist:

    wenn die konfigurierte Betriebsart eine Server-Belastungsausgleichsbetriebsart ist, Suchen nach einer Entsprechung zwischen gespeicherten Quintupeln von Paketen und physikalischen Netzwerkports gemäß einem Quintupel des Pakets, um zu prüfen, ob ein entsprechender physikalischer Netzwerkport vorhanden ist; wobei das Quintupel des Pakets eine Ausgangs-IP-Adresse, eine Ziel-IP-Adresse, eine Ausgangsportnummer, eine Zielportnummer und eine Protokollnummer des Pakets umfasst; und

    wenn der entsprechende physikalische Netzwerkport vorhanden ist, Empfangen und/oder Senden des Pakets durch den festgestellten physikalischen Netzwerkport; wenn kein entsprechender physikalischer Netzwerkport vorhanden ist, Auswählen eines physikalischen Netzwerkports mit minimalen Verkehr aus den verfügbaren physikalischen Netzwerkports, und Empfangen und/oder Senden des Pakets durch den ausgewählten physikalischen Netzwerkport.


     


    Revendications

    1. Procédé d'association de ports de réseau physiques, caractérisé en ce qu'il comprend les étapes suivantes :

    créer un port virtuel, où le port virtuel correspond à une carte de réseau virtuelle dans une couche d'application et peut être associé, dans la couche d'application, à d'autres ports virtuels créés par l'intermédiaire d'un logiciel de couche d'application ; la couche d'application réside dans un système de communication qui comprend une couche d'application et une couche physique ; le port virtuel est traité par la couche d'application comme un port physique ;

    ajouter plusieurs ports de réseau physiques, devant être associés, au port virtuel créé pour procéder à un traitement uniforme sur des données de la pluralité de ports de réseau physiques, d'une certaine manière ;

    lorsque le statut de liaison du port de réseau physique est un statut de connexion, déterminer le port de réseau physique comme port de réseau physique disponible ; et

    lorsqu'un paquet doit être reçu et/ou transmis, sélectionner un ou plusieurs ports de réseau physiques parmi les ports de réseau physiques disponibles conformément à un mode configuré pour recevoir et/ou transmettre le paquet ;

    où la sélection d'un ou de plusieurs ports de réseau physiques parmi les ports de réseau physiques disponibles conformément au mode configuré pour recevoir et/ou transmettre le paquet comprend les étapes suivantes :

    si le mode configuré est un mode d'équilibrage de charge de serveur, rechercher une correspondance entre des quintuplés de paquets stockés et des ports de réseau physiques conformément à un quintuplé du paquet pour vérifier si un port de réseau physique correspondant existe ; le quintuplé du paquet comprend une adresse de protocole Internet, IP, source, une adresse IP de destination, un numéro de port source, un numéro de port de destination et un numéro de protocole du paquet ; et

    si le port de réseau physique correspondant existe, recevoir et/ou transmettre le paquet à travers le port physique trouvé ; si aucun port de réseau physique correspondant n'existe, sélectionner un port de réseau physique avec un trafic minimum parmi les ports de réseau physiques disponibles, et recevoir et/ou transmettre le paquet à travers le port de réseau physique sélectionné.


     
    2. Procédé selon la revendication 1, dans lequel l'ajout de plusieurs ports de réseau physiques, qui doivent être associés, au port virtuel créé, comprend les étapes suivantes :

    déterminer, à partir de la pluralité de ports de réseau physiques qui doivent être associés, des ports de réseau physiques qui existent dans une couche physique et qui ne sont pas associés, et ajouter les ports de réseau physiques déterminés au port virtuel créé.


     
    3. Procédé selon la revendication 1, comprenant en outre, après avoir déterminé les ports de réseau physiques en communication normale comme ports de réseau physiques disponibles, les étapes suivantes :

    vérifier à intervalles réguliers si la communication des ports de réseau physiques dans le port virtuel est normale ;

    si la communication est normale, déterminer les ports de réseau physiques comme ports de réseau physiques disponibles ; et

    si la communication est anormale, déterminer les ports de réseau physiques comme ports de réseau physiques non disponibles.


     
    4. Procédé selon la revendication 1, dans lequel la sélection d'un ou plusieurs ports de réseau physiques parmi les ports de réseau physiques disponibles conformément au mode configuré pour recevoir et/ou transmettre le paquet comprend l'étape suivante :

    si le mode configuré est un mode d'équilibrage de charge, recevoir et/ou transmettre le paquet à travers les ports de réseau physiques disponibles.


     
    5. Procédé selon la revendication 1, dans lequel la sélection d'un ou plusieurs ports de réseau physiques parmi les ports de réseau physiques disponibles conformément au mode configuré pour recevoir et/ou transmettre le paquet comprend les étapes suivantes :

    si le mode configuré est un mode de double sauvegarde, désigner un port de réseau physique parmi les ports de réseau physiques disponibles ; et

    si la communication du port de réseau physique désigné est normale, recevoir et/ou transmettre le paquet à travers le port de réseau physique désigné ; si la communication du port de réseau physique désigné est anormale, désigner un nouveau port de réseau physique en communication normale parmi les ports de réseau physiques disponibles pour recevoir et/ou transmettre le paquet.


     
    6. Carte de réseau, caractérisée en ce qu'elle comprend :

    un module de création (401), configuré pour créer un port virtuel, où le port virtuel correspond à une carte de réseau virtuelle dans une couche d'application et peut être associé, dans la couche d'application, à d'autres ports virtuels créés par l'intermédiaire d'un logiciel de couche d'application ; la couche d'application réside dans un système de communication qui comprend une couche d'application et une couche physique ;

    le port virtuel est traité par la couche d'application comme un port physique ;

    un module d'ajout (402), configuré pour ajouter, au port virtuel créé, plusieurs ports de réseau physiques, devant être associés, pour procéder à un traitement uniforme sur des données de la pluralité de ports de réseau physiques, d'une certaine manière ;

    un module de détermination (403), configuré pour : lorsque le statut de liaison du port de réseau physique est un statut de connexion, déterminer le port de réseau physique comme port de réseau physique disponible ; et

    un module émetteur-récepteur de paquets (404), configuré pour : lorsqu'un paquet doit être reçu et/ou transmis, sélectionner un ou plusieurs ports de réseau physiques parmi les ports de réseau physiques disponibles conformément à un mode configuré pour recevoir et/ou transmettre le paquet ;

    où le module émetteur-récepteur de paquets comprend :

    une unité de recherche, configurée pour : si le mode configuré est un mode d'équilibrage de charge de serveur, rechercher une correspondance entre des quintuplés de paquets stockés et des ports de réseau physiques conformément à un quintuplé du paquet pour vérifier si un port. de réseau physique correspondant existe ;

    le quintuplé du paquet comprend une adresse de protocole Internet, IP, source, une adresse IP de destination, un numéro de port source, un numéro de port de destination et un numéro de protocole du paquet ; et

    une unité de sélection, configurée pour : si le port de réseau physique correspondant existe, recevoir et/ou transmettre le paquet à travers le port de réseau physique trouvé, et si aucun port de réseau physique correspondant n'existe, sélectionner un port de réseau physique avec un trafic minimum parmi les ports de réseau physiques disponibles, et recevoir et/ou transmettre le paquet à travers le port de réseau physique sélectionné.


     
    7. Carte de réseau selon la revendication 6, dans laquelle le module d'ajout (402) est spécifiquement configuré pour déterminer, à partir de la pluralité de ports de réseau physiques qui doivent être associés, des ports de réseau physiques qui existent dans une couche physique et qui ne sont pas associés, et ajouter les ports de réseau physiques déterminés au port virtuel créé.
     
    8. Carte de réseau selon la revendication 6, comprenant en outre :

    un module de vérification, configuré pour vérifier à intervalles réguliers si la communication des ports de réseau physiques dans le port virtuel est normale ; si la communication est normale, pour déterminer les ports de réseau physiques comme ports de réseau physiques disponibles ; si la communication est anormale, pour déterminer les ports de réseau physiques comme ports de réseau physiques non disponibles.


     
    9. Carte de réseau selon la revendication 6, dans laquelle le module émetteur-récepteur de paquets (404) est spécifiquement configuré pour : si le mode configuré est un mode d'équilibrage de charge, recevoir et/ou transmettre le paquet à travers les ports de réseau physiques disponibles.
     
    10. Carte de réseau selon la revendication 6, dans laquelle le module émetteur-récepteur de paquets (404) est spécifiquement configuré pour : si le mode configuré est un mode de double sauvegarde, désigner un port de réseau physique parmi les ports de réseau physiques disponibles ; si la communication du port de réseau physique désigné est normale, recevoir et/ou transmettre le paquet à travers le port de réseau physique désigné ; si la communication du port de réseau physique désigné est anormale, désigner un nouveau port de réseau physique en communication normale parmi les ports de réseau physiques disponibles pour recevoir et/ou transmettre le paquet.
     
    11. Système de communication, caractérisé en ce qu'il comprend une unité centrale de traitement CPU (501) et une carte de réseau (502), où la carte de réseau (502) comprend plusieurs ports de réseau physiques ;
    la CPU (501) est configurée pour exécuter des programmes de couche d'application pour traiter des données de service ; et
    la carte de réseau (502) est configurée pour créer un port virtuel, où le port virtuel correspond à une carte de réseau virtuelle dans une couche d'application et peut être associé, dans la couche d'application, à d'autres ports virtuels créés par l'intermédiaire d'un logiciel de couche d'application ; la couche d'application réside dans un système de communication qui comprend une couche d'application et une couche physique ; le port virtuel est traité par la couche d'application comme un port physique ; pour ajouter, au port virtuel créé, plusieurs ports de réseau physiques, devant être associés, pour procéder à un traitement uniforme sur des données de la pluralité de ports de réseau physiques, d'une certaine manière ; lorsque le statut de liaison du port de réseau physique est un statut de connexion, pour déterminer le port de réseau physique comme port de réseau physique disponible ; et, lorsqu'un paquet doit être reçu et/ou transmis, pour sélectionner un ou plusieurs ports de réseau physiques parmi les ports de réseau physiques disponibles conformément à un mode configuré pour recevoir et/ou transmettre le paquet ;
    où la sélection d'un ou plusieurs ports de réseau physiques parmi les ports de réseau physiques disponibles conformément au mode configuré pour recevoir et/ou transmettre le paquet comprend les étapes suivantes :

    si le mode configuré est un mode d'équilibrage de charge de serveur, rechercher une correspondance entre des quintuplés de paquets stockés et des ports de réseau physiques conformément à un quintuplé du paquet pour vérifier si un port de réseau physique correspondant existe ; le quintuplé du paquet comprend une adresse de protocole Internet, IP, source, une adresse IP de destination, un numéro de port source, un numéro de port de destination et un numéro de protocole du paquet ; et

    si le port de réseau physique correspondant existe, recevoir et/ou transmettre le paquet à travers le port de réseau physique trouvé ; si aucun port de réseau physique correspondant n'existe, sélectionner un port de réseau physique avec un trafic minimum parmi les ports de réseau physiques disponibles, et recevoir et/ou transmettre le paquet à travers le port de réseau physique sélectionné.


     




    Drawing























    Cited references

    REFERENCES CITED IN THE DESCRIPTION



    This list of references cited by the applicant is for the reader's convenience only. It does not form part of the European patent document. Even though great care has been taken in compiling the references, errors or omissions cannot be excluded and the EPO disclaims all liability in this regard.

    Patent documents cited in the description