CN106411739A - Data forwarding method, apparatus and system - Google Patents
Data forwarding method, apparatus and system Download PDFInfo
- Publication number
- CN106411739A CN106411739A CN201510466494.7A CN201510466494A CN106411739A CN 106411739 A CN106411739 A CN 106411739A CN 201510466494 A CN201510466494 A CN 201510466494A CN 106411739 A CN106411739 A CN 106411739A
- Authority
- CN
- China
- Prior art keywords
- wqe
- data
- switch
- pending
- data bag
- 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
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L45/00—Routing or path finding of packets in data switching networks
- H04L45/74—Address processing for routing
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L49/00—Packet switching elements
- H04L49/25—Routing or path finding in a switch fabric
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
The invention discloses a data forwarding method, apparatus and system. The method comprises the following steps: when copying data by using a remote direct memory access (RDMA), an electronic device takes out the WQE corresponding to the data to be transmitted from a transmit queue; a first destination address and a first source address corresponding to the WQE is matched with the destination address and the source address of each entry in a preset filter table; if the first destination address and the first source address are both different from the destination address and the source address in the preset filter table, the WQE is encapsulated into a data packet to be processed to be transmitted to a switch; the switch forwards the data packet to be processed to a controller; and the electronic device transmits the data packet to be processed to the switch after receiving acknowledgment information transmitted from the switch for the data packet to be processed. The method, device and system disclosed in the invention solve a problem that the data forwarding process of the existing RDMA technology is relatively large in time delay.
Description
Technical field
The present invention relates to communication technical field, more particularly, to a kind of data forwarding method, apparatus and system.
Background technology
Open Flow technology is to separate control function from the network equipment, safeguards on network devices
Flow table (flow table) structure, packet is forwarded according to flow table, and the generation of flow table, safeguards, joins
Put, to be managed by central controller.The flow table structure of Open Flow, by network processes level flattening, makes
The process obtaining network data meets fine-grained processing requirement.Forward under separation architecture in this control, network
Logic control function and higher layer policy can by central controller neatly enter Mobile state management and configure,
Can realize in existing network and deployment new network in the case of not affecting legacy network normal discharge
Framework.
Open Flow is initially as software defined network (Software Defined Network, SDN)
When prototype proposes, mainly it is made up of Open Flow switch and controller two parts.Open Flow exchanges
Machine forwards packet according to flow table, represents data forwarding plane;Controller is by whole network view Lai real
Existing management and control function, its control logic represents control plane.
In existing RDMA (Remote Direct Memory Access, RDMA) skill
Art completes data copy, flow process following (system architecture that this example uses is as shown in Figure 1):
Host side is using the raw requests of RDMA data as a Work Queue Elements (work
Queue element, WQE) deposit in transmit queue (Send Queue, SQ);
When carrying out data access, take out WQE from the SQ of RDMA, needs are taken out according to WQE
The data sending, this data of cutting is simultaneously packaged into the packet of identical destination address and source address, sends out one by one
Deliver to switch.
Switch is tabled look-up one by one according to the destination address of packet and source address, if table look-up not can determine that data
Forwarding list item under the path of bag, then be reported to controller by packet.
Controller is forwarding list item under the packet accessed path that each reports.
According to above-mentioned RDMA) technical data copy procedure is it is recognized that while control plane can be by control logic
Concentration is deployed to whole network, but the mass data obtaining when the reading and writing data request cutting of RDMA application
When pouring into Forwarding plane, then pouring into control plane by Forwarding plane, Forwarding plane and control plane will enter one
Individual invalid busy state, thus problems with can be caused:
Whole process time delay ratio is larger, and much the packet of identical destination address and source address needs in the process
Repeat to table look-up and determine forwarding list item under path, so causing substantial amounts of non-productive work, not only a large amount of consumption is handed over
The resource changed planes with controller, also postpones the process of effective data packets.
Content of the invention
A kind of embodiment of the present invention data forwarding method of offer, apparatus and system, method provided by the present invention,
Apparatus and system solves the problems, such as the data forwarding process time delay of existing RDMA technology than larger.
In a first aspect, offer data forwarding method, the method specifically includes:
When electronic equipment carries out data copy using RDMA RDMA mode, described electricity
Sub- equipment takes out data to be sent corresponding Work Queue Elements WQE from transmit queue SQ;Wherein, should
WQE is corresponding with the raw requests of described data to be sent;
Corresponding for described WQE the first destination address and the first source address are filtered by described electronic equipment with default
In table, the destination address of each list item and source address are mated;
If the destination address in described first destination address and the first source address and described default filter table and
Source address all differs, and described WQE is packaged into a pending data bag and is sent to by described electronic equipment
Switch;
Described pending data bag is forwarded to controller by switch by described electronic equipment;And receiving
After the confirmation for described pending data bag that switch sends, described data is activation to be sent is arrived
Switch.
In conjunction with a first aspect, in the first possible implementation, described pending data bag includes number
According to unique mark, this data unique mark is used for the described WQE of unique sign;
By described data is activation to be sent to before switch, also include:
Described WQE is determined according to described data unique mark;
Obtain the corresponding described data to be sent of described WQE determining.
In conjunction with the first possible implementation of first aspect or first aspect, in the possible realization of second
In mode, described WQE is packaged into a pending data bag and is sent to switch, including:
Described WQE is stored in pending queue;
WQE in described pending queue is packaged into a pending data bag send to switch.
In conjunction with the possible implementation of the second of first aspect, in the third possible implementation, will
WQE in described pending queue is packaged into a pending data bag and sends to switch, including:
When determining the WQE quantity in described pending queue more than predetermined threshold value, then by described pending team
The WQE of the setting quantity in row encapsulates a pending data bag and sends to switch;Or
Described pending queue is detected according to predetermined period, and by this pending queue detecting
WQE sends to switch to being packaged into a pending data bag.
In conjunction with a first aspect, or any one in the first to three kind of possible implementation of first aspect
Kind, in the 4th kind of possible implementation, by corresponding for each Work Queue Elements the first destination address and
Before first source address is mated with the destination address in default filter table and source address, also include:
Obtain obtained in described transmit queue SQ forward-path corresponding second destination address of WQE and
Second source address, and described default filter table is generated according to described second destination address and the second source address.
Second aspect, provides a kind of data forwarding method, and the method specifically includes:
Switch receives and carries out data copy when electronic equipment using RDMA RDMA mode
When the pending data bag that sends;
According to the inquiry mark in this pending data bag, described switch determines that this pending data bag is to use
In the packet of inquiry data forwarding paths, then described pending data bag is forwarded to controller;
Described switch receives the feedback information that controller sends, and this feedback information includes forwarding the stream of data
List item and confirmation;
Described confirmation is sent to described electronic equipment by described switch;
Described switch receives the described data that described electronic equipment sends, and forwards institute according to described flow table item
State data.
In conjunction with second aspect, in the first possible implementation, according to looking in this pending data bag
Ask mark and determine that this pending data bag is the packet for inquiring about data forwarding paths, including:
Obtain described inquiry mark from described pending data bag, and by the described inquiry getting mark with
Default inquiry list item is mated, if matching identical with described inquiry mark in described inquiry list item
Mark it is determined that described pending data bag is the packet for inquiring about data forwarding paths.
The third aspect, provides a kind of electronic equipment, and this electronic equipment specifically includes:
Acquisition module, when electronic equipment carries out data copy using RDMA RDMA mode
When, for taking out data to be sent corresponding Work Queue Elements WQE from transmit queue SQ, wherein,
This WQE is corresponding with the raw requests of described data to be sent;
Filtering module, for by corresponding for described WQE the first destination address and the first source address with preset
In filter table, the destination address of each list item and source address are mated;
Package module, if the mesh in described first destination address and the first source address and described default filter table
Address and source address all differ, for described WQE is packaged into a pending data bag;
Transceiver module, for being forwarded to controller by switch by described pending data bag;And receiving
After the confirmation for described pending data bag sending to switch, by described data is activation to be sent
To switch.
In conjunction with the third aspect, in the first possible implementation, described transceiver module is additionally operable to add number
According to unique mark in described pending data bag, and described WQE is determined according to described data unique mark;
Obtain the corresponding described data to be sent of described WQE determining;Wherein, this data unique mark is used for only
The one described WQE of sign.
In conjunction with the first possible implementation of the third aspect or the third aspect, in the possible realization of second
In mode, package module is specifically for being stored in described WQE in pending queue;By described pending team
WQE in row is packaged into a pending data bag and sends to switch.
In conjunction with the possible implementation of the second of the third aspect, in the third possible implementation, institute
State package module specifically for being more than predetermined threshold value when the WQE quantity in the described pending queue of determination, then
The WQE of the setting quantity in described pending queue is encapsulated a pending data bag send to exchange
Machine;Or described pending queue is detected according to predetermined period, and by this pending queue detecting
WQE sends to switch to being packaged into a pending data bag.
In conjunction with any one in the third aspect, or the first to three kind of possible implementation of the third aspect
Kind, in the 4th kind of possible implementation, this electronic equipment also includes:
Generation module, corresponding for obtaining the WQE having obtained forward-path in described transmit queue SQ
Second destination address and the second source address, and according to described second destination address and the second source address generate
Default filter table.
Fourth aspect, provides a kind of switch, and this switch specifically includes:
Identification module, is carried out using RDMA RDMA mode when electronic equipment for receiving
According to the inquiry mark in this pending data bag, the pending data bag sending during data copy, determines that this is treated
Processing data bag is the packet for inquiring about described data forwarding paths, then turn described pending data bag
It is sent to controller;
Receiver module, for receiving the feedback information of controller transmission, this feedback information includes forwarding data
Flow table item and confirmation;
Forwarding module, for described confirmation is sent to described electronic equipment, and receives described electronics and sets
The described data that preparation is sent, forwards described data according to described flow table item.
In conjunction with fourth aspect, in the first possible implementation, described identification module is specifically for from institute
State and in pending data bag, obtain described inquiry mark, and the described inquiry mark getting is looked into default
Ask list item to be mated, if matched in described inquiry list item and described inquiry mark identical mark,
Then determine that described pending data bag is the packet for inquiring about data forwarding paths.
In the embodiment of the present invention, if electronic equipment carries out data copy by RDMA technology, do not having
Before data exchange to be sent is become little data block to be sent to switch, electronic equipment first will be to be sent
The corresponding WQE of data is packaged into a packet, and by switch, this data is forwarded a packet to controller,
Make controller be directed to WQE and determine the corresponding path of data to be sent, and the path of determination is sent to friendship
Change planes, thus avoid switch and be directed to, by what described data to be sent was syncopated as, there is same source address and mesh
Address multiple cutting data blocks, be always intended to the problem of forwarding list item under controller request path, thus keeping away
Exempt from the data block for much identical destination address and source address occurring in prior art, switch needs
Repeat to table look-up to controller and determine the problem of forwarding list item under path, therefore saved the place of switch and controller
Reason resource, improves the forward efficiency of data to be sent.
Brief description
The system structure that Fig. 1 completes data copy for prior art medium-long range direct memory access technology is illustrated
Figure;
A kind of schematic flow sheet of data forwarding method that Fig. 2 provides for the embodiment of the present invention one;
A kind of schematic flow sheet of data forwarding method that Fig. 3 provides for the embodiment of the present invention two;
A kind of schematic flow sheet of data forwarding method that Fig. 4 provides for the embodiment of the present invention three;
Fig. 5 is the structural representation of a kind of electronic equipment provided in an embodiment of the present invention;
Fig. 6 is a kind of structural representation of switch provided in an embodiment of the present invention;
Fig. 7 is a kind of structural representation of data forwarding system provided in an embodiment of the present invention.
Specific embodiment
Purpose, technical scheme and advantage for making the embodiment of the present invention are clearer, below in conjunction with the present invention
Accompanying drawing in embodiment, the technical scheme in the embodiment of the present invention is clearly and completely described it is clear that
Described embodiment is a part of embodiment of the present invention, rather than whole embodiments.Based in the present invention
Embodiment, those of ordinary skill in the art obtained under the premise of not making creative work all its
His embodiment, broadly falls into the scope of protection of the invention.
Existing RDMA (Remote Direct Memory Access, RDMA) be in order to
Solve the delay of servers' data process in network transmission and produce.Line number is entered by RDMA technology
According to storage when, RDMA passes through the memory block the direct incoming computer of data for the network, by data from one
System moves quickly in remote system stored device, and operating system is not had any impact, thus not
Need to use the processing function of too many computer.Based on RDMA technology, the embodiment of the present invention provides a kind of
Data forwarding method, is described in further detail to the embodiment of the present invention with reference to Figure of description:
Embodiment one
As shown in Fig. 2 the embodiment of the present invention provides a kind of data forwarding method, the method specifically includes:
Step 201, when electronic equipment carries out data copy using RDMA mode, this electronic equipment from send out
Send and in queue (Send Queue, SQ), take out data to be sent corresponding Work Queue Elements (work queue
Element, WQE);
Wherein, this WQE is corresponding with the raw requests of described data to be sent;And this raw requests refers to
When electronic equipment needs to send data, the request being generated for data is activation.If in data forwarding flow process,
Data needs for original data to be sent to be cut into little data block and retransmits, that raw requests this original please
Ask, be the data original to be sent being directed to, be not the data block after cutting.
Step 202, electronic equipment by corresponding for described WQE the first destination address and the first source address with pre-
If the destination address of each list item and source address are mated in filter table;If described first destination address and
Destination address in first source address and described default filter table and source address all differ, then proceed to step
203;Otherwise, directly corresponding for this WQE data cutting is sent to switch;
Because the ID of distinct device can be identical in different domains, in present invention fact embodiment,
Source address can be formed by source protection domain identifier and source identifier combination, and wherein source protection domain identifier is source device institute
Belong to the unique mark of protected field;Source is designated the unique mark of source device.Destination address can be protected by purpose
Domain identifier and purpose mark combination are formed, and wherein purpose protected field is designated the affiliated protected field of purpose equipment only
One mark;Purpose mark is the unique mark of purpose equipment.
Step 203, described WQE is packaged into a pending data bag and is sent to switch;By handing over
Change planes and described pending data bag is forwarded to controller;
Switch is made to be forwarded to after controller by described pending data bag, controller determines described WQE
Corresponding flow table item (this flow table item includes forwarding the forward-path of data to be sent), controller is determining
After flow table item, flow table item is sent to switch;If switch receives that this WQE is corresponding to be treated below
After sending data, then can be forwarded according to this flow table item.
In this embodiment, switch judges pending data bag for query path according to default judgment rule
Packet after, then directly this pending data bag is transparent to controller, thus controller is treated according to this
Solicited message in processing data bag determines that (this forward-path is added on control for the forward-path of data to be sent
Device feeds back in the flow table item of switch).
Step 204, described pending data bag is forwarded to controller by switch by this electronic equipment;And
After the confirmation for described pending data bag receiving switch transmission, by described number to be sent
According to being sent to switch.
In embodiments of the present invention, by corresponding for each Work Queue Elements the first destination address and the first source ground
Before location is mated with the destination address in default filter table and source address, the method still further comprises:
Obtain obtained in described transmit queue SQ forward-path corresponding second destination address of WQE and
Second source address, and described default filter table is generated according to described second destination address and the second source address.
And, this filter table can be carried out according to the change having obtained forward-path WQE in transmit queue SQ
Adaptive adjustment.
In prior art, if electronic equipment copies data by RDMA mode, can be directly by this data
It is cut into multiple little data blocks, be subsequently sent to switch and forwarded;If there is no data in switch
Block (asking corresponding data) corresponding forward-path, then need to send out to controller for each data block
Send the request of acquisition approach, then controller is directed to each corresponding path of request feedback.Although same request
Corresponding multiple data blocks, but the path corresponding to multiple data block is the same, so according to prior art
Scheme then can lead to the waste of controller resource.For this problem, the scheme that the embodiment of the present invention is provided
In, if electronic equipment carries out data copy by RDMA technology, data to be sent is not being cut
Change into before little data block is sent to switch, electronic equipment is first by the corresponding WQE of data to be sent
It is packaged into a packet, and this data is forwarded a packet to so that controller is directed to by controller by switch
WQE determines the corresponding path of data to be sent, and the path of determination is sent to switch, thus avoiding
Switch is directed to has the multiple of same source address and destination address by what described data to be sent was syncopated as
Cutting data block, is always intended to the problem of forwarding list item under controller request path, thus avoiding prior art
The data block for much identical destination address and source address of middle appearance, switch needs to repeat to controller
Table look-up and determine the problem of forwarding list item under path, therefore saved the process resource of switch and controller, improve
The forward efficiency of data to be sent.
Because electronic equipment may initiate the request of data copy for different data, if there is multiple
During WQE, then by WQE be packaged into a pending data bag be sent to the specific implementation of switch can
To be:
Described WQE is stored in pending queue;
WQE in described pending queue is packaged into a pending data bag send to switch.
Wherein, can trigger equipment packages pending data bag condition can include multiple, two kinds presented below
Optimized embodiment, specifically includes:
First, when determining the WQE quantity in described pending queue more than predetermined threshold value, then wait to locate by described
In reason queue, the WQE of setting quantity is packaged into a pending data bag and sends to switch;
2nd, described pending queue is detected according to predetermined period, and by this pending queue detecting
WQE sends to switch to being packaged into a pending data bag.
When electronic equipment have sent multiple raw requests to controller after, if controller fed back correlation
Information, in order to find the corresponding data of feedback information and be forwarded, then can be accomplished by:
In the whole forwarding process of pending data bag, all carry default data unique mark, this data is only
One identifies and indicates described WQE for unique, then electronic equipment by described data is activation to be sent to switch
Before, further include:Described WQE is determined according to described data unique mark;Obtain the described of determination
The corresponding described data to be sent of WQE.
Embodiment two
As shown in figure 3, the scheme being provided for the more detailed description embodiment of the present invention, below for tool
The scheme that the use environment of body is provided to the embodiment of the present invention is described further, when electronic equipment utilizes
When RDMA RDMA technology carries out data copy, specifically include:
Step 301, filter table preset by the electronic equipment initiating data copy request, and this filter table includes many
Individual filtering meter item, each list item represents a directory entry having obtained forward-path;Wherein each list item bag
Including key message can be:Purpose id, source id, purpose protected field (Protection Domain, pd) pd, source
Pd, stream identification and status indicator;List item structure is as shown in table 1:
Purpose id | Source id | Purpose pd | Source pd |
Table 1
The parameter meaning of each key message is:
Purpose id and source id:Purpose equipment and the unique mark of source device;
Purpose pd and source pd:Purpose equipment and the unique mark of the affiliated protected field of source device, because in difference
Domain in can indicate distinct device with same id, so in order to determine unique destination address and source ground
Location, then need for purpose id and the combination of purpose pd to form destination address;Source id and source pd combination is formed
Source address.
Step 302, electronic equipment takes out WQE from SQ, and obtain corresponding purpose id of this WQE,
Source id, purpose pd and source pd;
Wherein, also obtain the corresponding stream identification of this WQE to uniquely identify this WQE.
Step 303, electronic equipment is by corresponding for WQE destination address and source address and storage in filter table
Destination address and source address are mated, and according to matching result, this WQE are put into await orders queue or execution
In queue, wherein, queue of awaiting orders is used for depositing the transmission instruction also not building up path;Execution queue is used for depositing
Put the instruction having built up transmitting path.
In this embodiment, destination address can be indicated with purpose id and purpose pd;Source address can use source
Id and source pd indicate, if in filter table not purpose id corresponding with WQE, source id, purpose pd and
Source pd identical list item, then put into this WQE and await orders in queue;When the state of WQE is adjusted to execute
State, then can put into this WQE in execution queue;The WQE in queue that awaits orders carries this WQE
Purpose id, source id, purpose pd, source pd data traffic identifier;
If having purpose id corresponding with WQE, source id, purpose pd and source pd identical table in filter table
, then this WQE is put in execution queue.
Step 304, electronic equipment selects WQE composition one special with certain cycle from queue of awaiting orders
Packet SQ_WQE_WAIT, send the packet to switch.
SQ_WQE_WAIT includes a WQE, the partial information of multiple WQE or WQE.From
Await orders and choose the principle of WQE in queue and can be:First choose in order, for not completing for a long time
The transmission instruction that path is set up can select according to certain policy priority.
Step 305, after switch receives SQ_WQE_WAIT, determines whether the number of request path
According to bag, if it is, being forwarded directly to controller, in the confirmation packet receiving controller feedback
After SQ_WQE_OK and flow table item, store this flow table item, and will confirm that packet SQ_WQE_OK turns
Issue electronic equipment;
Switch forwards packet SQ_WQE_WAIT and SQ_WQE_OK can pass through side in detail below
Formula is realized:
Two flow table items in advance, one is used for identifying that the packet receiving is special packet SQ_WQE_WAIT
Afterwards, directly packing reports controller;Another is used for identifying that the packet receiving is feedback data packet
It is transmitted to corresponding main frame after SQ_WQE_OK.Switch is to receive after SQ_WQE_WAIT immediately
Report controller, forward after rule by controller decision-making, controller sends SQ_WQE_OK to this switch
And flow table item.
Step 306, after electronic equipment receives the SQ_WQE_OK that switch forwarding comes, according to
The stream identification carrying in SQ_WQE_OK, finds out this stream identification corresponding from the SQ that awaits orders
WQE, this WQE is put into execution SQ.
Step 307, takes out, according to WQE, the data needing to send, this data of cutting has simultaneously been packaged into identical
Destination address and the packet of source address, this packet is sent one by one to switch;By switch by data
Forward a packet to the corresponding equipment of destination address.
In this embodiment, electronic equipment carries out data copy operation is all to obtain WQE from execution SQ
Carry out corresponding data acquisition, so after the WQE awaiting orders in SQ is put into execution SQ by electronic equipment,
Just triggering electronic equipment carries out RDMA operation.
Embodiment three
As Fig. 4, the embodiment of the present invention also provides another data forwarding method, when electronic equipment is using remote
When journey direct memory access RDMA technology carries out data copy, the method specifically includes:
Step 401, switch is received and is carried out using RDMA RDMA mode when electronic equipment
According to the inquiry mark in this pending data bag, the pending data bag sending during data copy, determines that this is treated
Processing data bag is the packet for inquiring about described data forwarding paths, then turn described pending data bag
It is sent to controller;
Wherein, determine that this pending data bag is for inquiring about according to the inquiry mark in this pending data bag
The packet of described data forwarding paths includes:
Obtain described inquiry mark from described pending data bag, and by the described inquiry getting mark with
Default inquiry list item is mated, if matching identical with described inquiry mark in described inquiry list item
Mark it is determined that described pending data bag is the packet for inquiring about data forwarding paths.
Step 402, receives the feedback information that controller sends, and this feedback information includes forwarding described data
Flow table item and confirmation;
Step 403, described confirmation is sent to described electronic equipment;
Step 404, receives the described data that described electronic equipment sends, and according to described flow table item (this stream
List item includes forwarding the forward-path of described data) forward described data.
In this embodiment, switch needs the pending data asking forward-path sending electronic equipment
Bag is transparent to controller so that controller can issue corresponding forward-path for this request.Work as controller
After determining the corresponding forward-path of request, then need to feed back forward-path and confirm message to switch and institute
State electronic equipment, because packet is to be forwarded to other equipment by switch, switch receives
After forward-path, then the forward-path with receiving updates the converting route of itself;In this embodiment,
Electronic equipment is it needs to be determined that after switch has the corresponding forward-path of request, then carries out the forwarding of data, so
After switch receives the confirmation of controller feedback, this confirmation message is forwarded to electronic equipment, thus
Electronic equipment is made to determine the data that can be transmitted according to this confirmation message.
In this embodiment, switch needs the confirmation message feeding back controller to be forwarded to electronic equipment, tool
Body implementation can be:
Will confirm that in information, setting identification is mated with default forward table, if with default forward table in certain
One list item is identical, then this confirmation is forwarded to electronic equipment.
Because path forwards request to pass through the process of two equipment, in order to ensure electronic equipment in reception
To confirmation can corresponding determine this confirmation corresponding to data to be forwarded, so generate request
When, then need to give a stream identification uniquely indicating this data to data to be forwarded, generating
During the request of acquisition forward-path, this request carries this stream identification, switch is existing with controller
Process the related message of this request and receive and all add this stream identification so that in the processing procedure of data and electricity
When sub- equipment finally receives confirmation message, it is able to know that the data corresponding to confirmation message receiving.
Example IV
As shown in figure 5, the embodiment of the present invention provides a kind of electronic equipment, this electronic equipment specifically includes:
Acquisition module 501, copies when electronic equipment carries out data using RDMA RDMA mode
Bei Shi, for taking out the corresponding Work Queue Elements of data to be sent (WQE) from transmit queue (SQ);
Wherein, this WQE is corresponding with the raw requests of described data to be sent;
Filtering module 502, for by corresponding for described WQE the first destination address and the first source address with pre-
If the destination address of each list item and source address are mated in filter table;
Package module 503, if in described first destination address and the first source address and described default filter table
Destination address and source address differ, for described WQE is packaged into a pending data bag;
Wherein, this package module 503 is specifically for being stored in described WQE in pending queue;And by institute
State the WQE in pending queue and be packaged into a pending data bag and send to switch.
In a particular application this pre-conditioned can using various ways realize, in this embodiment provide two kinds
Optimized mode, specially:
This package module 503 is specifically for default when determining that the WQE quantity in described pending queue is more than
Threshold value, then encapsulate a pending data bag by the WQE of the setting quantity in described pending queue and send
To switch;Or described pending queue is detected according to predetermined period, and by this pending team detecting
WQE in row sends to switch to being packaged into a pending data bag.
Transceiver module 504, for being forwarded to controller by switch by described pending data bag;And
After receiving the confirmation for described pending data bag of switch transmission, by described data to be sent
It is sent to switch.
On request in order to will forward between each equipment is corresponding with data, so can also add in the request
One unique data unique mark indicating WQE, so this transceiver module 504 is additionally operable to interpolation data only
One is identified in described pending data bag, and determines described WQE according to described data unique mark;Obtain
Take the corresponding described data to be sent of described WQE of determination;Wherein, this data unique mark is used for uniquely
Indicate described WQE.
In this embodiment, this electronic equipment also includes:
Generation module, corresponding for obtaining the WQE having obtained forward-path in described transmit queue SQ
Second destination address and the second source address, and according to described second destination address and the second source address generate
Default filter table.
Further, because the WQE in transmit queue SQ is real-time update, this generation module
Change periodically according to transmit queue can carry out adaptive renewal adjustment.
Embodiment five
As shown in fig. 6, the embodiment of the present invention also provides a kind of switch, when this electronic equipment is using remotely straight
When connecing memory access RDMA technology and carrying out data copy, this switch specifically includes:
Identification module 601, is entered using RDMA RDMA mode when electronic equipment for receiving
The pending data bag sending during row data copy, being determined according to the inquiry mark in this pending data bag should
Pending data bag is the packet for inquiring about described data forwarding paths, then by described pending data bag
It is forwarded to controller;
Wherein, this identification module 601 identifies specifically for obtaining described inquiry from described pending data bag,
And the described inquiry mark getting is mated with default inquiry list item, if in described inquiry list item
In match with described inquiry mark identical identify it is determined that described pending data bag is for inquiring about number
Packet according to forward-path.
Receiver module 602, for receiving the feedback information of controller transmission, this feedback information includes forwarding
The flow table item of data and confirmation;
Forwarding module 603, for described confirmation is sent to described electronic equipment, and receives described electricity
The described data that sub- equipment sends, forwards described data according to described flow table item.
Embodiment six
As shown in fig. 7, the embodiment of the present invention provides a kind of data forwarding system, this system includes:
Electronic equipment 701, for taking out data to be sent corresponding work queue unit from transmit queue SQ
Plain WQE;By in corresponding for described WQE the first destination address and the first source address and default filter table each
The destination address of list item and source address are mated, if described first destination address and the first source address and institute
State the destination address in default filter table and source address differs;By described WQE be packaged into one pending
Packet is sent to switch;After receiving the confirmation for described pending data bag, will be described
Data is activation to be sent is to switch;Wherein, this WQE is corresponding with the raw requests of described data to be sent
Switch 702, for receiving the pending data bag that described electronic equipment sends, waits to locate according to this
Inquiry mark in reason packet determines that this pending data bag is for inquiring about described data forwarding paths
Packet, then be forwarded to controller by described pending data bag;Receiving the feedback information that controller sends
Afterwards, this feedback information includes flow table item and the confirmation forwarding described data;Described confirmation is sent out
Deliver to described electronic equipment, and receive the described data that described electronic equipment sends, turned according to described flow table item
Send out data described;
Controller 703, forwards, for desampler, the pending data bag of coming, and from this pending data
Obtain WQE in bag, corresponding forward-path is obtained according to the source address in this WQE and destination address, and
Forward-path and confirmation are sent to switch.
Said one in the embodiment of the present application or multiple technical scheme, at least have the following technical effect that:
In prior art, if electronic equipment copies data by RDMA technology, can be directly by this data
It is cut into multiple little data blocks, be subsequently sent to switch and forwarded;If there is no data in switch
Block (asking corresponding data) corresponding forward-path, then need to send out to controller for each data block
Send the request of acquisition approach, then controller is directed to each corresponding path of request feedback.Although same request
Corresponding multiple data blocks, but the path corresponding to multiple data block is the same, so according to prior art
Scheme then can lead to the waste of controller resource.For this problem, in the embodiment of the present invention, if electronics
Equipment carries out data copy by RDMA technology, data exchange to be sent is not being become little data
Before block is sent to switch, the corresponding WQE of data to be sent is first packaged into a number by electronic equipment
According to bag, and this data is forwarded a packet to by controller by switch so that controller is treated for WQE determination
Send the corresponding path of data, and the path of determination is sent to switch, thus avoid switch being directed to
By what described data to be sent was syncopated as, there are same source address and multiple cutting data blocks of destination address, always
Be intended to the problem of forwarding list item under controller request path, thus avoid in prior art occur for very
The how data block of identical destination address and source address, switch needs to repeat to table look-up under determination path to controller
The problem of forwarding list item, has therefore saved the process resource of switch and controller, improves data to be sent
Forward efficiency.
Method of the present invention is not limited to the embodiment described in specific embodiment, art technology
Personnel's technology according to the present invention scheme draws other embodiments, also belongs to the technology wound of the present invention
New range.
Obviously, those skilled in the art can carry out various changes and modification without deviating from this to the present invention
The spirit and scope of invention.So, if these modifications of the present invention and modification belong to right of the present invention
Within the scope of requirement and its equivalent technologies, then the present invention is also intended to comprise these changes and modification exists
Interior.
Claims (14)
1. a kind of data forwarding method is it is characterised in that include:
When electronic equipment carries out data copy using RDMA RDMA mode, described electricity
Sub- equipment takes out data to be sent corresponding Work Queue Elements WQE from transmit queue SQ, wherein, should
WQE is corresponding with the raw requests of described data to be sent;
Corresponding for described WQE the first destination address and the first source address are filtered by described electronic equipment with default
In table, the destination address of each list item and source address are mated;
If the destination address in described first destination address and the first source address and described default filter table and
Source address all differs, and described WQE is packaged into a pending data bag and is sent to by described electronic equipment
Switch;
Described pending data bag is forwarded to controller by switch by described electronic equipment;
Described electronic equipment is receiving the confirmation for described pending data bag of switch transmission
Afterwards, by described data is activation to be sent to switch.
2. the method for claim 1 is it is characterised in that described pending data bag includes number
According to unique mark, this data unique mark is used for the described WQE of unique sign;
By described data is activation to be sent to before switch, also include:
Described WQE is determined according to described data unique mark;
Obtain the corresponding described data to be sent of described WQE determining.
3. method as claimed in claim 1 or 2 is it is characterised in that be packaged into one by described WQE
Pending data bag is sent to switch, including:
Described WQE is stored in pending queue;
WQE in described pending queue is packaged into a pending data bag send to switch.
4. method as claimed in claim 3 is it is characterised in that by the WQE in described pending queue
It is packaged into a pending data bag to send to switch, including:
When determining the WQE quantity in described pending queue more than predetermined threshold value, then by described pending team
The WQE of the setting quantity in row encapsulates a pending data bag and sends to switch;Or
Described pending queue is detected according to predetermined period, and by this pending queue detecting
WQE sends to switch to being packaged into a pending data bag.
5. described method as arbitrary in Claims 1 to 4 is it is characterised in that by each Work Queue Elements
Destination address in corresponding first destination address and the first source address and default filter table and source address are carried out
Before coupling, also include:
Obtain obtained in described transmit queue SQ forward-path corresponding second destination address of WQE and
Second source address, and described default filter table is generated according to described second destination address and the second source address.
6. a kind of data forwarding method is it is characterised in that include:
Switch receives and carries out data copy when electronic equipment using RDMA RDMA mode
When the pending data bag that sends;
According to the inquiry mark in this pending data bag, described switch determines that this pending data bag is to use
In the packet of inquiry data forwarding paths, then described pending data bag is forwarded to controller;
Described switch receives the feedback information that controller sends, and this feedback information includes forwarding the stream of data
List item and confirmation;
Described confirmation is sent to described electronic equipment by described switch;
Described switch receives the data that described electronic equipment sends, and forwards described number according to described flow table item
According to.
7. method as claimed in claim 6 is it is characterised in that according to looking in this pending data bag
Ask mark and determine that this pending data bag is the packet for inquiring about data forwarding paths, including:
Obtain described inquiry mark from described pending data bag, and by the described inquiry getting mark with
Default inquiry list item is mated, if matching identical with described inquiry mark in described inquiry list item
Mark it is determined that described pending data bag is the packet for inquiring about data forwarding paths.
8. a kind of electronic equipment is it is characterised in that this electronic equipment specifically includes:
Acquisition module, when electronic equipment carries out data copy using RDMA RDMA mode
When, for taking out data to be sent corresponding Work Queue Elements WQE from transmit queue SQ;Wherein,
This WQE is corresponding with the raw requests of described data to be sent;
Filtering module, for by corresponding for described WQE the first destination address and the first source address with preset
In filter table, the destination address of each list item and source address are mated;
Package module, if the mesh in described first destination address and the first source address and described default filter table
Address and source address all differ, for described WQE is packaged into a pending data bag;
Transceiver module, for being forwarded to controller by switch by described pending data bag;And receiving
After the confirmation for described pending data bag sending to switch, by described data is activation to be sent
To switch.
9. electronic equipment as claimed in claim 8 is it is characterised in that described transceiver module is additionally operable to add
Addend according to unique mark in described pending data bag, and according to described data unique mark determine described in
WQE;Obtain the corresponding described data to be sent of described WQE determining;Wherein, this data unique mark
Indicate described WQE for unique.
10. electronic equipment as claimed in claim 8 or 9 is it is characterised in that described package module is concrete
For described WQE is stored in pending queue;And the WQE in described pending queue is packaged into
One pending data bag sends to switch.
11. electronic equipments as claimed in claim 10 are it is characterised in that described package module is specifically used
In when determining the WQE quantity in described pending queue more than predetermined threshold value, then by described pending queue
In setting quantity WQE encapsulate a pending data bag send to switch;Or according to default week
Phase detects described pending queue, and by the WQE in this pending queue detecting to being packaged into one
Pending data bag sends to switch.
12. such as claim 8~11 arbitrary described electronic equipments it is characterised in that this electronic equipment also
Including:
Generation module, corresponding for obtaining the WQE having obtained forward-path in described transmit queue SQ
Second destination address and the second source address, and according to described second destination address and the second source address generate
Default filter table.
A kind of 13. switches are it is characterised in that this switch specifically includes:
Identification module, is carried out using RDMA RDMA mode when electronic equipment for receiving
According to the inquiry mark in this pending data bag, the pending data bag sending during data copy, determines that this is treated
Processing data bag is the packet for inquiring about described data forwarding paths, then turn described pending data bag
It is sent to controller;
Receiver module, for receiving the feedback information of controller transmission, this feedback information includes forwarding data
Flow table item and confirmation;
Forwarding module, for described confirmation is sent to described electronic equipment, and receives described electronics and sets
The described data that preparation is sent, forwards described data according to described flow table item.
14. switches as claimed in claim 13 it is characterised in that described identification module specifically for
Obtain described inquiry mark from described pending data bag, and by the described inquiry mark getting and preset
Inquiry list item mated, if described inquiry list item in match and described inquiry mark identical mark
Know it is determined that described pending data bag is the packet for inquiring about data forwarding paths.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510466494.7A CN106411739B (en) | 2015-07-31 | 2015-07-31 | A kind of data forwarding method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510466494.7A CN106411739B (en) | 2015-07-31 | 2015-07-31 | A kind of data forwarding method and device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN106411739A true CN106411739A (en) | 2017-02-15 |
CN106411739B CN106411739B (en) | 2019-06-21 |
Family
ID=58007992
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201510466494.7A Active CN106411739B (en) | 2015-07-31 | 2015-07-31 | A kind of data forwarding method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106411739B (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2019033891A1 (en) * | 2017-08-14 | 2019-02-21 | 华为技术有限公司 | Rdma-based network traffic determination method and device |
WO2019140556A1 (en) * | 2018-01-16 | 2019-07-25 | 华为技术有限公司 | Message transmission method and apparatus |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6948004B2 (en) * | 2001-03-28 | 2005-09-20 | Intel Corporation | Host-fabric adapter having work queue entry (WQE) ring hardware assist (HWA) mechanism |
US7013353B2 (en) * | 2001-03-30 | 2006-03-14 | Intel Corporation | Host-fabric adapter having an efficient multi-tasking pipelined instruction execution micro-controller subsystem |
CN103067280A (en) * | 2012-12-26 | 2013-04-24 | 华为技术有限公司 | Method and device of message processing |
US20130223277A1 (en) * | 2012-02-28 | 2013-08-29 | International Business Machines Corporation | Disjoint multi-pathing for a data center network |
US20130325998A1 (en) * | 2012-05-18 | 2013-12-05 | Dell Products, Lp | System and Method for Providing Input/Output Functionality by an I/O Complex Switch |
CN104301238A (en) * | 2014-10-17 | 2015-01-21 | 福建星网锐捷网络有限公司 | Message processing method, device and system |
-
2015
- 2015-07-31 CN CN201510466494.7A patent/CN106411739B/en active Active
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6948004B2 (en) * | 2001-03-28 | 2005-09-20 | Intel Corporation | Host-fabric adapter having work queue entry (WQE) ring hardware assist (HWA) mechanism |
US7013353B2 (en) * | 2001-03-30 | 2006-03-14 | Intel Corporation | Host-fabric adapter having an efficient multi-tasking pipelined instruction execution micro-controller subsystem |
US20130223277A1 (en) * | 2012-02-28 | 2013-08-29 | International Business Machines Corporation | Disjoint multi-pathing for a data center network |
US20130325998A1 (en) * | 2012-05-18 | 2013-12-05 | Dell Products, Lp | System and Method for Providing Input/Output Functionality by an I/O Complex Switch |
CN103067280A (en) * | 2012-12-26 | 2013-04-24 | 华为技术有限公司 | Method and device of message processing |
CN104301238A (en) * | 2014-10-17 | 2015-01-21 | 福建星网锐捷网络有限公司 | Message processing method, device and system |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2019033891A1 (en) * | 2017-08-14 | 2019-02-21 | 华为技术有限公司 | Rdma-based network traffic determination method and device |
WO2019140556A1 (en) * | 2018-01-16 | 2019-07-25 | 华为技术有限公司 | Message transmission method and apparatus |
US11716409B2 (en) | 2018-01-16 | 2023-08-01 | Huawei Technologies Co., Ltd. | Packet transmission method and apparatus |
Also Published As
Publication number | Publication date |
---|---|
CN106411739B (en) | 2019-06-21 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN104954281B (en) | Communication means, system, resource pool management system, interchanger and control device | |
CN102571587B (en) | Method and equipment for forwarding messages | |
JP2017518710A (en) | Service flow processing method, apparatus, and device | |
CN103748558A (en) | Virtual network overlays | |
CN102035751A (en) | Data transmission method and equipment | |
CN108702317B (en) | Industrialized communication system, the method and wireless receiving station for its operation that can redundantly run | |
CN103856302B (en) | A kind of smart machine control method | |
CN101834778B (en) | Method for processing neighbor discovery protocol item and three-layer switching equipment | |
CN101682476A (en) | Wireless network communications system | |
CN101394333A (en) | Packet forwarding method, apparatus and network system | |
JP2015529062A5 (en) | ||
CN100553189C (en) | Implementation method based on the multi-link redundancy of cache management | |
CN109076635B (en) | Industrial communication system, method and radio subscriber station capable of redundant operation | |
CN104301229B (en) | Data packet forwarding method, route table generating method and device | |
CN101938533B (en) | Method and device for processing address resolution | |
CN104735743A (en) | Routing optimization method for embedded wireless self-organized network | |
CN106411739A (en) | Data forwarding method, apparatus and system | |
CN106209644A (en) | A kind of message forwarding method based on equal-cost route and device | |
CN101022414B (en) | Message retransmitting method and apparatus | |
CN103716169A (en) | Point-to-multipoint multicast realization method, network nodes and system | |
CN103475626B (en) | A kind of method for asking resource, equipment and system | |
CN104427473B (en) | Communication equipment and communication means | |
CN105933235A (en) | Data communication method and data communication device | |
CN105847161A (en) | Control device and method for controlling switches to update flow tables | |
CN102420766B (en) | Routing determination method and routing device |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
TR01 | Transfer of patent right | ||
TR01 | Transfer of patent right |
Effective date of registration: 20210428 Address after: Unit 3401, unit a, building 6, Shenye Zhongcheng, No. 8089, Hongli West Road, Donghai community, Xiangmihu street, Futian District, Shenzhen, Guangdong 518040 Patentee after: Honor Device Co.,Ltd. Address before: 518129 Bantian HUAWEI headquarters office building, Longgang District, Guangdong, Shenzhen Patentee before: HUAWEI TECHNOLOGIES Co.,Ltd. |