Data transmission method, device and equipment based on cloud network
Data is transmitted between cloud servers through elastic network card interfaces, and independently deployed subnets and address forwarding mechanisms that do not belong to VPC are used to solve the problems of VPC routing complexity and performance bottlenecks in the existing technology, and realize efficient cloud computing. Device interconnection and data transmission.
Patent Information
- Application Number
- CN202411045703.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-31
- Publication Date
- 2024-10-11
- Estimated Expiration
- 2044-07-31
AI Technical Summary
The interconnection between existing cloud devices is complicated through VPC routing, and all VPC functions need to be performed during data transmission, which affects performance.
ENI pair is used for data transmission between cloud servers. Through independently deployed subnets and ENI pairs that do not belong to any subnet or VPC, the data flow is queried and forwarded based on its address, avoiding the use of VPC routing. .
It simplifies the implementation of device interconnection on the cloud, improves data transmission performance, reduces unnecessary function execution, and improves communication efficiency.
Smart Images

Figure CN118764464A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of communication technology, and in particular to a cloud network-based data transmission method, device and equipment. Background Art
[0002] VPC (Virtual Private Cloud) builds an isolated, user-configured and managed virtual network environment for elastic cloud servers, improves the security of user cloud resources, and simplifies user network deployment. Currently, the interconnection between two devices on the cloud is generally achieved through VPC routing. Specifically, if two devices need to communicate, a tunnel can be established between the two devices based on the VPC network, and then data is transmitted based on the configured VPC routing. This method is complex to implement, and all functions provided by VPC need to be executed during data transmission, while some other functions are not necessary for data transmission, affecting the performance of data forwarding. Summary of the invention
[0003] In view of this, the embodiments of the present application provide a data transmission method, apparatus and device based on a cloud network to simplify the implementation of interconnection between devices on the cloud and improve data transmission performance.
[0004] To solve the above problems, the technical solutions provided in the embodiments of the present application are as follows:
[0005] In a first aspect, an embodiment of the present application provides a cloud network-based data transmission method, comprising:
[0006] Receive a first data stream transmitted via a first elastic network card interface in an elastic network card interface pair connected to a first cloud server; the elastic network card interface pair is configured with a first elastic network card interface and a second elastic network card interface, the first elastic network card interface is connected to the first cloud server and transmits the data stream to the second cloud server through the first elastic network card interface via the second elastic network card interface connected to the second cloud server; wherein the elastic network card interface pair is independently deployed in a subnet in a cloud network;
[0007] When it is determined that the first data flow is transmitted via the elastic network card interface pair, the address of the second elastic network card interface is queried in the fast channel, and the first data flow is forwarded to the second cloud server based on the address of the second elastic network card interface.
[0008] In a second aspect, an embodiment of the present application provides a cloud network-based data transmission device, including:
[0009] A receiving unit, configured to receive a first data stream transmitted via a first elastic network card interface in an elastic network card interface pair connected to a first cloud server; the elastic network card interface pair is configured with a first elastic network card interface and a second elastic network card interface, the first elastic network card interface is connected to the first cloud server and transmits the data stream to the second cloud server through the first elastic network card interface via the second elastic network card interface connected to the second cloud server; wherein the elastic network card interface pair is independently deployed in a subnet in a cloud network;
[0010] A query unit, configured to query an address of a second elastic network card interface in a fast channel when it is determined that the first data flow is transmitted via the elastic network card interface pair;
[0011] A forwarding unit, configured to forward the first data flow to the second cloud server based on the address of the second elastic network card interface.
[0012] In a third aspect, an embodiment of the present application provides a cloud network-based data transmission device, comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the cloud network-based data transmission method as described above is implemented.
[0013] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, in which instructions are stored. When the instructions are executed on a terminal device, the terminal device executes the cloud network-based data transmission method as described above.
[0014] It can be seen that the embodiments of the present application have the following beneficial effects:
[0015] In the embodiment of the present application, the elastic network card interface pair is configured with a first elastic network card interface and a second elastic network card interface, the first elastic network card interface is connected to the first cloud server, and the second elastic network card interface is connected to the second cloud server. The elastic network card interface pair is independently deployed in the subnet in the cloud network, that is, it does not belong to any subnet and VPC. When two cloud servers are transmitting data, after receiving the first data stream transmitted via the first elastic network card interface, the address of the second elastic network card interface is queried in the fast channel, and the first data stream is forwarded to the second cloud server based on the address of the second elastic network card interface. Communication based on the address of the second elastic network card interface does not require VPC routing, and the implementation is relatively simple. At the same time, since the elastic network card interface pair does not belong to the VPC, it is not necessary to execute all the functions of the VPC during data transmission, which improves the data transmission performance. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] Figure 1 A schematic diagram of an exemplary application scenario of the prior art;
[0017] Figure 2 A schematic diagram of an exemplary implementation of the prior art;
[0018] Figure 3 A schematic diagram of an exemplary application scenario provided for an embodiment of the present application;
[0019] Figure 4 A flowchart of a cloud network-based data transmission method provided in an embodiment of the present application;
[0020] Figure 5 A schematic diagram of an exemplary implementation provided for an embodiment of the present application;
[0021] FIG6( a ) is a schematic diagram of a connection method of an elastic network card interface pair in an embodiment of the present application;
[0022] FIG6( b ) is a schematic diagram of another flexible network interface pair connection method in an embodiment of the present application;
[0023] FIG6( c ) is a schematic diagram of a connection method of an elastic network card interface pair in an embodiment of the present application;
[0024] Figure 7 A schematic diagram of a data forwarding device provided in an embodiment of the present application;
[0025] Figure 8 A schematic diagram of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0026] In order to make the above-mentioned purposes, features and advantages of the embodiments of the present application more obvious and easy to understand, the embodiments of the present application are further described in detail below in conjunction with the accompanying drawings and specific implementation methods.
[0027] In order to facilitate understanding and explanation of the technical solution provided by the embodiments of the present application, the background technology of the embodiments of the present application will be described below.
[0028] Currently, the interconnection between two devices on the cloud is generally achieved through VPC routing. Cloud devices can be network elements such as routers, load balancers, NAT (Network Address Translation), firewalls, etc. VPC-based network elements are generally implemented by ECS (Elastic Compute Service, also known as cloud server). ECS can be understood as a virtual machine that needs to run on a physical machine. In other words, the interconnection of cloud devices in actual applications is the communication process between ECS.
[0029] like Figure 1As shown, a scenario example diagram of the prior art is shown. Network element 1 provides the ability for devices in VPC1 and VPC2 to communicate with the private network outside the cloud, forming a forwarding router (Transit Router, TR), and network element 1 belongs to ServiceVPC1. Network element 2 can be a router used by a third-party SDWAN (Software Defined Wide Area Network) manufacturer for multi-cloud interconnection, and network element 2 belongs to Service VPC2. When the data packet from VPC1 and VPC2 needs to be sent to the external network, network element 1 can send the data packet to network element 2 and then send it to the external network. When network element 1 and network element 2 communicate, VPC routing needs to be configured. For example, the export routing table of network element 1 is: 192.168.100.0 / 24peering tunnel, and the import routing table of network element 1 is: 192.168.1.0 / 24VPC1, 192.168.2.0 / 24VPC2. The egress routing table of NE 2 is: 192.168.100.0 / 24extunnel, and the ingress routing table of NE 2 is: 192.168.1.0 / 24TR, 192.168.2.0 / 24TR.
[0030] The peering tunnel between NE 1 and NE 2 is established based on the VPC network. The VPC network function consists of the QoS (Quality of Service) policy of ENI (Elastic Network Interfaces), the security group ACL (Access Control List), and the VPC routing (TR). Figure 2 As shown, an example diagram of an implementation of the prior art is shown. Figure 1 In the implementation scenario, NE 1 is implemented by ECS1, which runs on physical machine 1, and NE 2 is implemented by ECS2, which runs on physical machine 2. When a data packet is sent from NE 1 to NE 2, the traffic of the peering tunnel passes through the forwarding component vswitch1 that provides the VPC function on physical machine 1 where ECS1 is located.
[0031] In the existing technology implementation, data forwarding needs to be implemented based on VPC routing, and the configuration of routing is relatively complex. At the same time, traffic needs to pass through all functions on the VPC forwarding component vswitch, and some of these functions are not necessary for data forwarding. These functions consume performance and affect the performance of data forwarding. In addition, data forwarding based on tunnels will bring elephant flows, so it is necessary to limit the single-flow capacity, which will bring performance bottlenecks.
[0032] Based on this, the embodiments of the present application provide a data transmission method, device and equipment based on a cloud network, and propose a new cloud device interconnection technology, which connects two cloud servers ECS through an elastic network card interface pair (ENI pair), and communicates between ECS based on the address of the elastic network card interface in the elastic network card interface pair.
[0033] In order to facilitate understanding of the data transmission method of the cloud network provided in the embodiment of the present application, Figure 3 See the example scenario shown in the figure. Figure 3 As shown, this figure is a schematic diagram of an exemplary application scenario provided in an embodiment of the present application.
[0034] Figure 3 The left side is a schematic diagram of the connection of an ordinary cloud server ECS. The ENI of an ordinary ECS has only one mac (Media Access Control) address and belongs to one ECS. The ENIs of two ECSs belong to their respective subnets and VPCs. Therefore, the communication between the two ECSs needs to be based on VPC routing and all VPC functions need to be executed.
[0035] Figure 3 On the right is the elastic network interface pair (ENI pair) provided in the embodiment of the present application. The ENI pair can be created separately and can be mounted on two ECSs. It has two MAC addresses and does not belong to any subnet or VPC, which greatly simplifies the complexity of address planning for users to manage ECS interconnection.
[0036] In the embodiment of the present application, the ECS interconnection can be extended to all data transmission scenarios between ECSs that are not the source address and destination address of the data packet.
[0037] Those skilled in the art will understand that Figure 3 The framework diagram shown is only an example in which the embodiments of the present application can be implemented. The scope of application of the embodiments of the present application is not limited by any aspect of the framework.
[0038] To facilitate understanding of the embodiments of the present application, a cloud network-based data transmission method provided in the embodiments of the present application is described below with reference to the accompanying drawings.
[0039] See also Figure 4 As shown in FIG. 1 , this figure is a flow chart of a data transmission method based on a cloud network provided in an embodiment of the present application, such as Figure 4 As shown, the method may include S401-S403:
[0040] S401: Receive a first data stream transmitted via a first elastic network interface of an elastic network interface pair connected to a first cloud server.
[0041] Among them, the elastic network card interface pair is configured with a first elastic network card interface and a second elastic network card interface. The first elastic network card interface is connected to the first cloud server and transmits data flow to the second cloud server through the first elastic network card interface via the second elastic network card interface connected to the second cloud server; wherein the elastic network card interface pair is independently deployed in a subnet in the cloud network.
[0042] In an embodiment of the present application, when the first cloud server and the second cloud server need to be interconnected, the management and control module on the cloud can create an elastic network card interface pair ENI pair, and the ENI pair is configured with two elastic network card interfaces ENI, namely the first elastic network card interface and the second elastic network card interface. Two mac addresses are assigned to the ENI pair, and the ENIs at both ends of the ENI pair have a mac address respectively. The ENI pair is mounted on the first cloud server and the second cloud server, and the first elastic network card interface is used as the ENI used by the first cloud server, and the second elastic network card interface is used as the ENI used by the second cloud server. The first cloud server and the second cloud server each run on a physical machine. The ENI pair is independently deployed in the cloud network and does not belong to the VPC, that is, a non-VPC ENI peer connection method is provided.
[0043] Then the management and control module can obtain the address of the first elastic network card interface and the address of the second elastic network card interface, attach the address of the first elastic network card interface and the address of the second elastic network card interface to the data structure of the ENI pair, and send them to the physical machines at both ends.
[0044] In addition, the IP (Internet Protocol) address of the ENI pair can be allocated by ECS, that is, the first cloud server allocates an IP address to the first elastic network interface, and the second cloud server allocates an IP address to the second elastic network interface. ECS can specify the use of ENI pair for communication through the IP address. In actual applications, IPV4 can use 169.254 or other non-business-planned / 31 mask IP addresses, and IPV6 can use commonly used device interconnection addresses.
[0045] The embodiment of the present application describes a data transmission method based on a cloud network from the perspective of a physical machine where a first cloud server is located. When the first cloud server sends a first data stream to a second cloud server, the first data stream can be obtained through the first elastic network interface in the ENI pair.
[0046] In a possible implementation, the method may further include:
[0047] After the elastic network card interface pair is connected to the first cloud server and the second cloud server, the address of the first elastic network card interface and the address of the second elastic network card interface are obtained; and the address of the first elastic network card interface and the address of the second elastic network card interface are saved in the fast channel.
[0048] In actual applications, after the control module sends the address of the first elastic network card interface and the address of the second elastic network card interface, the physical machine where the first cloud server is located can obtain and save the address of the first elastic network card interface and the address of the second elastic network card interface. Specifically, the address of the first elastic network card interface and the address of the second elastic network card interface can be saved in the fast channel of the first forwarding component in the physical machine where the first cloud server is located.
[0049] Among them, the address of the first elastic network card interface can be configured as the physical machine address of the physical machine where the first cloud server is located, and the address of the second elastic network card interface can be configured as the physical machine address of the physical machine where the second cloud server is located.
[0050] S402: When it is determined that the first data flow is transmitted via the elastic network interface pair, query the address of the second elastic network interface in the fast channel.
[0051] In actual applications, the fastpath of the first forwarding component stores the data structure of the ENI pair, which includes the address of the first elastic network card interface and the address of the second elastic network card interface. When it is determined according to the ENI type that the first data flow is sent through the ENI pair, the address of the second elastic network card interface is queried in the fastpath to obtain the physical machine address of the physical machine where the second cloud server is located.
[0052] S403: Forward the first data flow to the second cloud server based on the address of the second elastic network interface.
[0053] Based on the address of the second elastic network card interface, the first data stream is sent to the second cloud server. In actual applications, the first data stream can be sent to the second forwarding component on the physical machine where the second cloud server is located, and the second forwarding component sends the first data stream to the second cloud server.
[0054] In the embodiment of the present application, the elastic network card interface pair is configured with a first elastic network card interface and a second elastic network card interface, the first elastic network card interface is connected to the first cloud server, and the second elastic network card interface is connected to the second cloud server. The elastic network card interface pair is independently deployed in the subnet in the cloud network, that is, it does not belong to any subnet and VPC. When two cloud servers are transmitting data, after receiving the first data stream transmitted via the first elastic network card interface, the address of the second elastic network card interface is queried in the fast channel, and the first data stream is forwarded to the second cloud server based on the address of the second elastic network card interface. Communication based on the address of the second elastic network card interface does not require VPC routing, and the implementation is relatively simple. At the same time, since the elastic network card interface pair does not belong to the VPC, it is not necessary to execute all the functions of the VPC during data transmission, which improves the data transmission performance.
[0055] In a possible implementation, the specific implementation of S403 sending the data packet to the second cloud server on the physical machine corresponding to the physical machine address may include:
[0056] A1: Encapsulate the first data stream. The inner layer of the encapsulated first data stream carries the source address, destination address, source MAC address and destination MAC address, and the outer layer carries the source physical machine address and the destination physical machine address. The source physical machine address is the address of the first elastic network card interface, and the destination physical machine address is the address of the second elastic network card interface. The source MAC address and the destination MAC address are the MAC addresses of the elastic network card interface pair.
[0057] The first forwarding component encapsulates the data packet, and the inner layer of the encapsulated data packet carries the source address src0, the destination address dst0, the source mac address and the destination mac address, and the outer layer carries the address of the first elastic network card interface and the address of the second elastic network card interface. Among them, the source mac address and the destination mac address are the mac addresses allocated to the ENI pair.
[0058] A2: Send the encapsulated first data stream to the physical machine corresponding to the destination physical machine address, so that the physical machine corresponding to the destination physical machine address decapsulates the encapsulated first data stream, and sends the decapsulated first data stream to the second cloud server according to the destination MAC address.
[0059] The encapsulated first data stream is sent to the second forwarding component on the physical machine corresponding to the destination physical machine address. The second forwarding component decapsulates the first data stream and sends it to the second cloud server based on the destination MAC address.
[0060] In a possible implementation, the cloud network-based data transmission method provided in the embodiment of the present application may further include: executing a corresponding quality of service strategy for the first data stream.
[0061] The first forwarding component and the second forwarding component can also execute corresponding QoS policies, such as limiting the speed of data packets sent through the ENI pair, obtaining the speed limit of the total data packets sent, etc., and then skipping the security group, VPC routing query and other functions of the forwarding component VPC, and only using the required QoS policies to fully improve the communication performance while ensuring the quality of service.
[0062] In a possible implementation, the cloud network-based data transmission method provided in the embodiment of the present application may further include:
[0063] The address of the first elastic network card interface or the second elastic network card interface in the elastic network card interface pair is dynamically updated according to changes in the physical machine connected to the elastic network card interface pair.
[0064] In some scenarios, the physical machine where the first cloud server or the second cloud server is located may not be able to provide services, so the first cloud server or the second cloud server can be hot migrated to a new physical machine. When the physical machine changes, the management and control module on the cloud will re-issue the address of the changed first elastic network card interface or the second elastic network card interface, and save the address of the changed first elastic network card interface or the second elastic network card interface to the data structure of the ENI pair. Based on the address of the changed first elastic network card interface or the second elastic network card interface, the first cloud server and the second cloud server communicate with each other, thereby realizing the hot migration of ECS.
[0065] Similarly, when the second cloud server sends the second data stream to the first cloud server, the second forwarding component in the physical machine where the second cloud server is located can obtain the second data stream through the second elastic network card interface in the ENI pair. According to the ENI type, it is determined that the second data stream is sent through the ENI pair, and then the fast channel of the second forwarding component is queried to obtain the address of the first elastic network card interface, that is, the physical machine address of the physical machine where the first cloud server is located is obtained. Then, based on the address of the first elastic network card interface, the second data stream is sent to the first forwarding component on the physical machine where the first cloud server is located, and the first forwarding component sends the second data stream to the first cloud server.
[0066] The embodiment of the present application implements high-performance data forwarding based on ENI pair, supports ECS-related functions such as QoS and hot migration, and simplifies the implementation method of ECS interconnection.
[0067] In actual application, the physical machine where the first server is located includes a first forwarding component, and the physical machine where the second server is located includes a second forwarding component. The first forwarding component is connected to the first cloud server, and the second forwarding component is connected to the second cloud server.
[0068] The elastic network card interface pair is specifically used to communicate between the first cloud server and the second cloud server through the first forwarding component and the second forwarding component based on the address of the first elastic network card interface or the address of the second elastic network card interface.
[0069] That is, the first forwarding component is a component used for data forwarding in the physical machine where the first cloud server is located, and the second forwarding component is a component used for data forwarding in the physical machine where the second cloud server is located. The first forwarding component and the second forwarding component constitute a path of the ENI pair.
[0070] The data structure of the ENI pair can be stored in the first forwarding component and the second forwarding component. Specifically, the first forwarding component can store the address of the first elastic network card interface of the local end in addition to the address of the second elastic network card interface of the other end. The second forwarding component can store the address of the second elastic network card interface of the local end in addition to the address of the first elastic network card interface of the other end.
[0071] When the first cloud server sends the first data stream to the second cloud server, the first forwarding component determines that the first data stream is sent through the ENI pair based on the ENI type, then queries the address of the second elastic network card interface from the data structure of the ENI pair saved by the fast channel, sends the first data stream to the second forwarding component, and the second forwarding component sends the first data stream to the second cloud server.
[0072] Similarly, when the second cloud server sends the second data stream to the first cloud server, the second forwarding component determines that the data packet is sent through the ENI pair based on the ENI type, and then queries the address of the first elastic network card interface from the data structure of the ENI pair saved by the fast channel, and sends the second data stream to the first forwarding component, and the first forwarding component sends the second data stream to the first cloud server.
[0073] Thus, the ENI pair is implemented to communicate between the first cloud server and the second cloud server through the first forwarding component and the second forwarding component.
[0074] The data structure of the ENI pair is saved in the fastpath of the first forwarding component and the fastpath of the second forwarding component, so that the address of the first elastic network card interface or the address of the second elastic network card interface can be obtained more quickly without occupying the forwarding resources of the slowpath of the first forwarding component and the second forwarding component.
[0075] See also Figure 5As shown, a schematic diagram of an exemplary implementation of a cloud network-based data transmission method provided in an embodiment of the present application is shown. In this example, the first cloud server ECS1 runs on physical machine 1, and the first forwarding component vswitch1 is connected to ECS1 and runs on physical machine 1. The second cloud server ECS2 runs on physical machine 2, and the first forwarding component vswitch2 is connected to ECS2 and runs on physical machine 2. ECS1 and ECS2 are connected through an ENI pair. The management and control module sends the mounting information of the ENIpair, that is, the physical machine address of physical machine 1 and the physical machine address of physical machine 2 are attached to the data structure of the ENI pair, and saved in the fastpath of vswitch1 and vswitch2.
[0076] When the first data stream is sent from ECS1, for example, the final destination address of the first data stream is dst0, and the source address is src0. vswitch1 only performs resource restrictions and management at the QoS level, such as limiting the speed of the first data stream. vswitch1 determines that the first data stream is sent through the ENI pair based on the ENI type, and queries the physical machine address of physical machine 2 based on the data structure of the ENI pair. The first data stream is encapsulated, and the inner layer of the encapsulated data packet carries the source address src0, the destination address dst0, the source mac address and the destination mac address, and the outer layer carries the address of physical machine 1 and the address of physical machine 2. Among them, the source mac address and the destination mac address are the mac addresses assigned to the ENI pair. After the encapsulated data packet is sent to vswitch2, the data packet is unpacked, sent to ECS2 based on the destination mac address, and the corresponding QoS policy is executed.
[0077] In the communication process between ECS1 and ECS2, in the embodiment of the present application, there is no VPC network planning requirement, no VPC routing and security policy requirement, no single-flow bottleneck problem caused by the tunnel, and the data forwarding performance can be optimized to the extreme, and can be used for the interconnection of multiple network elements.
[0078] In practical applications, the definition of ENI pair can be further expanded. In a possible implementation, the first elastic network card interface is connected to at least one first cloud server, and / or the second elastic network card interface is connected to at least one second cloud server.
[0079] When both ends of the ENI pair, the first elastic network interface ENI1 and the second elastic network interface ENI2, are connected to one ECS, a common ENI pair is formed, as shown in FIG6( a ), which shows a schematic diagram of such an ENI pair.
[0080] When one end of the ENI pair is a bondENI (parent ENI), and bondENI includes multiple workENIs (child ENIs), then one end of the ENI pair can be connected to multiple ECSs, and multiple ECSs provide the same service to achieve high availability. The data stream can be sent to any of the multiple ECSs. Referring to Figure 6(b), a schematic diagram of this type of ENI pair is shown, which is equivalent to an ENI pair formed by ENI and bondENI. For example, the first elastic network card interface ENI1 can be connected to an ECS, and the second elastic network card interface as a bondENI (parent ENI) can include multiple workENIs (child ENIs), and each child ENI can be connected to an ECS.
[0081] When both ends of the ENI pair are bondENIs, and multiple workENIs are included after the bondENI, both ends of the ENI pair can be connected to multiple ECSs. Referring to FIG6(c), a schematic diagram of such an ENI pair is shown, which is equivalent to an ENI pair formed by a bondENI and a bondENI. For example, the first elastic network card interface as a bondENI (parent ENI) can include multiple workENIs (child ENIs), each of which can be connected to an ECS, and the second elastic network card interface can also be a bondENI (parent ENI) and can include multiple workENIs (child ENIs), each of which can be connected to an ECS.
[0082] In the embodiment of the present application, ENI pair can be used in combination with technologies such as bondENI to achieve high availability of ECS.
[0083] Based on the cloud network-based data transmission method provided in the above method embodiment, the embodiment of the present application also provides a cloud network-based data transmission device, which will be described below in conjunction with the accompanying drawings.
[0084] See also Figure 7 As shown in FIG. 1 , this figure is a schematic diagram of the structure of a data transmission device based on a cloud network provided in an embodiment of the present application. Figure 7 As shown, the cloud network-based data transmission device includes:
[0085] A receiving unit 701 is used to receive a first data stream transmitted via a first elastic network card interface in an elastic network card interface pair connected to a first cloud server; the elastic network card interface pair is configured with a first elastic network card interface and a second elastic network card interface, the first elastic network card interface is connected to the first cloud server and transmits the data stream to the second cloud server through the first elastic network card interface via the second elastic network card interface connected to the second cloud server; wherein the elastic network card interface pair is independently deployed in a subnet in a cloud network;
[0086] A query unit 702, configured to query an address of a second elastic network card interface in a fast channel when determining that the first data flow is transmitted via the elastic network card interface pair;
[0087] The forwarding unit 703 is used to forward the first data flow to the second cloud server based on the address of the second elastic network card interface.
[0088] In a possible implementation, the method further includes:
[0089] an acquisition unit, configured to acquire the address of the first elastic network card interface and the address of the second elastic network card interface after the elastic network card interface pair is connected to the first cloud server and the second cloud server;
[0090] A saving unit is used to save the address of the first elastic network card interface and the address of the second elastic network card interface in a fast channel.
[0091] In a possible implementation, the method further includes:
[0092] The updating unit is used to dynamically update the address of the first elastic network card interface or the second elastic network card interface in the elastic network card interface pair according to the change of the physical machine connected to the elastic network card interface pair.
[0093] In a possible implementation, the address of the first elastic network card interface is configured as the physical machine address of the physical machine where the first cloud server is located, and the address of the second elastic network card interface is configured as the physical machine address of the physical machine where the second cloud server is located.
[0094] In a possible implementation manner, the forwarding unit is specifically configured to:
[0095] The first data stream is encapsulated, wherein the inner layer of the encapsulated first data stream carries a source address, a destination address, a source media access control MAC address and a destination MAC address, and the outer layer carries a source physical machine address and a destination physical machine address; the source physical machine address is the address of the first elastic network card interface, and the destination physical machine address is the address of the second elastic network card interface; the source MAC address and the destination MAC address are the MAC addresses of the elastic network card interface pair;
[0096] The encapsulated first data stream is sent to the physical machine corresponding to the destination physical machine address, so that the physical machine corresponding to the destination physical machine address decapsulates the encapsulated first data stream, and sends the decapsulated first data stream to the second cloud server according to the destination MAC address.
[0097] In a possible implementation, the first elastic network card interface is connected to at least one of the first cloud servers, and / or the second elastic network card interface is connected to at least one of the second cloud servers.
[0098] In a possible implementation, the method further includes:
[0099] An execution unit is used to execute a corresponding quality of service policy for the first data flow.
[0100] In addition, an embodiment of the present application also provides a computer-readable storage medium, which stores instructions. When the instructions are executed on a terminal device, the terminal device executes the cloud network-based data transmission method as described in any one of the above items.
[0101] An embodiment of the present application also provides a computer program product, including computer program instructions, which, when executed on a computer, enable the computer to execute any of the cloud network-based data transmission methods described above.
[0102] Based on the cloud network-based data transmission method provided in the above method embodiment, the present application also provides an electronic device, including: one or more processors; a storage device, on which one or more programs are stored, when the one or more programs are executed by the one or more processors, the one or more processors implement the cloud network-based data transmission method described in any of the above embodiments.
[0103] In the embodiment of the present application, the elastic network card interface pair is configured with a first elastic network card interface and a second elastic network card interface, the first elastic network card interface is connected to the first cloud server, and the second elastic network card interface is connected to the second cloud server. The elastic network card interface pair is independently deployed in the subnet in the cloud network, that is, it does not belong to any subnet and VPC. When two cloud servers are transmitting data, after receiving the first data stream transmitted via the first elastic network card interface, the address of the second elastic network card interface is queried in the fast channel, and the first data stream is forwarded to the second cloud server based on the address of the second elastic network card interface. Communication based on the address of the second elastic network card interface does not require VPC routing, and the implementation is relatively simple. At the same time, since the elastic network card interface pair does not belong to the VPC, it is not necessary to execute all the functions of the VPC during data transmission, which improves the data transmission performance.
[0104] Reference below Figure 8 , which shows a schematic diagram of the structure of an electronic device 1300 suitable for implementing the embodiment of the present application. The terminal device in the embodiment of the present application may include but is not limited to mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, PDAs (Personal Digital Assistants), PADs (portable android devices), PMPs (Portable Media Players), vehicle-mounted terminals (such as vehicle-mounted navigation terminals), etc., and fixed terminals such as digital TVs (televisions), desktop computers, etc. Figure 8 The electronic device shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.
[0105] like Figure 8 As shown, the electronic device 1300 may include a processing device (e.g., a central processing unit, a graphics processing unit, etc.) 1301, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 1302 or a program loaded from a storage device 1306 into a random access memory (RAM) 1303. In the RAM 1303, various programs and data required for the operation of the electronic device 1300 are also stored. The processing device 1301, the ROM 1302, and the RAM 1303 are connected to each other via a bus 1304. An input / output (I / O) interface 1305 is also connected to the bus 1304.
[0106] Typically, the following devices may be connected to the I / O interface 1305: an input device 1306 including, for example, a touch screen, a touch pad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; an output device 1307 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; a storage device 1306 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 1309. The communication device 1309 may allow the electronic device 1300 to communicate with other devices wirelessly or by wire to exchange data. Although Figure 8 The electronic device 1300 is shown with various devices, but it should be understood that it is not required to implement or possess all the devices shown. More or fewer devices may be implemented or possessed instead.
[0107] In particular, according to an embodiment of the present application, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present application includes a computer program product, which includes a computer program carried on a non-transitory computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication device 1309, or installed from the storage device 1306, or installed from the ROM 1302. When the computer program is executed by the processing device 1301, the above-mentioned functions defined in the method of the embodiment of the present application are executed.
[0108] The electronic device provided in the embodiment of the present application and the cloud network-based data transmission method provided in the above embodiment belong to the same inventive concept. The technical details not fully described in this embodiment can be found in the above embodiment, and this embodiment has the same beneficial effects as the above embodiment.
[0109] Based on the cloud network-based data transmission method provided in the above method embodiment, an embodiment of the present application provides a computer-readable medium on which a computer program is stored, wherein when the program is executed by a processor, the cloud network-based data transmission method as described in any of the above embodiments is implemented.
[0110] It should be noted that the computer-readable medium in the embodiment of the present application may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to, an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In an embodiment of the present application, a computer-readable storage medium may be any tangible medium containing or storing a program that may be used by or in combination with an instruction execution system, device or device. In an embodiment of the present application, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, in which a computer-readable program code is carried. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. The computer readable signal medium may also be any computer readable medium other than a computer readable storage medium, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer readable medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.
[0111] In some embodiments, the client and the server may communicate using any currently known or future developed network protocol such as HTTP (HyperText Transfer Protocol), and may be interconnected with any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), an internet (e.g., the Internet), and a peer-to-peer network (e.g., an ad hoc peer-to-peer network), as well as any currently known or future developed network.
[0112] The computer-readable medium may be included in the electronic device, or may exist independently without being incorporated into the electronic device.
[0113] The computer-readable medium carries one or more programs. When the one or more programs are executed by the electronic device, the electronic device executes the cloud network-based data transmission method.
[0114] The computer program code for performing the operation of the embodiment of the present application can be written in one or more programming languages or a combination thereof, and the above-mentioned programming languages include but are not limited to object-oriented programming languages-such as Java, Smalltalk, C++, and also include conventional procedural programming languages-such as "C" language or similar programming languages. The program code can be executed completely on the user's computer, partially on the user's computer, as an independent software package, partially on the user's computer and partially on the remote computer, or completely on the remote computer or server. In the case of a remote computer, the remote computer can be connected to the user's computer through any type of network-including a local area network (LAN) or a wide area network (WAN), or it can be connected to an external computer (for example, using an Internet service provider to connect through the Internet).
[0115] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present application. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0116] The units involved in the embodiments described in this application may be implemented by software or hardware, wherein the name of the unit / module does not, in some cases, constitute a limitation on the unit itself.
[0117] The functions described above herein may be performed at least in part by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), and the like.
[0118] In the context of the present application embodiment, machine-readable medium can be a tangible medium that can contain or store a program for use by an instruction execution system, device or equipment or used in combination with an instruction execution system, device or equipment. Machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. Machine-readable medium can include but is not limited to electronic, magnetic, optical, electromagnetic, infrared or semiconductor systems, devices or equipment, or any suitable combination of the above. More specific examples of machine-readable storage media can include electrical connections based on one or more lines, portable computer disks, hard disks, random access memories (RAM), read-only memories (ROM), erasable programmable read-only memories (EPROM or flash memory), optical fibers, portable compact disk read-only memories (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the above.
[0119] It should be noted that the various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments, and the same or similar parts between the various embodiments can be referred to each other. For the system or device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part description.
[0120] It should be understood that in the present application, "at least one (item)" means one or more, and "plurality" means two or more. "And / or" is used to describe the association relationship of associated objects, indicating that three relationships may exist. For example, "A and / or B" can mean: only A exists, only B exists, and A and B exist at the same time, where A and B can be singular or plural. The character " / " generally indicates that the objects associated before and after are in an "or" relationship. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single or plural items. For example, at least one of a, b or c can mean: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, c can be single or multiple.
[0121] It should also be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the presence of other identical elements in the process, method, article or device including the elements.
[0122] The steps of the method or algorithm described in conjunction with the embodiments disclosed herein may be implemented directly using hardware, a software module executed by a processor, or a combination of the two. The software module may be placed in a random access memory (RAM), a memory, a read-only memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
[0123] The above description of the disclosed embodiments enables those skilled in the art to implement or use the present application. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application will not be limited to the embodiments shown herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A data transmission method based on a cloud network, characterized in that: include: Receiving a first data stream transmitted via a first elastic network interface of an elastic network interface pair connected to a first cloud server; The elastic network card interface pair is configured with a first elastic network card interface and a second elastic network card interface, the first elastic network card interface is connected to the first cloud server and transmits a data stream to the second cloud server through the first elastic network card interface via the second elastic network card interface connected to the second cloud server; wherein the elastic network card interface pair is independently deployed in a subnet in the cloud network; When it is determined that the first data flow is transmitted via the elastic network card interface pair, the address of the second elastic network card interface is queried in the fast channel, and the first data flow is forwarded to the second cloud server based on the address of the second elastic network card interface.
2. The method according to claim 1, characterized in that Also includes: After the elastic network card interface pair is connected to the first cloud server and the second cloud server, an address of the first elastic network card interface and an address of the second elastic network card interface are obtained; The address of the first elastic network card interface and the address of the second elastic network card interface are saved in the fast channel.
3. The method according to claim 1 or 2, characterized in that: Also includes: Following changes in the physical machine connected to the elastic network card interface pair, the address of the first elastic network card interface or the second elastic network card interface in the elastic network card interface pair is dynamically updated.
4. The method according to any one of claims 1 to 3, characterized in that: The address of the first elastic network card interface is configured as the physical machine address of the physical machine where the first cloud server is located, and the address of the second elastic network card interface is configured as the physical machine address of the physical machine where the second cloud server is located.
5. The method according to claim 1 or 2, characterized in that: The forwarding the first data flow to the second cloud server based on the address of the second elastic network card interface includes: The first data stream is encapsulated, wherein the inner layer of the encapsulated first data stream carries a source address, a destination address, a source media access control MAC address and a destination MAC address, and the outer layer carries a source physical machine address and a destination physical machine address; the source physical machine address is the address of the first elastic network card interface, and the destination physical machine address is the address of the second elastic network card interface; the source MAC address and the destination MAC address are the MAC addresses of the elastic network card interface pair; The encapsulated first data stream is sent to the physical machine corresponding to the destination physical machine address, so that the physical machine corresponding to the destination physical machine address decapsulates the encapsulated first data stream, and sends the decapsulated first data stream to the second cloud server according to the destination MAC address.
6. The method according to claim 1, characterized in that The first elastic network card interface is connected to at least one of the first cloud servers, and / or the second elastic network card interface is connected to at least one of the second cloud servers.
7. The method according to claim 1, characterized in that Also includes: A corresponding quality of service policy is executed for the first data flow.
8. A data transmission device based on a cloud network, characterized in that: include: A receiving unit, configured to receive a first data stream transmitted via a first elastic network card interface of an elastic network card interface pair connected to a first cloud server; The elastic network card interface pair is configured with a first elastic network card interface and a second elastic network card interface, the first elastic network card interface is connected to the first cloud server and transmits a data stream to the second cloud server through the first elastic network card interface via the second elastic network card interface connected to the second cloud server; wherein the elastic network card interface pair is independently deployed in a subnet in the cloud network; A query unit, configured to query an address of a second elastic network card interface in a fast channel when it is determined that the first data flow is transmitted via the elastic network card interface pair; A forwarding unit, configured to forward the first data flow to the second cloud server based on the address of the second elastic network card interface.
9. A data transmission device based on a cloud network, characterized in that: include: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the cloud network-based data transmission method as described in any one of claims 1 to 7 is implemented.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores instructions, and when the instructions are executed on a terminal device, the terminal device executes the cloud network-based data transmission method as described in any one of claims 1 to 7.
Citation Information
Patent Citations
System for operation and maintenance of intelligent network card
CN115695056A
Server resource acquisition method, intelligent network card and cloud data center system
CN117061514A
Method and apparatus for interconnection between networks
US20170272274A1
Techniques for utilizing multiple network interfaces for a cloud shell
US20220052878A1
Industrial automation secure remote access
US20230275897A1
Cited By
Network anomaly detection method for cloud network and related equipment
CN119071198A
