Data transmission system, virtual extensible local area network identifier distribution method and device and medium
VXLAN technology assigns unique VNI to each tenant and transmits VLAN information in the IP network, solving the network expansion bottleneck caused by the limit on the number of VLANs, and realizing flexible migration and efficient resource utilization of virtual networks.
Patent Information
- Application Number
- CN202510524792.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-24
- Publication Date
- 2025-07-29
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The limited number of traditional VLANs has led to network expansion bottlenecks, existing solutions are complex and resource utilization is not high, and network performance is degraded.
Using VXLAN technology, each tenant is assigned a unique virtual extensible LAN identification VNI through an SDN controller, and VLAN information is encapsulated at the access switch to the VXLAN header, and transmitted through the IP network, and the target switch decapsulates and restores the original data packet.
The virtual network capacity is expanded, the number of VLANs is restricted, the scalability, flexibility and resource utilization of the network are improved, and the problem of insufficient VLANs is solved.
Smart Images

Figure CN120389929A_ABST
Abstract
Description
Technical Field
[0001] Embodiments of the present invention relate to the technical field of data communication, and more particularly, to a data transmission system, a method, an apparatus, and a medium for allocating virtual extensible local area network identifiers. Background Art
[0002] In traditional networks, VLAN (Virtual Local Area Network) is usually used to logically partition the network. However, the number of VLANs is limited, and the IEEE 802.1Q standard stipulates that up to 4096 VLAN identifiers are supported. With the rapid growth of virtual machines in modern data centers, multi-tenant environments, and increasing demands for large-scale deployments, the limitation of the number of VLANs has become particularly prominent.
[0003] To address this issue, various workarounds such as VLAN trunks and subnets have been adopted, but these methods often result in complex configurations and low resource utilization. These solutions also face challenges such as degraded network performance and managing the increasing demands for VLANs. Summary of the Invention
[0004] Embodiments of the present invention provide a data transmission system, a method, an apparatus, and a medium for allocating virtual extensible local area network identifiers, which solve the network expansion bottleneck caused by the limitation of the number of VLANs.
[0005] In a first aspect, embodiments of the present invention provide a data transmission system, which includes:
[0006] A software-defined network controller SDN, configured to receive tenant information and attribute information of a virtual machine sent by a cloud management platform, allocate a unique corresponding virtual extensible local area network identifier VNI for the tenant, and send the mapping relationship between the tenant information and the VNI to an access switch, where the tenant information is an identity identifier generated when the tenant first creates a virtual machine in the cloud management platform, and the attribute information of the virtual machine includes the media access control MAC address and the Internet protocol address IP corresponding to the virtual machine;
[0007] An access switch for receiving original data packets sent by a source virtual machine through a source host, where the original data packets include original virtual local area network (VLAN) tags and virtual machine attribute information. The access switch determines tenant information corresponding to the virtual machine according to the MAC address in the virtual machine attribute information, and determines a target VNI corresponding to the tenant information based on the mapping relationship between the received tenant information and virtual extensible local area network identifier (VNI). Then, it generates a virtual extensible local area network (VXLAN) header containing the target VNI, and encapsulates the VXLAN header, user datagram protocol (UDP) header, Internet protocol (IP) header, and Ethernet header outside the original data packet to obtain an encapsulated VXLAN data packet, and sends the encapsulated VXLAN data packet to the core network. The IP header includes a source IP address and a target IP address, and the Ethernet header includes a source MAC address and a target MAC address;
[0008] A core network device for transmitting the encapsulated VXLAN data packet to a target switch through an IP network according to the target IP address;
[0009] A target switch for parsing the encapsulated VXLAN data packet to obtain an original data packet, and sending the parsed original data packet to a target virtual machine through a target host.
[0010] Optionally, the access switch is specifically configured to:
[0011] After receiving the encapsulated VXLAN data packet, perform layer-by-layer decapsulation on the VXLAN data packet to obtain a VXLAN header and an original data packet;
[0012] Extract the target VNI from the VXLAN header, and determine the VLAN tag corresponding to the target VNI by querying the mapping table between the local VNI and VLAN;
[0013] Determine the target MAC address corresponding to the target virtual machine according to the Ethernet header, and determine the target port of the target host corresponding to the target MAC address;
[0014] Send the original data packet containing the VLAN tag and the target MAC address to the target virtual machine through the target host via the target port.
[0015] Optionally, the identity of the tenant is represented by an identity number ID. Correspondingly, the SDN is specifically configured to:
[0016] Hash the tenant ID into an unsigned integer based on a hash algorithm;
[0017] Map the unsigned integer to the 24-bit VNI range through modulo operation to obtain the VNI corresponding to the tenant ID.
[0018] Optionally, the SDN is used to maintain a VNI pool and track the allocated VNIs in real time;
[0019] Correspondingly, the SDN is specifically used for:
[0020] When receiving the tenant information and attribute information sent by the cloud management platform each time, select an unused VNI from the VNI pool as the VNI uniquely corresponding to the tenant information, and mark the VNI as the allocated state.
[0021] Optionally, the VNI pool includes multiple logical segments, each logical segment corresponds to a group of physical paths, and the load metrics of each physical path are collected in real time through a network monitoring tool, where the load metrics include bandwidth utilization rate and packet loss rate;
[0022] Correspondingly, the SDN is specifically used for:
[0023] Calculate the load score value of each physical path according to the load metrics, and when receiving the tenant information and attribute information of the virtual machine sent by the cloud management platform each time, select the target VNI segment with the lowest load score value from the respective logical segments, and allocate the corresponding VNI for the tenant information from the target VNI segment.
[0024] Optionally, the load score value is calculated through the following formula:
[0025] y = αA + βB
[0026] Where y represents the load score value, A represents the bandwidth utilization rate, B represents the packet loss rate, and α and β represent different weight coefficients.
[0027] Optionally, the SDN is further used for:
[0028] When receiving the tenant cancellation message sent by the cloud management platform, mark the VNI corresponding to the tenant as unused and recycle it to the VNI pool.
[0029] In a second aspect, an embodiment of the present invention further provides a method for allocating virtual extensible local area network identifiers, which is applied to the SDN controller provided in any embodiment of the present invention. The method includes:
[0030] Receive the tenant information and attribute information of the virtual machine sent by the cloud management platform, and allocate a virtual extensible local area network identifier VNI uniquely corresponding to the tenant, where the tenant information is generated when the tenant creates a virtual machine on the cloud management platform for the first time, and the attribute information includes the MAC address and IP address corresponding to the virtual machine;
[0031] Send the mapping relationship between the tenant information and the VNI to the access switch.
[0032] Optionally, the identity identifier of the tenant is represented by an identity number ID. Correspondingly, the allocation of a unique virtual extensible local area network identifier (VNI) for the tenant includes:
[0033] Hashing the tenant ID into an unsigned integer based on a hashing algorithm;
[0034] Mapping the unsigned integer to the 24-bit VNI range through modulo operation to obtain the VNI corresponding to the tenant ID.
[0035] Optionally, the allocation of a unique virtual extensible local area network identifier (VNI) for the tenant includes:
[0036] When receiving the tenant information and attribute information sent by the cloud management platform each time, select an unused VNI from the VNI pool as the VNI uniquely corresponding to the tenant information, and mark the VNI as the allocated state.
[0037] Optionally, the VNI pool includes multiple logical segments, each segment corresponding to a group of physical paths. The load metrics of each physical path are collected in real time through a network monitoring tool, where the load metrics include bandwidth utilization rate and packet loss rate;
[0038] Correspondingly, selecting an unused VNI from the VNI pool as the VNI uniquely corresponding to the tenant information includes:
[0039] Calculating the load score value of each physical path according to the load metrics, and when receiving the tenant information and attribute information of the virtual machine sent by the cloud management platform each time, select the target VNI segment with the lowest load score value from the respective logical segments, and allocate the corresponding VNI for the tenant information from the target VNI segment.
[0040] Optionally, the load score value is calculated through the following formula:
[0041] y = αA + βB
[0042] Where y represents the load score value, A represents the bandwidth utilization rate, B represents the packet loss rate, and α and β represent different weight coefficients.
[0043] Optionally, the method for allocating a virtual extensible local area network identifier provided in the embodiments of the present invention further includes:
[0044] When receiving the tenant cancellation message sent by the cloud management platform, mark the VNI corresponding to the tenant as unused and recycle it to the VNI pool.
[0045] In a third aspect, the embodiments of the present invention further provide an apparatus for allocating a virtual extensible local area network identifier. The apparatus includes:
[0046] The tenant information receiving module is configured to receive the tenant information and attribute information of the virtual machine sent by the cloud management platform. Among them, the tenant information is generated when the tenant first creates a virtual machine on the cloud management platform, and the attribute information includes the MAC address and IP address corresponding to the virtual machine.
[0047] The VNI allocation module is configured to allocate a uniquely corresponding virtual extensible local area network identifier VNI for the tenant.
[0048] The mapping relationship distribution module is configured to distribute the mapping relationship between the tenant information and the VNI to the access switch.
[0049] Optionally, the identity identifier of the tenant is represented by the identity number ID. Correspondingly,
[0050] The VNI allocation module includes:
[0051] The hash conversion unit is configured to hash the tenant ID into an unsigned integer based on the hash algorithm.
[0052] The mapping unit is configured to map the unsigned integer to the 24-bit VNI range through modulo operation to obtain the VNI corresponding to the tenant ID.
[0053] Optionally, the VNI allocation module includes:
[0054] The VNI allocation unit is configured to, each time it receives the tenant information and attribute information of the virtual machine sent by the cloud management platform, select an unused VNI from the VNI pool as the VNI uniquely corresponding to the tenant information, and mark the VNI as the allocated state.
[0055] Optionally, the VNI pool includes multiple logical segments, each logical segment corresponds to a group of physical paths, and the load metrics of each physical path are collected in real time through a network monitoring tool. Among them, the load metrics include bandwidth utilization rate and packet loss rate.
[0056] Correspondingly, the VNI allocation unit is specifically configured to:
[0057] Calculate the load score value of each physical path according to the load metrics, and each time it receives the tenant information and attribute information of the virtual machine sent by the cloud management platform, select the target VNI segment with the lowest load score value from the various logical segments, and allocate the corresponding VNI for the tenant information from the target VNI segment.
[0058] Optionally, the load score value is calculated through the following formula:
[0059] y = αA + βB
[0060] Among them, y represents the load fraction value, A represents the bandwidth utilization rate, B represents the packet loss rate, and α and β represent different weight coefficients.
[0061] Optionally, the virtual extensible local area network identifier allocation device provided by the embodiment of the present invention further includes:
[0062] A VNI recycling module, configured to mark the VNI corresponding to the tenant as unused and recycle it to the VNI pool when receiving the tenant cancellation message sent by the cloud management platform.
[0063] In a fourth aspect, an embodiment of the present invention further provides a server, including:
[0064] A memory storing executable program code;
[0065] A processor coupled to the memory;
[0066] The processor calls the executable program code stored in the memory and executes the virtual extensible local area network identifier allocation method provided by any embodiment of the present invention.
[0067] In a fifth aspect, an embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored, and when the program is executed by a processor, it implements the virtual extensible local area network identifier allocation method provided by any embodiment of the present invention.
[0068] The technical solution provided by the embodiments of the present invention expands the capacity of the virtual network by introducing the VXLAN technology, enabling each tenant to have an independent virtual network identifier without being restricted by the number of VLANs. This avoids the network expansion bottleneck problem caused by the VLAN number limitation, allowing virtual machines to migrate more flexibly between different physical machines without considering VLAN conflicts or occupancy. When the traffic of the virtual machine reaches the access switch, the access switch embeds the VLAN information into the VXLAN header through encapsulation technology to generate a VXLAN data packet containing the VNI, and transmits the VXLAN data packet through the third-layer IP network. During the transmission process, the VLAN information is hidden inside the VXLAN data packet, and the core network does not need to process the actual VLAN information, avoiding the occupancy of network resources by VLANs. After the VXLAN data packet reaches the target switch, the target switch de-encapsulates the data packet to restore the original VLAN information, and forwards the data containing the original VLAN information to the target virtual machine through the target host. The above process eliminates the need for VLAN information in the core network, effectively alleviates the problem of insufficient VLANs, especially in a large multi-tenant data center environment, greatly alleviates the problem of insufficient VLANs in the core network, and enhances the scalability, flexibility, and efficiency of modern networks in large-scale, virtualized, and multi-tenant environments.
[0069] The innovation points of the embodiments of the present invention include:
[0070] 1. The SDN controller expands the capacity of the virtual network by allocating an independent virtual network identifier for each tenant, enabling tenants not to be restricted by the number of VLANs, and avoiding the network expansion bottleneck problem caused by the VLAN number limitation. This is one of the innovation points of the embodiments of the present invention.
[0071] 2. The access switch embeds the VLAN information into the VXLAN header through encapsulation technology to generate a VXLAN data packet containing the VNI, and transmits the VXLAN data packet through the third-layer IP network. During the transmission process, the VLAN information is hidden inside the VXLAN data packet, and the core network does not need to process the actual VLAN information, effectively reducing the occupancy of VLAN IDs in the core network and solving the bottleneck problem of traditional VLAN technology in large-scale data centers. This is one of the innovation points of the embodiments of the present invention.
[0072] 3. By real-time monitoring of network load data and preferentially selecting low-load VNI segments to allocate VNIs for tenants, the overall resource utilization rate is improved. This is one of the innovation points of the embodiments of the present invention. Brief Description of the Drawings
[0073] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the accompanying drawings required for the description of the embodiments or the prior art. Obviously, the accompanying drawings in the following description are only some embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other drawings can be obtained based on these drawings.
[0074] Figure 1 The structural block diagram of a data transmission system provided in the first embodiment of the present invention;
[0075] Figure 2 The flowchart of a method for allocating virtual extensible local area network identifiers provided in the second embodiment of the present invention;
[0076] Figure 3 The structural block diagram of a device for allocating virtual extensible local area network identifiers provided in the third embodiment of the present invention;
[0077] Figure 4 The structural schematic diagram of a server provided in the fourth embodiment of the present invention. Detailed implementation manners
[0078] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, rather than all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts belong to the scope of protection of the present invention.
[0079] It should be noted that the terms "include" and "have" and any variations thereof in the embodiments of the present invention and the accompanying drawings are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or device that includes a series of steps or units is not limited to the listed steps or units, but optionally further includes unlisted steps or units, or optionally further includes other steps or units inherent to these processes, methods, products, or devices.
[0080] The embodiments of the present invention disclose a data transmission system, a method, a device, and a medium for allocating virtual extensible local area network identifiers. The following will be described in detail respectively.
[0081] Embodiment 1
[0082] A data transmission system provided in Embodiment 1 of the present invention adopts the VXLAN technology, which is applied to the CE (Customer Edge) side. By adopting the VXLAN technology, the requirement for VLAN information in the core network is eliminated during the data transmission process, thus effectively alleviating the problem of insufficient VLANs. Figure 1 It is a structural block diagram of a data transmission system provided in Embodiment 1 of the present invention. As Figure 1 shown, the data transmission system provided in Embodiment 1 of the present invention includes an SDN (Software Defined Networking) controller 1, an access switch 2, a core network device 3, and a target switch 4. Next, the functions of each component of the system and the interaction between each component will be introduced in detail. Among them,
[0083] 1. SDN controller 1
[0084] The SDN controller is used to receive the tenant information and attribute information of the virtual machines sent by the cloud management platform, assign a unique corresponding Virtual Extensible LAN Identifier (VNI) to each tenant, and send the mapping relationship between the tenant information and the VNI to the access switch.
[0085] Among them, a tenant refers to an independent user or customer group running on a shared physical infrastructure. Each tenant can be an independent business entity, having its own computing resources, storage resources, and network resources. Each tenant can submit the creation requirement of a virtual machine through the platform interface or API (Application Programming Interface). When the cloud management platform receives the tenant requirement for the first time, it generates the identity identifier of the tenant, such as the tenant ID (Identity document), and creates the corresponding virtual machine according to the tenant requirement. Specifically, the cloud management platform can be OpenStack (an open-source cloud computing management platform project), or AWS Wavelength (an edge computing service platform provided by Amazon). This embodiment does not make specific limitations in this regard. When the virtual machine starts up, the cloud management platform assigns the corresponding attribute information to it, and the attribute information includes the MAC (Media Access Control Address) address and IP (Internet Protocol Address) corresponding to each virtual machine. The cloud management platform associates the tenant information of each tenant with the virtual machine attribute information through the pre-configured API and sends it to the SDN controller.
[0086] When the SDN controller receives the tenant information and attribute information of the virtual machine sent by the cloud management platform, it assigns a uniquely corresponding VNI (Virtual eXtensible Local Area Network Identifier) to the tenant, and sends the mapping relationship between the tenant information and the VNI to the access switch. The access switch can store the mapping relationship locally. Among them, the SDN controller and the access switch can communicate through the OpenFlow (a network communication protocol belonging to the data link layer) protocol.
[0087] Those skilled in the art can understand that VXLAN (Virtual Extensible Local Area Network) can provide a 24-bit VXLAN network identifier (hereinafter simply referred to as VNI), and allows up to 16 million unique identifiers to be supported, far exceeding the 4096 VLAN (Virtual Local Area Network) tags provided by traditional VLAN technology. In this embodiment, by introducing VXLAN technology, the capacity of the virtual network is expanded, so that each tenant can have an independent virtual network identifier, and is no longer limited by the number of VLANs, avoiding the network expansion bottleneck problem caused by the VLAN number limitation, and enabling the virtual machine to migrate more flexibly between different physical machines without worrying about VLAN conflicts or occupancy.
[0088] Optionally, the SDN controller can generate the VNI corresponding to the tenant in the following manner:
[0089] Hash the tenant ID into an unsigned integer based on the hash algorithm, and then map the unsigned integer to the 24-bit VNI range through modulo operation to obtain the VNI corresponding to the tenant ID.
[0090] With the above settings in this embodiment, each tenant can uniquely correspond to a VNI. Further, in order to further ensure the uniqueness of the VNI corresponding to each tenant, after generating the VNI corresponding to the tenant ID based on the hash algorithm, check whether the status of the VNI is allocated. If it is not allocated, send the mapping relationship between the VNI and the tenant ID to the access switch; if the status of the VNI is allocated, perform an increment operation on the VNI until the status of the obtained VNI is unallocated, and use the finally obtained unallocated VNI as the VNI corresponding to the tenant.
[0091] As another alternative implementation, the SDN controller can also assign the corresponding VNI to the tenant ID in the following manner.
[0092] The SDN controller maintains a VNI pool and tracks the allocated VNIs in real time. Each time tenant information and attribute information sent by the cloud management platform are received, an unused VNI is selected from the VNI pool as the VNI uniquely corresponding to the tenant information, and the VNI is marked as the allocated state.
[0093] Furthermore, the VNI pool can be divided into multiple logical segments, and each logical segment corresponds to a group of physical paths. The physical paths can be different ports or links of a core switch. For example, logical segment 1 (5001 - 10000) is bound to ports 1 - 10 of the core switch and transmitted through link A, and logical segment 2 (10001 - 15000) is bound to ports 11 - 20 of the core switch and transmitted through link B. The load metrics of each physical path can be collected in real time through network monitoring tools, where the load metrics include bandwidth utilization rate and packet loss rate.
[0094] The SDN controller can calculate the load score value of each physical path according to the load metrics, and each time tenant information and attribute information of a host sent by the cloud management platform are received, the target VNI segment with the lowest load score value is selected from each logical segment, and the corresponding VNI is allocated for the tenant information from the target VNI segment. Such a setting can avoid introducing new traffic into the physical paths with high load, thereby achieving the effect of optimizing the overall network performance. Among them, calculating the load score value of each physical path according to the load metrics can be obtained through the following formula:
[0095] y = αA + βB
[0096] Where y represents the load score value, A represents the bandwidth utilization rate, B represents the packet loss rate, and α and β represent different weight coefficients.
[0097] Furthermore, calculate the load score value corresponding to each logical segment according to the above formula, and the VNI logical segments can be divided into three levels from low to high according to the size of the load score value. For example, low load corresponds to the load score value range of 0 - 20 points; medium load corresponds to the load score value range of: 21 - 75 points; high load corresponds to the load score value range of: 76 - 100 points. When a new tenant requests a VNI, an available VNI is preferentially selected from the VNI segments with low load scores (such as 0 - 20 points).
[0098] Furthermore, the load scores of each VNI segment can be recalculated at set intervals (e.g., every 1 hour). If a certain VNI segment is continuously highly loaded, some of its VNI segments can be migrated to a low-load path to optimize resource utilization and avoid core network congestion. During the specific migration process, free VNIs can be selected from the low-load segments, new VNIs can be allocated to the tenants to be migrated, and the migration information of the tenants' VNIs before and after migration can be marked in the database, and the migration timestamp can be recorded. Further, after the migration is completed, the old VNI can be retained for a period of time (such as 30 minutes) to ensure that residual traffic is processed.
[0099] Furthermore, when receiving a tenant cancellation message sent by the cloud management platform, the SDN controller marks the VNI corresponding to the tenant as unused and recovers it to the VNI pool.
[0100] In this embodiment, the VXLAN technology is adopted, and the SDN controller assigns a unique VNI to each tenant, enabling each tenant to have an independent virtual network identifier and no longer being restricted by the number of VLANs, ensuring that each tenant can achieve isolation and security management through an independent network segment.
[0101] 2. Access Switch 2
[0102] The access switch is used to receive the original data packet sent by the source virtual machine through the source host. The original data packet includes the original VLAN tag and virtual machine attribute information. The access switch determines the tenant information corresponding to the virtual machine according to the MAC address in the virtual machine attribute information, determines the target VNI corresponding to the tenant information based on the mapping relationship between the received and stored tenant information and the VNI, generates a VXLAN header containing the target VNI, and encapsulates the VXLAN header, UDP (User Datagram Protocol) header, IP header, and Ethernet header outside the original data packet to obtain the encapsulated VXLAN data packet, and sends the encapsulated VXLAN data packet to the core network. Among them, the IP header includes the source IP address and the target IP address, and the Ethernet header includes the source MAC address and the target MAC address.
[0103] In this embodiment, when the traffic of the virtual machine arrives, the access switch embeds the VLAN information into the VXLAN header through encapsulation technology to generate a VXLAN data packet containing the VNI, and transmits it through the third-layer IP network. During the transmission process, the VLAN information is hidden in the VXLAN data packet, and the core network does not need to process the actual VLAN information, thus avoiding the resources occupied by the VLAN. Especially when the number of virtual machines far exceeds the number of VLANs, the problem of insufficient VLAN numbers is solved.
[0104] 3. Core Network Device 3
[0105] Among them, the core network device refers to a three-layer network device that supports IP routing functions, such as a router or a three-layer switch. Its core role is to efficiently transmit the VXLAN-encapsulated data packets through the IP network. In this embodiment, the core network device is used to transmit the encapsulated VXLAN data packets to the target switch through the IP network according to the target IP address.
[0106] In this embodiment, the VLAN information is encapsulated on the access switch side through the VXLAN technology and transmitted through the IP network, without relying on the transmission of the native VLAN in the core network, so that the core network no longer bears the actual VLAN information, thereby greatly reducing the VLAN consumption of the core network and solving the bottleneck problem of the traditional VLAN technology in large-scale data centers.
[0107] 4. Target Switch 4
[0108] The target switch is used to parse the encapsulated VXLAN data packets to obtain the original data packets, and send the original data packets obtained by parsing to the target virtual machine through the target host.
[0109] Specifically, the decapsulation process of the target switch can be implemented through the following steps A to D:
[0110] A. Decapsulate the VXLAN data packets layer by layer, that is, strip the Ethernet header, IP header, UDP header, and VXLAN header in sequence to restore the original Ethernet frame. In this embodiment, the VXLAN header and the original Ethernet frame, that is, the original data packet, need to be retained.
[0111] B. Extract the target VNI from the VXLAN header, query the mapping table between the local VNI and VLAN, and determine the VLAN tag corresponding to the target VNI.
[0112] Among them, the mapping table between the VNI and VLAN is created by the SDN controller and sent to the target switch by the SDN controller.
[0113] C. Determine the target MAC address corresponding to the target virtual machine according to the Ethernet header, and determine the target port of the target host corresponding to the target MAC address;
[0114] D. Send the original data packet containing the VLAN tag and the target MAC address to the target virtual machine through the target host through the target port.
[0115] In this embodiment, by introducing the VXLAN technology, the capacity of the virtual network is expanded, enabling each tenant to have an independent virtual network identifier without being restricted by the number of VLANs. This avoids the network expansion bottleneck problem caused by the VLAN number limit, allowing virtual machines to migrate more flexibly between different physical machines without considering VLAN conflicts or occupancy. When the traffic of the virtual machine reaches the access switch, the access switch embeds the VLAN information into the VXLAN header through encapsulation technology to generate a VXLAN data packet containing the VNI, and transmits the VXLAN data packet through the third-layer IP network. During the transmission process, the VLAN information is hidden within the VXLAN data packet, and the core network does not need to process the actual VLAN information, thus avoiding the occupancy of network resources by VLANs. After the VXLAN data packet reaches the target switch, the target switch de-encapsulates the data packet to restore the original VLAN information, and forwards the data containing the original VLAN information to the target virtual machine through the target host. The above process eliminates the need for VLAN information in the core network, effectively alleviates the problem of insufficient VLANs, especially in a large multi-tenant data center environment, greatly alleviates the problem of insufficient VLANs in the core network, and enhances the scalability, flexibility, and efficiency of modern networks in large-scale, virtualized, and multi-tenant environments.
[0116] Embodiment 2
[0117] Figure 2 It is a flowchart of a method for allocating virtual extensible local area network identifiers provided in Embodiment 2 of the present invention. This method is implemented through the SDN controller provided in any embodiment of the present invention. As Figure 2 shown, the method provided in this embodiment includes:
[0118] S210. Receive the tenant information and attribute information of the virtual machine sent by the cloud management platform, and allocate a uniquely corresponding VNI for the tenant.
[0119] Among them, the tenant information is generated when the tenant first creates a virtual machine on the cloud management platform, and the attribute information includes the MAC address and IP address corresponding to the virtual machine.
[0120] Optionally, the identity identifier of the tenant is represented by the identity number ID. Correspondingly, allocating a uniquely corresponding virtual extensible local area network identifier VNI for the tenant includes:
[0121] Hashing the tenant ID into an unsigned integer based on the hash algorithm;
[0122] Mapping the unsigned integer to the 24-bit VNI range through modulo operation to obtain the VNI corresponding to the tenant ID.
[0123] Optionally, a unique VNI is assigned to this tenant, and the following steps can be used to achieve this:
[0124] There is a VNI pool maintained in the SDN controller. Each time the SDN controller receives tenant information and attribute information sent by the cloud management platform, it selects an unused VNI from the VNI pool as the VNI uniquely corresponding to the tenant information, and marks this VNI as the allocated state.
[0125] Furthermore, the VNI pool includes multiple logical segments, each logical segment corresponding to a group of physical paths. The load metrics of each physical path are collected in real time through a network monitoring tool, where the load metrics include bandwidth utilization rate and packet loss rate.
[0126] Correspondingly, selecting an unused VNI from the VNI pool as the VNI uniquely corresponding to the tenant information includes:
[0127] Calculating the load score value of each physical path according to the load metrics, and each time receiving the tenant information and attribute information of the virtual machine sent by the cloud management platform, selecting the target VNI segment with the lowest load score value from each logical segment, and allocating the corresponding VNI for the tenant information from the target VNI segment.
[0128] Specifically, the load score value can be calculated through the following formula:
[0129] y = αA + βB
[0130] Where y represents the load score value, A represents the bandwidth utilization rate, B represents the packet loss rate, and α and β represent different weight coefficients.
[0131] In the actual application process, the weight values corresponding to each load metric can be adjusted according to actual requirements.
[0132] Furthermore, the method for allocating virtual extensible local area network identifiers provided by the embodiments of the present invention further includes:
[0133] When receiving the tenant cancellation message sent by the cloud management platform, marking the VNI corresponding to this tenant as unused and recycling it to the VNI pool.
[0134] Specifically, the process of the SDN controller allocating a unique corresponding VNI for this tenant can refer to the description of the above embodiments and will not be elaborated here.
[0135] S220. Send the mapping relationship between the tenant information and the VNI to the access switch.
[0136] In this embodiment, the SDN controller extends the capacity of the virtual network by assigning an independent virtual network identifier to each tenant, enabling tenants to be no longer restricted by the number of VLANs, avoiding the network expansion bottleneck caused by the VLAN number limit, and also enabling virtual machines to migrate more flexibly between different physical machines without worrying about VLAN conflicts or occupations, enhancing the scalability, flexibility, and efficiency of modern networks in large-scale, virtualized, and multi-tenant environments.
[0137] Embodiment III
[0138] Figure 3 As shown in the block diagram of an apparatus for allocating virtual extensible local area network identifiers provided in Embodiment III of the present invention, Figure 3 the apparatus includes: a tenant information receiving module 310, a VNI allocation module 320, and a mapping relationship distribution module 330, where,
[0139] The tenant information receiving module 310 is configured to receive the tenant information and attribute information of the virtual machine sent by the cloud management platform. The tenant information is generated when the tenant creates a virtual machine on the cloud management platform for the first time, and the attribute information includes the MAC address and IP address corresponding to the virtual machine.
[0140] The VNI allocation module 320 is configured to allocate a uniquely corresponding virtual extensible local area network identifier VNI for the tenant.
[0141] The mapping relationship distribution module 330 is configured to distribute the mapping relationship between the tenant information and the VNI to the access switch.
[0142] Optionally, the identity identifier of the tenant is represented by the identity number ID. Correspondingly,
[0143] The VNI allocation module 320 includes:
[0144] The hash conversion unit is configured to hash the tenant ID into an unsigned integer based on the hash algorithm.
[0145] The mapping unit is configured to map the unsigned integer to the 24-bit VNI range through modulo operation to obtain the VNI corresponding to the tenant ID.
[0146] Optionally, the VNI allocation module 320 includes:
[0147] The VNI allocation unit is configured to, each time receiving the tenant information and attribute information sent by the cloud management platform, select an unused VNI from the VNI pool as the VNI uniquely corresponding to the tenant information, and mark the VNI as the allocated state.
[0148] Optionally, the VNI pool includes multiple logical segments, each logical segment corresponding to a group of physical paths, and the load metrics of each physical path are collected in real time through a network monitoring tool, where the load metrics include bandwidth utilization rate and packet loss rate;
[0149] Correspondingly, the VNI allocation unit is specifically configured to:
[0150] Calculate the load score value of each physical path according to the load metrics, and when receiving the tenant information and attribute information of the virtual machine sent by the cloud management platform each time, select the target VNI segment with the lowest load score value from each logical segment, and allocate the corresponding VNI for the tenant information from the target VNI segment.
[0151] Optionally, the load score value is calculated through the following formula:
[0152] y = αA + βB
[0153] where y represents the load score value, A represents the bandwidth utilization rate, B represents the packet loss rate, and α and β represent different weight coefficients.
[0154] Optionally, the virtual extensible local area network identifier allocation device provided by the embodiments of the present invention further includes:
[0155] A VNI recycling module, configured to mark the VNI corresponding to the tenant as unused and recycle it to the VNI pool when receiving the tenant cancellation message sent by the cloud management platform.
[0156] Embodiment 4
[0157] Please refer to Figure 4 , Figure 4 which is a schematic structural diagram of a server provided by Embodiment 4 of the present invention. This server is used to deploy the SDN controller provided by any embodiment of the present invention. As Figure 4 shown, the server may include:
[0158] A memory 701 storing executable program code;
[0159] A processor 702 coupled to the memory 701;
[0160] wherein, the processor 702 calls the executable program code stored in the memory 701 to execute the virtual extensible local area network identifier allocation method provided by any embodiment of the present invention.
[0161] The embodiments of the present invention disclose a computer-readable storage medium, which stores a computer program, wherein the computer program enables a computer to execute the virtual extensible local area network identifier allocation method provided by any embodiment of the present invention.
[0162] In various embodiments of the present invention, it should be understood that the magnitude of the sequence numbers of the above processes does not necessarily imply the order of execution. The order of execution of each process should be determined by its function and internal logic, and should not constitute any limitation to the implementation process of the embodiments of the present invention.
[0163] In the embodiments provided by the present invention, it should be understood that "B corresponding to A" means that B is associated with A, and B can be determined according to A. However, it should also be understood that determining B according to A does not mean determining B only according to A, and B can also be determined according to A and / or other information.
[0164] In addition, in each embodiment of the present invention, each functional unit can be integrated into a processing unit, or each unit can exist physically alone, or two or more units can be integrated into one unit. The above integrated unit can be implemented in the form of hardware or in the form of a software functional unit.
[0165] When the above integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-accessible memory. Based on such an understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a memory and includes several instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc., specifically, the processor in the computer device) to execute some or all of the steps of the above methods in various embodiments of the present invention.
[0166] Those of ordinary skill in the art will understand that all or part of the steps in the various methods of the above embodiments can be completed by instructing relevant hardware through a program, and the program can be stored in a computer-readable storage medium. The storage medium includes read-only memory (ROM), random access memory (RAM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), one-time programmable read-only memory (OTPROM), electrically-erasable programmable read-only memory (EEPROM), compact disc read-only memory (CD-ROM) or other optical disc memories, magnetic disk memories, tape memories, or any other medium that can be used to carry or store data and is computer-readable.
[0167] Those of ordinary skill in the art will understand that the drawings are only schematic diagrams of an embodiment, and the modules or processes in the drawings are not necessarily essential for implementing the present invention.
[0168] Those of ordinary skill in the art will understand that the modules in the device in the embodiment can be distributed in the device in the embodiment according to the description of the embodiment, or can be correspondingly changed to be located in one or more devices different from the present embodiment. The modules of the above embodiments can be combined into one module, or further split into multiple sub-modules.
[0169] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit them. Although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions described in the foregoing embodiments, or perform equivalent replacements for some of the technical features. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A data transmission system, characterized in that, Including: A Software Defined Network (SDN) controller, which is used to receive the tenant information and attribute information of virtual machines sent by the cloud management platform, allocate a uniquely corresponding Virtual Extensible LAN Identifier (VNI) for the tenant, and send the mapping relationship between the tenant information and the VNI to the access switch. Among them, the tenant information is the identity identifier generated when the tenant first registers a virtual machine in the cloud management platform, and the attribute information of the virtual machine includes the Media Access Control (MAC) address and Internet Protocol (IP) address corresponding to the virtual machine; An access switch, which is used to receive the original data packet sent by the source virtual machine through the source host. The original data packet includes an original Virtual Local Area Network (VLAN) tag and virtual machine attribute information. The access switch determines the tenant information corresponding to the virtual machine according to the MAC address in the virtual machine attribute information, and determines the target VNI corresponding to the tenant information based on the mapping relationship between the received tenant information and the Virtual Extensible LAN Identifier (VNI), and generates a Virtual Extensible LAN (VXLAN) header containing the target VNI, and encapsulates the VXLAN header, User Datagram Protocol (UDP) header, Internet Protocol (IP) header and Ethernet header outside the original data packet to obtain an encapsulated VXLAN data packet, and sends the encapsulated VXLAN data packet to the core network. The IP header includes a source IP address and a target IP address, and the Ethernet header includes a source MAC address and a target MAC address; Core network equipment, which is used to transmit the encapsulated VXLAN data packet to the target switch through the IP network according to the target IP address; The target switch, which is used to parse the encapsulated VXLAN data packet and send the parsed original data packet to the target virtual machine through the target host.
2. The system according to claim 1, characterized in that, The access switch is specifically used for: After receiving the encapsulated VXLAN data packet, unpack the VXLAN data packet layer by layer to obtain the VXLAN header and the original data packet; Extract the target VNI from the VXLAN header, and determine the VLAN tag corresponding to the target VNI by querying the mapping table between the local VNI and the VLAN; Determine the target MAC address corresponding to the target virtual machine according to the Ethernet header, and determine the target port of the target host corresponding to the target MAC address; Send the original data packet containing the VLAN tag and the target MAC address to the target virtual machine through the target host through the target port.
3. The system according to claim 1, wherein The identity identifier of the tenant is represented by the identity number ID. Correspondingly, the SDN is specifically used for: Hashing the tenant ID into an unsigned integer based on the hash algorithm; Mapping the unsigned integer to the 24-bit VNI range through modulo operation to obtain the VNI corresponding to the tenant ID.
4. The system according to claim 1, wherein The SDN is used to maintain a VNI pool and track the allocated VNI in real time; Correspondingly, the SDN is specifically used for: Each time tenant information and attribute information sent by the cloud management platform are received, select an unused VNI from the VNI pool as the VNI uniquely corresponding to the tenant information, and mark the VNI as the allocated state.
5. The system according to claim 4, wherein The VNI pool includes multiple logical segments, each logical segment corresponding to a group of physical paths, and the load metrics of each physical path are collected in real time through a network monitoring tool, where the load metrics include bandwidth utilization rate and packet loss rate; Correspondingly, the SDN is specifically used for: Calculate the load score value of each physical path according to the load metrics, and each time tenant information and attribute information of a virtual machine sent by the cloud management platform are received, select the target VNI segment with the lowest load score value from the respective logical segments, and allocate the corresponding VNI for the tenant information from the target VNI segment.
6. The system according to claim 5, wherein The load score value is calculated through the following formula: y = αA + βB Where y represents the load score value, A represents the bandwidth utilization rate, B represents the packet loss rate, and α and β represent different weight coefficients.
7. The system according to any one of claims 1-6, characterized in that, The SDN is further used for: When receiving the tenant cancellation message sent by the cloud management platform, mark the VNI corresponding to the tenant as unused and recycle it to the VNI pool.
8. A method for allocating virtual extensible local area network identifiers, characterized in that, Applied to the SDN according to any one of claims 1-7, the method includes: Receive tenant information and attribute information of a virtual machine sent by the cloud management platform, and allocate a virtual extensible local area network identifier VNI uniquely corresponding to the tenant, where the tenant information is generated when the tenant first registers a virtual machine on the cloud management platform, and the attribute information includes the MAC address and IP address corresponding to the virtual machine; Send the mapping relationship between the tenant information and the VNI to the access switch.
9. A virtual extensible local area network identifier allocation device, characterized in that, Including: A tenant information receiving module configured to receive tenant information and attribute information of a virtual machine sent by the cloud management platform, where the tenant information is generated when the tenant first creates a virtual machine on the cloud management platform, and the attribute information includes the MAC address and IP address corresponding to the virtual machine; A VNI allocation module configured to: allocate a virtual extensible local area network identifier VNI uniquely corresponding to the tenant; A mapping relationship sending module configured to send the mapping relationship between the tenant information and the VNI to the access switch.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by a processor, it implements the method for allocating a virtual extensible local area network identifier as described in claim 8.
Citation Information
Patent Citations
A public network IP distribution method and apparatus and a virtualized data center system
CN107580077A
Data transmission method and device, switch and storage medium
CN109995639A
Message processing method and system and related equipment
CN112702252A
Method and apparatus for implementing communication between virtual machines
US20150281067A1
Orchestration of tenant overlay network constructs
US20230013269A1
Cited By
Virtual data packet transmission method and device, equipment, storage medium and program
CN121396927A