A multi-tenant network construction method and device based on cloud analysis

By using VXLAN technology and VNI tags in Cloud Analysis PrivateZone, the problems of high resource usage and redundant isolation functions of traditional multi-tenant network architecture are solved, achieving efficient tenant isolation and business model support, and adapting to changes in the cloud network environment.

CN116016436BActive Publication Date: 2024-09-27CHINA TELECOM CLOUD TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202211563806.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-12-07
Publication Date
2024-09-27
Estimated Expiration
2042-12-07

AI Technical Summary

Technical Problem

The traditional multi-tenant network protocol architecture has problems such as high resource usage, difficult deployment, performance bottlenecks and redundant isolation functions in specific application scenarios of Cloud Parsing PrivateZone. It cannot effectively support the isolation of a large number of tenant instances and seven-layer business data.

Method used

Adopt a multi-tenant network construction method based on cloud resolution, and use VXLAN technology and VNI tags to implement domain name query and forwarding services between tenants, reduce system resource usage, support 2 to the 24th power tenant instances, and tag in the overlay network Special processing ensures seven-layer application business isolation.

Benefits of technology

It minimizes tenant functional isolation, shares message sending and receiving device interfaces and network protocol clusters, eliminates the need for routing isolation, supports 16 business models and transport layer protocols, and adapts to flexible and ever-changing cloud network environments.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116016436B
    Figure CN116016436B
Patent Text Reader

Abstract

The present invention discloses a multi-tenant network construction method based on cloud resolution, and relates to the field of Internet technology. The multi-tenant network construction method based on cloud resolution includes the following application steps: S1, request service: PrivateZone request service, if accessing PrivateZone, determine whether the VNI of the request of the upstream ECS is between 1 and 0xFFFFFE, if the application layer processes to obtain the tenant PrivateZone information according to the VNI, and complete the request processing of the PrivateZone message, the present invention satisfies the routing selection of the TCP / IP protocol cluster used by the domain name query service and domain name forwarding service of multiple tenants, and satisfies the effective isolation and real-time resolution of the business data of each tenant, while not occupying system resources, combining actual measurement with theory, and supporting 2 to the power of 24 tenant instances.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of Internet technology, and in particular to a method and device for constructing a multi-tenant network based on cloud resolution. Background Art

[0002] Cloud Resolution PrivateZone technology is integrated on a network TCP / IP protocol cluster architecture, using VXLAN technology to distinguish tenants' intranet DNS resolution technology. This technology implements how to provide PrivateZone domain name resolution services and forwarding recursive resolution domain name services in a multi-tenant environment, while ensuring the isolation of each tenant's domain name and routing protocol stack while completing real-time resolution of east-west traffic. Since multi-tenant technology allows multiple tenants to share an application and TCP / IP protocol cluster environment, for cloud platform providers, multi-tenant technology can effectively reduce the cost of environment construction, including the hardware system itself, operating system, etc.

[0003] There are two main isolation schemes for traditional multi-tenant network protocol cluster architectures. One is to implement a completely independent view of the network protocol stack based on the netnamespace (network command space), including network device interfaces, ipv4 and ipv6 protocol stacks, ip routing tables, firewall rules, sockets, etc. Each net namespace provides an independent network environment, just like an independent system. A layer 2 device interface can only exist in one net namespace. This solution uses tenants as the minimum granularity to isolate network protocol stacks and private domain name data. It is necessary to start thousands of net namespace instances on the host to support the isolation of protocol stacks and services of many tenants, including network interfaces and protocol stacks, routing table sockets and even seven-layer services. This technical solution has the disadvantages of occupying a lot of system resources, difficult deployment, high operation and maintenance costs, and easy performance bottlenecks during business peaks. At the same time, in theory, it is necessary to support 2 to the 24th power of net namespace instance objects and create 2 to the 24th power of two-layer virtual physical interfaces. The disadvantages are particularly obvious. It can be said that a single device cannot meet the requirements at all. For the scenarios of cloud resolution PrivateZone specific application services, this solution is too cumbersome and redundant with too many unnecessary isolation functions. The other is based on VRF (Virtual Routing and Rorwarding) technology to achieve multi-tenant routing isolation by creating multiple routing tables on a three-layer forwarding device. It is often used in MPLS VPN, firewalls, network forwarding devices and other application scenarios that require isolation. Although this solution solves TCP / IP and routing isolation and is lighter than netnamespacke, it is incapable of isolating layer-7 business data. At the same time, this solution also theoretically needs to support 2 to the 24th power routing tables on the host machine.

[0004] However, for the scenario of Cloud Resolution PrivateZone specific application services, the backend forwarding routes corresponding to this solution are basically the same in business scenarios. However, using 2 to the power of 24 routing table entries is too repetitive and redundant. Therefore, we proposed a multi-tenant network construction method based on Cloud Resolution to solve the above problems. Summary of the invention

[0005] In view of the shortcomings of the prior art, the present invention provides a multi-tenant network construction method based on cloud resolution, which solves the routing selection of the TCP / IP protocol cluster used for domain name query services and domain name forwarding services for multiple tenants, and satisfies the effective isolation and real-time resolution of business data of each tenant without occupying system resources. It combines actual measurements with theory and supports 2 to the power of 24 tenant instances.

[0006] To achieve the above objectives, the present invention is implemented through the following technical solutions: a multi-tenant network construction method based on cloud resolution, comprising the following application steps:

[0007] S1. Request service:

[0008] PrivateZone request service: When accessing PrivateZone, determine whether the VNI of the upstream ECS request is between 1 and 0xFFFFFE. If so, the application layer processes the tenant PrivateZone information based on the VNI, thus completing the request processing of the PrivateZone message.

[0009] Public network domain name request service, if the intranet domain name is not hit, the public network access process is followed, first saving the intranet user forwarding node information, then constructing a Vxlan tunnel by encapsulating VNI=0xFFFFFF, accessing the public recursive server through the next hop, and obtaining the final result;

[0010] S2. Response service:

[0011] When PrivateZone responds to the service, the application layer obtains the tenant domain name record set based on the VNI information, determines whether the VNI is between 1 and 0xFFFFFE, and searches for the tenant's intranet domain name information based on the corresponding VNI information. If the intranet domain name is matched, the request is completed and the response message is directly encapsulated and returned;

[0012] When responding to the public domain name service, the IDNS node receives the complete VXLAN response message from the device interface and processes it according to the original protocol stack to determine whether the VNI is equal to 0xFFFFFF. It finds the requesting user in the intranet by searching the previously saved forwarding node information, encapsulates the response message of the intranet domain name, and returns it to the requesting user, finally completing the processing of the public domain name.

[0013] Furthermore, the PrivateZone request service in S1 includes the following application steps:

[0014] Complete the PrivateZone configuration update;

[0015] When accessing PrivateZone, the VM constructs a DNS request message and encapsulates the vxlan message through the underlay network between the compute nodes and network element nodes within the region to reach the device node IDNS that provides the cloud resolution PrivateZone service.

[0016] The device node IDNS obtains the vxlan message and sends it to the vxlan protocol unit module for processing;

[0017] Special processing is performed on the Vxlan tunnel. Only two tunnels, vxlan0 and vxlan1, are created. The initial VNI of the vxlan0 tunnel is equal to 0, and the remote vtep IP is 0.0.0.0. The vxlan0 tunnel processes the domain name query service of the ECS of all upstream tenants, that is, the VNI is between 1 and 0xFFFFFE.

[0018] Determine that the VNI of the upstream ECS request is between 1 and 0xFFFFFE. After hitting the Vxlan0 tunnel, change the packet receiving device interface to vxlan0 and perform a validity check on the vxlan0 device interface.

[0019] The network protocol stack processes the Overlay message. The Layer 2 unit module processes and determines the M_VXLANTAG mark and saves the Layer 2 source MAC of the Overlay to mbuf for response message encapsulation.

[0020] The POSIX processing module of the Overlay message saves the MAC address and VNI information to the front of the recv buffer of the application layer socket according to the flag M_VXLANTAG;

[0021] The socket unit processing module delivers the complete data of recvbuf to the application layer. The application layer obtains the tenant PrivateZone information based on the VNI, thus completing the request processing of the PrivateZone message.

[0022] Furthermore, the public domain name request service in S1 includes the following application steps:

[0023] Complete the PrivateZone configuration update;

[0024] When accessing PrivateZone, the VM constructs a DNS request message and encapsulates the vxlan message through the underlay network between the compute nodes and network element nodes within the region to reach the device node IDNS that provides the cloud resolution PrivateZone service.

[0025] After receiving the complete VXLAN message from the device interface, the DNS node forwards it to the public domain name request unit module for processing;

[0026] The public domain name request unit module processes and makes a mapping association between the downstream DNS ID and the upstream DNS ID for processing the response message, and then calls the socket's sendto function to send the message;

[0027] The overlay inner layer message first receives the socket sendbuf data in the POSIX module, extracts the VNI and MAC information according to the private data structure, determines that the VNI is equal to 0xFFFFFF, and enters the processing of the next protocol module;

[0028] The Overlay UDP protocol sending module processes and determines whether the tag M_VXLANTAG exists and combines it with VNI, then directly traverses the global address interface, obtains the interface name "vxlan1" and local address, and saves the sending device interface vxlan1;

[0029] The Overlay IP protocol sending module processes and determines the mark M_VXLANTAG, then directly uses the device interface and route obtained by the upper layer protocol module and skips the routing module;

[0030] The physical link of Overlay is sent, and the mark M_VXLANTAG is judged. If it exists, the trasmit interface is directly called to enter the sending module of the vxlan protocol;

[0031] The sending module of the Vxlan protocol processes, obtains the remote vtep IP of the underlay, encapsulates the vxlan protocol module with VNI0xFFFFFF, generates the source port, and performs RSS check to ensure that the response message hits the current network card queue thread and the destination port 4789 to encapsulate the underlay udp module, and then enters the processing of the next module;

[0032] The Underlay IP protocol module processes and selects routes according to the original logic of the TCP / IP protocol stack, including supporting layer 2 message ARP learning encapsulation. This completes the processing of public domain name request messages.

[0033] Furthermore, the PrivateZone response service in S2 includes the following application steps:

[0034] After the application layer obtains the tenant domain name record set based on the VNI information, it encapsulates the DNS response message and then calls the socket's sendto function to send the message.

[0035] The overlay inner layer message first receives the socket sendbuf data in the POSIX module, and extracts the VNI and MAC information according to the pre-defined private data structure. If the VNI is between 1 and 0xFFFFFE, the mbuf is marked with M_VXLANTAG and the MAC address and VNI information are saved. The length of the private data is subtracted from the length of the sent data, and the message is processed by the next protocol module.

[0036] The overlay UDP protocol sending module processes and determines whether the tag M_VXLANTAG exists and combines it with the VNI interval, then directly traverses the global address interface, obtains the interface name "vxlan0" and the local address, and saves the sending device interface vxlan0;

[0037] The overlay IP protocol sending module processes and determines the mark M_VXLANTAG, then directly uses the device interface and routing module obtained by the upper layer protocol module, skipping the routing module;

[0038] The overlay layer 2 protocol sending module processes and determines the mark M_VXLANTAG, then directly uses the MAC address saved by the upper layer protocol module to encapsulate the destination MAC, and uses the device interface information obtained by the upper layer protocol module to directly encapsulate the source MAC. The protocol type encapsulates IPv4 or IPv6 according to the family.

[0039] The physical link of the overlay is sent, and the mark M_VXLANTAG is judged. If it exists, the trasmit interface is directly called to enter the sending module of the vxlan protocol;

[0040] The sending module of the Vxlan protocol processes the tunnel information according to the context of the vxlan0 interface, searches the vxlan mapping table according to the inner destination mac of the Overlay to obtain the remote vtep IP of the underlay, encapsulates the vxlan protocol module according to the VNI saved in the mbuf, randomly generates the source port and destination port 4789 to encapsulate the udp module of the underlay, encapsulates the underlay IP module according to the obtained IP information, deletes the mark M_VXLANTAG, and then enters the processing of the next module;

[0041] Under lay IP protocol module processing, when performing routing selection, is based on the original logic of the TCP / IP protocol stack, including the support of layer 2 message ARP learning encapsulation, thus completing the response processing of the PrivateZone message.

[0042] Furthermore, the public domain name response service in S2 includes the following application steps:

[0043] After receiving the complete VXLAN response message from the device interface, the IDNS node processes the network data according to the original protocol stack, including the Layer 2 MAC, Layer 3 IP, and Layer 4 UDP network data of the underlay network;

[0044] The Underlay four-layer UDP protocol module processes the pcb context information obtained through the destination port 4789, and then obtains the vxlan message, which enters the vxlan protocol unit module for processing;

[0045] The Vxlan tunnel is specially processed. According to the VNI of 0xFFFFFF, the vxlan1 tunnel context information is obtained, the receiving device interface is modified to vxlan1, and the mbuf mark is M_VXLANTAG. Then the network protocol stack of the Overlay message is processed. The Layer 2 protocol receiving unit module determines that it is VNI0xFFFFFF and does not perform special processing, and directly delivers it to the Layer 3 protocol module.

[0046] The Layer 3 protocol packet receiving module of the Overlay message performs an IP protocol legitimacy check and then enters the Layer 4 UDP unit module for processing. The PCB context created in the public network domain name request logic is hit through the five-tuple information.

[0047] The POSIX processing module of the Overlay message will judge that it is VNI 0xFFFFFF and will not perform any special processing;

[0048] The socket unit processing module delivers the complete data of recvbuf to the application layer, directly processes the application layer DNS information, and finally obtains the upstream request information. Then, the public network response information is sent to the tenant ECS, and the processing of the public network domain name response is completed.

[0049] Furthermore, the vxlan1 tunnel initialization VNI is 0xFFFFFF; the remote vtep IP is the Overlay IP of the SGW device issued through configuration, and the vxlan1 tunnel is responsible for processing the network protocol processing of the forwarding domain name.

[0050] Furthermore, the message sending length is equal to the sum of the length of the private data and the length of the DNS message.

[0051] Furthermore, the data length of the delivery application layer is equal to the sum of the length of the placeholder private data and the length of the delivery original data.

[0052] Furthermore, the Overlay IP protocol sending module can directly skip the routing module during processing.

[0053] A multi-tenant network construction device based on cloud resolution, comprising:

[0054] S1. Request service module:

[0055] The PrivateZone request service module is used to determine whether the VNI of the upstream ECS request is between 1 and 0xFFFFFE when accessing the PrivateZone. If so, the application layer processes the tenant's PrivateZone information based on the VNI, completing the request processing of the PrivateZone message.

[0056] The public domain name request service module is used to determine whether the VNI is equal to 0xFFFFFF when accessing the public domain name. If so, the public domain name request message is processed;

[0057] S2, response service module:

[0058] The PrivateZone response service module is used to process the application layer and obtain the tenant domain name record set according to the VNI information, determine whether the VNI is between 1 and 0xFFFFFE, and search for the tenant's intranet domain name information according to the corresponding VNI information. If the intranet domain name is matched, the request is completed and the response message is directly encapsulated and returned;

[0059] The public domain name response service module is used to process the complete VXLAN response message received from the IDNS node from the device interface according to the original protocol stack, and determine whether the VNI is equal to 0xFFFFFF. If so, the public domain name response processing is completed.

[0060] The present invention has the following beneficial effects:

[0061] The multi-tenant network construction method based on cloud resolution can minimize the functional isolation of tenants, share the interface of the device for sending and receiving messages, and share the network protocol cluster without routing isolation, distinguish the underlay network protocol stack and the overlay network protocol stack, and mark the overlay network for special processing, while ensuring the tenant isolation of the seven-layer application business. The network protocol cluster satisfies one of the four specific combinations of the Overlay network and one of the four specific combinations of the Underlay network in the following business scenarios, and arbitrarily matches the network model of VXLAN, that is, supports 16 business models, and also supports the transport layer protocols UDP and TCP, including UDP long connection, UDP short connection, TCP long connection, and TCP short connection (UDP long connection only refers to the use of fixed five-tuples); flexibly select the long connection and short connection of UDP or TCP according to the application layer business requirements, and only need to configure to match the 16 models of Vxlan multi-tenant network; so as to adapt to the flexible and changeable cloud network environment.

[0062] Of course, any product implementing the present invention does not necessarily need to achieve all of the advantages described above at the same time. BRIEF DESCRIPTION OF THE DRAWINGS

[0063] Figure 1 It is a schematic diagram of the overall structure of the present invention;

[0064] Figure 2 The overall network topology diagram of the PrivateZone of the Cloud Resolution of the present invention;

[0065] Figure 3 This is the overall system architecture diagram of the Cloud Resolution PrivateZone of the present invention. DETAILED DESCRIPTION

[0066] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0067] In the description of the present invention, it should be understood that the terms "opening", "upper", "lower", "thickness", "top", "middle", "length", "inside", "all around" and the like indicating orientation or positional relationship are only for the convenience of describing the present invention and simplifying the description, rather than indicating or implying that the components or elements referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be understood as limiting the present invention.

[0068] See also Figure 1-3 The embodiment of the present invention provides a technical solution: a multi-tenant network construction method based on cloud resolution, including the following application steps:

[0069] S1. Request service:

[0070] PrivateZone request service: When accessing PrivateZone, determine whether the VNI of the upstream ECS request is between 1 and 0xFFFFFE. If so, the application layer processes the tenant PrivateZone information based on the VNI, thus completing the request processing of the PrivateZone message.

[0071] Public network domain name request service, if the intranet domain name is not hit, the public network access process is followed, first saving the intranet user forwarding node information, then constructing a Vxlan tunnel by encapsulating VNI=0xFFFFFF, accessing the public recursive server through the next hop, and obtaining the final result;

[0072] S2. Response service:

[0073] When PrivateZone responds to the service, the application layer processes the tenant domain name record set based on the VNI information and determines whether the VNI is between 1 and 0xFFFFFE. If so, the response processing of the PrivateZone message is completed;

[0074] When responding to the public domain name service, the IDNS node receives the complete VXLAN response message from the device interface and processes it according to the original protocol stack to determine whether the VNI is equal to 0xFFFFFF. It finds the requesting user in the intranet by searching the previously saved forwarding node information, encapsulates the response message of the intranet domain name, and returns it to the requesting user, finally completing the processing of the public domain name.

[0075] Specifically, the PrivateZone request service in S1 includes the following application steps:

[0076] Complete the PrivateZone configuration update;

[0077] When accessing PrivateZone, the VM constructs a DNS request message and encapsulates the vxlan message through the underlay network between the compute nodes and network element nodes within the region to reach the device node IDNS that provides the cloud resolution PrivateZone service.

[0078] After receiving the complete VXLAN message from the device interface, the IDNS node processes the underlay network's layer 2 MAC, layer 3 IP, layer 4 UDP and other network data according to the original protocol stack, and obtains the pcb context information from the underlay layer 4 UDP, and then obtains the vxlan message and enters the vxlan protocol unit module for processing;

[0079] At this time, the Vxlan tunnel is specially processed. Only two tunnels, vxlan0 and vxlan1, are created. The initial VNI of the vxlan0 tunnel is equal to 0, and the remote vtep IP is 0.0.0.0. The vxlan0 tunnel processes the domain name query service of the ECS of all upstream tenants, that is, the VNI is between 1 and 0xFFFFFE, and the initial VNI of the vxlan1 tunnel is 0xFFFFFF; the remote vtep IP is the Overlay IP of the SGW device issued by the configuration, and the vxlan1 tunnel is responsible for processing the network protocol processing of the forwarding domain name;

[0080] Determine that the VNI of the upstream ECS request is between 1 and 0xFFFFFE. After hitting the Vxlan0 tunnel, change the packet receiving device interface to vxlan0 and perform a validity check on the vxlan0 device interface. At the same time, save the VNI information to mbuf and mark the Overlay network message with M_VXLANTAG. The most important step is to learn and save the mapping table of the Overlay source MAC and the underlay source IP of the vxlan message.

[0081] The network protocol stack processes the Overlay message. The Layer 2 unit module processes and determines the M_VXLANTAG mark and saves the Layer 2 source MAC of the Overlay to mbuf for response message encapsulation. This is because the MAC addresses of all tenants' ECSs are globally unique.

[0082] The overlay message is processed by the third layer of IP protocol legitimacy check and then enters the fourth layer UDP unit module for processing. The five-tuple information hits the pcb contex of the listen 53 port.

[0083] The POSIX processing module of the overlay message saves the MAC address and VNI information to the front of the recv buffer of the application layer socket according to the flag M_VXLANTAG. At this time, the space of the vacated IP header and UDP header of the mbuf is sufficient to carry private data to the application layer. There is no need to apply for additional mbuf and memory space. The length of the data delivered to the application layer is equal to the sum of the length of the private data and the length of the original data delivered;

[0084] The socket unit processing module will deliver the complete data of recvbuf to the application layer. At this time, after the socket corresponds to the recvfrom function to obtain the application layer data, it will extract the VNI and mac according to the private data structure. These key information will accompany the entire life cycle of the tenant domain name query business processing at the application layer. The application layer processing obtains the tenant PrivateZone information based on the VNI, and the request processing of the PrivateZone message is completed.

[0085] Specifically, the public domain name request service in S1 includes the following application steps:

[0086] Complete the PrivateZone configuration update;

[0087] When accessing PrivateZone, the VM constructs a DNS request message and encapsulates the vxlan message through the underlay network between the compute nodes and network element nodes within the region to reach the device node IDNS that provides the cloud resolution PrivateZone service.

[0088] After the DNS node receives the complete VXLAN message from the device interface, it carries the VNI and MAC information to the application layer, similar to the processing logic of the PrivateZone upstream protocol module. It obtains tenant information based on the VNI but fails to find the available domain name record set information. At this time, the tenant activates the recursive forwarding service of the zone and needs to enter the public domain name request unit module for processing;

[0089] The public network domain name request unit module processes, first saves the upstream request information to the memory and records the DNS ID, and the application layer applies for buf to reserve enough private space in advance to encapsulate VNI 0xFFFFFF and MAC information. The Overlay mac address does not support arp learning, so the MAC address and forwarding server at this time are issued in advance through configuration, because the next hop to the forwarding server is the fixed device SGW, and then encapsulates the DNS request message. The most important thing is to map the downstream DNS ID and the upstream DNSID for processing the response message. The length of the sent message is equal to the sum of the length of the private data plus the length of the DNS message, and then the sendto function of the socket is called to send the message;

[0090] The overlay inner message first receives the socket sendbuf data in the POSIX module, and extracts the VNI and MAC information according to the private data structure. If the VNI is equal to 0xFFFFFF, it will mark the mbuf with M_VXLANTAG and save the mac address and VNI information to the mbuf. The length of the private data is subtracted from the length of the sent data, and then the next protocol module is processed.

[0091] The Overlay UDP protocol sending module processes and determines whether the tag M_VXLANTAG exists and combines it with VNI. It directly traverses the global address interface, obtains the interface name "vxlan1" and the local address, and saves the sending device interface vxlan1. It creates PCB information for processing the response message, with a destination port of 53, a destination IP of the forwarding server, a source IP of the vxlan1 interface, and a source port calculated based on the RSS check and guaranteed to be unique. If the RSS of the Overlay network does not need to be guaranteed, there is no need to do an RSS check.

[0092] When the Overlay IP protocol sending module is processed, the M_VXLANTAG mark is also judged first, and the device interface and route obtained by the upper-layer protocol module are directly used, and the routing selection module is skipped. At the same time, because the Overlay and Underlay networks overlap, the confusion of the IP protocol data module is avoided to prevent the network from being unavailable. If a specific business scenario can ensure that the downstream routing of the underlay and Overlay will not overlap, the protocol stack routing selection module can be directly used;

[0093] For the physical link transmission of Overlay, the M_VXLANTAG tag is first judged. If it exists, the trasmit interface is directly called to enter the sending module of the vxlan protocol. Many checks such as vlan, bridge, and bond are skipped here to improve efficiency.

[0094] The sending module of the Vxlan protocol first obtains the tunnel information according to the context of the vxlan1 interface, and then obtains the remote vtep IP of the underlay, encapsulates the vxlan protocol module with VNI 0xFFFFFF, generates the source port, and performs RSS check to ensure that the response message hits the current network card queue thread (if the vxlan underlay quintuple communication changes, no RSS check is required) and the destination port 4789 to encapsulate the underlay udp module, encapsulates the underlay IP module according to the obtained IP information, deletes the mark M_VXLANTAG, and then enters the processing of the next module;

[0095] The Underlay IP protocol module processes and selects routes according to the original logic of the TCP / IP protocol stack, including supporting the ARP learning encapsulation of the Layer 2 message. Therefore, the routing configuration and MAC forwarding table are based on the underlay network, that is, where conflicts occur, the underlay network is used as the standard. At the same time, the processing of the underlay network in the protocol sending module is simpler than that of the Overlay. At this point, the processing of the public domain name request message is completed.

[0096] Specifically, the PrivateZone response service in S2 includes the following application steps:

[0097] After the application layer obtains the tenant domain name record set according to the VNI information, it will reserve enough private space in advance to encapsulate the VNI and mac information when applying for the response buf after business processing, and then encapsulate the DNS response message. The length of the message sent is equal to the sum of the length of the private data and the length of the DNS response message, and then call the socket's sendto function to send the message;

[0098] The overlay inner message first receives the socket sendbuf data in the POSIX module, and extracts the VNI and MAC information according to the pre-defined private data structure. If the VNI is between 1 and 0xFFFFFE, the mbuf is marked with M_VXLANTAG and the MAC address and VNI information are saved. The length of the private data is subtracted from the length of the sent data, and the next protocol module is processed.

[0099] The Overlay UDP protocol sending module processes and determines whether the M_VXLANTAG tag exists and combines it with the VNI interval. It directly traverses the global address interface, obtains the interface name "vxlan0" and the local address, and saves the sending device interface vxlan0. This special processing skips the five-tuple search for the PCB module to improve efficiency. At the same time, because the Overlay and Underlay networks overlap, it avoids confusion in the UDP protocol data module and causes network failure.

[0100] When the overlay IP protocol sending module is processed, the M_VXLANTAG mark is also judged first, and the device interface and routing module obtained by the upper-layer protocol module are directly used, and the routing module is skipped. At the same time, because the overlay and underlay networks overlap, the confusion of the IP protocol data module is avoided, which may cause network failure.

[0101] The overlay layer 2 protocol sending module processes the packet and first determines the M_VXLANTAG tag. It then directly uses the mac address saved by the upper layer protocol module to encapsulate the destination mac, and uses the device interface information obtained by the upper layer protocol module to directly encapsulate the source mac. The protocol type encapsulates IPv4 or IPv6 according to the family. This cleverly solves the following problem, because in the cloud environment, the IDNS node of the overlay network does not support ARP learning mac and does not save the mac forwarding table for the request message.

[0102] For overlay physical link transmission, the M_VXLANTAG tag is first judged. If it exists, the trasmit interface is directly called to enter the sending module of the vxlan protocol. Many checks such as vlan, bridge, and bond are skipped here to improve efficiency.

[0103] The sending module of the Vxlan protocol first obtains the tunnel information according to the context of the vxlan0 interface. Because mac is globally unique, the vxlan mapping table is searched according to the inner destination mac of Overlay to obtain the remote vtep IP of the underlay. The vxlan protocol module is encapsulated according to the VNI saved in mbuf, and the source port and destination port 4789 are randomly generated to encapsulate the underlay udp module. The underlay IP module is encapsulated according to the obtained IP information, and the mark M_VXLANTAG is deleted. Then, the processing of the next module is entered. Here is the response message processing, so when the source port is randomly generated, no RSS check is performed;

[0104] The underlay IP protocol module processes and performs routing selection according to the original logic of the TCP / IP protocol stack, including supporting the ARP learning encapsulation of the second-layer message. Therefore, the routing configuration and MAC forwarding table are based on the underlay network. At the same time, the processing in the protocol sending module is simpler than that in the Overlay. At this point, the response processing of the PrivateZone message is completed.

[0105] Specifically, the public domain name response service in S2 includes the following application steps:

[0106] After receiving the complete VXLAN response message from the device interface, the IDNS node processes the network data according to the original protocol stack, including the Layer 2 MAC, Layer 3 IP, and Layer 4 UDP network data of the underlay network;

[0107] The Underlay four-layer UDP protocol module processes the pcb context information obtained through the destination port 4789, and then obtains the vxlan message, which enters the vxlan protocol unit module for processing;

[0108] At this time, the Vxlan tunnel is specially processed. According to the VNI of 0xFFFFFF, the vxlan1 tunnel context information is obtained, the packet receiving device interface is modified to vxlan1, and the mbuf mark is M_VXLANTAG. Next, the network protocol stack of the Overlay message is processed. The Layer 2 protocol packet receiving unit module determines that it is VNI0xFFFFFF and does not perform special processing, and directly delivers it to the Layer 3 protocol module;

[0109] The Layer 3 protocol packet receiving module of the Overlay message performs an IP protocol legitimacy check and then enters the Layer 4 UDP unit module for processing. The PCB context created in the public network domain name request logic is hit through the five-tuple information.

[0110] The POSIX processing module of the Overlay message will not perform any special processing based on the judgment that it is VNI 0xFFFFFF. However, it is important to remember that the corresponding private data structure size space must be reserved in front of the recv buffer of the application layer socket. The data length delivered to the application layer is equal to the sum of the length of the reserved private data plus the length of the delivered original data.

[0111] The socket unit processing module delivers the complete data of recvbuf to the application layer. At this time, after the socket corresponding to the public domain name request descriptor fd recvfrom function obtains the application layer data, it skips the VNI and mac information according to the specific data structure, directly processes the application layer DNS information, parses the DNS ID to query the forwarding information node saved when the public domain name request is requested, finds the mapped upstream DNS ID, and finally obtains the upstream request information, then calls the PrivateZone response logic processing, and finally sends the public network response information to the tenant ECS. At this point, the processing of the public domain name response has been completed.

[0112] A multi-tenant network construction device based on cloud resolution, comprising:

[0113] S1. Request service module:

[0114] The PrivateZone request service module is used to determine whether the VNI of the upstream ECS request is between 1 and 0xFFFFFE when accessing the PrivateZone. If so, the application layer processes the tenant's PrivateZone information based on the VNI, thus completing the request processing of the PrivateZone message.

[0115] The public domain name request service module is used to determine whether the VNI is equal to 0xFFFFFF when accessing the public domain name. If so, the public domain name request message is processed;

[0116] S2, response service module:

[0117] The PrivateZone response service module is used to process the application layer and obtain the tenant domain name record set according to the VNI information, and then determine whether the VNI is between 1 and 0xFFFFFE. If so, the response processing of the PrivateZone message is completed;

[0118] The public domain name response service module is used to process the complete VXLAN response message received from the IDNS node from the device interface according to the original protocol stack, and determine whether the VNI is equal to 0xFFFFFF. If so, the public domain name response processing is completed.

[0119] When in use, it can minimize the functional isolation of tenants, share the interface of the device for sending and receiving messages, and share the network protocol cluster without routing isolation. It distinguishes between the underlay network protocol stack and the overlay network protocol stack, and performs special marking on the overlay network. At the same time, it ensures the tenant isolation of the seven-layer application business, and the network protocol cluster meets the following business scenarios. One of the four specific combinations of the overlay network and one of the four specific combinations of the underlay network can be arbitrarily matched into a VXLAN network model, that is, it supports 16 business models.

[0120] Under lay network has various combinations as follows:

[0121] Intranet underlay IPv4 and extranet under lay IPv4;

[0122] Intranet underlay IPv4 and extranet underlay IPv6;

[0123] Intranet underlay IPv6 and extranet underlay IPv4;

[0124] Intranet underlay IPv6 and extranet underlay IPv6;

[0125] The various combinations of Overerlay networks are as follows:

[0126] Intranet overlay IPv4 and extranet overlay IPv4;

[0127] Intranet overlay IPv4 and extranet overlay IPv6;

[0128] Intranet overlay IPv6 and extranet overlay IPv4;

[0129] Intranet overlay IPv6 and extranet overlay IPv6;

[0130] It also supports the transport layer protocols UDP and TCP, including UDP long connection, UDP short connection, TCP long connection, and TCP short connection (UDP long connection only refers to the use of a fixed five-tuple); flexibly select UDP or TCP long and short connections according to application layer business needs, and only need to configure to match 16 models of Vxlan multi-tenant networks; in this way, it can adapt to the flexible and changeable cloud network environment.

[0131] It should 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.

[0132] It should be understood that when an element is referred to as being "fixed to" or "disposed on" another element, it can be directly on the other element or there may be an intermediate element at the same time; when an element is referred to as being "connected to" another element, it can be directly connected to the other element or there may be an intermediate element at the same time. In addition, the "connection" used here may include wireless connection; the wording "and / or" used includes any unit and all combinations of one or more associated listed items.

[0133] Any process or method description in a flowchart or otherwise described herein may be understood to represent a module, fragment or portion of code comprising one or more executable instructions for implementing the steps of a specific logical function or process, and the scope of the preferred embodiments of the present application includes alternative implementations in which functions may not be performed in the order shown or discussed, including performing functions in a substantially simultaneous manner or in the reverse order depending on the functions involved, which should be understood by technicians in the technical field to which the embodiments of the present application belong.

[0134] It should be understood that the various parts of the present application can be implemented by hardware, software, firmware or a combination thereof. In the above-mentioned embodiments, multiple steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, it can be implemented by any one of the following technologies known in the art or their combination: a discrete logic circuit having a logic gate circuit for implementing a logic function for a data signal, a dedicated integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.

[0135] A person skilled in the art may understand that all or part of the steps in the method for implementing the above-mentioned embodiment may be completed by instructing related hardware through a program, and the program may be stored in a computer-readable storage medium, which, when executed, includes one or a combination of the steps of the method embodiment.

[0136] A person skilled in the art can understand that all or part of the steps in the method of the above-mentioned embodiment can be completed by instructing related hardware through a program, and the program can be stored in a computer-readable storage medium. When the program is executed, it includes the following steps: (steps of the method), the storage medium, such as: ROM / RAM, disk, CD, etc.

[0137] In addition, each functional unit in each embodiment of the present application may be integrated into a processing module, or each unit may exist physically separately, or two or more units may be integrated into one module. The above-mentioned integrated module may be implemented in the form of hardware or in the form of a software functional module. If the integrated module is implemented in the form of a software functional module and sold or used as an independent product, it may also be stored in a computer-readable storage medium.

[0138] The storage medium mentioned above can be a read-only memory, a magnetic disk or an optical disk, etc.

[0139] The preferred embodiments of the present invention disclosed above are only used to help illustrate the present invention. The preferred embodiments do not describe all the details in detail, nor do they limit the invention to the specific implementation methods described. Obviously, many modifications and changes can be made according to the content of this specification. This specification selects and specifically describes these embodiments in order to better explain the principles and practical applications of the present invention, so that those skilled in the art can understand and use the present invention well. The present invention is limited only by the claims and their full scope and equivalents.

Claims

1. A multi-tenant network construction method based on cloud resolution. Features: The application steps include: S1. Request service: PrivateZone request service: When accessing PrivateZone, determine whether the VNI of the upstream ECS request is between 1 and 0xFFFFFE. If so, the application layer processes the tenant PrivateZone information based on the VNI, thus completing the request processing of the PrivateZone message. Public network domain name request service, if the intranet domain name is not hit, the public network access process is followed, first saving the intranet user forwarding node information, then constructing a Vxlan tunnel by encapsulating VNI=0xFFFFFF, accessing the public recursive server through the next hop, and obtaining the final result; S2. Response service: When PrivateZone responds to the service, the application layer obtains the tenant domain name record set based on the VNI information, determines whether the VNI is between 1 and 0xFFFFFE, and searches for the tenant's intranet domain name information based on the corresponding VNI information. If the intranet domain name is matched, the request is completed and the response message is directly encapsulated and returned; When responding to the public domain name service, the IDNS node receives the complete VXLAN response message from the device interface and processes it according to the original protocol stack to determine whether the VNI is equal to 0xFFFFFF. It then finds the requesting user in the intranet by searching the previously saved forwarding node information, encapsulates the response message of the intranet domain name, and returns it to the requesting user, thus completing the processing of the public domain name. The public domain name response service in S2 includes the following application steps: After receiving the complete VXLAN response message from the device interface, the IDNS node processes the network data according to the original protocol stack, including the layer 2 MAC, layer 3 IP, and layer 4 UDP network data of the underlay network; The Underlay four-layer UDP protocol module processes the pcb context information obtained through the destination port 4789, and then obtains the vxlan message, which enters the vxlan protocol unit module for processing; The Vxlan tunnel is specially processed. According to the VNI of 0xFFFFFF, the vxlan1 tunnel context information is obtained, the receiving device interface is modified to vxlan1, and the mbuf mark is M_VXLANTAG. Then the network protocol stack of the Overlay message is processed. The Layer 2 protocol receiving unit module determines that the VNI is 0xFFFFFF and does not perform special processing, and directly delivers it to the Layer 3 protocol module. The Layer 3 protocol packet receiving module of the Overlay message performs an IP protocol validity check and then enters the Layer 4 UDP unit module for processing. The PCB context created in the public domain name request logic is hit through the five-tuple information. The posix processing module of the overlay message will judge that it is VNI 0xFFFFFF and will not perform any special processing; The socket unit processing module delivers the complete data of recvbuf to the application layer, directly processes the application layer DNS information, obtains the upstream request information, sends the public network response information to the tenant ECS, and completes the processing of the public network domain name response.

2. According to claim 1, a multi-tenant network construction method based on cloud resolution, Features: The PrivateZone request service in S1 includes the following application steps: Complete the PrivateZone configuration update; When accessing PrivateZone, the VM constructs a DNS request message and encapsulates the vxlan message through the underlay network between the compute nodes and network element nodes within the region to reach the device node IDNS that provides the cloud resolution PrivateZone service. The device node IDNS obtains the vxlan message and sends it to the vxlan protocol unit module for processing; Special processing is performed on the Vxlan tunnel. Only two tunnels, vxlan0 and vxlan1, are created. The initial VNI of the vxlan0 tunnel is equal to 0, and the remote vtep IP is 0.0.0.

0. The vxlan0 tunnel processes the domain name query service of the ECS of all upstream tenants, that is, the VNI is between 1 and 0xFFFFFE. Determine that the VNI of the upstream ECS request is between 1 and 0xFFFFFE. After hitting the Vxlan0 tunnel, change the packet receiving device interface to vxlan0 and perform a validity check on the vxlan0 device interface. The network protocol stack processes the Overlay message. The Layer 2 unit module processes and determines the M_VXLANTAG mark and saves the Layer 2 source MAC of the Overlay to mbuf for response message encapsulation. The POSIX processing module of the Overlay message saves the MAC address and VNI information to the front of the recv buffer of the application layer socket according to the flag M_VXLANTAG; The socket unit processing module delivers the complete data of recvbuf to the application layer. The application layer obtains the tenant PrivateZone information based on the VNI, thus completing the request processing of the PrivateZone message.

3. According to claim 2, a multi-tenant network construction method based on cloud resolution, Features: The public domain name request service in S1 includes the following application steps: Complete the PrivateZone configuration update; When accessing PrivateZone, the VM constructs a DNS request message and encapsulates the vxlan message through the underlay network between the compute nodes and network element nodes within the region to reach the device node IDNS that provides the cloud resolution PrivateZone service. After receiving the complete VXLAN message from the device interface, the DNS node forwards it to the public network domain name request unit module for processing; The public domain name request unit module processes and makes a mapping association between the downstream DNS ID and the upstream DNS ID for processing the response message, and then calls the socket's sendto function to send the message; The overlay inner layer message first receives the socket sendbuf data in the POSIX module, extracts the VNI and MAC information according to the private data structure, determines that the VNI is equal to 0xFFFFFF, and enters the processing of the next protocol module; The Overlay UDP protocol sending module processes and determines whether the tag M_VXLANTAG exists and combines it with VNI, then directly traverses the global address interface, obtains the interface name "vxlan1" and local address, and saves the sending device interface vxlan1; The Overlay IP protocol sending module processes and determines the mark M_VXLANTAG, then directly uses the device interface and route obtained by the upper layer protocol module and skips the routing module; The physical link of Overlay is sent, and the mark M_VXLANTAG is judged. If it exists, the trasmit interface is directly called to enter the sending module of the vxlan protocol; The sending module of the Vxlan protocol processes, obtains the remote vtep IP of the underlay, encapsulates the vxlan protocol module with VNI 0xFFFFFF, generates the source port, and performs RSS check to ensure that the response message hits the current network card queue thread and the destination port 4789 to encapsulate the underlay udp module, and then enters the processing of the next module; The Underlay IP protocol module processes and selects routes according to the original logic of the TCP / IP protocol stack, including supporting layer 2 message ARP learning encapsulation. This completes the processing of public domain name request messages.

4. According to the method for building a multi-tenant network based on cloud resolution in claim 1, Features: The PrivateZone response service in S2 includes the following application steps: After the application layer obtains the tenant domain name record set based on the VNI information, it encapsulates the DNS response message and then calls the socket's sendto function to send the message. The overlay inner message first receives the socket sendbuf data in the POSIX module, and extracts the VNI and MAC information according to the pre-defined private data structure. If the VNI is between 1 and 0xFFFFFE, the mbuf is marked with M_VXLANTAG and the MAC address and VNI information are saved. The length of the private data is subtracted from the length of the sent data, and the next protocol module is processed. The Overlay UDP protocol sending module processes and determines whether the M_VXLANTAG tag exists and combines it with the VNI interval, then directly traverses the global address interface, obtains the interface name "vxlan0" and the local address, and saves the sending device interface vxlan0; The Overlay IP protocol sending module processes and determines the mark M_VXLANTAG, then directly uses the device interface and routing module obtained by the upper layer protocol module, skipping the routing module; Overlay Layer 2 protocol sending module processes and determines the mark M_VXLANTAG, then directly uses the MAC address saved by the upper-layer protocol module to encapsulate the destination MAC, and uses the device interface information obtained by the upper-layer protocol module to directly encapsulate the source MAC. The protocol type encapsulates IPv4 or IPv6 according to the family; The physical link of Overlay is sent, and the mark M_VXLANTAG is judged. If it exists, the trasmit interface is directly called to enter the sending module of the vxlan protocol; The sending module of the Vxlan protocol processes, obtains tunnel information according to the context of the vxlan0 interface, searches the vxlan mapping table according to the inner destination mac of the Overlay to obtain the remote vtep IP of the underlay, encapsulates the vxlan protocol module according to the VNI saved in the mbuf, randomly generates the source port and destination port 4789 to encapsulate the underlay udp module, encapsulates the underlay IP module according to the obtained IP information, deletes the mark M_VXLANTAG, and then enters the processing of the next module; The Underlay IP protocol module processes and selects routes according to the original logic of the TCP / IP protocol stack, including supporting the ARP learning encapsulation of the Layer 2 message. This completes the response processing of the PrivateZone message.

5. According to claim 2, a multi-tenant network construction method based on cloud resolution, Features: The vxlan1 tunnel initialization VNI is 0xFFFFFF; the remote vtep IP is the OverlayIP of the SGW device issued through configuration, and the vxlan1 tunnel is responsible for processing the network protocol processing of the forwarding domain name.

6. According to claim 3, a multi-tenant network construction method based on cloud resolution, Features: The message sending length is equal to the sum of the length of the private data and the length of the DNS message.

7. According to claim 1, a multi-tenant network construction method based on cloud resolution, Features: The data length of the delivery application layer is equal to the sum of the length of the placeholder private data and the length of the delivery original data.

8. According to claim 4, a multi-tenant network construction method based on cloud resolution, Features: The Overlay IP protocol sending module can directly skip the routing module during processing.

9. A multi-tenant network construction device based on cloud resolution. It is characterized in that include: S1. Request service module: The PrivateZone request service module is used to determine whether the VNI of the upstream ECS request is between 1 and 0xFFFFFE when accessing the PrivateZone. If so, the application layer processes the tenant's PrivateZone information based on the VNI, completing the request processing of the PrivateZone message. The public domain name request service module is used to determine whether the VNI is equal to 0xFFFFFF when accessing the public domain name. If so, the public domain name request message is processed; S2, response service module: The PrivateZone response service module is used to process the application layer and obtain the tenant domain name record set according to the VNI information, and then determine whether the VNI is between 1 and 0xFFFFFE. If so, the response processing of the PrivateZone message is completed; The public domain name response service module is used to process the complete VXLAN response message received from the IDNS node from the device interface according to the original protocol stack to determine whether the VNI is equal to 0xFFFFFF. If the public domain name response is completed, the following application steps are included: After receiving the complete VXLAN response message from the device interface, the IDNS node processes the network data according to the original protocol stack, including the layer 2 MAC, layer 3 IP, and layer 4 UDP network data of the underlay network; The Underlay four-layer UDP protocol module processes the pcb context information obtained through the destination port 4789, and then obtains the vxlan message, which enters the vxlan protocol unit module for processing; The Vxlan tunnel is specially processed. According to the VNI of 0xFFFFFF, the vxlan1 tunnel context information is obtained, the receiving device interface is modified to vxlan1, and the mbuf mark is M_VXLANTAG. Then the network protocol stack of the Overlay message is processed. The Layer 2 protocol receiving unit module determines that the VNI is 0xFFFFFF and does not perform special processing, and directly delivers it to the Layer 3 protocol module. The Layer 3 protocol packet receiving module of the Overlay message performs an IP protocol validity check and then enters the Layer 4 UDP unit module for processing. The PCB context created in the public domain name request logic is hit through the five-tuple information. The posix processing module of the overlay message will judge that it is VNI 0xFFFFFF and will not perform any special processing; The socket unit processing module delivers the complete data of recvbuf to the application layer, directly processes the application layer DNS information, obtains the upstream request information, sends the public network response information to the tenant ECS, and completes the processing of the public network domain name response.