CN109672575A - Data processing method and electronic equipment - Google Patents

Data processing method and electronic equipment Download PDF

Info

Publication number
CN109672575A
CN109672575A CN201910093781.6A CN201910093781A CN109672575A CN 109672575 A CN109672575 A CN 109672575A CN 201910093781 A CN201910093781 A CN 201910093781A CN 109672575 A CN109672575 A CN 109672575A
Authority
CN
China
Prior art keywords
core
numerical value
queues
receiving
interface
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201910093781.6A
Other languages
Chinese (zh)
Other versions
CN109672575B (en
Inventor
徐炽云
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
New H3C Technologies Co Ltd Hefei Branch
Original Assignee
New H3C Technologies Co Ltd Hefei Branch
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by New H3C Technologies Co Ltd Hefei Branch filed Critical New H3C Technologies Co Ltd Hefei Branch
Priority to CN201910093781.6A priority Critical patent/CN109672575B/en
Publication of CN109672575A publication Critical patent/CN109672575A/en
Application granted granted Critical
Publication of CN109672575B publication Critical patent/CN109672575B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0896Bandwidth or capacity management, i.e. automatically increasing or decreasing capacities
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0893Assignment of logical groups to network elements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L49/00Packet switching elements
    • H04L49/30Peripheral units, e.g. input or output ports
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L49/00Packet switching elements
    • H04L49/30Peripheral units, e.g. input or output ports
    • H04L49/3036Shared queuing

Abstract

Present applicant proposes a kind of data processing method and electronic equipments, it is related to field of computer technology, in the starting of NFV system, it is all different if the quantity of the core of NFV system distribution with each numerical value in numerical value group, then by determining the first numerical value in numerical value group, and then the target core of starting and the first numerical value corresponding number, and each VF interface starting and the object message of the first numerical value corresponding number receive and dispatch set of queues, so that each object message transmitting-receiving set of queues of the corresponding starting of each VF interface and each target core correspond, and then target nuclear energy is made enough to pass through respectively corresponding object message transmitting-receiving set of queues transmitting-receiving message, NFV system can start, a kind of data processing method provided herein and electronic equipment, the packet sending and receiving for enabling the quantity of the core distributed for NFV system to start with VF interface When the quantity of set of queues is not identical, NFV system can start.

Description

Data processing method and electronic equipment
Technical field
This application involves field of computer technology, in particular to a kind of data processing method and electronic equipment.
Background technique
SRIOV (Single Root I/O Virtualization, single input and output virtualization) is a kind of based on hard The virtualization solution of part allows to share PCI (Peripheral Component between different virtual machines or container Interconnect, Peripheral component interface) equipment, so that virtually on PF (Physical Function, physical function) port VF (Virtualized Function, virtualization) port can directly use the hardware capability of PCI, and virtually in same Different VF interfaces on one port PF can share one or more physical resources, to improve efficiency, wherein Internet resources It calculates and deployment expense is mainly on hardware device.
Summary of the invention
The application's is designed to provide a kind of data processing method and electronic equipment, makes the core distributed for NFV system When the quantity for the packet sending and receiving set of queues that quantity and VF interface can start is not identical, NFV system can start.
To achieve the goals above, the embodiment of the present application the technical solution adopted is as follows:
In a first aspect, the embodiment of the present application provides a kind of data processing method, it is applied to electronic equipment, the electronics is set Standby to be stored with network function virtualization NFV system, the NFV system includes at least two virtual functions VF interfaces, it is described at least Multiple corresponding packet sending and receiving queues have been pre-created in each VF interface in two VF interfaces, and the electronic equipment is the NFV System is assigned multiple cores, which comprises in NFV system starting, if the number of the core of NFV system distribution Amount is all different with each numerical value in numerical value group, the first numerical value is determined in the numerical value group, wherein first numerical value is small Each numerical value in the quantity of the core distributed for the NFV system, the numerical value group indicates that each VF interface can start Packet sending and receiving set of queues quantity;The target core of starting and the first numerical value corresponding number, and each VF interface opens The dynamic object message with the first numerical value corresponding number receives and dispatches set of queues, so that the corresponding starting of each VF interface is each The object message transmitting-receiving set of queues and each target core correspond;The target core passes through respectively corresponding described Object message receives and dispatches set of queues and receives and dispatches message.
Second aspect, the embodiment of the present application provide a kind of electronic equipment, including processor, memory and network interface Block, network function virtualization NFV system is stored in the memory, the network interface card virtually there are at least two virtual function Can VF interface, multiple corresponding packet sending and receiving queues have been pre-created in each VF interface in at least two VF interface, described Electronic equipment is that the NFV system is assigned multiple cores;The processor is used for, in NFV system starting, if described The quantity of the core of NFV system distribution is all different with each numerical value in numerical value group, and the first numerical value is determined in the numerical value group, Wherein, first numerical value is less than the quantity of the core for NFV system distribution, and each numerical value in the numerical value group indicates institute State the quantity of the bootable packet sending and receiving set of queues of each VF interface;The processor is also used to, starting and first numerical value The target core of corresponding number, and each VF interface starting and the object message of the first numerical value corresponding number receive and dispatch queue Group, so that each object message transmitting-receiving set of queues of the corresponding starting of each VF interface and each target core are one by one It is corresponding;The processor is also used to, and the target core receives and dispatches set of queues by the respectively corresponding object message and transmits and receive telegrams Text.
Compared with the existing technology, a kind of data processing method and electronic equipment provided by the embodiment of the present application, in NFV system When system starting, it is all different if the quantity of the core of NFV system distribution with each numerical value in numerical value group, then by numerical value group In determine the first numerical value, and then start the target core with the first numerical value corresponding number, and the starting of each VF interface and the first number The object message for being worth corresponding number receives and dispatches set of queues, so that each object message of the corresponding starting of each VF interface receives and dispatches set of queues It is corresponded with each target core, and then so that target nuclear energy is enough passed through respectively corresponding object message transmitting-receiving set of queues and transmit and receive telegrams Text, NFV system can start, and compared with the prior art, the quantity of the core distributed for NFV system and VF interface be enable to start When the quantity of packet sending and receiving set of queues is not identical, NFV system can start.
To enable the above objects, features, and advantages of the application to be clearer and more comprehensible, preferred embodiment is cited below particularly, and cooperate Appended attached drawing, is described in detail below.
Detailed description of the invention
Technical solution in ord to more clearly illustrate embodiments of the present application, below will be to needed in the embodiment attached Figure is briefly described, it should be understood that the following drawings illustrates only some embodiments of the application, therefore is not construed as pair The restriction of range for those of ordinary skill in the art without creative efforts, can also be according to this A little attached drawings obtain other relevant attached drawings.
Fig. 1 is a kind of block diagram of NFV system provided by the embodiments of the present application;
Fig. 2 is a kind of illustrative application scene figure provided by the embodiment of the present application;
Fig. 3 is another kind illustrative application scene figure provided by the embodiment of the present application;
Fig. 4 shows a kind of a kind of schematic flow chart of data processing method provided by the embodiment of the present application;
Fig. 5 is a kind of schematic flow chart of the sub-step of S103 in Fig. 4.
In figure: 300- electronic equipment;301- processor;302- memory;303- bus;304- network interface card.
Specific embodiment
To keep the purposes, technical schemes and advantages of the embodiment of the present application clearer, below in conjunction with the embodiment of the present application In attached drawing, the technical scheme in the embodiment of the application is clearly and completely described, it is clear that described embodiment is Some embodiments of the present application, instead of all the embodiments.The application being usually described and illustrated herein in the accompanying drawings is implemented The component of example can be arranged and be designed with a variety of different configurations.
Therefore, the detailed description of the embodiments herein provided in the accompanying drawings is not intended to limit below claimed Scope of the present application, but be merely representative of the selected embodiment of the application.Based on the embodiment in the application, this field is common Technical staff's every other embodiment obtained without creative efforts belongs to the model of the application protection It encloses.
It should also be noted that similar label and letter indicate similar terms in following attached drawing, therefore, once a certain Xiang Yi It is defined in a attached drawing, does not then need that it is further defined and explained in subsequent attached drawing.Meanwhile the application's In description, term " first ", " second " etc. are only used for distinguishing description, are not understood to indicate or imply relative importance.
It should be noted that, in this document, relational terms such as first and second and the like are used merely to a reality Body or operation are distinguished with another entity or operation, are deposited without necessarily requiring or implying between these entities or operation In any actual relationship or order or sequence.Moreover, the terms "include", "comprise" or its any other variant are intended to Non-exclusive inclusion, so that the process, method, article or equipment including a series of elements is not only wanted including those Element, but also including other elements that are not explicitly listed, or further include for this process, method, article or equipment Intrinsic element.In the absence of more restrictions, the element limited by sentence "including a ...", it is not excluded that There is also other identical elements in process, method, article or equipment including the element.
With reference to the accompanying drawing, it elaborates to some embodiments of the application.In the absence of conflict, following Feature in embodiment and embodiment can be combined with each other.
NFV (Network Function Virtualization, network function virtualization) system is a can to install Virtual unit on common X86 server adds in conjunction with DPDK (Data Plan Develop Kit, data surface development kit) Fast technology can realize protocol stack forwarding capability in User space.
For example, please referring to Fig. 1, Fig. 1 is a kind of block diagram of electronic equipment 300 provided by the embodiments of the present application. Electronic equipment 300 includes processor 301, memory 302, bus 303 and (the Network Interface of network interface card 304 Card, NIC), processor 301, memory 302 and network interface card 304 are communicated with each other by bus 303.
Wherein, processor 301 is for executing the executable module stored in memory 302, such as computer program.This Shen Please embodiment meaning processor 301, can be a processing element, be also possible to the general designation of multiple processing elements, for example, should Processor 301 can be central processing unit (Central Processing Unit, CPU), be also possible to specific integrated circuit (Application Specific Integrated Circuit, ASIC), or be arranged to implement the embodiment of the present application One or more integrated circuits, such as: one or more microprocessors (Digital Signal Processor, DSP), Or, one or more field programmable gate array (Field Programmable Gate Array, FPGA).
Memory 302, can be used for storing various programs and data in electronic equipment 300, for example NFV system is corresponding Program instruction.Memory 302 can be a storage device, be also possible to the general designation of multiple memory elements, and memory 302 can be with It also may include nonvolatile memory (non-including random access memory (random access memory, RAM) Volatile memory), for example, magnetic disk storage, flash memory (Flash) etc..
It is total that bus 303 can be industry standard architecture (Industry Standard Architecture, ISA) Line, external equipment interconnection (Peripheral Component Interconnect, PCI) bus or extension Industry Standard Architecture Structure (Extended Industry Standard Architecture, EISA) bus etc..The bus 303 can be divided into ground Location bus, data/address bus, control bus etc..Only to be indicated with a four-headed arrow in Fig. 1, it is not intended that only convenient for indicating There are a bus or a type of bus.
Network interface card 304 is that computer and transmission are connected in local area network for the networking component for operating mainly in link layer The interface of medium, the physical connection and electric signal being not only able to achieve between local network transport medium match, and further relate to the hair of frame It send and receives, the function of the encapsulation of frame and opening, medium access control, the coding of data and decoding and data buffer storage, and The port PF is provided, and fictionalizes VF interface using virtualization on the port PF, is used for NFV system.
For storing program, such as the program instruction to implement NFV function, processor 301 is receiving memory 302 After executing instruction, the program that memory 302 is stored is executed to realize the data processing method of the embodiment of the present application announcement.
DPDK platform provides the driving of multiple types network interface card in User space, to realize the transmitting-receiving of message.Wherein, Processor 301 includes multiple cores (core), and network interface card, can be at the end PF according to virtualization for providing the port PF VF interface is fictionalized on mouthful, so that NFV system receives and dispatches message using the VF interface fictionalized, and NFV is distributed to by processor 301 At least one core of system handles message, wherein processor 301 is the quantity of the core of NFV system distribution, can be NFV system When starting, the gain of parameter of user's input is received by processor 301, it can also be by preset gain of parameter.For example, NFV system On startup, the parameter of user's input is specified: core 0 and core 1 are as core used in NFV system, then processor 301 determines distribution Core to NFV system includes 1 two cores of core 0 and core, and core 0 and core 1 are isolated, only allow the NFV system using core 0 and Core 1.Wherein, processor 301 distributes at least one core of NFV system, be finger processor 301 distribute at least one core give NFV system System uses, i.e., provides NFV system for the expense of core by processor 301.
But in virtual environment, the packet sending and receiving number of queues that virtual port can create will receive the limit of hardware port System.For example, in some network interface cards, all ports PF that network interface card is included can at most create 128 VF and connect Mouthful, such as the network interface card with 4 ports PF, 32 VF interfaces of each port PF most multipotency creation, and When receiving and dispatching message, the maximum queue number that can start in VF interface depends on the corresponding port PF of VF interface.Due to hardware port Limitation, in some network interface cards, the maximum quantity of transmit queue and receiving queue that VF interface can start is 4, And receiving queue must be 2 power side, that is to say, that the quantity that receiving queue can start is only 1,2,4.Therefore, exist In virtual environment, if being that NFV system virtualization goes out VF interface, each VF that NFV system includes in the port PF of network interface card The maximum quantity for the transmit queue that can start on interface is also 4, and the quantity that can start of receiving queue also must be 2 power The quantity that power, i.e. receiving queue can start is only 1,2,4.
In general, in the NFV system for being assigned multiple cores, the more queue technologies of network interface card be can use, make a VF The corresponding receiving queue of interface and a transmit queue are tied up with a specific core for distributing to NFV system respectively It is fixed, so that the nuclear energy be made enough to pass through the transmitting-receiving that the VF interface carries out message;Also, to avoid the concurrent of multiple verification same queues Operation, on same VF interface, the different cores for starting work need to correspond to different receiving queue and transmit queue and are received It transmits messages text.
Also, since each core is likely to the behavior that there is transmitting-receiving message on each VF interface, then in NFV system It when starting, needs in the corresponding receiving queue of VF interface and transmit queue of each starting, binds one for each core and connect Receive queue and a transmit queue;Therefore, in order to make it easy to understand, in the embodiment of the present application, some VF interface is corresponding The receiving queue and transmit queue combination of two started in packet sending and receiving queue is defined as packet sending and receiving set of queues, each report Text transmitting-receiving set of queues includes a receiving queue and a transmit queue, and each packet sending and receiving set of queues correspond to it is same VF interface, and bound with the same core.
For example, referring to Fig. 2, Fig. 2 be the embodiment of the present application provided by a kind of illustrative application scene figure, it is exemplary Ground, the processor 301 of the electronic equipment 300 include core 0, core 1, core 2, core 3, core 4, core 5, core 6, total 8 cores of core 7, electricity Sub- equipment 300 is that NFV system distribution uses 1 two cores of core 0 and core;Network interface card includes PF0, PF1, PF2 and PF3 total 4 ports PF, and have two VF interfaces of VF0 and VF1 on the PF1 of port for NFV system virtualization;It can be pre- for VF0 in memory First create 4 corresponding packet sending and receiving queues, including 4 receiving queues and 4 transmit queues, and for VF1 be pre-created 4 it is right The packet sending and receiving queue answered equally includes 4 receiving queues and 4 transmit queues;Since core 0 and core 1 have in VF0 and VF1 There may be the behaviors of transmitting-receiving message to start then in 4 corresponding packet sending and receiving queues being pre-created for VF0 and VF1 Two receiving queues and two transmit queues, and (schematically starting receives team to two receiving queues of the corresponding starting of VF0 in Fig. 2 Column 3 and receiving queue 4) it is bound respectively with core 0 and core 1, two transmit queues of the corresponding starting of VF0 (schematically open in Fig. 2 Dynamic transmit queue 11 and transmit queue 12) it is bound respectively with core 0 and core 1, specifically, receiving queue 3 and core 0 are bound, and are connect It receives queue 4 and core 1 is bound, transmit queue 11 and core 0 are bound, and transmit queue 12 and core 1 are bound, as a result, in the corresponding starting of VF0 In two receiving queues and two transmit queues, the receiving queue 3 and transmit queue 11 of binding corresponding with core 0 constitute a report Text transmitting-receiving set of queues, the receiving queue 4 and transmit queue 12 of binding corresponding with core 1 constitute another packet sending and receiving set of queues; Similarly, two receiving queues (schematically starting receiving queue 5 and receiving queue 6 in Fig. 2) of the corresponding starting of VF1 respectively with core 0 It is bound with core 1, two transmit queues of the corresponding starting of VF1 (schematically start transmit queue 13 and transmit queue in Fig. 2 14) it is bound respectively with core 0 and core 1, specifically, receiving queue 5 and core 0 are bound, and receiving queue 6 and core 1 are bound, and send team Column 13 and core 0 are bound, and transmit queue 14 and core 1 are bound;As a result, in two receiving queues and two transmissions of the corresponding starting of VF1 In queue, the receiving queue 5 and transmit queue 13 of binding corresponding with core 0 constitute a packet sending and receiving set of queues, corresponding with core 1 The receiving queue 6 and transmit queue 14 of binding constitute another packet sending and receiving set of queues.
Wherein, it is worth noting that, in general, NFV system receives the VF interface of message and sends when handling message The VF interface of message may be not identical.For example, in application scenarios as shown in Figure 2, by taking core 0 handles message as an example, by VF0 Received message is assigned into the corresponding packet sending and receiving set of queues of VF0 the receiving queue 3 with the binding of 0 phase of core;Core 0 is obtaining By the received message of VF0, it may be sent to the hair in the corresponding packet sending and receiving set of queues of VF1 with the binding of 0 phase of core after processing Queue 13 is sent, and then is issued by VF1.
But as noted previously, as under virtual environment, the quantity of transmit queue and receiving queue that VF interface can start It will receive the limitation of the port PF, such as in some network interface cards, the transmit queue and receiving queue that can start on VF interface Maximum quantity be 4, and the quantity that receiving queue can start is only 1,2,4, leads to the core distributed if NFV system The quantity for the packet sending and receiving set of queues that quantity and VF interface can start mismatches, for example, the quantity of the core for the distribution of NFV system Greater than the quantity for the packet sending and receiving set of queues that VF interface can start, the packet sending and receiving set of queues that can be started by VF interface Quantity and multiple cores cannot correspond to the limitation that same packet sending and receiving set of queues carries out concurrent operations, may result in NFV system Success can not be started.
Based on drawbacks described above, a kind of possible implementation provided by the embodiment of the present application are as follows: start in NFV system When, it is all different if the quantity of the core of NFV system distribution with each numerical value in numerical value group, then by being determined in numerical value group First numerical value out, and then start the target core with the first numerical value corresponding number, and the starting of each VF interface is corresponding with the first numerical value The object message of quantity receives and dispatches set of queues so that each object message transmitting-receiving set of queues of the corresponding starting of each VF interface with it is each Target core corresponds, and then target nuclear energy is made enough to pass through respectively corresponding object message transmitting-receiving set of queues transmitting-receiving message, NFV System can start.
As noted previously, as NFV system is on startup, the packet sending and receiving queue of starting corresponding for every VF interface is needed A packet sending and receiving set of queues is distributed for the core of each starting, and the core of each starting corresponds to message on every VF interface The mode for receiving and dispatching set of queues is all the same, may be not identical with the VF interface for sending message based on the VF interface for receiving message, under Face carries out illustratively a kind of data processing method provided by the embodiments of the present application using two VF interfaces as the object implemented Explanation.
Referring to Fig. 3, Fig. 3 is another kind illustrative application scene figure provided by the embodiment of the present application, the NFV system packet It has included VF interface and has been assigned multiple cores (illustratively including 5 cores in Fig. 3), exemplary theory is carried out with 1 VF interface Bright, which has been pre-created multiple corresponding packet sending and receiving queues, than as explained in connection with fig.2,1 VF interface can including 4 corresponding packet sending and receiving queues have been pre-created in depositing, have included 4 receiving queues and 4 transmit queues;Think NFV system It distributes for the application scenarios of 5 core, since the maximum quantity that receiving queue can start is 4, and must be 2 power side, That is, the quantity that receiving queue can start is only 1,2,4, therefore, by a receiving queue and the starting started One transmit queue and correspondence bind same core and constitute a packet sending and receiving set of queues, then the report that can start on the VF interface The quantity of text transmitting-receiving set of queues is only 1,2,4.
It is worth noting that Fig. 3 is only illustrated by taking 1 VF interface as an example, but the VF interface of each starting, There are corresponding relationships as shown in Figure 3.
Also, in the embodiment of the present application, packet sending and receiving set of queues is logical concept, in the corresponding starting of a VF interface In receiving queue and transmit queue, the receiving queue and a transmit queue for being bundled with same target core constitute a message Set of queues is received and dispatched, such as in application scenarios as shown in Figure 2, two receiving queues of the corresponding starting of VF0 and two transmission teams In column, the receiving queue 3 and transmit queue 11 for being bundled with core 0 constitute a packet sending and receiving set of queues, are bundled with the reception team of core 1 Column 4 and transmit queue 12 constitute another packet sending and receiving set of queues.
Referring to Fig. 4, Fig. 4 shows a kind of schematic stream of one kind of data processing method provided by the embodiment of the present application Cheng Tu, the data processing method are applied to electronic equipment 300 as shown in Figure 1, which is stored with as shown in Figure 3 NFV system, in the embodiment of the present application, the data processing method the following steps are included:
The starting of S101, NFV system.
S102 is judged as whether the quantity of the core of NFV system distribution and the numerical value in numerical value group are identical;If it is, executing S105;If it has not, executing S103.
In the embodiment of the present application, record has a numerical value group in electronic equipment 300, and record has at least one in the numerical value group Numerical value, wherein each numerical value in numerical value group indicates the quantity of the bootable packet sending and receiving set of queues of each VF interface, such as In application scenarios as shown in Figure 3, since the quantity that the corresponding receiving queue of VF interface can start is only 1,2,4, then The quantity for the packet sending and receiving set of queues that the VF interface can start is only 1,2,4, then the numerical value for including in numerical value group has 1,2, 4。
NFV system on startup, electronic equipment 300 then according to be NFV system distribution core quantity, by the quantity of core with Each numerical value in numerical value group is compared, and judges whether the quantity of core identical as the numerical value in numerical value group, if the quantity of core with A certain numerical value in numerical value group is identical, then NFV system can in the way of for the corresponding packet sending and receiving set of queues of each core, Each VF interface starting has the receiving queue and transmit queue of identical quantity with the quantity of core, so that each VF interface be made to constitute With the quantity of core there is the object message of identical quantity to receive and dispatch set of queues, completes the starting of NFV system, execute S105;Conversely, if The quantity of core is all different with each numerical value in numerical value group, then executes S103.
For example, the numerical value for including in numerical value group has 1,2,4 in application scenarios as shown in Figure 3, if the quantity of core is 4, Then the quantity of core is identical as " 4 " in numerical value group, and NFV system can start 4 receiving queues and 4 transmit queues at this time, thus So that each VF interface is constituted 4 object message transmitting-receiving set of queues, executes S105 at this time;And if the quantity of core is 5, the number of core Amount is all different (numerical value in numerical value group only has 1,2,4) with each numerical value in numerical value group, then executes S103 at this time.
S103 determines the first numerical value in numerical value group.
When each numerical value being determined as in the quantity and numerical value group of core of the distribution of NFV system by S102 is all different, this When the first numerical value is determined in numerical value group, the quantity of the first numerical representation method NFV system core currently to be started, also, should First numerical value is less than the quantity of all cores for the distribution of NFV system.
It optionally, can as one kind referring to Fig. 5, Fig. 5 is a kind of schematic flow chart of the sub-step of S103 in Fig. 4 The implementation of energy, S103 includes following sub-step:
S103-1, is judged as whether the quantity of the core of NFV system distribution is greater than the maximum value in numerical value group;If it has, then Execute S103-3;If it has not, then executing S103-2.
S103-2, will be less than in numerical value group for NFV system distribution core quantity all numerical value in maximum value as First numerical value.
S103-3, using the maximum value in numerical value group as the first numerical value.
As noted previously, as the quantity for the packet sending and receiving set of queues that each VF interface can start is recorded in numerical value group In, therefore, electronic equipment 300 needs each numerical value for including in the quantity and numerical value group that synthesis is the core of NFV system distribution Size determines the first numerical value.
Electronic equipment 300 is judged as in the quantity and numerical value group of the core of NFV system distribution when determining the first numerical value The size of both maximum values is greater than the maximum value in numerical value group if the quantity of the core of NFV system distribution, even if characterization opens at this time All packet sending and receiving set of queues are moved, cannot still be corresponded with all core.Therefore, as a kind of possible realization side Formula is greater than the maximum value in numerical value group if the quantity of the core of NFV system distribution, then by numerical value group in the embodiment of the present application In maximum value as the first numerical value so that the quantity of the core of starting work maximizes.Wherein, the maximum value characterization in numerical value group Current each VF interface can support the packet sending and receiving set of queues of the maximum quantity of starting.
For example, in the examples described above, the numerical value for including in numerical value group has 1,2,4, if being the quantity of the core of NFV system distribution It is 5, then the quantity (for 5) for the core of NFV system distribution is greater than the maximum value (for 4) in numerical value group, is then used as first for 4 at this time Numerical value.
At this point, illustratively, being carried out for starting two VF interfaces (i.e. VF0 and VF1) of serial number 0 and serial number 1 Illustrate, then 4 packet sending and receiving queues corresponding for VF0 and VF1, four receiving queue RxQ of unlatching and four transmissions The corresponding relationship of queue TxQ and core can be as shown in table 1 below:
The signal of the corresponding relationship of a kind of packet sending and receiving set of queues of table 1 and core
Wherein, Core0, Core1, Core2, Core3, Core4 respectively indicate the core of serial number 0,1,2,3,4;TxQ:00, TxQ:01, TxQ:02, TxQ:03 indicate in the corresponding multiple transmit queues of VF0 that serial number is respectively 00,01,02,03 transmission team Column;RxQ:00, RxQ:01, RxQ:02, RxQ:03 indicate in the corresponding multiple receiving queues of VF0, serial number is respectively 00,01,02, 03 receiving queue;TxQ:20, TxQ:21, TxQ:22, TxQ:23 indicate in the corresponding multiple transmit queues of VF1 that serial number is distinguished For 20,21,22,23 transmit queue;RxQ:20, RxQ:21, RxQ:22, RxQ:23 indicate the corresponding multiple receiving queues of VF1 In, serial number is respectively 20,21,22,23 receiving queue;NA indicates not responsible queue.
It is worth noting that in the other some embodiments of the embodiment of the present application, if the core of NFV system distribution Quantity is greater than the maximum value in numerical value group, and other values in numerical value group in addition to maximum value can also be selected as the first numerical value, Such as in the examples described above, the numerical value for including in numerical value group has 1,2,4, and the quantity if the core of NFV system distribution is 5, not only 4 can be selected and be used as the first numerical value, 1 or 2 can also be selected and be used as the first numerical value, as long as the numerical value selected in numerical value group is small In the quantity of the core distributed for NFV system.
Also, it is worth noting that in the examples described above, due in the quantity and numerical value group of the core distributed for NFV system Each numerical value be all different, therefore, for NFV system distribution core quantity be only possible to be more than or less than numerical value group in maximum Value.
Therefore, the quantity if the core of NFV system distribution is less than the maximum value in numerical value group, if starting is all at this time for characterization Packet sending and receiving set of queues, then the message that receives of packet sending and receiving set of queues that may cause part starting do not have corresponding core to carry out The processing of message, the packet sending and receiving set of queues message obtained for causing the part to start will be dropped.
As a kind of possible implementation, it is less than the maximum value in numerical value group if the quantity of the core of NFV system distribution, The maximum value in all numerical value of the quantity of the core for the distribution of NFV system will be then less than in numerical value group at this time as the first numerical value, So that the quantity that NFV system can start the core of work maximizes.
For example, in the examples described above, the numerical value for including in numerical value group has 1,2,4, if the quantity of the core of NFV system distribution It is 3, then the quantity (for 3) of core is less than the maximum value (for 4) in numerical value group, at this time less than all numbers of the quantity of core in numerical value group Value includes 1 and 2, then will be less than the maximum value of the quantity of core in numerical value group, i.e., 2 are used as the first numerical value.
At this point, illustratively, being carried out for starting two VF interfaces (i.e. VF0 and VF1) of serial number 0 and serial number 1 Illustrate, then in 4 packet sending and receiving queues corresponding for VF0 and VF1, two receiving queue RxQ of unlatching and two hairs Send the corresponding relationship of queue TxQ and core as shown in table 2 below:
The corresponding relationship of another packet sending and receiving set of queues of table 2 and core is illustrated
Wherein, Core0, Core1, Core2 respectively indicate the core of serial number 0,1,2;TxQ:00, TxQ:01 indicate VF0 pairs In the multiple transmit queues answered, serial number is respectively 00,01 transmit queue;RxQ:00, RxQ:01 indicate that VF0 is corresponding and multiple connect It receives in queue, serial number is respectively 00,01 receiving queue;In the corresponding multiple transmit queues of TxQ:20, TxQ:21 expression VF1, Serial number is respectively 20,21 transmit queue;RxQ:20, RxQ:21 indicate in the corresponding multiple receiving queues of VF1 that serial number is respectively 20,21 receiving queue;NA indicates not responsible queue.
It is worth noting that in the other some embodiments of the embodiment of the present application, if the core of NFV system distribution Quantity is less than the maximum value in numerical value group, and its in all numerical value of the quantity of the core for the distribution of NFV system is less than in numerical value group He is worth as the first numerical value, such as in the examples described above, and all numbers of the quantity of the core for the distribution of NFV system are less than in numerical value group Value includes 1 and 2, not only can be used as the first numerical value for 2 at this time, can also select 1 and be used as the first numerical value.
S104, the target core of starting and the first numerical value corresponding number, and each VF interface starts number corresponding with the first numerical value The object message of amount receives and dispatches set of queues, so that each object message transmitting-receiving set of queues of the corresponding starting of each VF interface and each mesh Core is marked to correspond.
S105, target core receive and dispatch set of queues by respectively corresponding object message and receive and dispatch message.
As a result, according to the first numerical value determined in numerical value group, start the target core with the first numerical value corresponding number, and The receiving queue and transmit queue of each VF interface starting and the first numerical value corresponding number, and start according to each VF interface is corresponding All receiving queues and transmit queue in, constitute a target report with the receiving queue of corresponding same target core and transmit queue The mode of text transmitting-receiving set of queues, so that each object message transmitting-receiving set of queues and each target core correspond.
For example, in the examples described above, the numerical value that numerical value group includes has 1,2,4, and determines that the first numerical value is 4, then start 4 A core and each VF interface 4 receiving queues of corresponding starting and 4 transmit queues, and by 4 receiving queues of starting and 4 In a transmit queue, the receiving queue of the same core of correspondence and transmit queue group are combined into an object message transmitting-receiving set of queues, with Make 4 object messages of 4 cores starting corresponding with each VF interface receive and dispatch set of queues to correspond;If the first numerical value is 2, open Dynamic 2 cores and each VF interface starts 2 corresponding receiving queues and transmit queue, and by 2 receiving queues of starting with In 2 transmit queues, the receiving queue of the same core of correspondence and transmit queue group are combined into an object message transmitting-receiving set of queues, with Make 2 object messages of 2 cores starting corresponding with each VF interface receive and dispatch set of queues to correspond.
For example, electronic equipment 300 is that NFV system is assigned core 0 and core 1 two in application scenarios as shown in Figure 2 Core, and start two VF interfaces of VF0 and VF1, then in the multiple packet sending and receiving queues created in advance for VF0 and VF1, open (such as in Fig. 2, VF0 is corresponding to be started receiving queue 3, receiving queue 4, sends team for dynamic 2 receiving queues and 2 transmit queues Column 11 and transmit queue 12, VF1 correspondence start receiving queue 5, receiving queue 6, transmit queue 13 and transmit queue 14);It will 2 receiving queues of the corresponding starting of VF0 respectively correspond core 0 and core 1, and 2 transmit queues of the corresponding starting of VF0 are respectively corresponded Core 0 and core 1, specifically, receiving queue 3 is corresponding with core 0, and receiving queue 4 is corresponding with core 1, and transmit queue 11 is corresponding with core 0, hair Send queue 12 corresponding with core 1, as a result, in 2 receiving queues and 2 transmit queues of the corresponding starting of VF0, corresponding core 0 is connect Queue 3 and transmit queue 11 are received as an object message and receives and dispatches set of queues, the receiving queue 4 and transmit queue 12 of corresponding core 1 Set of queues is received and dispatched as another object message;Similarly, 2 receiving queues by the corresponding starting of VF1 respectively correspond core 0 and core 1, And 2 transmit queues of the corresponding starting of VF1 are respectively corresponded into core 0 and core 1, specifically, receiving queue 5 is corresponding with core 0, receives team Column 6 are corresponding with core 1, and transmit queue 13 is corresponding with core 0, and transmit queue 14 is corresponding with core 1, as a result, at 2 of the corresponding starting of VF1 In receiving queue and 2 transmit queues, the receiving queue 5 and transmit queue 13 of corresponding core 0 receive and dispatch team as an object message Column group, the receiving queue 6 and transmit queue 14 of corresponding core 1 receive and dispatch set of queues as another object message.
After the object message transmitting-receiving set of queues of each starting and each target core correspond in each VF interface as a result, Each target core starts thread, and the thread of each target core and corresponding object message transmitting-receiving set of queues are tied up It is fixed, thus make each target core by the receiving queue reception message in respectively corresponding object message transmitting-receiving set of queues, and by Respectively the transmit queue in corresponding object message transmitting-receiving set of queues sends message, makes each target core that can start thread And set of queues circulation transmitting-receiving message is received and dispatched by respectively corresponding object message, NFV system can start.
Wherein, as described above, a packet sending and receiving set of queues is by the corresponding receiving queue of a VF interface and one Transmit queue is constituted.Therefore, it is worth noting that, target core is receiving and dispatching set of queues transmitting-receiving message by corresponding object message When, for same message, the VF interface due to receiving and dispatching the message may be different, and target core receives the receiving queue of the message Same object message transmitting-receiving set of queues may be not belonging to the transmit queue for sending the message.
Wherein, by taking the corresponding relationship of above-mentioned table 2 as an example, the thread and packet sending and receiving set of queues of bound targets core are shown Example property explanation.Illustratively, when creating packet sending and receiving queue in memory, receiving queue that each packet sending and receiving set of queues includes Address is all had in memory with transmit queue;In thread and object message the transmitting-receiving set of queues of bound targets core, by target Address of the receiving queue and transmit queue that packet sending and receiving set of queues includes respectively in memory is sent to target core;Target as a result, Core then receives message, and the ground according to the transmit queue of binding in memory according to the address of the receiving queue of binding in memory Location sends message.
It is worth noting that in starting and the target core of the first numerical value corresponding number, by distributing to the institute of NFV system Having in core, other whole cores in addition to all target core receive and dispatch message without corresponding packet sending and receiving set of queues, because This can not start the target core that all startings are removed in multiple cores for the distribution of NFV system as a kind of possible implementation Other all cores in addition are transmited and receive telegrams to avoid object message transmitting-receiving set of queues by other cores in addition to corresponding target core There is concurrent situation in text.
Also, it is worth noting that in the corresponding each object message transmitting-receiving set of queues started of each VF interface and often There are one-to-one relationships for one target core;But for each target core, the corresponding object message transmitting-receiving of each target core The quantity of set of queues, it is related with the quantity of VF interface of starting, such as in application scenarios as shown in Figure 2, in starting two When VF interface, core 0 is corresponding, and there are two object messages to receive and dispatch set of queues, and core 1 is corresponding, and there are two object messages to receive and dispatch set of queues.
Based on above-mentioned design, a kind of data processing method provided by the embodiment of the present application, in the starting of NFV system, if The quantity of core for the distribution of NFV system is all different with each numerical value in numerical value group, then by determining the in numerical value group One numerical value, and then start the target core with the first numerical value corresponding number, and the starting of each VF interface and the first numerical value corresponding number Object message receive and dispatch set of queues so that each object message transmitting-receiving set of queues and each target of the corresponding starting of each VF interface Core corresponds, and then target nuclear energy is made enough to pass through respectively corresponding object message transmitting-receiving set of queues transmitting-receiving message, NFV system It can start, compared with the prior art, the packet sending and receiving team for enabling the quantity of the core distributed for NFV system and VF interface to start When the quantity of column group is not identical, NFV system can start.
In application scenes, when handling message, the VF interface for receiving message connects NFV system with the VF for sending message Mouth may be not identical, for example, in application scenarios as shown in Figure 2, by taking core 0 handles message as an example, by the received report of VF0 Text may be issued after distributing to the processing of core 0 by VF1.
Therefore, optionally, as a kind of possible implementation, include in at least two VF interfaces that NFV system includes First VF interface and the 2nd VF interface, and the first VF interface and the 2nd each self-starting of VF interface have and the first numerical value corresponding number Object message receives and dispatches set of queues.
When target core receives and dispatches set of queues transmitting-receiving message by respectively corresponding object message in NFV system as a result: mesh It marks core to receive and dispatch the object message started by the first VF interface in set of queues, the received report of receiving queue institute corresponding with target core Text distributes in the object message transmitting-receiving set of queues started to the 2nd VF interface, transmission corresponding with target core team after processing Column, so as to be issued after the processing of target core through the 2nd VF interface by the first received message of VF interface institute.
For example, making in application scenarios as shown in Figure 2 using core 0 as target core, VF0 as the first VF interface, VF1 To be schematically illustrated for the 2nd VF interface, core 0 is corresponding with core 0 in the object message transmitting-receiving set of queues started by VF0 Receiving queue 3 when receiving message, after the Message processing, distribute object message start to VF1 and receive and dispatch in set of queues, with The corresponding transmit queue 13 of core 0, so that the message is issued by after the processing of core 0 by VF1.
It is worth noting that in some other possible application scenarios of the embodiment of the present application, the target core in NFV system When receiving and dispatching set of queues by respectively corresponding object message and receiving and dispatching message, target core can also will be started by the first VF interface Object message is received and dispatched in set of queues, the received message of receiving queue institute corresponding with target core, after processing, distribution to the first VF In the object message transmitting-receiving set of queues of interface starting, transmit queue corresponding with target core, i.e., at this point, being connect by the first VF interface The message of receipts is equally issued through the first VF interface after the processing of target core.
For example, making in application scenarios as shown in Figure 2 using core 0 as target core, VF0 as the first VF interface, VF1 To be schematically illustrated for the 2nd VF interface, core 0 is corresponding with core 0 in the object message transmitting-receiving set of queues started by VF0 Receiving queue 3 receive message, core 0 will distribute object message start to VF0 and receive and dispatch in set of queues after the Message processing, Transmit queue 11 corresponding with core 0, so that the message is equally issued by VF0 by after the processing of core 0.
In application scenes, since NFV system not only needs to handle the data message for belonging to business, while also needing Certain protocol massages, such as OSPF (Open Shortest Path First, ospf) agreement are handled, It is generally desirable to just can ensure that data message is normal reachable between routing, and if equipment room data when OSPF keeps connecting Measure it is larger, the amount for the data message that equipment receives be more than software program processing speed in handling capacity or equipment not It is enough fast, then it may cause and be dropped for the hello packet of OSPF keep-alive, so as to cause OSPF connection disconnection, make NFV system not Message can be normally received and dispatched, NFV system forwards business is caused to stop.
Therefore, optionally, as a kind of possible implementation, by target core respective of all startings of NFV system Business is allocated, wherein the target core of all startings includes control core and forwarding core.
Also, in general, compared to data message, the data volume of protocol massages is smaller.Therefore, in the embodiment of the present application In, protocol massages are distributed to the receiving queue into the corresponding object message transmitting-receiving set of queues of control core, so that control core processing Protocol massages;Data message is distributed to the receiving queue into the corresponding object message transmitting-receiving set of queues of forwarding core, so that forwarding Core handles data message.
It wherein, can be using the hardware capability air deflector (Flow on network interface card as a kind of possible implementation Director) protocol massages and data message are shunted with RSS (Receive Side Scaling, receiving end extension). But since in the prior art, RSS does not support individually to shunt protocol massages, thus, in method provided in this embodiment, As a kind of possible implementation, protocol massages can be guided to the corresponding object message of control core by air deflector and receive and dispatch team Receiving queue in column group, and data message is branched into connecing in the corresponding object message transmitting-receiving set of queues of forwarding core by RSS Queue is received, so that protocol massages be made individually to be handled by control core, it is ensured that protocol massages are not lost, and NFV system does not stop.
For example, in schematic diagram as shown in Figure 3, it is assumed that include 5 cores, receiving queue on VF interface in NFV system Quantity with transmit queue is 4, and determine at this time 4 cores corresponded respectively with 4 packet sending and receiving set of queues (such as Core 0, core 1, core 2 and core 3 in Fig. 3), and by core 0 as control core, core 1, core 2 and core 3 are as forwarding core.At this point, working as When NFV system receives message, protocol massages are guided to receiving queue corresponding to core 0 as air deflector, so that protocol massages Individually handled by core 0;Also, data message is branched in the respective corresponding receiving queue of core 1, core 2 and core 3 by RSS, with It is jointly processed by data message by core 1, core 2 and core 3.
It wherein, is the hardware function on network interface card based on air deflector and RSS as a kind of possible implementation Can, belong to different hardware devices from core, to realize that protocol massages are guided to the corresponding target report of control core by above-mentioned air deflector Receiving queue in text transmitting-receiving set of queues, and data message is branched to the corresponding object message of forwarding core and receives and dispatches set of queues by RSS In receiving queue, control core is when starting is with the target core of the first numerical value corresponding number and object message transmitting-receiving set of queues, control The corresponding relationship of each target core and each object message transmitting-receiving set of queues is sent to network interface card by core processed, so that network connects Protocol massages are guided to the receiving queue in the corresponding object message transmitting-receiving set of queues of control core, and benefit with air deflector by mouth Cali Data message is branched to the receiving queue forwarded in the corresponding object message transmitting-receiving set of queues of core with RSS.
It is understood that in some other possible application scenarios of the embodiment of the present application, it can also be using others Some modes realize the shunting to protocol massages and data message, for example in application scenarios as shown in Figure 2, are stored with and are used for To the program instruction that the type of message is identified, message is being assigned after being sent to memory by VF interface to reception team Before column, the type of message is identified by the program instruction identified for the type to message, if message is identified For protocol massages, then message is distributed to the receiving queue into the corresponding object message transmitting-receiving set of queues of control core;And if message It is identified as data message, then message is distributed to the receiving queue into the corresponding object message transmitting-receiving set of queues of forwarding core.Its In, it identifies the mode of type of message, can be realized by the specific fields of matching message, for example, if the EtherType of message is 0x0806, it is determined that message is ARP (Address Resolution Protocol, address resolution protocol) message, belongs to agreement Message.
Also, it is worth noting that as a kind of possible implementation, NFV system on startup, above-mentioned S101, S102, S103 and S104 can be executed specifically by control core.For example, the NFV system is assigned in NFV system as shown in Figure 3 There are core 0, core 1, core 2, core 3 and core 4 to amount to 5 cores, and using core 0 as control core, 4 correspondences have been pre-created in each VF interface Receiving queue and 4 corresponding transmit queues, and the quantity for the packet sending and receiving set of queues that can start can be 1,2 or 4, then Numerical value in numerical value group includes 1,2,4;On startup, core 0 is determined as that NFV system is assigned 5 cores to NFV system, with numerical value Each numerical value in group is all different, then according to all numerical value in the quantity 5 of the core of distribution and numerical value group, illustratively, It is used as the first numerical value by 4, and in 4 receiving queues and 4 transmit queues of the corresponding starting of every VF interface, and starts 4 cores, such as 4 cores of starting include core 0, core 1, core 2 and core 3;4 receiving queues started as a result, respectively with core 0, core 1, core 2 and core 3 Correspond, 4 transmit queues of starting are corresponded with core 0, core 1, core 2 and core 3 respectively, and corresponding core 0, core 1, core 2 and The respective receiving queue of core 3 and transmit queue combination of two form 4 object messages transmitting-receiving set of queues, thus make core 0, core 1, Core 2 and core 3 are corresponding with an object message transmitting-receiving set of queues on a VF interface.
Based on above-mentioned design, a kind of data processing method provided by the embodiment of the present application, by the way that protocol massages are independent Distribution to control core is handled, and data message is distributed to forwarding core processing, it can be ensured that protocol massages are not lost, and avoid Equipment room cutout.
Based on above-mentioned, please continue to refer to Fig. 1, electronic equipment 300 as shown in Figure 1, the data processing side stated in realization When method:
Processor 301 is used for, NFV system starting when, if NFV system distribution core quantity with it is every in numerical value group One numerical value is all different, and the first numerical value is determined in numerical value group, wherein the first numerical value is less than the number of the core for the distribution of NFV system It measures, each numerical value in numerical value group indicates the quantity of the bootable packet sending and receiving set of queues of each VF interface;
Processor 301 is also used to, the target core of starting and the first numerical value corresponding number, and each VF interface starting and first The object message of numerical value corresponding number receives and dispatches set of queues, so that each object message of the corresponding starting of each VF interface receives and dispatches queue Group is corresponded with each target core;
Processor 301 is also used to, and target core receives and dispatches set of queues by respectively corresponding object message and receives and dispatches message.
Optionally, as a kind of possible implementation, when determining the first numerical value in numerical value group, processor 301 is specific For:
If NFV system distribution core quantity be greater than numerical value group in maximum value, using the maximum value in numerical value group as First numerical value.
Optionally, as a kind of possible implementation, when determining the first numerical value in numerical value group, processor 301 is specific For:
It is less than the maximum value in numerical value group if the quantity of the core of NFV system distribution, will be less than in numerical value group for NFV system Maximum value in all numerical value of the quantity of the core of distribution is as the first numerical value.
Optionally, as a kind of possible implementation, at least two VF interfaces include that the first VF interface and the 2nd VF connect Mouthful, each packet sending and receiving set of queues includes receiving queue and transmit queue;
First VF interface and the 2nd each self-starting of VF interface, which have, receives and dispatches queue with the object message of the first numerical value corresponding number Group;
When target core receives and dispatches set of queues transmitting-receiving message by respectively corresponding object message, processor 301 is specifically used for:
Target core receives and dispatches the object message started by the first VF interface in set of queues, receiving queue corresponding with target core The received message of institute distributes in the object message transmitting-receiving set of queues started to the 2nd VF interface, transmission corresponding with target core team Column, so that message is issued by the 2nd VF interface.
It optionally, include control core and forwarding core as a kind of possible implementation, in target core, each message is received Sending out set of queues includes receiving queue and transmit queue;
Network interface card 304 is used for, and protocol massages are distributed into the corresponding object message transmitting-receiving set of queues of control core Receiving queue, so that control core processing protocol message;
Network interface card 304 is also used to, and data message is distributed into the corresponding object message transmitting-receiving set of queues of forwarding core Receiving queue so that forwarding core handle data message.
Optionally, as a kind of possible implementation, network interface card 304 includes air deflector and receiving end extension RSS;
Air deflector is used for, and protocol massages are guided to the reception team in the corresponding object message transmitting-receiving set of queues of control core Column;
RSS is used for, and distributes data message to the receiving queue into the corresponding object message transmitting-receiving set of queues of forwarding core.
In embodiment provided herein, it should be understood that disclosed device and method, it can also be by other Mode realize.The apparatus embodiments described above are merely exemplary, for example, the flow chart and block diagram in attached drawing are shown According to the device of the embodiment of the present application, the architecture, function and operation in the cards of method and computer program product. In this regard, each box in flowchart or block diagram can represent a part of a module, section or code, the mould A part of block, program segment or code includes one or more executable instructions for implementing the specified logical function.Also it answers When note that function marked in the box can also be to be different from being marked in attached drawing in some implementations as replacement The sequence of note occurs.For example, two continuous boxes can actually be basically executed in parallel, they sometimes can also be by opposite Sequence execute, this depends on the function involved.It is also noted that each box in block diagram and or flow chart and The combination of box in block diagram and or flow chart can use the dedicated hardware based system for executing defined function or movement System is to realize, or can realize using a combination of dedicated hardware and computer instructions.
In addition, each functional module in the embodiment of the present application can integrate one independent part of formation together, It can be modules individualism, an independent part can also be integrated to form with two or more modules.
It, can be with if the function is realized and when sold or used as an independent product in the form of software function module It is stored in a computer readable storage medium.Based on this understanding, the technical solution of the application is substantially in other words The part of the part that contributes to existing technology or the technical solution can be embodied in the form of software products, the meter Calculation machine software product is stored in a storage medium, including some instructions are used so that a computer equipment (can be a People's computer, server or network equipment etc.) execute the embodiment of the present application the method all or part of the steps.And it is preceding The storage medium stated includes: USB flash disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory The various media that can store program code such as (RAM, Random Access Memory), magnetic or disk.
In conclusion a kind of data processing method and electronic equipment provided by the embodiment of the present application, start in NFV system When, it is all different if the quantity of the core of NFV system distribution with each numerical value in numerical value group, then by being determined in numerical value group First numerical value out, and then start the target core with the first numerical value corresponding number, and the starting of each VF interface is corresponding with the first numerical value The object message of quantity receives and dispatches set of queues so that each object message transmitting-receiving set of queues of the corresponding starting of each VF interface with it is each Target core corresponds, and then target nuclear energy is made enough to pass through respectively corresponding object message transmitting-receiving set of queues transmitting-receiving message, NFV System can start, and compared with the prior art, the message for enabling the quantity of the core distributed for NFV system and VF interface to start is received When the quantity of hair set of queues is not identical, NFV system can start;Also by individually distributing protocol massages to control core Reason, and data message is distributed to forwarding core processing, it can be ensured that protocol massages are not lost, and equipment room is avoided to stop.
The foregoing is merely preferred embodiment of the present application, are not intended to limit this application, for the skill of this field For art personnel, various changes and changes are possible in this application.Within the spirit and principles of this application, made any to repair Change, equivalent replacement, improvement etc., should be included within the scope of protection of this application.
It is obvious to a person skilled in the art that the application is not limited to the details of above-mentioned exemplary embodiment, Er Qie In the case where without departing substantially from spirit herein or essential characteristic, the application can be realized in other specific forms.Therefore, no matter From the point of view of which point, the present embodiments are to be considered as illustrative and not restrictive, and scope of the present application is by appended power Benefit requires rather than above description limits, it is intended that all by what is fallen within the meaning and scope of the equivalent elements of the claims Variation is included in the application.Any reference signs in the claims should not be construed as limiting the involved claims.

Claims (12)

1. a kind of data processing method, which is characterized in that be applied to electronic equipment, the electronic equipment is stored with network function void Quasi-ization NFV system, the NFV system include at least two virtual functions VF interfaces, each VF in at least two VF interface Multiple corresponding packet sending and receiving queues have been pre-created in interface, and the electronic equipment is that the NFV system is assigned multiple cores, institute The method of stating includes:
In NFV system starting, not if each numerical value in the quantity and numerical value group of the core of NFV system distribution It is identical, the first numerical value is determined in the numerical value group, wherein first numerical value is less than the core for NFV system distribution Quantity, each numerical value in the numerical value group indicate the quantity of the bootable packet sending and receiving set of queues of each VF interface;
The target core of starting and the first numerical value corresponding number, and each VF interface starting is corresponding with first numerical value The object message of quantity receives and dispatches set of queues, so that each object message of the corresponding starting of each VF interface receives and dispatches queue Group is corresponded with each target core;
The target core receives and dispatches set of queues by the respectively corresponding object message and receives and dispatches message.
2. the method as described in claim 1, which is characterized in that described the step of the first numerical value is determined in the numerical value group, Include:
If the NFV system distribution core quantity be greater than the numerical value group in maximum value, by the numerical value group most Big value is used as first numerical value.
3. method according to claim 1 or 2, which is characterized in that the step for determining the first numerical value in the numerical value group Suddenly, comprising:
It is less than the maximum value in the numerical value group if the quantity of the core of NFV system distribution, will be less than in the numerical value group It is the maximum value in all numerical value of the quantity of the core of NFV system distribution as first numerical value.
4. the method as described in claim 1, which is characterized in that at least two VF interface includes the first VF interface and second VF interface, each packet sending and receiving set of queues includes receiving queue and transmit queue;
The first VF interface and each self-starting of the 2nd VF interface have the object message with the first numerical value corresponding number Receive and dispatch set of queues;
The target core receives and dispatches the step of set of queues receives and dispatches message by the respectively corresponding object message, comprising:
The target core receives and dispatches the object message started by the first VF interface in set of queues, checks with the target The received message of receiving queue institute answered distributes in the object message transmitting-receiving set of queues started to the 2nd VF interface, with institute The corresponding transmit queue of target core is stated, so that the message is issued by the 2nd VF interface.
5. the method as described in claim 1, which is characterized in that it include to control core and forwarding core in the target core, it is each The packet sending and receiving set of queues includes receiving queue and transmit queue;
The method also includes:
Protocol massages are distributed to the receiving queue into the corresponding object message transmitting-receiving set of queues of the control core, so that institute It states control core and handles the protocol massages;
Data message is distributed to the receiving queue into the corresponding object message transmitting-receiving set of queues of the forwarding core, so that institute It states forwarding core and handles the data message.
6. method as claimed in claim 5, which is characterized in that the electronic equipment further includes having air deflector and receiving end extension RSS;
The protocol massages are guided in the corresponding object message transmitting-receiving set of queues of the control core by the air deflector Receiving queue;
The data message is distributed the reception into the corresponding object message transmitting-receiving set of queues of the forwarding core by the RSS Queue.
7. a kind of electronic equipment, which is characterized in that including processor, memory and network interface card, stored in the memory There is network function to virtualize NFV system, the network interface card virtually has an at least two virtual functions VF interfaces, and described at least two Multiple corresponding packet sending and receiving queues have been pre-created in each VF interface in a VF interface, and the electronic equipment is the NFV system System is assigned multiple cores;
The processor is used for, in NFV system starting, if the quantity and numerical value group of the core of NFV system distribution In each numerical value be all different, in the numerical value group determine the first numerical value, wherein first numerical value be less than be described The quantity of the core of NFV system distribution, each numerical value in the numerical value group indicate that the bootable message of each VF interface is received Send out the quantity of set of queues;
The processor is also used to, the target core of starting and the first numerical value corresponding number, and each VF interface starting Set of queues is received and dispatched with the object message of the first numerical value corresponding number, so that each institute of the corresponding starting of each VF interface It states object message transmitting-receiving set of queues and each target core corresponds;
The processor is also used to, and the target core receives and dispatches set of queues by the respectively corresponding object message and transmits and receive telegrams Text.
8. electronic equipment as claimed in claim 7, which is characterized in that described when determining the first numerical value in the numerical value group Processor is specifically used for:
If the NFV system distribution core quantity be greater than the numerical value group in maximum value, by the numerical value group most Big value is used as first numerical value.
9. electronic equipment as claimed in claim 7 or 8, which is characterized in that when determining the first numerical value in the numerical value group, institute Processor is stated to be specifically used for:
It is less than the maximum value in the numerical value group if the quantity of the core of NFV system distribution, will be less than in the numerical value group It is the maximum value in all numerical value of the quantity of the core of NFV system distribution as first numerical value.
10. electronic equipment as claimed in claim 7, which is characterized in that at least two VF interface includes the first VF interface With the 2nd VF interface, each packet sending and receiving set of queues includes receiving queue and transmit queue;
The first VF interface and each self-starting of the 2nd VF interface have the object message with the first numerical value corresponding number Receive and dispatch set of queues;
When the target core receives and dispatches set of queues transmitting-receiving message by the respectively corresponding object message, the processing implement body For:
The target core receives and dispatches the object message started by the first VF interface in set of queues, checks with the target The received message of receiving queue institute answered distributes in the object message transmitting-receiving set of queues started to the 2nd VF interface, with institute The corresponding transmit queue of target core is stated, so that the message is issued by the 2nd VF interface.
11. electronic equipment as claimed in claim 7, which is characterized in that it include to control core and forwarding core in the target core, Each packet sending and receiving set of queues includes receiving queue and transmit queue;
The network interface card is used for, and protocol massages are distributed to the corresponding object message of the control core and receive and dispatch set of queues In receiving queue so that the control core handles the protocol massages;
The network interface card is also used to, and data message is distributed to the corresponding object message of the forwarding core and receives and dispatches queue Receiving queue in group, so that the forwarding core handles the data message.
12. electronic equipment as claimed in claim 11, which is characterized in that the network interface card includes air deflector and reception End extension RSS;
The air deflector is used for, and the protocol massages are guided to the corresponding object message of the control core and receive and dispatch set of queues In receiving queue;
The RSS is used for, and the data message is distributed into the corresponding object message transmitting-receiving set of queues of the forwarding core Receiving queue.
CN201910093781.6A 2019-01-30 2019-01-30 Data processing method and electronic equipment Active CN109672575B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910093781.6A CN109672575B (en) 2019-01-30 2019-01-30 Data processing method and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910093781.6A CN109672575B (en) 2019-01-30 2019-01-30 Data processing method and electronic equipment

Publications (2)

Publication Number Publication Date
CN109672575A true CN109672575A (en) 2019-04-23
CN109672575B CN109672575B (en) 2022-03-08

Family

ID=66150085

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910093781.6A Active CN109672575B (en) 2019-01-30 2019-01-30 Data processing method and electronic equipment

Country Status (1)

Country Link
CN (1) CN109672575B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110333899A (en) * 2019-06-27 2019-10-15 腾讯科技(深圳)有限公司 Data processing method, device and storage medium
CN111277514A (en) * 2020-01-21 2020-06-12 新华三技术有限公司合肥分公司 Message queue distribution method, message forwarding method and related device
CN112968965A (en) * 2021-02-25 2021-06-15 网宿科技股份有限公司 Metadata service method, server and storage medium for NFV network node

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160098372A1 (en) * 2014-10-03 2016-04-07 Futurewei Technologies, Inc. METHOD TO USE PCIe DEVICE RESOURCES BY USING UNMODIFIED PCIe DEVICE DRIVERS ON CPUs IN A PCIe FABRIC WITH COMMODITY PCI SWITCHES
US20170063979A1 (en) * 2014-03-19 2017-03-02 Nec Corporation Reception packet distribution method, queue selector, packet processing device, and recording medium
CN106713185A (en) * 2016-12-06 2017-05-24 瑞斯康达科技发展股份有限公司 Load balancing method and apparatus of multi-core CPU
CN108984327A (en) * 2018-07-27 2018-12-11 新华三技术有限公司 Message forwarding method, multi-core CPU and the network equipment
CN109284192A (en) * 2018-09-29 2019-01-29 网宿科技股份有限公司 Method for parameter configuration and electronic equipment

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20170063979A1 (en) * 2014-03-19 2017-03-02 Nec Corporation Reception packet distribution method, queue selector, packet processing device, and recording medium
US20160098372A1 (en) * 2014-10-03 2016-04-07 Futurewei Technologies, Inc. METHOD TO USE PCIe DEVICE RESOURCES BY USING UNMODIFIED PCIe DEVICE DRIVERS ON CPUs IN A PCIe FABRIC WITH COMMODITY PCI SWITCHES
CN106796529A (en) * 2014-10-03 2017-05-31 华为技术有限公司 By using the method that commodity-type PCI interchangers use PCIe device resource on the CPU in PCIe structures using unmodified PCIe device driver
CN106713185A (en) * 2016-12-06 2017-05-24 瑞斯康达科技发展股份有限公司 Load balancing method and apparatus of multi-core CPU
CN108984327A (en) * 2018-07-27 2018-12-11 新华三技术有限公司 Message forwarding method, multi-core CPU and the network equipment
CN109284192A (en) * 2018-09-29 2019-01-29 网宿科技股份有限公司 Method for parameter configuration and electronic equipment

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110333899A (en) * 2019-06-27 2019-10-15 腾讯科技(深圳)有限公司 Data processing method, device and storage medium
CN110333899B (en) * 2019-06-27 2022-11-01 腾讯科技(深圳)有限公司 Data processing method, device and storage medium
CN111277514A (en) * 2020-01-21 2020-06-12 新华三技术有限公司合肥分公司 Message queue distribution method, message forwarding method and related device
CN111277514B (en) * 2020-01-21 2023-07-18 新华三技术有限公司合肥分公司 Message queue distribution method, message forwarding method and related devices
CN112968965A (en) * 2021-02-25 2021-06-15 网宿科技股份有限公司 Metadata service method, server and storage medium for NFV network node

Also Published As

Publication number Publication date
CN109672575B (en) 2022-03-08

Similar Documents

Publication Publication Date Title
CN104718723B (en) For the networking in virtual network and the frame of security service
CN102334112B (en) Method and system for virtual machine networking
CN107278362B (en) The method of Message processing, host and system in cloud computing system
CN105159753B (en) The method, apparatus and pooling of resources manager of accelerator virtualization
CN104636184B (en) The dispositions method and device and equipment of virtual machine instance
CN101809943B (en) Method and system for virtual port communications
CN104995880B (en) The method and system of quantization congestion notification in virtual networking system
CN104348740B (en) Data package processing method and system
CN103414535B (en) Data sending method, data receiving method and relevant devices
CN104221331B (en) The 2nd without look-up table layer packet switch for Ethernet switch
CN104572243B (en) Method and system for sharing Java Virtual Machine
CN109672575A (en) Data processing method and electronic equipment
CN107896195A (en) Service chaining method of combination, device and service chaining topological structure
CN105993009A (en) Method and apparatus for delivering msi-x interrupts through non-transparent bridges to computing resources in pci-express clusters
CN106330779B (en) Server, physical switch, and communication system
CN108768692A (en) A kind of network creation method, relevant device and system
CN105049464B (en) Techniques for accelerating network virtualization
CN109495405A (en) A kind of method and interchanger of bare metal server and cloud mainframe network intercommunication
CN108432189A (en) Load balance on multiple endpoint of a tunnel
CN110380992A (en) Message processing method, device and network flow acquire equipment
CN105518610B (en) Storage system, method and apparatus for processing operation request
CN106610789A (en) Data processing method, device and system
CN107506324A (en) Interconnecting device, telecommunication system, data transmission method and device
US10088643B1 (en) Multidimensional torus shuffle box
CN109379269A (en) Virtual swap device data forwarding method, device and computer equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant