CN106789756A - A kind of data transmission method for uplink and device based on operating system nucleus bridge - Google Patents
A kind of data transmission method for uplink and device based on operating system nucleus bridge Download PDFInfo
- Publication number
- CN106789756A CN106789756A CN201611218589.8A CN201611218589A CN106789756A CN 106789756 A CN106789756 A CN 106789756A CN 201611218589 A CN201611218589 A CN 201611218589A CN 106789756 A CN106789756 A CN 106789756A
- Authority
- CN
- China
- Prior art keywords
- packet
- address
- target
- trawl performance
- forwarding information
- 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.)
- Pending
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L61/00—Network arrangements, protocols or services for addressing or naming
- H04L61/45—Network directories; Name-to-address mapping
- H04L61/4535—Network directories; Name-to-address mapping using an address exchange platform which sets up a session between two nodes, e.g. rendezvous servers, session initiation protocols [SIP] registrars or H.323 gatekeepers
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L12/00—Data switching networks
- H04L12/28—Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
- H04L12/46—Interconnection of networks
- H04L12/4604—LAN interconnection over a backbone network, e.g. Internet, Frame Relay
- H04L12/462—LAN interconnection over a bridge based backbone
- H04L12/4625—Single bridge functionality, e.g. connection of two networks over a single bridge
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L12/00—Data switching networks
- H04L12/28—Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
- H04L12/46—Interconnection of networks
- H04L12/4604—LAN interconnection over a backbone network, e.g. Internet, Frame Relay
- H04L12/462—LAN interconnection over a bridge based backbone
-
- 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
- H04L45/00—Routing or path finding of packets in data switching networks
- H04L45/74—Address processing for routing
- H04L45/742—Route cache; Operation thereof
-
- 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
- H04L45/745—Address table lookup; Address filtering
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L61/00—Network arrangements, protocols or services for addressing or naming
- H04L61/58—Caching of addresses or names
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L49/00—Packet switching elements
- H04L49/30—Peripheral units, e.g. input or output ports
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
The embodiment of the invention discloses a kind of data transmission method for uplink and device based on operating system nucleus bridge;The embodiment of the present invention is used and reads packet to be sent from network interface card caching, then, the corresponding address forwarding information of the packet is searched in the address forwarding information of caching, when the corresponding address forwarding information of the packet is found, address forwarding information according to finding determines the target trawl performance for sending the packet, the packet directly is sent to the target trawl performance, so that the target trawl performance sends the packet.The program can improve the data forwarding performance of Linux kernel bridge.
Description
Technical field
The present invention relates to field of computer technology, and in particular to a kind of data sender based on operating system nucleus bridge
Method and device.
Background technology
At present, the process of Linux kernel bridge (kernel bridge) forwardings data is:Trawl performance is cached from network interface card
Middle extraction network data, then, trawl performance is by the network data transmission to Linux kernel bridge subsystems, Linux
Kernel bridge subsystems carry out forward process to network packet, and the network data is sent.
However, because Linux kernel bridge subsystems are more complicated to the forward process of network data, code is patrolled
Collect relatively more thick and heavy, therefore the data forwarding performance of Linux kernel bridge can be reduced.
The content of the invention
The embodiment of the present invention provides a kind of data transmission method for uplink and device based on operating system nucleus bridge, can improve
The data forwarding performance of Linux kernel bridge.
The embodiment of the present invention provides a kind of data transmission method for uplink based on operating system nucleus bridge, including:
Packet to be sent is read from network interface card caching;
The corresponding address forwarding information of the packet is searched in the address forwarding information of caching;
When the corresponding address forwarding information of the packet is found, determine to use according to the address forwarding information for finding
In the target trawl performance for sending the packet;
The packet directly is sent to the target trawl performance, so that the target trawl performance is by the packet
Send.
Accordingly, the embodiment of the present invention also provides a kind of data sending device based on operating system nucleus bridge, including:
Reading unit, for being cached from network interface card in read packet to be sent;
Searching unit, for searching the corresponding address forwarding information of the packet in the address forwarding information of caching;
Determining unit, for when the corresponding address forwarding information of the packet is found, according to the address for finding
Forwarding information determines the target trawl performance for sending the packet;
Transmitting element, for directly sending the packet to the target trawl performance, so that the target network interface card drives
It is dynamic to send the packet.
The embodiment of the present invention is used and reads packet to be sent from network interface card caching, then, in the address forwarding of caching
The corresponding address forwarding information of the packet is searched in information, when the corresponding address forwarding information of the packet is found, root
It is investigated that the address forwarding information for finding determines the target trawl performance for sending the packet, directly to the target trawl performance
The packet is sent, so that the target trawl performance sends the packet.The program can directly transmit packet
Target trawl performance is given, and is forwarded packet by target trawl performance, without first sending data packets to Linux again
Kernel bridge subsystems, then carry out forward process and are gone out with by data is activation by the subsystem;Therefore, the program can
To improve the data forwarding speed of Linux kernel bridge, and then improve the data forwarding of Linux kernel bridge
Performance.
Brief description of the drawings
Technical scheme in order to illustrate more clearly the embodiments of the present invention, below will be to that will make needed for embodiment description
Accompanying drawing is briefly described, it should be apparent that, drawings in the following description are only some embodiments of the present invention, for
For those skilled in the art, on the premise of not paying creative work, can also obtain other attached according to these accompanying drawings
Figure.
Fig. 1 a are the schematic diagram of a scenario of data forwarding system provided in an embodiment of the present invention;
Fig. 1 b are the flow charts of the data transmission method for uplink based on operating system nucleus bridge provided in an embodiment of the present invention;
Fig. 2 a are the structural representations of Linux bridge (bridge) system provided in an embodiment of the present invention;
Fig. 2 b are another flows of the data transmission method for uplink based on operating system nucleus bridge provided in an embodiment of the present invention
Figure;
Fig. 3 a are the structural representations of the data sending device based on operating system nucleus bridge provided in an embodiment of the present invention
Figure;
Fig. 3 b are another structures of the data sending device based on operating system nucleus bridge provided in an embodiment of the present invention
Schematic diagram;
Fig. 3 c are the another structures of the data sending device based on operating system nucleus bridge provided in an embodiment of the present invention
Schematic diagram.
Specific embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is carried out clear, complete
Site preparation is described, it is clear that described embodiment is only a part of embodiment of the invention, rather than whole embodiments.It is based on
Embodiment in the present invention, the every other implementation that those skilled in the art are obtained under the premise of creative work is not made
Example, belongs to the scope of protection of the invention.
The embodiment of the present invention provides a kind of data transmission method for uplink and device based on operating system nucleus bridge.
The embodiment of the invention provides a kind of data forwarding system includes:Any offer of the embodiment of the present invention based on operation
The data sending device of system kernel bridge.The data sending device can with it is integrated in the server, such as, be integrated in Linux
In the server of operating system.
As shown in Figure 1a, the data forwarding system includes server a, server b and terminal c, wherein, server a collection
Into the data sending device based on operating system nucleus bridge for having any offer of the embodiment of the present invention.Server a and service
By network connection between device b, network connection is passed through between server a and terminal c.
In data forwarding, server a is used to read packet to be sent from network interface card caching, then, in caching
The corresponding address forwarding information of the packet is searched in the forwarding information of address, is believed when the corresponding address forwarding of the packet is found
During breath, the target trawl performance for sending the packet is determined according to the address forwarding information for finding, directly to the target
Trawl performance sends the packet, so that the target trawl performance sends the packet to server a and terminal c.
Additionally, server a is additionally operable to that the signal that server b or terminal c sends is converted into network by physical network card
Data, and be stored in corresponding network interface card caching.
To be described in detail respectively below.
Embodiment one,
The present embodiment will enter from the angle of the data sending device based on operating system nucleus bridge (kernel bridge)
Row description, during the data sending device specifically can be with integrating server, such as, the server can be Linux server.
A kind of data transmission method for uplink based on operating system nucleus bridge, including:Read from network interface card caching to be sent
Packet, then, searches the corresponding address forwarding information of the packet, when finding the number in the address forwarding information of caching
During according to wrapping corresponding address forwarding information, the target network for sending the packet is determined according to the address forwarding information for finding
Card drives, and directly the packet is sent to the target trawl performance, so that the target trawl performance sends the packet.
As shown in Figure 1 b, the flow chart of the data transmission method for uplink that should be based on operating system nucleus bridge specifically can be as follows:
101st, packet to be sent is read from network interface card caching.
Wherein, network interface card caches the network data for depositing physical network card conversion, and each physical network card can correspond to one
Network interface card is cached.
Operating system can be with linux system or other operating systems in the present embodiment.
Alternatively, before step 101, the present embodiment method can also include:The address conversion of internal nucleoreticulum bridge system
Information is copied, and the information of address conversion to copying is cached.Packet enters when being so easy to follow-up data bag to forward
The determination of the address forwarding information of packet is carried out before kernel bridge system.
102nd, the corresponding address forwarding information of the packet is searched in the address forwarding information of caching.
Wherein, forwarding (fdb) information in address is the information for forwarding or sending packet, and its major function is to supply net
Network equipment such as server is forwarded in data link layer to packet, for determining which port packet is sent to.The address
Forwarding information mainly includes right between MAC (Media Access Control, media access control) addresses and forwarding port
Should be related to (i.e. mapping relations).
The address forwarding information can include addresses forwarding table, such as, can include MAC (Media Access
Control, media access control) addresses forwarding table;The MAC Address is referred to as physical address, hardware address etc..
Wherein, addresses forwarding table contains corresponding relation (the mapping pass between forwarding address and forwarding port (port)
System), specifically, the addresses forwarding table includes some address repeat listings, and the address repeat listing contains forwarding address and turns
Corresponding relation (mapping relations) between originator mouth.
Such as, mac address forwarding table includes some mac address forwarding tables, and each list item contains MAC Address with forwarding
Corresponding relation between port (port).The addresses forwarding table can be a two-layer retransmitting table.
When the address forwarding information of caching includes addresses forwarding table, step " is searched in the address forwarding information of caching
The corresponding address forwarding information of the packet " can include:
Obtain the corresponding destination address of the packet;
According to the destination address in the addresses forwarding table of caching, address repeat listing corresponding with destination address is searched.
Wherein, the corresponding address repeat listing of destination address can include the corresponding pass between destination address and forwarding port
System.
Such as, the corresponding target MAC (Media Access Control) address of packet can be obtained, then, according to the target MAC (Media Access Control) address in MAC Address
In forward table, address repeat listing corresponding with target MAC (Media Access Control) address, the corresponding address repeat listing of the target MAC (Media Access Control) address are searched
Comprising the corresponding relation between target MAC (Media Access Control) address and forwarding port.
103rd, when the corresponding address forwarding information of the packet is found, determined according to the address forwarding information for finding
Target trawl performance for sending the packet.
Step " the address forwarding information according to finding determines the target trawl performance for sending the packet ", bag
Include:
The address forwarding information found according to this searches corresponding forwarding port;
By the trawl performance with the forwarding port association, driven as sending the objective network of the packet.
Specifically, when address forward packets include addresses forwarding table, the addresses forwarding table includes some addresses forwarding tables
, each address repeat listing includes the corresponding relation between forwarding address and forwarding port;Now, the address forwarding for finding
Information includes the corresponding address repeat listing of destination address, and the destination address is the destination address of packet, namely destination address
Corresponding address repeat listing includes the mapping relations between destination address and forwarding port.
Step " the address forwarding information found according to this searches corresponding forwarding port " can include:According to finding
Address repeat listing search corresponding forwarding port.
Such as, when the address forwarding information of caching includes mac address forwarding table, the corresponding purpose of packet can be obtained
MAC Address, then, MAC ground corresponding with target MAC (Media Access Control) address is searched according to the target MAC (Media Access Control) address in the mac address forwarding table
Location forwarding-table item.After the corresponding mac address forwarding table of target MAC (Media Access Control) address is found, can be forwarded based on the MAC Address
Entry lookup forwards port accordingly.
In the present embodiment, mapping relations set can be driven to determine the trawl performance of forwarding port association based on port;
Namely step " by the trawl performance with the forwarding port association, being driven as sending the objective network of the packet " can be with
Including:
Mapping set is driven to determine the trawl performance with the forwarding port association, the port according to the forwarding port, port
Driving mapping set includes the mapping relations (corresponding relation) between forwarding port and trawl performance;
By the trawl performance of the forwarding port association, driven as sending the objective network of the packet.
In the present embodiment, trawl performance is that a kind of driver (Device Driver) full name is " device driver ",
It is that one kind can make central processing unit (CPU) --- CPU is controlled and using the separate procedure of equipment, equivalent to the interface of hardware,
Operating system controls the work of hardware device by this interface.
104th, the packet directly is sent to the target trawl performance, so that the target trawl performance sends the packet
Go out.
Specifically, step " directly sending the packet to the target trawl performance " can include:
Communication port is set up between the target trawl performance;
The packet is sent to the target trawl performance by the communication port.
Alternatively, when the corresponding address forwarding information of the packet is not found, the present embodiment method can be to kernel
Bridge system sends the packet, so that the kernel bridge system sends the packet within away.
Such as, when the corresponding address repeat listing of destination address is not found, can inwardly nucleoreticulum bridge system be (such as
Linux kernel bridge subsystems) packet is sent, the kernel bridge system opens mode of learning, and according to study
Result sends the packet to corresponding trawl performance, so that the trawl performance sends the packet.
From the foregoing, it will be observed that the embodiment of the present invention is used reads packet to be sent from network interface card caching, then, in caching
The corresponding address forwarding information of the packet is searched in the forwarding information of address, is believed when the corresponding address forwarding of the packet is found
During breath, the target trawl performance for sending the packet is determined according to the address forwarding information for finding, directly to the target
Trawl performance sends the packet, so that the target trawl performance sends the packet.The program can be by packet
Target trawl performance is transmitted directly to, and is forwarded packet by target trawl performance, without again first sending out packet
Linux kernel bridge subsystems are delivered to, then carry out forward process by the subsystem goes out with by data is activation;Cause
This, the program can improve the data forwarding speed of Linux kernel bridge, and then improve Linux kernel
The data forwarding performance of bridge and save device resource.
Embodiment two,
, be described in further detail for citing below by the method according to described by embodiment one.
In the present embodiment, by with specific server of the integrated operating system as Linux of the data sending device (referred to as
Linux server) as a example by illustrate.
As shown in Figure 2 a, the Linux server can include Linux bridge (bridge) system, and the system can be wrapped
Include:Linux kernel bridge (linux kernel bridge) subsystem, trawl performance 1, physical network card 1, trawl performance 2, thing
Reason network interface card 2, trawl performance 3 and physical network card 3.
Data sender of the invention is discussed in detail below based on Linux bridge (bridge) systems shown in Fig. 2 a
Method.
As shown in Figure 2 b, a kind of data transmission method for uplink based on operating system nucleus bridge (kernel bridge), specifically
Flow is as follows:
201st, Linux server is copied to the address forwarding information of Linux kernel bridge subsystems, and is delayed
Deposit the address forwarding information of copy.
Such as, a function is inserted in linux kernel bridge subsystems, for copying caching inux
Address forwarding (fdb) information of kernel bridge subsystems.
Wherein, address forwarding information can include mac address forwarding table, and the mac address forwarding table includes some MAC Address
List item, the list item contains the mapping relations between MAC Address and forwarding port (port).
Again such as, the address forwarding information of Linux kernel bridge subsystems can be copied by trawl performance 1
Shellfish, and cached copies address forwarding information.
202nd, physical network card 1 receives electric signal, and converts the electrical signal to network data, and the network data is deposited
In corresponding network interface card caching.
Such as, physical network card 1 receives electric signal by network, then, converts the electrical signal to corresponding data, obtains net
Network packet.
203rd, trawl performance 1 reads network packet to be sent from network interface card caching.
204th, trawl performance 1 searches the corresponding address forwarding letter of the network packet from the address forwarding information of caching
Breath.
Such as, a function can be inserted in trawl performance 1 for performing step 204-208.
Specifically, trawl performance 1 obtains the corresponding target MAC (Media Access Control) address of network packet, then, according to purpose MAC ground
The corresponding MAC Address list item of the target MAC (Media Access Control) address is searched in the mac address forwarding table of caching in location.
205th, trawl performance 1 determines whether to find the corresponding address forwarding information of the network packet, if so, then performing
Step 206, if it is not, then performing step 210.
Such as, by a function int nfp_process (uint32_t if_index, struct sk_buff*
Skb) search the corresponding address forwarding information of the network packet from the forwarding information of address, if finding, return to 0, if
Can not find out and then return to -1.
206th, trawl performance 1 searches corresponding forwarding port according to the address forwarding information for finding.
When trawl performance 1 finds the corresponding MAC Address list item of target MAC (Media Access Control) address, the MAC Address list item can be based on
Search corresponding forwarding port.
Wherein it is possible to call function dev_queue_xmit () performs step 206-208.
For example, in trawl performance 1, in tun_get_user (), after generating packet sk_buff, performing nfp_
Process (), if nfp_process () returns to 0, that is, finds the corresponding fdb information of network packet.At this point it is possible to call
Dev_queue_xmit () forwards (perform step 206-208) packet, no longer performs tun_netif_rx_ni
(skb), i.e., packet is no longer transmitted to linux kernel bridge subsystems.
207th, trawl performance 1 determines that the target network interface card of the forwarding port association is driven to trawl performance 2.
208th, communication port is set up between trawl performance 1 and trawl performance 3, and by the communication by by the network data
Bag is sent to trawl performance 2.
209th, trawl performance 2 puts into corresponding network interface card caching the network packet, and physical network card 2 delays the network interface card
Network packet in depositing is converted into electric signal and sends.
210th, the network packet is sent to Linux kernel bridge subsystems by trawl performance 1.
Such as, in trawl performance 1, in tun_get_user (), after generating packet sk_buff, nfp_ is performed
Process (), if nfp_process () returns to -1, continues executing with tun_netif_rx_ni (skb), and packet is passed
Give linux kernel bridge subsystems.
211st, Linux kernel bridge subsystems open mode of learning, and according to learning outcome to corresponding network interface card
3 are driven to send network packet.
212nd, trawl performance 3 puts into corresponding network interface card caching the network packet, and physical network card 3 delays the network interface card
Network packet in depositing is converted into electric signal and sends.
In the present embodiment, trawl performance 1 can be performed in tun_get_user (), after generating packet sk_buff
Nfp_process (), if nfp_process () returns to 0, that is, finds the corresponding fdb information of network packet, and call
Dev_queue_xmit () forwards the packet, now no longer performs tun_netif_rx_ni (skb), i.e., no longer will
Packet is transmitted to linux kernel bridge subsystems;If nfp_process () returns to -1, tun_ is continued executing with
Netif_rx_ni (skb), linux kernel bridge subsystems are transmitted to by packet.Specific code is as follows:
if(!nfp_process(skb->dev->ifindex,skb)){
tun_netif_rx_ni(skb);
}。
From the foregoing, it will be observed that the embodiment of the present invention can read packet to be sent from network interface card caching, then, in caching
The corresponding address forwarding information of the packet is searched in the forwarding information of address, is believed when the corresponding address forwarding of the packet is found
During breath, the target trawl performance for sending the packet is determined according to the address forwarding information for finding, directly to the target
Trawl performance sends the packet, is sent the packet with will pass through the driving of target network card;When not finding the data
Kernel bridge system is sent the packet to when wrapping corresponding address forwarding information, will pass through kernel bridge system by data
Bag sends.A part of packet can be transmitted directly to target trawl performance by the program, and by target trawl performance
Packet is forwarded, without first sending data packets to Linux kernel bridge subsystems again, then by the subsystem
System carries out forward process and is gone out with by data is activation;Therefore, the program can improve the data turn of Linux kernel bridge
Hair speed, and then improve the data forwarding performance of Linux kernel bridge and save the resource of server.
Embodiment three,
In order to preferably implement above method, the embodiment of the present invention also provides a kind of number based on operating system nucleus bridge
According to dispensing device, as shown in Figure 3 a, the advertising message dispensing device includes reading unit 301, searching unit 302, determining unit
303 and transmitting element 304, it is as follows:
(1) reading unit 301;
Reading unit 301, for being cached from network interface card in read packet to be sent.
Wherein, network interface card caches the network data for depositing physical network card conversion, and each physical network card can correspond to one
Network interface card is cached.
Operating system can be with linux system or other operating systems in the present embodiment.
(2) searching unit 302;
Searching unit 302, for searching the corresponding address forwarding information of the packet in the address forwarding information of caching.
Wherein, forwarding (fdb) information in address is the information for forwarding or sending packet, and its major function is to supply net
Network equipment such as server is forwarded in data link layer to packet, for determining which port packet is sent to.The address
Forwarding information mainly includes right between MAC (Media Access Control, media access control) addresses and forwarding port
Should be related to (i.e. mapping relations).,
Such as, with reference to Fig. 3 b, when the address forwarding information of the caching includes:During addresses forwarding table, the searching unit 302,
Can specifically include:
Address acquisition subelement 3021, for obtaining the corresponding destination address of the packet;
Subelement 3022 is searched, in the addresses forwarding table of caching, is searched and destination address for according to the destination address
Corresponding address forwarding information.
Such as, address acquisition subelement 3021, can be used for obtaining the corresponding target MAC (Media Access Control) address of the packet;Search son
Unit 3022, in mac address forwarding table, searching address forwarding corresponding with target MAC (Media Access Control) address according to the target MAC (Media Access Control) address
List item.
(3) determining unit 303;
Determining unit 303, for when the corresponding address forwarding information of the packet is found, according to the address for finding
Forwarding information determines the target trawl performance for sending the packet.
Such as, with reference to Fig. 3 c, determining unit 303 can include:
Subelement 3031 is searched in port, and the address forwarding information for being found according to this searches corresponding forwarding port;
Determination subelement 3032 is driven, for by the trawl performance with the forwarding port association, as sending the number
Driven according to the objective network of bag.
For example, subelement 3031 is searched in port, for forwarding end accordingly according to the MAC Address entry lookup for finding
Mouthful.
Again for example, drive determination subelement 3032, for according to the forwarding port, port drive mapping set determine with should
The trawl performance of port association is forwarded, the port drives mapping set including forwarding the mapping relations between port and trawl performance
(corresponding relation).
In the present embodiment, trawl performance is that a kind of driver (Device Driver) full name is " device driver ",
It is that one kind can make central processing unit (CPU) --- CPU is controlled and using the separate procedure of equipment, equivalent to the interface of hardware,
Operating system controls the work of hardware device by this interface.
(4) transmitting element 304;
Transmitting element 304, for directly sending the packet to the target trawl performance, so that the target trawl performance will
The packet sends.
Such as, the transmitting element 304, can specifically include:
Path Setup subelement, for setting up communication port between the target trawl performance;
Transmission sub-unit, for sending the packet to the target trawl performance by the communication port.
Alternatively, the data forwarding device can also include:Buffer unit;The buffer unit is used for:
Before reading unit read data packet, the information of address conversion of internal nucleoreticulum bridge system is copied;
Information of address conversion to copying is cached.
During specific implementation, above unit can be realized as independent entity, it is also possible to be combined, and be made
Realized for same or several entities, the specific implementation of above unit can be found in embodiment of the method above, herein not
Repeat again.
The data sending device for being based on operating system nucleus bridge can be specifically integrated in the network equipments such as server,
The server can be Linux server etc..In practical application, the data sending device can be integrated in trawl performance.
From the foregoing, it will be observed that embodiment of the present invention data forwarding device by reading unit 301 from network interface card cache in read it is pending
The packet for sending, then, searches the corresponding address of the packet in the address forwarding information of caching and forwards by searching unit 302
Information, when the corresponding address forwarding information of the packet is found, letter is forwarded by determining unit 303 according to the address for finding
Breath determines the target trawl performance for sending the packet, and directly being sent to the target trawl performance from transmitting element 304 should
Packet, so that the target trawl performance sends the packet.Packet can be transmitted directly to target by the program
Trawl performance, and forwarded packet by target trawl performance, without first sending data packets to Linux again
Kernel bridge subsystems, then carry out forward process and are gone out with by data is activation by the subsystem;Therefore, the program can
To improve the data forwarding speed of Linux kernel bridge, and then improve the data forwarding of Linux kernel bridge
Performance and save device resource.
One of ordinary skill in the art will appreciate that all or part of step in the various methods of above-described embodiment is can
Completed with instructing the hardware of correlation by program, the program can be stored in a computer-readable recording medium, storage
Medium can include:Read-only storage (ROM, Read Only Memory), random access memory (RAM, Random
Access Memory), disk or CD etc..
A kind of data transmission method for uplink and dress based on operating system nucleus bridge for being provided the embodiment of the present invention above
Put and be described in detail, specific case used herein is set forth to principle of the invention and implementation method, the above
The explanation of embodiment is only intended to help and understands the method for the present invention and its core concept;Simultaneously for those skilled in the art
Member, according to thought of the invention, will change in specific embodiments and applications, in sum, this explanation
Book content should not be construed as limiting the invention.
Claims (10)
1. a kind of data transmission method for uplink based on operating system nucleus bridge, it is characterised in that including:
Packet to be sent is read from network interface card caching;
The corresponding address forwarding information of the packet is searched in the address forwarding information of caching;
When the corresponding address forwarding information of the packet is found, determined for sending out according to the address forwarding information for finding
Send the target trawl performance of the packet;
The packet directly is sent to the target trawl performance, so that the target trawl performance sends the packet
Go out.
2. data transmission method for uplink as claimed in claim 1, it is characterised in that the address forwarding information that the basis finds is true
The fixed target trawl performance for being used to send the packet, including:
Corresponding forwarding port is searched according to the address forwarding information for finding;
By the trawl performance with the forwarding port association, driven as sending the objective network of the packet.
3. data transmission method for uplink as claimed in claim 1 or 2, it is characterised in that the address forwarding information of the caching includes:
Addresses forwarding table;
The corresponding address forwarding information of the packet is searched in the address forwarding information of caching, including:
Obtain the corresponding destination address of the packet;
According to the destination address in the addresses forwarding table of caching, address repeat listing corresponding with destination address is searched.
4. data transmission method for uplink as claimed in claim 1, it is characterised in that described directly to be sent to the target trawl performance
The packet, including:
Communication port is set up between the target trawl performance;
The packet is sent to the target trawl performance by the communication port.
5. data transmission method for uplink as claimed in claim 1, it is characterised in that also include:
When the corresponding address forwarding information of the packet is not found, inside nucleoreticulum bridge system sends the packet, with
Toilet is stated kernel bridge system and is sent the packet within away.
6. the data transmission method for uplink as described in claim any one of 1-5, it is characterised in that data are read in being cached from network interface card
Before bag, the data transmission method for uplink also includes:
The information of address conversion of internal nucleoreticulum bridge system is copied;
Information of address conversion to copying is cached.
7. a kind of data sending device based on operating system nucleus bridge, it is characterised in that including:
Reading unit, for being cached from network interface card in read packet to be sent;
Searching unit, for searching the corresponding address forwarding information of the packet in the address forwarding information of caching;
Determining unit, for when the corresponding address forwarding information of the packet is found, according to the address forwarding for finding
Information determines the target trawl performance for sending the packet;
Transmitting element, for directly sending the packet to the target trawl performance, so that the target trawl performance will
The packet sends.
8. data sending device as claimed in claim 7, it is characterised in that the determining unit, including:
Subelement is searched in port, and the address forwarding information for being found according to searches corresponding forwarding port;
Determination subelement is driven, for by the trawl performance with the forwarding port association, as sending the packet
Objective network drive.
9. data sending device as claimed in claim 7, it is characterised in that the address forwarding information of the caching includes:Ground
Location forward table;
The searching unit, specifically includes:
Address acquisition subelement, for obtaining the corresponding destination address of the packet;
Subelement is searched, in the addresses forwarding table of caching, is searched corresponding with destination address for according to the destination address
Address repeat listing.
10. data sending device as claimed in claim 7, it is characterised in that transmitting element, including:
Path Setup subelement, for setting up communication port between the target trawl performance;
Transmission sub-unit, for sending the packet to the target trawl performance by the communication port.
Priority Applications (3)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201611218589.8A CN106789756A (en) | 2016-12-26 | 2016-12-26 | A kind of data transmission method for uplink and device based on operating system nucleus bridge |
PCT/CN2017/117415 WO2018121373A1 (en) | 2016-12-26 | 2017-12-20 | Data forwarding method and apparatus based on network bridge of kernel of operating system |
US16/351,322 US11201760B2 (en) | 2016-12-26 | 2019-03-12 | Data forwarding method and apparatus based on operating system kernel bridge |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201611218589.8A CN106789756A (en) | 2016-12-26 | 2016-12-26 | A kind of data transmission method for uplink and device based on operating system nucleus bridge |
Publications (1)
Publication Number | Publication Date |
---|---|
CN106789756A true CN106789756A (en) | 2017-05-31 |
Family
ID=58926741
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201611218589.8A Pending CN106789756A (en) | 2016-12-26 | 2016-12-26 | A kind of data transmission method for uplink and device based on operating system nucleus bridge |
Country Status (3)
Country | Link |
---|---|
US (1) | US11201760B2 (en) |
CN (1) | CN106789756A (en) |
WO (1) | WO2018121373A1 (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2018121373A1 (en) * | 2016-12-26 | 2018-07-05 | 腾讯科技(深圳)有限公司 | Data forwarding method and apparatus based on network bridge of kernel of operating system |
WO2021051919A1 (en) * | 2019-09-21 | 2021-03-25 | 华为技术有限公司 | Data forwarding chip and server |
CN114500654A (en) * | 2022-02-23 | 2022-05-13 | 石家庄通合电子科技股份有限公司 | Data forwarding device, power module and data forwarding method |
Families Citing this family (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN116366542A (en) * | 2021-12-27 | 2023-06-30 | 成都鼎桥通信技术有限公司 | Data transmission method and related equipment |
CN116546557B (en) * | 2023-06-29 | 2023-11-17 | 阿里巴巴(中国)有限公司 | Data packet processing method, system, device and storage medium |
Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101582880A (en) * | 2008-05-14 | 2009-11-18 | 北京启明星辰信息技术股份有限公司 | Method and system for filtering messages based on audited object |
CN102694727A (en) * | 2012-05-21 | 2012-09-26 | 太仓市同维电子有限公司 | Method and device for realizing transmission acceleration of network data packets |
CN103347014A (en) * | 2013-06-25 | 2013-10-09 | 深圳市共进电子股份有限公司 | Network fast forwarding module and network fast forwarding achieving method |
CN103404084A (en) * | 2012-11-21 | 2013-11-20 | 华为技术有限公司 | MAC address forced forwarding device and method |
CN103812751A (en) * | 2014-02-28 | 2014-05-21 | 成都卫士通信息产业股份有限公司 | SSL VPN (secure sockets layer virtual private network) terminal data interaction method based on NDIS (network driver interface standard) |
WO2015058698A1 (en) * | 2013-10-23 | 2015-04-30 | Hangzhou H3C Technologies Co., Ltd. | Data forwarding |
CN104883302A (en) * | 2015-03-18 | 2015-09-02 | 华为技术有限公司 | Method, device and system for forwarding data packet |
CN105553889A (en) * | 2015-12-21 | 2016-05-04 | 浪潮集团有限公司 | Fast packet-receiving/packet-transmitting transferring method between physical network card and virtual network card under kernel network bridge |
Family Cites Families (34)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US5940596A (en) * | 1996-03-25 | 1999-08-17 | I-Cube, Inc. | Clustered address caching system for a network switch |
US6904519B2 (en) * | 1998-06-12 | 2005-06-07 | Microsoft Corporation | Method and computer program product for offloading processing tasks from software to hardware |
DE69934192T2 (en) * | 1998-10-27 | 2007-08-30 | Hewlett-Packard Development Co., L.P., Houston | Method and device for network connection by means of bridges |
US20020039365A1 (en) * | 1999-03-17 | 2002-04-04 | Broadcom Corporation | Pipelined searches with a cache table |
JP2001211190A (en) * | 2000-01-25 | 2001-08-03 | Hitachi Ltd | Device and method for managing communication |
JP2002057682A (en) * | 2000-08-09 | 2002-02-22 | Hitachi Ltd | Network interface changeover method and computer connectable to network |
US7089335B2 (en) * | 2000-10-30 | 2006-08-08 | Microsoft Corporation | Bridging multiple network segments and exposing the multiple network segments as a single network to a higher level networking software on a bridging computing device |
JP2003281109A (en) * | 2002-03-26 | 2003-10-03 | Hitachi Ltd | Load distribution method |
US7269739B2 (en) * | 2002-05-30 | 2007-09-11 | International Business Machines Corporation | Method and system for allowing for the secure transmission and reception of data in a processing system |
US7111303B2 (en) * | 2002-07-16 | 2006-09-19 | International Business Machines Corporation | Virtual machine operating system LAN |
KR20040023843A (en) * | 2002-09-12 | 2004-03-20 | 삼성전기주식회사 | Apparatus and method for processing defect in memory |
US7305493B2 (en) * | 2002-11-27 | 2007-12-04 | Intel Corporation | Embedded transport acceleration architecture |
US7408933B2 (en) * | 2003-02-20 | 2008-08-05 | Samsung Electronics Co., Ltd. | Distributed router with ping-pong preventing function and ping-pong preventing method using the same |
TWI243555B (en) * | 2003-07-09 | 2005-11-11 | Hon Hai Prec Ind Co Ltd | Apparatus and method of firewall |
EP1503286B1 (en) * | 2003-07-30 | 2014-09-03 | Jaluna SA | Multiple operating system networking |
JP4365672B2 (en) * | 2003-12-04 | 2009-11-18 | 株式会社日立製作所 | Packet communication node equipment |
JP2006060579A (en) * | 2004-08-20 | 2006-03-02 | Fujitsu Ltd | Communication device concurrently using a plurality of paths according to application characteristic |
US7688825B2 (en) * | 2005-04-12 | 2010-03-30 | Fujitsu Limited | Filtering frames at an input port of a switch |
TW200826571A (en) * | 2006-12-08 | 2008-06-16 | Univ Nat Chiao Tung | Identification and management system and method applicable to a point-to-point gateway |
US8312541B2 (en) * | 2007-07-17 | 2012-11-13 | Cisco Technology, Inc. | Detecting neighbor discovery denial of service attacks against a router |
TWI393390B (en) * | 2009-01-20 | 2013-04-11 | Ralink Technology Corp | Method and apparatus for forwarding packets |
US9111325B2 (en) * | 2009-12-31 | 2015-08-18 | Nvidia Corporation | Shared buffer techniques for heterogeneous hybrid graphics |
US20160154673A1 (en) * | 2014-07-23 | 2016-06-02 | Sitting Man, Llc | Methods, systems, and computer program products for providing a minimally complete operating environment |
US8478997B2 (en) * | 2010-09-10 | 2013-07-02 | Raytheon Company | Multi-level security software architecture |
US8468225B2 (en) * | 2010-12-16 | 2013-06-18 | Samsung Electronics Co., Ltd. | Roaming TCP connections between changing physical networks |
US9218356B2 (en) * | 2013-01-31 | 2015-12-22 | Cumulus Networks, Inc. | Systems and methods for accelerating networking functionality |
US9092336B2 (en) * | 2013-03-15 | 2015-07-28 | Intelligent Intellectual Property Holdings 2 Llc | Write admittance policy for a memory cache |
US8954631B2 (en) * | 2013-04-08 | 2015-02-10 | International Business Machines Corporation | Continuously transferring data using a USB mass storage device |
US9385773B2 (en) * | 2013-06-14 | 2016-07-05 | Broadcom Corporation | Traffic tunnel for end to end low latency |
US10129148B2 (en) * | 2014-08-18 | 2018-11-13 | Red Hat Israel, Ltd. | Table-based load balancing for bonded network interfaces |
US10270701B2 (en) * | 2014-12-05 | 2019-04-23 | Nec Corporation | Management node, terminal, communication system, communication method, and program storage medium |
CN106664242B (en) * | 2015-07-03 | 2019-09-03 | 华为技术有限公司 | A kind of configuration method of network, network system and equipment |
US9923818B2 (en) * | 2015-09-14 | 2018-03-20 | Citrix Systems, Inc. | Systems and methods of achieving equal distribution of packets in a multicore system which acts as a tunnel end point |
CN106789756A (en) * | 2016-12-26 | 2017-05-31 | 腾讯科技(深圳)有限公司 | A kind of data transmission method for uplink and device based on operating system nucleus bridge |
-
2016
- 2016-12-26 CN CN201611218589.8A patent/CN106789756A/en active Pending
-
2017
- 2017-12-20 WO PCT/CN2017/117415 patent/WO2018121373A1/en active Application Filing
-
2019
- 2019-03-12 US US16/351,322 patent/US11201760B2/en active Active
Patent Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101582880A (en) * | 2008-05-14 | 2009-11-18 | 北京启明星辰信息技术股份有限公司 | Method and system for filtering messages based on audited object |
CN102694727A (en) * | 2012-05-21 | 2012-09-26 | 太仓市同维电子有限公司 | Method and device for realizing transmission acceleration of network data packets |
CN103404084A (en) * | 2012-11-21 | 2013-11-20 | 华为技术有限公司 | MAC address forced forwarding device and method |
CN103347014A (en) * | 2013-06-25 | 2013-10-09 | 深圳市共进电子股份有限公司 | Network fast forwarding module and network fast forwarding achieving method |
WO2015058698A1 (en) * | 2013-10-23 | 2015-04-30 | Hangzhou H3C Technologies Co., Ltd. | Data forwarding |
CN103812751A (en) * | 2014-02-28 | 2014-05-21 | 成都卫士通信息产业股份有限公司 | SSL VPN (secure sockets layer virtual private network) terminal data interaction method based on NDIS (network driver interface standard) |
CN104883302A (en) * | 2015-03-18 | 2015-09-02 | 华为技术有限公司 | Method, device and system for forwarding data packet |
CN105553889A (en) * | 2015-12-21 | 2016-05-04 | 浪潮集团有限公司 | Fast packet-receiving/packet-transmitting transferring method between physical network card and virtual network card under kernel network bridge |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2018121373A1 (en) * | 2016-12-26 | 2018-07-05 | 腾讯科技(深圳)有限公司 | Data forwarding method and apparatus based on network bridge of kernel of operating system |
US11201760B2 (en) | 2016-12-26 | 2021-12-14 | Tencent Technology (Shenzhen) Company Limited | Data forwarding method and apparatus based on operating system kernel bridge |
WO2021051919A1 (en) * | 2019-09-21 | 2021-03-25 | 华为技术有限公司 | Data forwarding chip and server |
US11829309B2 (en) | 2019-09-21 | 2023-11-28 | Huawei Technologies Co., Ltd. | Data forwarding chip and server |
CN114500654A (en) * | 2022-02-23 | 2022-05-13 | 石家庄通合电子科技股份有限公司 | Data forwarding device, power module and data forwarding method |
CN114500654B (en) * | 2022-02-23 | 2024-03-22 | 石家庄通合电子科技股份有限公司 | Data forwarding device, power module and data forwarding method |
Also Published As
Publication number | Publication date |
---|---|
WO2018121373A1 (en) | 2018-07-05 |
US11201760B2 (en) | 2021-12-14 |
US20190207783A1 (en) | 2019-07-04 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106789756A (en) | A kind of data transmission method for uplink and device based on operating system nucleus bridge | |
CN104009920B (en) | The processing method of data source movement, the method for E-Packeting and its device | |
CN101997785B (en) | Gateway system and control method | |
CN113411243B (en) | Data transmission method and device | |
CN109802985A (en) | Data transmission method, device, equipment and read/write memory medium | |
EP2760174A1 (en) | Virtual private cloud access authentication method and related apparatus | |
CN103441948B (en) | A kind of data access method, network interface card and storage system | |
CN105939332B (en) | Defend the method and device of ARP attack message | |
CN105704036B (en) | Message forwarding method, device and system | |
CN101052022B (en) | System and method for virtual special net user to access public net | |
CN103067353A (en) | Method of transmitting data stream from remote sender to remote destination | |
JP2003273951A (en) | Information processor and communication path selection method | |
CN101141420A (en) | Method and system for performing data communication between private network and public network | |
CN101964799A (en) | Solution method of address conflict in point-to-network tunnel mode | |
WO2017019696A1 (en) | Methods and apparatus to reflect routes from a remotely located virtual route reflector | |
JP6928076B2 (en) | Packet monitoring | |
CN109067634A (en) | A kind of forwarding-table item creation method and device | |
CN103023778A (en) | Method and device for selecting path for router | |
CN107147580A (en) | The method and communication system of a kind of tunnel building | |
TW201931828A (en) | Flow table-based data transfer method | |
CN106250322B (en) | A kind of method and apparatus for writing data | |
CN108965479A (en) | A kind of domain collaboration caching method and device based on content center network | |
CN106302638A (en) | A kind of data managing method, forwarding unit and system | |
CN110392123A (en) | The methods, devices and systems of detection outlet IP address | |
CN103812774B (en) | Tactics configuring method, message processing method and related device based on TCAM |
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 | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20170531 |
|
RJ01 | Rejection of invention patent application after publication |