CN109309663B - Method and device for realizing penetration of two-layer protocol stack by docker network in cloud computing environment - Google Patents

Method and device for realizing penetration of two-layer protocol stack by docker network in cloud computing environment Download PDF

Info

Publication number
CN109309663B
CN109309663B CN201810918542.5A CN201810918542A CN109309663B CN 109309663 B CN109309663 B CN 109309663B CN 201810918542 A CN201810918542 A CN 201810918542A CN 109309663 B CN109309663 B CN 109309663B
Authority
CN
China
Prior art keywords
protocol stack
data packet
transparent transmission
new data
packet
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.)
Active
Application number
CN201810918542.5A
Other languages
Chinese (zh)
Other versions
CN109309663A (en
Inventor
张瑞海
靳春孟
张建伟
刘建
邵洪润
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Xiamen Jiwei Technology Co ltd
Original Assignee
Xiamen Jiwei Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Xiamen Jiwei Technology Co ltd filed Critical Xiamen Jiwei Technology Co ltd
Priority to CN201810918542.5A priority Critical patent/CN109309663B/en
Publication of CN109309663A publication Critical patent/CN109309663A/en
Application granted granted Critical
Publication of CN109309663B publication Critical patent/CN109309663B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/16Implementation or adaptation of Internet protocol [IP], of transmission control protocol [TCP] or of user datagram protocol [UDP]
    • H04L69/161Implementation details of TCP/IP or UDP/IP stack architecture; Specification of modified or new header fields
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/12Protocol engines
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L2212/00Encapsulation of packets

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention discloses a method and a device for realizing the penetration of a two-layer protocol stack by a docker network in a cloud computing environment, wherein the method comprises the following steps: the docker network protocol stack stores tcp/ip/eth related packet data and corresponding packet header information into a protocol stack cache for transparent transmission created in advance by a physical node, constructs a new data packet according to address and size corresponding to the cache, puts the new data packet into a related protocol stack packet processing function and sends the new data packet to a cloud host protocol stack, so that the cloud host protocol stack judges whether the received data packet is put in the protocol stack cache for transparent transmission or not, and directly sends the data packet to the physical node protocol stack if the received data packet is put in the protocol stack cache for transparent transmission; and the physical node protocol stack takes out the address, the size and the corresponding header information when receiving the data packet, takes out the data stored in the transparent transmission protocol stack cache according to the taken out address and size, performs packet processing on the functions corresponding to the tcp, ip and eth layers, and sends the functions to the physical network card for transmission. The data packet quantity of network protocol stacks in the docker and the cloud host can be reduced, and the CPU utilization rate and the data packet forwarding speed are reduced.

Description

Method and device for realizing penetration of two-layer protocol stack by docker network in cloud computing environment
Technical Field
The embodiment of the invention relates to the technical field of computer networks, in particular to a method and a device for realizing that a docker network penetrates through two layers of protocol stacks in a cloud computing environment.
Background
The docker is an open-source application container engine, so that developers can package their applications and dependency packages into a portable container and then distribute the portable container to any popular Linux machine, and virtualization can be realized. Docker envisages that the operating environment is delivered as a ship, the OS (operating system) as a ship, each piece of software based on the OS as a container, the user can freely assemble the operating environment by standardized means, and the content of the container can be customized by the user or manufactured by professionals. Thus, delivering a piece of software, i.e. a collection of standardized components, like a happy block, the user simply selects the appropriate block combination and deploys his name at the top (the last standardized component is the user's application app)
At present, more and more dockers are used in cloud computing environments, a user often creates a cloud host and then installs docker services, and under the scene, a data packet of a docker network firstly walks through a network protocol stack of the docker, then goes out of the protocol stack of the cloud host and then walks through a protocol stack of a physical machine, so that a very large cpu (central processing unit), a memory and time consumption can be caused, and at present, no good technical scheme can solve the problem.
Disclosure of Invention
Because the existing method has the problems, the embodiment of the invention provides a method and a device for realizing the penetration of a two-layer protocol stack by a docker network in a cloud computing environment.
In a first aspect, an embodiment of the present invention provides a method for enabling a docker network to penetrate a two-layer protocol stack in a cloud computing environment, where the method includes:
the method comprises the steps that a docker network protocol stack stores tcp/ip/eth related packet data and corresponding packet header information into a transparent transmission protocol stack cache created by a physical node in advance, a new data packet is constructed according to an address and a size corresponding to the transparent transmission protocol stack cache, and the new data packet is placed into a related protocol stack packet processing function and sent to a cloud host protocol stack;
the cloud host network protocol stack judges whether the received new data packet is placed in a protocol stack cache for transparent transmission, and if yes, the new data packet is directly transmitted to a physical node protocol stack;
and when the physical node protocol stack receives the new data packet, the address, the size and the corresponding header information in the new data packet are taken out, the data stored in the protocol stack cache for the transparent transmission is taken out according to the taken out address and size, the data stored in the protocol stack cache for the transparent transmission is transmitted to a function corresponding to a tcp layer, an ip layer and an eth layer for packet processing, and then the data is transmitted to a physical network card for transmission.
Optionally, before the packet data and corresponding packet header information related to tcp/ip/eth are stored in a transparent transmission protocol stack cache created in advance by a physical node in a docker network protocol stack, a new data packet is constructed according to an address and a size corresponding to the transparent transmission protocol stack cache, and the new data packet is placed in a related protocol stack packet processing function and sent to a cloud host protocol stack, the method further includes:
and creating a transparent transmission protocol stack cache at the physical node, and transmitting the transparent transmission protocol stack cache to a network drive of a docker network protocol stack.
Optionally, after creating a transparent transmission protocol stack cache in the physical node and transmitting the transparent transmission protocol stack cache to a network driver of the docker network protocol stack, the method further includes:
modifying a network drive of a docker network protocol stack, enabling the docker network protocol stack to store tcp/ip/eth related packet data and corresponding packet header information into a transparent transmission protocol stack cache created in advance by a physical node, constructing a new data packet according to an address and a size corresponding to the transparent transmission protocol stack cache, and sending the new data packet to a cloud host protocol stack by putting the new data packet into a related protocol stack packet processing function;
modifying the network drive of the cloud host network protocol stack, so that the cloud host network protocol stack judges whether the received new data packet is placed in a transparent transmission protocol stack cache, and if so, directly forwarding the new data packet to a physical node protocol stack;
modifying a network drive of a physical node protocol stack, so that when the physical node protocol stack receives the new data packet, the address, the size and corresponding header information in the new data packet are taken out, the data stored in the transparent transmission protocol stack cache is taken out according to the taken address and the size, the data stored in the transparent transmission protocol stack cache is transmitted to a function corresponding to a tcp layer, an ip layer and an eth layer for packet processing, and then the data is transmitted to a physical transmission network card.
In a second aspect, an embodiment of the present invention further provides an apparatus for implementing a docker network to penetrate a two-layer protocol stack in a cloud computing environment, where the apparatus includes:
the first sending module is used for the docker network protocol stack to store tcp/ip/eth related packet data and corresponding packet header information into a transparent transmission protocol stack cache created by a physical node in advance, construct a new data packet according to an address and a size corresponding to the transparent transmission protocol stack cache, and send the new data packet to a cloud host protocol stack in a related protocol stack packet processing function;
the second sending module is used for judging whether the received new data packet is placed in a protocol stack cache for transparent transmission or not by the cloud host network protocol stack, and if so, directly forwarding the new data packet to a physical node protocol stack;
and the third sending module is used for taking out the address, the size and the corresponding header information in the new data packet when the physical node protocol stack receives the new data packet, taking out the data stored in the protocol stack cache for the transparent transmission according to the taken out address and size, transmitting the data stored in the protocol stack cache for the transparent transmission to a function corresponding to a tcp layer, an ip layer and an eth layer for packet processing, and then transmitting the data to a physical network card for transmission.
Optionally, the apparatus further comprises:
and the creating module is used for creating a transparent transmission protocol stack cache at the physical node and transmitting the transparent transmission protocol stack cache to a network drive of the docker network protocol stack.
Optionally, the apparatus further comprises:
the first modification module is used for modifying the network drive of the docker network protocol stack, so that the docker network protocol stack stores tcp/ip/eth related packet data and corresponding packet header information into a transparent transmission protocol stack cache created by a physical node in advance, constructs a new data packet according to an address and a size corresponding to the transparent transmission protocol stack cache, and sends the new data packet to a related protocol stack packet processing function to the cloud host protocol stack;
the second modification module is used for modifying the network drive of the cloud host network protocol stack, so that the cloud host network protocol stack judges whether the received new data packet is placed in the transparent transmission protocol stack cache or not, and if yes, the new data packet is directly forwarded to the physical node protocol stack;
and the third modification module is used for modifying the network drive of the physical node protocol stack, so that when the physical node protocol stack receives the new data packet, the address, the size and the corresponding header information in the new data packet are taken out, the data stored in the protocol stack cache for transparent transmission is taken out according to the taken address and the size, the data stored in the protocol stack cache for transparent transmission is transmitted to the functions corresponding to the tcp, ip and eth layers for packet processing, and then the data is transmitted to the physical network card for transmission.
In a third aspect, an embodiment of the present invention provides an electronic device, including: a processor, a memory, a bus, and a computer program stored on the memory and executable on the processor;
the processor and the memory complete mutual communication through the bus;
the processor, when executing the computer program, implements the method described above.
In a fourth aspect, an embodiment of the present invention provides a non-transitory computer-readable storage medium, on which a computer program is stored, and the computer program, when executed by a processor, implements the above method.
According to the technical scheme, the method and the device for realizing the penetration of the two layers of protocol stacks by the docker network in the cloud computing environment provided by the embodiment of the invention have the advantages that the data and the corresponding data header information are put into the transparent transmission protocol stack cache created in advance by the physical node, so that the data packets in the docker are not processed by the docker network protocol stack, the cloud host network protocol stack and the physical node protocol stack one by one, the number of the data packets in the docker and the cloud host network protocol stack is greatly reduced, and the cpu utilization rate and the forwarding speed of the data packets are reduced.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to these drawings without creative efforts.
Fig. 1 is a schematic flowchart of a method for implementing a docker network to penetrate through two layers of protocol stacks in a cloud computing environment according to an embodiment of the present invention;
fig. 2 is a schematic structural diagram of an apparatus for implementing a docker network to penetrate through two layers of protocol stacks in a cloud computing environment according to an embodiment of the present invention;
fig. 3 is a schematic physical structure diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
The following further describes embodiments of the present invention with reference to the accompanying drawings. The following examples are only for illustrating the technical solutions of the present invention more clearly, and the protection scope of the present invention is not limited thereby.
Fig. 1 is a schematic flowchart illustrating a method for implementing a docker network to penetrate through two layers of protocol stacks in a cloud computing environment according to an embodiment of the present invention, where as shown in fig. 1, the method for implementing the docker network to penetrate through two layers of protocol stacks in a cloud computing environment according to the embodiment includes:
s1, storing packet data related to tcp (transmission control protocol)/ip (protocol interconnected between networks)/eth (Ethernet) and corresponding packet header information into a transparent transmission protocol stack cache (high-speed buffer memory) pre-created by a physical node by a docker network protocol stack, constructing a new data packet according to address and size corresponding to the transparent transmission protocol stack cache, and sending the new data packet to a related protocol stack packet processing function to a cloud host protocol stack.
At this time, tens of thousands of data packets can be merged into one data block, and only the address and the size of the corresponding protocol stack cache for transparent transmission are recorded, so that the cpu consumption of the data packets in one physical node is greatly reduced.
S2, the cloud host network protocol stack judges whether the received new data packet is placed in a protocol stack cache for transparent transmission, and if yes, the new data packet is directly forwarded to a physical node protocol stack;
s3, when the physical node protocol stack receives the new data packet, the address, the size and the corresponding header information in the new data packet are taken out, the data stored in the protocol stack cache for the transparent transmission is taken out according to the taken out address and size, the data stored in the protocol stack cache for the transparent transmission is transmitted to the function corresponding to the tcp, ip and eth layers for packet processing, and then the data is transmitted to the physical network card for transmission.
In the method for realizing the penetration of the two layers of protocol stacks by the docker network in the cloud computing environment provided by this embodiment, data and corresponding data packet header information are placed in the transparent transmission protocol stack cache created in advance by the physical node, so that data packets in the docker are not all processed by the docker network protocol stack, the cloud host network protocol stack and the physical node protocol stack one by one, the number of data packets in the docker and the cloud host network protocol stack is greatly reduced, and the cpu utilization rate and the forwarding speed of the data packets are reduced.
Further, in a specific application, before the step S1, the method in this embodiment may further include:
and creating a transparent transmission protocol stack cache at the physical node, and transmitting the transparent transmission protocol stack cache to a network drive of a docker network protocol stack.
Further, after creating a transparent transmission protocol stack cache at the physical node and transmitting the transparent transmission protocol stack cache to a network driver of the docker network protocol stack, the method may further include:
modifying a network drive of a docker network protocol stack, enabling the docker network protocol stack to store tcp/ip/eth related packet data and corresponding packet header information into a transparent transmission protocol stack cache created in advance by a physical node, constructing a new data packet according to an address and a size corresponding to the transparent transmission protocol stack cache, and sending the new data packet to a cloud host protocol stack by putting the new data packet into a related protocol stack packet processing function;
modifying the network drive of the cloud host network protocol stack, so that the cloud host network protocol stack judges whether the received new data packet is placed in a transparent transmission protocol stack cache, and if so, directly forwarding the new data packet to a physical node protocol stack;
modifying a network drive of a physical node protocol stack, so that when the physical node protocol stack receives the new data packet, the address, the size and corresponding header information in the new data packet are taken out, the data stored in the transparent transmission protocol stack cache is taken out according to the taken address and the size, the data stored in the transparent transmission protocol stack cache is transmitted to a function corresponding to a tcp layer, an ip layer and an eth layer for packet processing, and then the data is transmitted to a physical transmission network card.
In the method for realizing the penetration of the two layers of protocol stacks by the docker network in the cloud computing environment provided by this embodiment, data and corresponding data packet header information are placed in the transparent transmission protocol stack cache created in advance by the physical node, so that data packets in the docker are not all processed by the docker network protocol stack, the cloud host network protocol stack and the physical node protocol stack one by one, the number of data packets in the docker and the cloud host network protocol stack is greatly reduced, and the cpu utilization rate and the forwarding speed of the data packets are reduced.
Fig. 2 is a schematic structural diagram of a device for implementing a docker network to penetrate through two layers of protocol stacks in a cloud computing environment according to an embodiment of the present invention, and as shown in fig. 2, the device for implementing a docker network to penetrate through two layers of protocol stacks in a cloud computing environment according to the embodiment includes: a first sending module 21, a second sending module 22 and a third sending module 23; wherein:
the first sending module 21 is configured to store tcp/ip/eth-related packet data and corresponding packet header information in a transparent transmission protocol stack cache created in advance by a physical node by a docker network protocol stack, construct a new data packet according to an address and a size corresponding to the transparent transmission protocol stack cache, and send the new data packet to a cloud host protocol stack in a related protocol stack packet processing function;
the second sending module 22 is configured to determine, by the cloud host network protocol stack, whether the received new data packet is placed in the transparent transmission protocol stack cache, and if so, directly forward the new data packet to the physical node protocol stack;
the third sending module 23 is configured to, when the physical node protocol stack receives the new data packet, take out the address, the size, and the corresponding header information in the new data packet, take out the data stored in the transparent transmission protocol stack cache according to the taken out address and size, transmit the data stored in the transparent transmission protocol stack cache to a function corresponding to the tcp, ip, and eth layers for packet processing, and then send the data to the physical network card for transmission.
It can be understood that the first sending module 21 constructs a new data packet according to the address and the size corresponding to the transparent transmission protocol stack cache, and sends the new data packet to the relevant protocol stack packet processing function to the cloud host protocol stack, so that tens of thousands of data packets can be merged into one data block, and only the address and the size of the corresponding transparent transmission protocol stack cache are recorded, thereby greatly reducing cpu consumption of the data packet in one physical node.
According to the device for realizing the fact that the docker network penetrates through two layers of protocol stacks in the cloud computing environment, data and corresponding data packet header information are placed in the transparent transmission protocol stack cache created in advance by the physical node, so that data packets in the docker do not all pass through the docker network protocol stack, the cloud host network protocol stack and the physical node protocol stack one by one, the number of the data packets in the docker network protocol stack and the cloud host network protocol stack is greatly reduced, and therefore the utilization rate of a cpu and the forwarding speed of the data packets are reduced.
Further, in a specific application, the apparatus according to this embodiment may further include:
and the creating module is used for creating a transparent transmission protocol stack cache at the physical node and transmitting the transparent transmission protocol stack cache to a network drive of the docker network protocol stack.
Further, the apparatus may further include, not shown in the figure:
the first modification module is used for modifying the network drive of the docker network protocol stack, so that the docker network protocol stack stores tcp/ip/eth related packet data and corresponding packet header information into a transparent transmission protocol stack cache created by a physical node in advance, constructs a new data packet according to an address and a size corresponding to the transparent transmission protocol stack cache, and sends the new data packet to a related protocol stack packet processing function to the cloud host protocol stack;
the second modification module is used for modifying the network drive of the cloud host network protocol stack, so that the cloud host network protocol stack judges whether the received new data packet is placed in the transparent transmission protocol stack cache or not, and if yes, the new data packet is directly forwarded to the physical node protocol stack;
and the third modification module is used for modifying the network drive of the physical node protocol stack, so that when the physical node protocol stack receives the new data packet, the address, the size and the corresponding header information in the new data packet are taken out, the data stored in the protocol stack cache for transparent transmission is taken out according to the taken address and the size, the data stored in the protocol stack cache for transparent transmission is transmitted to the functions corresponding to the tcp, ip and eth layers for packet processing, and then the data is transmitted to the physical network card for transmission.
According to the device for realizing the fact that the docker network penetrates through two layers of protocol stacks in the cloud computing environment, data and corresponding data packet header information are placed in the transparent transmission protocol stack cache created in advance by the physical node, so that data packets in the docker do not all pass through the docker network protocol stack, the cloud host network protocol stack and the physical node protocol stack one by one, the number of the data packets in the docker network protocol stack and the cloud host network protocol stack is greatly reduced, and therefore the utilization rate of a cpu and the forwarding speed of the data packets are reduced.
The apparatus for implementing a docker network to penetrate through a two-layer protocol stack in a cloud computing environment in this embodiment may be configured to implement the technical solution of the foregoing method embodiment, and the implementation principle and the technical effect are similar, which are not described herein again.
Fig. 3 is a schematic physical structure diagram of an electronic device according to an embodiment of the present invention, and as shown in fig. 3, the electronic device may include: a processor 301, a memory 302, a bus 303, and computer programs stored on the memory 302 and operable on the processor 301;
wherein, the processor 301 and the memory 302 complete the communication with each other through the bus 303;
when the processor 301 executes the computer program, the method provided by the above method embodiment is implemented, for example, including: the method comprises the steps that a docker network protocol stack stores tcp/ip/eth related packet data and corresponding packet header information into a transparent transmission protocol stack cache created by a physical node in advance, a new data packet is constructed according to an address and a size corresponding to the transparent transmission protocol stack cache, and the new data packet is placed into a related protocol stack packet processing function and sent to a cloud host protocol stack; the cloud host network protocol stack judges whether the received new data packet is placed in a protocol stack cache for transparent transmission, and if yes, the new data packet is directly transmitted to a physical node protocol stack; and when the physical node protocol stack receives the new data packet, the address, the size and the corresponding header information in the new data packet are taken out, the data stored in the protocol stack cache for the transparent transmission is taken out according to the taken out address and size, the data stored in the protocol stack cache for the transparent transmission is transmitted to a function corresponding to a tcp layer, an ip layer and an eth layer for packet processing, and then the data is transmitted to a physical network card for transmission.
An embodiment of the present invention provides a non-transitory computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the computer program implements the method provided by the above method embodiment, for example, the method includes: the method comprises the steps that a docker network protocol stack stores tcp/ip/eth related packet data and corresponding packet header information into a transparent transmission protocol stack cache created by a physical node in advance, a new data packet is constructed according to an address and a size corresponding to the transparent transmission protocol stack cache, and the new data packet is placed into a related protocol stack packet processing function and sent to a cloud host protocol stack; the cloud host network protocol stack judges whether the received new data packet is placed in a protocol stack cache for transparent transmission, and if yes, the new data packet is directly transmitted to a physical node protocol stack; and when the physical node protocol stack receives the new data packet, the address, the size and the corresponding header information in the new data packet are taken out, the data stored in the protocol stack cache for the transparent transmission is taken out according to the taken out address and size, the data stored in the protocol stack cache for the transparent transmission is transmitted to a function corresponding to a tcp layer, an ip layer and an eth layer for packet processing, and then the data is transmitted to a physical network card for transmission.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, apparatus, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus, and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means/systems for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
It is noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element. The terms "upper", "lower", and the like, indicate orientations or positional relationships based on the orientations or positional relationships shown in the drawings, and are only for convenience in describing the present invention and simplifying the description, but do not indicate or imply that the referred devices or elements must have a specific orientation, be constructed and operated in a specific orientation, and thus, should not be construed as limiting the present invention. Unless expressly stated or limited otherwise, the terms "mounted," "connected," and "connected" are intended to be inclusive and mean, for example, that they may be fixedly connected, detachably connected, or integrally connected; can be mechanically or electrically connected; they may be connected directly or indirectly through intervening media, or they may be interconnected between two elements. The specific meanings of the above terms in the present invention can be understood by those skilled in the art according to specific situations.
In the description of the present invention, numerous specific details are set forth. It is understood, however, that embodiments of the invention may be practiced without these specific details. In some instances, well-known methods, structures and techniques have not been shown in detail in order not to obscure an understanding of this description. Similarly, it should be appreciated that in the foregoing description of exemplary embodiments of the invention, various features of the invention are sometimes grouped together in a single embodiment, figure, or description thereof for the purpose of streamlining the disclosure and aiding in the understanding of one or more of the various inventive aspects. However, the disclosed method should not be interpreted as reflecting an intention that: that the invention as claimed requires more features than are expressly recited in each claim. Rather, as the following claims reflect, inventive aspects lie in less than all features of a single foregoing disclosed embodiment. Thus, the claims following the detailed description are hereby expressly incorporated into this detailed description, with each claim standing on its own as a separate embodiment of this invention. It should be noted that the embodiments and features of the embodiments in the present application may be combined with each other without conflict. The present invention is not limited to any single aspect, nor is it limited to any single embodiment, nor is it limited to any combination and/or permutation of these aspects and/or embodiments. Moreover, each aspect and/or embodiment of the present invention may be utilized alone or in combination with one or more other aspects and/or embodiments thereof.
Finally, it should be noted that: the above embodiments are only used to illustrate the technical solution of the present invention, and not to limit the same; while the invention has been described in detail and with reference to the foregoing embodiments, it will be understood by those skilled in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some or all of the technical features may be equivalently replaced; such modifications and substitutions do not depart from the spirit and scope of the present invention, and they should be construed as being included in the following claims and description.

Claims (8)

1. A method for realizing that a docker network penetrates through a two-layer protocol stack in a cloud computing environment is characterized by comprising the following steps:
the method comprises the steps that a docker network protocol stack stores tcp/ip/eth related packet data and corresponding packet header information into a transparent transmission protocol stack cache created by a physical node in advance, a new data packet is constructed according to an address and a size corresponding to the transparent transmission protocol stack cache, and the new data packet is placed into a related protocol stack packet processing function and sent to a cloud host network protocol stack;
the cloud host network protocol stack judges whether the received new data packet is placed in a protocol stack cache for transparent transmission, and if yes, the new data packet is directly transmitted to a physical node protocol stack;
and when the physical node protocol stack receives the new data packet, the address, the size and the corresponding header information in the new data packet are taken out, the data stored in the protocol stack cache for the transparent transmission is taken out according to the taken out address and size, the data stored in the protocol stack cache for the transparent transmission is transmitted to a function corresponding to a tcp layer, an ip layer and an eth layer for packet processing, and then the data is transmitted to a physical network card for transmission.
2. The method according to claim 1, wherein before the docker network protocol stack stores tcp/ip/eth-related packet data and corresponding packet header information into a transparent transmission protocol stack cache created in advance by a physical node, constructs a new data packet according to an address and a size corresponding to the transparent transmission protocol stack cache, and places the new data packet into a related protocol stack packet processing function to be sent to a cloud host network protocol stack, the method further comprises:
and creating a transparent transmission protocol stack cache at the physical node, and transmitting the transparent transmission protocol stack cache to a network drive of a docker network protocol stack.
3. The method of claim 2, wherein after the creating the transparent transmission protocol stack cache at the physical node and transmitting the transparent transmission protocol stack cache to the network driver of the docker network protocol stack, the method further comprises:
modifying a network drive of a docker network protocol stack, enabling the docker network protocol stack to store tcp/ip/eth related packet data and corresponding packet header information into a transparent transmission protocol stack cache created in advance by a physical node, constructing a new data packet according to an address and a size corresponding to the transparent transmission protocol stack cache, and sending the new data packet to a cloud host network protocol stack by putting the new data packet into a related protocol stack packet processing function;
modifying the network drive of the cloud host network protocol stack, so that the cloud host network protocol stack judges whether the received new data packet is placed in a transparent transmission protocol stack cache, and if so, directly forwarding the new data packet to a physical node protocol stack;
modifying a network drive of a physical node protocol stack, so that when the physical node protocol stack receives the new data packet, the address, the size and corresponding header information in the new data packet are taken out, the data stored in the transparent transmission protocol stack cache is taken out according to the taken address and the size, the data stored in the transparent transmission protocol stack cache is transmitted to a function corresponding to a tcp layer, an ip layer and an eth layer for packet processing, and then the data is transmitted to a physical transmission network card.
4. A device for realizing that a docker network penetrates through two layers of protocol stacks in a cloud computing environment is characterized by comprising:
the first sending module is used for the docker network protocol stack to store tcp/ip/eth related packet data and corresponding packet header information into a transparent transmission protocol stack cache created by a physical node in advance, construct a new data packet according to an address and a size corresponding to the transparent transmission protocol stack cache, and send the new data packet to a cloud host network protocol stack in a related protocol stack packet processing function;
the second sending module is used for judging whether the received new data packet is placed in a protocol stack cache for transparent transmission or not by the cloud host network protocol stack, and if so, directly forwarding the new data packet to a physical node protocol stack;
and the third sending module is used for taking out the address, the size and the corresponding header information in the new data packet when the physical node protocol stack receives the new data packet, taking out the data stored in the protocol stack cache for the transparent transmission according to the taken out address and size, transmitting the data stored in the protocol stack cache for the transparent transmission to a function corresponding to a tcp layer, an ip layer and an eth layer for packet processing, and then transmitting the data to a physical network card for transmission.
5. The apparatus of claim 4, further comprising:
and the creating module is used for creating a transparent transmission protocol stack cache at the physical node and transmitting the transparent transmission protocol stack cache to a network drive of the docker network protocol stack.
6. The apparatus of claim 5, further comprising:
the first modification module is used for modifying the network drive of the docker network protocol stack, so that the docker network protocol stack stores tcp/ip/eth related packet data and corresponding packet header information into a transparent transmission protocol stack cache created by a physical node in advance, constructs a new data packet according to an address and a size corresponding to the transparent transmission protocol stack cache, and sends the new data packet to a related protocol stack packet processing function to the cloud host network protocol stack;
the second modification module is used for modifying the network drive of the cloud host network protocol stack, so that the cloud host network protocol stack judges whether the received new data packet is placed in the transparent transmission protocol stack cache or not, and if yes, the new data packet is directly forwarded to the physical node protocol stack;
and the third modification module is used for modifying the network drive of the physical node protocol stack, so that when the physical node protocol stack receives the new data packet, the address, the size and the corresponding header information in the new data packet are taken out, the data stored in the protocol stack cache for transparent transmission is taken out according to the taken address and the size, the data stored in the protocol stack cache for transparent transmission is transmitted to the functions corresponding to the tcp, ip and eth layers for packet processing, and then the data is transmitted to the physical network card for transmission.
7. An electronic device, comprising: a processor, a memory, a bus, and a computer program stored on the memory and executable on the processor;
the processor and the memory complete mutual communication through the bus;
the processor, when executing the computer program, implements the method of any of claims 1-3.
8. A non-transitory computer-readable storage medium, having stored thereon a computer program which, when executed by a processor, implements the method of any one of claims 1-3.
CN201810918542.5A 2018-08-13 2018-08-13 Method and device for realizing penetration of two-layer protocol stack by docker network in cloud computing environment Active CN109309663B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810918542.5A CN109309663B (en) 2018-08-13 2018-08-13 Method and device for realizing penetration of two-layer protocol stack by docker network in cloud computing environment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810918542.5A CN109309663B (en) 2018-08-13 2018-08-13 Method and device for realizing penetration of two-layer protocol stack by docker network in cloud computing environment

Publications (2)

Publication Number Publication Date
CN109309663A CN109309663A (en) 2019-02-05
CN109309663B true CN109309663B (en) 2021-03-19

Family

ID=65223877

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810918542.5A Active CN109309663B (en) 2018-08-13 2018-08-13 Method and device for realizing penetration of two-layer protocol stack by docker network in cloud computing environment

Country Status (1)

Country Link
CN (1) CN109309663B (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101567897A (en) * 2008-04-25 2009-10-28 国家广播电影电视总局广播科学研究院 Method and system for realizing transparent transmission of files in CMMB channel
CN102045378A (en) * 2009-10-13 2011-05-04 杭州华三通信技术有限公司 Method for realizing full distribution of protocol stack process and distributed system
CN105227493A (en) * 2015-10-15 2016-01-06 上海斐讯数据通信技术有限公司 The method of data message forwarding performance is improved under multi-core platform
CN106385365A (en) * 2015-08-07 2017-02-08 杭州华三通信技术有限公司 Method of realizing cloud platform safety based on openflow table and apparatus thereof
CN107204942A (en) * 2016-03-18 2017-09-26 上海有云信息技术有限公司 A kind of implementation method that service chaining transparent transmission is realized based on five-tuple

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6999470B2 (en) * 2001-06-28 2006-02-14 Nortel Networks Limited Methods and apparatus for transmitting synchronous data
US10356182B2 (en) * 2016-07-19 2019-07-16 Telefonaktiebolaget Lm Ericsson (Publ) Communication stack optimized per application without virtual machine overhead

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101567897A (en) * 2008-04-25 2009-10-28 国家广播电影电视总局广播科学研究院 Method and system for realizing transparent transmission of files in CMMB channel
CN102045378A (en) * 2009-10-13 2011-05-04 杭州华三通信技术有限公司 Method for realizing full distribution of protocol stack process and distributed system
CN106385365A (en) * 2015-08-07 2017-02-08 杭州华三通信技术有限公司 Method of realizing cloud platform safety based on openflow table and apparatus thereof
CN105227493A (en) * 2015-10-15 2016-01-06 上海斐讯数据通信技术有限公司 The method of data message forwarding performance is improved under multi-core platform
CN107204942A (en) * 2016-03-18 2017-09-26 上海有云信息技术有限公司 A kind of implementation method that service chaining transparent transmission is realized based on five-tuple

Also Published As

Publication number Publication date
CN109309663A (en) 2019-02-05

Similar Documents

Publication Publication Date Title
US8819113B2 (en) Remote provisioning of virtual machines
US9602307B2 (en) Tagging virtual overlay packets in a virtual networking system
CN105579987B (en) The port general PCI EXPRESS
CN105159753B (en) The method, apparatus and pooling of resources manager of accelerator virtualization
US9183032B2 (en) Method and system for migration of multi-tier virtual application across different clouds hypervisor platforms
US10341196B2 (en) Reliably updating a messaging system
CN107678835B (en) Data transmission method and system
US8675644B2 (en) Enhanced virtual switch
US20140207930A1 (en) Independent network interfaces for virtual network environments
CN103176833B (en) A kind of data transmission method for uplink based on virtual machine, method of reseptance and system
US8595839B2 (en) Selecting one of a plurality of scanner nodes to perform scan operations for an interface node receiving a file request
US9742616B2 (en) Device for indicating packet processing hints
CN110391993A (en) A kind of data processing method and system
CN105049464B (en) Techniques for accelerating network virtualization
US8953600B2 (en) Telemetry data routing
CN108228309B (en) Data packet sending and receiving method and device based on virtual machine
CN105389120A (en) Supporting RMA API over active message
US8594113B2 (en) Transmit-side scaler and method for processing outgoing information packets using thread-based queues
CN110728558A (en) Virtual article package sending method, device, equipment and storage medium
CN110225061A (en) Heterogeneous protocol conversion method and device based on flow table driving
CN109309663B (en) Method and device for realizing penetration of two-layer protocol stack by docker network in cloud computing environment
CN109032693A (en) Method and device for loading display information, electronic equipment and readable storage medium
WO2010117359A1 (en) Transmit-side scaler and method for processing outgoing information packets using thread-based queues
US20140298287A1 (en) Methods and systems for creating data applications
US20200150904A1 (en) System and Method for Managing Content using Generic Content Management Interface

Legal Events

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