Domain name resolution method and device

By deploying the domain name resolution process on the physical machine where the cloud server is located, the problems of high complexity and slow scaling of the domain name resolution system in the existing technology are solved, and efficient domain name resolution services are achieved.

CN116112466BActive Publication Date: 2025-09-16ALIBABA (CHINA) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211313629.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-10-25
Publication Date
2025-09-16
Estimated Expiration
2042-10-25

AI Technical Summary

Technical Problem

The domain name resolution system in the existing technology has high deployment complexity and high cost, and has slow expansion and contraction speed. It is difficult to meet the domain name resolution requests of a large number of cloud servers, and the registration and destruction speed of cloud servers is slow.

Method used

The domain name resolution process is implemented directly on the physical machine where the cloud server is located. By deploying the domain name resolution process and device query service in each virtual machine monitor, domain name resolution is performed directly inside the physical machine, avoiding the deployment of traditional local-authoritative resolution clusters.

Benefits of technology

It reduces the deployment complexity and cost of the domain name resolution system, improves the speed and efficiency of scaling, and can meet the domain name resolution requests of a large number of cloud servers.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116112466B_ABST
    Figure CN116112466B_ABST
Patent Text Reader

Abstract

An embodiment of the present application provides a domain name resolution method and device, which includes: obtaining a domain name resolution request initiated by a first cloud server, wherein the domain name resolution request includes a domain name identifier of a second cloud server. Determine the target device identifier corresponding to the domain name identifier based on the first mapping information stored in the first device. Obtain the target network address corresponding to the domain name identifier, the target network address is determined based on the second mapping information stored in the target device, the target device is the device corresponding to the target device identifier, and the second cloud server is running in the target device. The first cloud server returns the target network address, which is the resolution result corresponding to the domain name resolution request. The method provided by the present application can effectively implement domain name resolution based on the device running the cloud server, without the need for deployment and architecture of the resolution server, and thus can effectively reduce the deployment complexity of the domain name resolution system.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present application relate to computer technology, and in particular to a domain name resolution method and apparatus. Background Art

[0002] Domain name resolution refers to the conversion between domain names and IP (Internet Protocol) addresses. Domain name resolution can facilitate access to websites through domain names.

[0003] In the prior art, when performing domain name resolution, an authoritative DNS (Domain Name System) server and a local DNS server are usually deployed. When a domain name resolution request is received, the local DNS server is first searched for the IP address corresponding to the domain name. If the local DNS server cannot find the IP address, the authoritative DNS server is searched to resolve the domain name.

[0004] However, the network architecture of deploying local DNS servers and authoritative DNS servers will lead to a high level of complexity in the deployment of the domain name resolution system. Summary of the Invention

[0005] The embodiments of the present application provide a domain name resolution method and apparatus to overcome the high deployment complexity of the domain name resolution system.

[0006] In a first aspect, an embodiment of the present application provides a domain name resolution method, comprising:

[0007] Obtaining a domain name resolution request initiated by the first cloud server, wherein the domain name resolution request includes a domain name identifier of the second cloud server;

[0008] Determining a target device identifier corresponding to the domain name identifier according to first mapping information stored in the first device;

[0009] Obtaining a target network address corresponding to the domain name identifier, where the target network address is determined based on second mapping information stored in a target device, the target device being the device corresponding to the target device identifier, and the second cloud server running on the target device;

[0010] The target network address is returned to the first cloud server, where the target network address is the resolution result corresponding to the domain name resolution request.

[0011] In a second aspect, an embodiment of the present application provides a domain name resolution device, including:

[0012] An acquisition module, configured to acquire a domain name resolution request initiated by the first cloud server, wherein the domain name resolution request includes a domain name identifier of the second cloud server;

[0013] a determination module, configured to determine a target device identifier corresponding to the domain name identifier based on first mapping information stored in the first device;

[0014] The acquisition module is further configured to acquire a target network address corresponding to the domain name identifier, where the target network address is determined based on second mapping information stored in a target device, the target device being the device corresponding to the target device identifier, and the second cloud server running on the target device;

[0015] The transmission module is used to return the target network address to the first cloud server, where the target network address is the resolution result corresponding to the domain name resolution request.

[0016] In a third aspect, an embodiment of the present application provides a domain name resolution device, including:

[0017] Memory, used to store programs;

[0018] A processor is used to execute the program stored in the memory. When the program is executed, the processor is used to execute the method described in the first aspect and any one of the various possible designs of the first aspect.

[0019] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium comprising instructions, which, when executed on a computer, enables the computer to execute the method described in the first aspect and any one of the various possible designs of the first aspect.

[0020] In a fifth aspect, an embodiment of the present application provides a computer program product, including a computer program, which, when executed by a processor, implements the method described in the first aspect and any of the various possible designs of the first aspect.

[0021] A domain name resolution method and apparatus provided in an embodiment of the present application can achieve effective domain name resolution based on a device running a cloud server by storing first mapping information corresponding to a domain name and a device identifier in a first device, and storing second mapping information corresponding to a domain name and a network address in the first device, without the need for deployment and architecture of a resolution server, thereby effectively reducing the deployment complexity of the domain name resolution system. BRIEF DESCRIPTION OF THE DRAWINGS

[0022] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, a brief introduction will be given below to the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0023] Figure 1 Schematic diagram of the DNS server architecture for domain name resolution;

[0024] Figure 2 A schematic diagram of the architecture of the domain name resolution system provided in an embodiment of the present application;

[0025] Figure 3 A flowchart of the domain name resolution system provided in an embodiment of the present application;

[0026] Figure 4 The process of the domain name resolution method provided in the embodiment of this application Figure 2 ;

[0027] Figure 5 Schematic diagram of the execution process of the domain name resolution method provided in the embodiment of the present application Figure 1 ;

[0028] Figure 6 A schematic diagram of implementing the second mapping information provided in an embodiment of the present application;

[0029] Figure 7 The process of the domain name resolution method provided in the embodiment of this application Figure 3 ;

[0030] Figure 8 Schematic diagram of the execution process of the domain name resolution method provided in the embodiment of the present application Figure 2 ;

[0031] Figure 9 The process of the domain name resolution method provided in the embodiment of this application Figure 4 ;

[0032] Figure 10 Schematic diagram of the execution process of the domain name resolution method provided in the embodiment of the present application Figure 3 ;

[0033] Figure 11 A schematic diagram of the structure of a domain name resolution device provided in an embodiment of the present application;

[0034] Figure 12 A schematic diagram of the hardware structure of the domain name resolution device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0035] To make the purpose, technical solutions, and advantages of the embodiments of this application more clear, the technical solutions in the embodiments of this application will be clearly and completely described below in conjunction with the drawings in the embodiments of this application. Obviously, the described embodiments are part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.

[0036] In order to better understand the technical solution of this application, the relevant technologies involved in this application are further introduced in detail below.

[0037] A domain name is a name for a computer or group of computers on the Internet, consisting of a string of names separated by dots. It is used to locate and identify computers during data transmission. Because IP addresses are difficult to remember and fail to reveal the name and nature of the address organization, domain names were designed. DNS is used to map domain names to IP addresses, making it easier for users to access the Internet without having to remember machine-readable IP addresses.

[0038] The conversion between domain names and IP addresses is called domain name resolution. In one application scenario, for example, a public cloud may provide private domain name resolution services. Private domain names are domain names accessible only within a private network. For example, a customer might access a cloud server with the ID "abc" using a domain name like "abc.ecs.local." This implementation requires domain name resolution to determine the IP address corresponding to the domain name. Using a private domain name to access a cloud server avoids the issue of private IP addresses changing when the cloud server restarts, thereby reducing the complexity of application software deployment and lowering resource operation and maintenance costs.

[0039] The following can be combined Figure 1 This paper introduces the implementation of domain name resolution in current related technologies. Figure 1 Schematic diagram of the implementation of the DNS server architecture for domain name resolution.

[0040] First of all, Figure 1 The regions and AZs (Availability Zones) shown in the figure are used for explanation.

[0041] A Region can be understood as a geographical area, such as Asia or North America. An AZ refers to a fault isolation domain. A Region can contain multiple AZs. While physically isolated, they have intranet connectivity, so failures in one AZ are not affected by failures in other AZs. This division ensures AZ independence while providing low-cost, low-latency network connectivity.

[0042] For example, Figure 1 In the illustration, it is assumed that there are regions 1 and 2, and region 1 includes AZ1 and AZ2, and region 2 includes AZ2. It can be understood that AZ2 in region 1 and AZ2 in region 2 are two different availability zones.

[0043] In this architecture, the current related technologies deploy a local resolution cluster in each AZ, which includes multiple local DNS servers. Figure 1 In the diagram, multiple local DNS servers are deployed within AZ1 and AZ2. These local DNS servers, also known as recursive resolvers, are responsible for receiving user queries for arbitrary domain names, querying authoritative resolvers, and returning the results to the user. The local DNS servers can cache the results to avoid repeated upward queries.

[0044] In addition, an authoritative resolution cluster is deployed in each region, which includes multiple authoritative DNS servers. Figure 1 In the diagram, multiple authoritative DNS servers are deployed in both Area 1 and Area 2. An authoritative DNS server is a server authorized by the upper level to resolve domain names.

[0045] and in Figure 1 In the example, a site-level global domain name resolution management and control system is deployed for multiple regions, which is used to perform global domain name resolution management.

[0046] Furthermore, users can register cloud servers on the cloud platform. A cloud server is equivalent to a virtual server, containing basic computing components such as CPU, memory, operating system, network configuration, and disk. It is understood that multiple physical machines can exist in each AZ, and multiple cloud servers can be registered on a physical machine. Cloud servers are also called instances. It is understood that through cloud servers, users can quickly create or release multiple cloud servers without having to acquire hardware.

[0047] For example, reference Figure 1 It is certain that in Figure 1 As shown, there are multiple cloud servers inside each AZ. A cloud server inside an AZ can be registered on one physical machine or on multiple physical machines, which is not limited in this embodiment.

[0048] In the above introduction Figure 1 Based on the architecture of the cloud server, the related implementation when the cloud server is newly built is explained first.

[0049] When a user creates a new cloud server, the domain name resolution management and control system will find the authoritative resolution cluster for the region corresponding to the cloud server and add the A record and / or AAAA record of the domain name to the authoritative resolution cluster.

[0050] When a domain name is pointed to an IPv4 address, an A (Address) record needs to be added. The A record is used to indicate the IPv4 address corresponding to the domain name. And when a domain name is pointed to an IPv6 address, an AAAA record needs to be added. The AAAA record is used to indicate the IPv6 address corresponding to the domain name.

[0051] Also, when the cloud server is released or shut down, the domain name resolution management and control system will find the authoritative resolution cluster of the area corresponding to the cloud server and delete the A record and AAAA record corresponding to the domain name of the cloud server in the authoritative resolution cluster.

[0052] And, when the cloud server requests to resolve a domain name, for example Figure 1 If the second cloud server in AZ1 requests to resolve a domain name, the domain name resolution control system will first query the local resolution cluster in AZ1.

[0053] If there is no cache hit in the local resolution cluster in AZ1, the local resolution cluster in AZ1 queries the authoritative resolution cluster in zone 1 to obtain the A record and / or AAAA record corresponding to the domain name in the authoritative resolution cluster in zone 1, returns the query result to the requester, and caches the query result in the local resolution cluster in AZ1.

[0054] Alternatively, if a cache hit is found in the local resolution cluster within AZ1, the A record and / or AAAA record corresponding to the domain name recorded in AZ1 is directly returned to the requester.

[0055] The local-authoritative centralized domain name resolution system described above has the following drawbacks:

[0056] 1. The need to deploy a dedicated local resolution cluster in each AZ and a dedicated authoritative resolution cluster in each region results in high costs and deployment complexity.

[0057] When scaling is needed, corresponding adjustments must be made for each AZ and each region, resulting in larger scaling granularity and slower scaling speed.

[0058] 2. The bandwidth and QPS (queries per second) of the local resolution cluster in each AZ must meet the domain name resolution requests from a large number of cloud servers within the AZ. The current deployment method has the problem of low request bandwidth, which makes it difficult to meet the domain name resolution requests from a large number of cloud servers.

[0059] 3. When a new cloud server is created, the domain name resolution control system must distribute the A record and / or AAAA record corresponding to the cloud server's domain name to all authoritative resolution clusters in the region corresponding to the cloud server. After all records are successfully distributed, the authoritative resolution clusters return a successful delivery feedback message to the domain name resolution control system. This process often takes a considerable amount of time, for example, minutes.

[0060] In addition, when the cloud server is shut down or released, the domain name resolution management and control system needs to delete the domain name and corresponding records in all authoritative resolution clusters in the area corresponding to the cloud server, and also needs to timeout and eliminate the domain name and corresponding records in the local resolution clusters in each AZ in the area. This process also takes a lot of time, usually in minutes.

[0061] That is to say, the current related technologies have the problem of slow registration and destruction of cloud servers and low efficiency.

[0062] In response to the problems in the related technologies introduced above, this application proposes the following technical ideas: Because cloud servers are created and destroyed relatively frequently, the corresponding correspondence between the domain names of cloud servers does not actually need to be persistent for a long time. Therefore, this application no longer uses the traditional local-authoritative resolution cluster, but instead deploys the domain name resolution process inside each physical machine, that is, directly implements domain name resolution on the physical machine equipped with the cloud server, so as to avoid the need to build a resolution cluster and overcome the related problems introduced above.

[0063] Describe the system architecture in this application. Figure 2 A schematic diagram of the architecture of the domain name resolution system provided in an embodiment of the present application.

[0064] like Figure 2 As shown, there can be multiple devices in each AZ. For example, there are devices 1 and 2 in AZ1, and device 3 in AZ2. The devices here can be understood as physical machines. When users register for a cloud server, they register with the physical machine.

[0065] Each device runs a hypervisor, also known as a virtual machine monitor (VMM). A hypervisor is software, firmware, or hardware used to create and execute virtual machines. The computer used by the hypervisor to execute one or more virtual machines is called the host machine, or the physical machine (or device) mentioned in this embodiment. These virtual machines are called guest machines, or the cloud servers mentioned in this embodiment.

[0066] Therefore, the virtual machine monitor in this embodiment can be used to manage the cloud server in the physical machine. Figure 2 What is certain is that each virtual machine monitor has a domain name resolution process, a device query service, and an IP query service.

[0067] The domain name resolution process is used to perform data transmission and data processing operations related to domain name resolution. The device query service is used to provide device services for querying the corresponding domain name, and the IP query service is used to provide device services for querying the IP address corresponding to the domain name.

[0068] based on Figure 2 It is certain that in this embodiment, the domain name resolution related services are deployed inside the physical machine, thereby effectively avoiding the need to build a resolution cluster.

[0069] Based on the above introduction, the domain name resolution method provided by this application is described in detail below in conjunction with specific embodiments. Prior to this introduction, it should be noted that the domain name resolution method provided by this application can be applied to a first device, where the first device can be understood as the physical machine described above. In actual implementation, the specific implementation of the physical machine can be selected based on actual needs. Any device that can be used to create and support the operation of a virtual machine can be used as the first device in this embodiment.

[0070] The following combination Figure 3 To explain, Figure 3 A flowchart of the domain name resolution system provided in an embodiment of the present application.

[0071] like Figure 3 As shown, the method includes:

[0072] S301. Obtain a domain name resolution request initiated by a first cloud server, wherein the domain name resolution request includes a domain name identifier of a second cloud server.

[0073] In this embodiment, at least one cloud server may be run in the first device, and correspondingly, there are many other devices, similar to the first device, in which at least one cloud server may be run.

[0074] In this embodiment, the first device can obtain a domain name resolution request initiated by the first cloud server. The first cloud server can be, for example, a cloud server in the first device, which means that the cloud server in the first device can initiate the domain name resolution request to the first device. Alternatively, the first cloud server can be a cloud server in another device, which means that the cloud server in the other device requests the first device to process the domain name resolution request.

[0075] And in this embodiment, the domain name resolution request includes the domain name identifier of the second cloud server, that is, the user requests the first cloud server to resolve the domain name corresponding to the second cloud server.

[0076] The second cloud server may be, for example, a cloud server in the first device, meaning that the current first cloud server requests the first device to resolve the domain name of the cloud server in the first device. Alternatively, the second cloud server may be, for example, a cloud server in another device, meaning that the current first cloud server requests the first device to resolve the domain name of the cloud server in the other device.

[0077] In the actual implementation process, the cloud servers in which the first cloud server and the second cloud server are specifically located can be selected based on actual needs. Correspondingly, the cloud server in which device initiates the domain name resolution request and the cloud server in which device the resolution is performed can all be selected based on actual needs.

[0078] S302: Determine a target device identifier corresponding to the domain name identifier according to first mapping information stored in the first device.

[0079] In this embodiment, the first mapping information is stored in the first device, wherein the first mapping information may include a mapping relationship between a domain name identifier and its corresponding target device identifier. When there are multiple domain name identifiers, there are correspondingly multiple mapping relationships.

[0080] In a possible implementation, the target device identifier corresponding to the domain name identifier of the second cloud server is the device identifier of the device that creates the second cloud server.

[0081] The domain name resolution request in this embodiment includes the domain name identifier of the second cloud server, so the first device can determine the target device identifier corresponding to the domain name identifier of the second cloud server according to the first mapping information stored in the first device.

[0082] The device identifier may be, for example, the IP address of the device, or other identification information. As long as the device identifier can uniquely indicate the device, this embodiment does not impose any limitation on this.

[0083] S303: Obtain a target network address corresponding to the domain name identifier, where the target network address is determined based on second mapping information stored in the target device. The target device is the device corresponding to the target device identifier, and a second cloud server is running in the target device.

[0084] The target device identifier determined in this embodiment may indicate the target device. It is understood that the target device may be the first device in this embodiment or another device. However, in either case, the devices are similar, and it is understood that the second cloud server is running in the target device.

[0085] In one possible implementation, second mapping information is stored in the target device. The second mapping information may include mapping relationships between multiple domain name identifiers and their corresponding network addresses. When there are multiple domain name identifiers, there are correspondingly multiple mapping relationships. The network address here may be, for example, an intranet IP address, or the implementation method of the network address may be selected based on actual needs.

[0086] Therefore, in this embodiment, after determining the target device identifier, the target device indicated by the target device identifier can be determined first, and then the target device determines the target network address corresponding to the domain name identifier based on the second mapping information stored therein, and then the first device in this embodiment can obtain the target network address corresponding to the domain name identifier.

[0087] S304. Return the target network address to the first cloud server, where the target network address is the resolution result corresponding to the domain name resolution request.

[0088] In this embodiment, the domain name resolution request is used to request resolution of the network address corresponding to the domain name of the second cloud server, and the above-determined target network address is actually the request result corresponding to the domain name resolution request.

[0089] Therefore, after determining the target network address, the first device can return the target network address to the first cloud server. In one possible implementation, the first device can, for example, transmit the target network address to the first cloud server via a virtual machine monitor running on the first device, thereby effectively enabling processing by the first cloud server.

[0090] The domain name resolution method provided by the embodiment of the present application includes: obtaining a domain name resolution request initiated by the first cloud server, wherein the domain name resolution request includes the domain name identifier of the second cloud server. According to the first mapping information stored in the first device, the target device identifier corresponding to the domain name identifier is determined. The target network address corresponding to the domain name identifier is obtained, and the target network address is determined according to the second mapping information stored in the target device. The target device is the device corresponding to the target device identifier, and the second cloud server is running in the target device. The first cloud server returns the target network address, and the target network address is the resolution result corresponding to the domain name resolution request. By storing the first mapping information corresponding to the domain name and the device identifier in the first device, and storing the second mapping information corresponding to the domain name and the network address in the first device, it is possible to effectively implement domain name resolution based on the device running the cloud server without the need for deployment and architecture of the resolution server, thereby effectively reducing the deployment complexity of the domain name resolution system.

[0091] Based on the above embodiments, it can be determined that the first cloud server in this application can be a server running in the first device or a server running in another device. Furthermore, the second cloud server can be a server running in the first device or a server running in another device. Depending on the situation, the corresponding implementation methods also vary to some extent. The following describes the implementation methods for different situations in conjunction with several specific embodiments.

[0092] First, the case where the first cloud server and the second cloud server are both cloud servers in the first device is explained. Specifically, the cloud server in the first device requests resolution of the domain name of another cloud server in the first device.

[0093] The following combination Figures 4 to 6 The domain name resolution method provided in this application is further introduced in detail. Figure 4 The process of the domain name resolution method provided in the embodiment of this application Figure 2 , Figure 5 Schematic diagram of the execution process of the domain name resolution method provided in the embodiment of the present application Figure 1 , Figure 6 A schematic diagram of the implementation of the second mapping information provided in an embodiment of the present application.

[0094] like Figure 4 As shown, the method includes:

[0095] S401. Obtain a domain name resolution request initiated by a first cloud server through a domain name resolution process in a first device.

[0096] In this embodiment, the first cloud server is a cloud server in the first device. Since it is an operation inside the first device, the domain name resolution request initiated by the first cloud server can be obtained, for example, through the domain name resolution process in the first device.

[0097] The domain name resolution request includes the domain name identifier of the second cloud server. In this embodiment, the second cloud server is also the cloud server in the first device.

[0098] For example, combining Figure 5 To understand, Figure 5 In the example of , device 1 can obtain the domain name resolution request initiated by cloud server a through the domain name resolution process. It is assumed that the domain name resolution request is a request to resolve the domain name of cloud server b.

[0099] Among them, cloud server a and cloud server b are both cloud servers in device 1. Cloud server a is equivalent to the first cloud server introduced above, and cloud server b is equivalent to the second cloud server introduced above.

[0100] S402: If the first mapping information stored in the first device includes a first mapping relationship between the domain name identifier and the target device identifier, determine the target device identifier corresponding to the domain name identifier according to the first mapping relationship.

[0101] In this embodiment, after receiving the domain name resolution request, it is necessary to determine the target device identifier corresponding to the domain name identifier according to the first mapping information stored in the first device.

[0102] In one possible implementation, the cloud server in this embodiment is typically created on a device. After creation, the device creating the cloud server can, for example, generate a mapping between the cloud server's domain name and the device identifier, and write this mapping to a central database. When a mapping is needed, the device retrieves the mapping from the central database.

[0103] Therefore, the first mapping information stored in the first device may include the first mapping relationship between the domain name identifier and the target device identifier, or may not include the first mapping relationship.

[0104] In this embodiment, it is necessary to first determine whether the first mapping information stored in the first device includes the first mapping relationship between the domain name identifier and the target device identifier. For example, the first mapping relationship can be expressed as <domain name of cloud server a, device 1>.

[0105] In one possible implementation, if the first mapping information stored by the first device includes the first mapping relationship described above, the target device identifier corresponding to the domain name identifier can be directly determined based on the first mapping relationship stored in the first device. For example, in the example described above, it can be determined that the target device identifier corresponding to the domain name of cloud server a is "Device 1."

[0106] And, the first mapping information may correspond to Figure 5 The device query service in the device query service, for example, may store the first mapping information in a unit corresponding to the device query service, and then query the target device identifier corresponding to the domain name identifier by the device query service.

[0107] In one possible implementation, Figure 5 The device query service can also be understood as a management and control unit in the virtual machine monitor, where the management and control unit is used to determine the device corresponding to the domain name identifier. When determining the target device identifier based on the first mapping information, for example, the first mapping information can be queried through the management and control unit to determine the target device identifier corresponding to the domain name identifier.

[0108] S403: If the first mapping information stored in the first device does not include the first mapping relationship, obtain the first mapping relationship from the central database according to the domain name identifier, and determine the target device identifier corresponding to the domain name identifier according to the first mapping relationship.

[0109] In another possible implementation, if the first mapping information stored in the first device does not include the first mapping relationship described above, it is necessary to obtain the first mapping relationship from the central database.

[0110] For example, a first mapping relationship corresponding to the domain name identifier may be obtained from a central database according to the domain name identifier, and then the target device identifier corresponding to the domain name identifier may be determined according to the first mapping relationship obtained from the central database.

[0111] In actual implementation, for example, a central database could be established for the entire cloud platform, which would then include mappings between devices and domain names across the entire cloud platform. Alternatively, a central database could be established for each AZ, which would then include mappings between devices and domain names across the entire AZ. The specific configuration of the central database can be selected and configured based on actual needs.

[0112] S404: Store the first mapping relationship in the first device to update the first mapping information.

[0113] After obtaining the first mapping relationship from the central database, for example, the first mapping relationship can be stored in the first device, so that the next time the first mapping relationship needs to be accessed, it can be directly obtained from the local of the first device to avoid initiating a request to the central database, thereby effectively reducing data interaction operations.

[0114] S405: Determine the target network address corresponding to the domain name identifier according to the second mapping information stored in the first device.

[0115] Based on the above introduction, it can be determined that the second mapping information is stored in the first device. Then, it is necessary to determine the target network address corresponding to the domain name identifier of the second cloud server according to the second mapping information stored in the first device.

[0116] It should be noted here that each cloud server in this embodiment is created in a certain device, so the network address corresponding to the domain name of this cloud server will only be stored in the device that creates this cloud server.

[0117] For example, you can combine Figure 6 To understand, such as Figure 6 As shown, assuming that cloud server a and cloud server b are both created in device 1, the second mapping information corresponding to device 1 includes the mapping relationship of <domain name of cloud server a, IP1> and the mapping relationship of <domain name of cloud server b, IP1>.

[0118] And, in Figure 6 In the example, assuming that cloud server c and cloud server d are both created in device 2, the second mapping information corresponding to device 2 includes the mapping relationship of <domain name of cloud server c, IP3> and the mapping relationship of <domain name of cloud server c, IP4>.

[0119] It is understandable that the network address corresponding to the domain name of cloud server C cannot be found in the second mapping information in device 1. In other words, the second mapping information in each device only includes the mapping relationship between the cloud server created in the device and its corresponding IP address, which can effectively save storage space in each device.

[0120] Based on the above description, it can be determined that in this embodiment, the target device identifier corresponding to the domain name identifier of the second cloud server is determined based on the first mapping information. The target device identifier corresponding to the domain name of the cloud server is the device identifier of the device that created the cloud server.

[0121] The second cloud server in this embodiment is the cloud server in the first device, that is, the second cloud server is created in the first device, so the target device in this embodiment is actually the first device.

[0122] Furthermore, because the second cloud server is created on the first device, the second mapping information on the first device includes the mapping between the domain name of the second cloud server and its corresponding IP address. Therefore, in this embodiment, the target network address corresponding to the domain name identifier can be determined directly based on the second mapping information stored on the first device.

[0123] Among them, the second mapping information may correspond to Figure 5 The IP query service in the example may be that the second mapping information is stored in a unit corresponding to the IP query service, and then the IP query service queries the target network address corresponding to the domain name identifier.

[0124] In one possible implementation, Figure 5 The IP query service can also be understood as an execution unit in the virtual machine monitor, where the execution unit is used to determine the network address corresponding to the domain name identifier. When determining the target network address corresponding to the domain name identifier based on the second mapping information stored in the first device, for example, the second mapping information can be queried through the execution unit to determine the target network address corresponding to the domain name identifier.

[0125] S406. Return the target network address to the first cloud server, where the target network address is the resolution result corresponding to the domain name resolution request.

[0126] After determining the target network address, the target network address can be returned to the first cloud server. For example, the domain name resolution process in the virtual machine monitor in the first device can be used to return the target network address to the second cloud server to complete the domain name resolution process.

[0127] For the implementation process introduced in this embodiment, for example, Figure 5 For a complete process introduction, refer to Figure 5 The domain name resolution process in device 1 obtains the domain name resolution request initiated by cloud server a, which is used to request the resolution of the domain name of cloud server b.

[0128] The domain name resolution process can then query the first mapping information through the device query service to determine the target device identifier corresponding to the domain name of cloud server a. In the current example, the target device identifier is the device identifier of device 1.

[0129] The domain name resolution process can then query the second mapping information through the IP query service to determine the target IP address corresponding to the domain name of cloud server a, and return the target IP address to cloud server a to complete the processing of the domain name resolution request.

[0130] The domain name resolution method provided in the embodiment of the present application can effectively implement the domain name resolution process in the device, complete the processing of the domain name resolution request of the cloud server in the device to another cloud server in the device, without relying on the DNS server, thereby effectively reducing the deployment complexity and cost of the domain name resolution service.

[0131] Next, combine Figure 7 and Figure 8 First, the situation in which the first cloud server is the cloud server in the first device and the second cloud server is not the cloud server in the first device is explained. Specifically, the cloud server in the first device requests to resolve the domain name of the cloud server in the other device.

[0132] Figure 7 The process of the domain name resolution method provided in the embodiment of this application Figure 3 , Figure 8 Schematic diagram of the execution process of the domain name resolution method provided in the embodiment of the present application Figure 2 .

[0133] like Figure 7 As shown, the method includes:

[0134] S701. Obtain a domain name resolution request initiated by a first cloud server through a domain name resolution process in a first device.

[0135] SS701 is similar to the above-mentioned S401, except that the second cloud server in this embodiment is a cloud server in a device other than the first device.

[0136] For example, combining Figure 8 To understand, Figure 8 In the example of , device 1 can obtain the domain name resolution request initiated by cloud server a through the domain name resolution process. It is assumed that the domain name resolution request is a request to resolve the domain name of cloud server c.

[0137] Cloud server a is the cloud server in device 1, and is equivalent to the first cloud server described above. Cloud server c is the cloud server in device 2, and is equivalent to the second cloud server described above.

[0138] S702: If the first mapping information stored in the first device includes a first mapping relationship between the domain name identifier and the target device identifier, determine the target device identifier corresponding to the domain name identifier according to the first mapping relationship.

[0139] S703: If the first mapping information stored in the first device does not include the first mapping relationship, obtain the first mapping relationship from the central database according to the domain name identifier, and determine the target device identifier corresponding to the domain name identifier according to the first mapping relationship.

[0140] S704: Store the first mapping relationship in the first device to update the first mapping information.

[0141] Among them, the implementation methods of S702, S703, and S704 are similar to the implementation methods of S402, S403, and S404 introduced above, and will not be repeated here.

[0142] S705: Send a domain name resolution request to the target device, and receive a target network address sent by the target device in response to the domain name resolution request, where the target network address is determined by the target device according to the second mapping information stored therein.

[0143] Based on the above description, it can be determined that the second mapping information in each device only includes the mapping relationship between the cloud server created in the device and its corresponding IP address.

[0144] However, the second cloud server in this embodiment is not created in the first device, so the target network address cannot be queried in the second mapping information in the first device.

[0145] Based on the above description, it can be determined that in this embodiment, the target device identifier corresponding to the domain name identifier of the second cloud server is determined based on the first mapping information. The target device is actually the device that created the second cloud server, so the mapping relationship between the domain name of the second cloud server and the corresponding IP address is actually stored in the second mapping information on the target device.

[0146] Therefore, in this embodiment, a domain name resolution request can be sent to the target device, wherein the target device will respond to the domain name resolution request and query the target network address corresponding to the domain name identifier of the second cloud server according to the second mapping information stored in the target device.

[0147] Afterwards, the target device sends the target network address obtained by the query to the first device to complete the query of the target network address corresponding to the domain name identifier of the second cloud server.

[0148] S706. Return the target network address to the first cloud server, where the target network address is the resolution result corresponding to the domain name resolution request.

[0149] The implementation of S706 is similar to that of S406 and will not be described in detail here.

[0150] For the implementation process introduced in this embodiment, for example, Figure 8 For a complete process introduction, refer to Figure 8 The domain name resolution process in device 1 obtains the domain name resolution request initiated by cloud server a, which is used to request the resolution of the domain name of cloud server c.

[0151] The domain name resolution process can then query the first mapping information through the device query service to determine the target device identifier corresponding to the domain name of cloud server c. In the current example, the target device identifier is the device identifier of device 2.

[0152] Because the target device is device 2, that is, only device 2 stores the IP address corresponding to cloud server C. Therefore, device 1 needs to send the domain name resolution request to device 2 through the domain name resolution process.

[0153] The domain name resolution process in device 2 can then, for example, first query the first mapping information in device 2 through the device query service to determine the target device identifier corresponding to the domain name of cloud server c. In the current example, the target device identifier is the device identifier of device 2. The purpose of performing the device identifier query here is to further ensure the correctness of the domain name resolution request transmission, so as to prevent the situation in which the domain name in the domain name resolution request received by device 2 is not the domain name of the cloud server in device 2 due to data transmission anomalies.

[0154] Device 2 can then query the second mapping information in device 2 through the IP query service to determine the target IP address corresponding to the domain name of cloud server c, and return the target IP address to the domain name resolution process of device 1. The domain name resolution process of device 1 then returns the target IP address to cloud server a, completing the processing of the domain name resolution request.

[0155] And understandably, in Figure 8 In the domain name resolution process shown, the domain name resolution process in device 1 actually plays the role of the local DNS server (or recursive DNS server) described above, while the domain name resolution process in device 2 actually plays the role of the authoritative DNS server described above. Therefore, it can be understood that the technical solution of this application, through the distributed architecture of setting up domain name resolution processes in each physical machine, can effectively implement various domain name resolutions without the need for the architectural deployment of local DNS servers and authoritative DNS servers.

[0156] The domain name resolution method provided in the embodiment of the present application can effectively implement the domain name resolution process in the device, complete the processing of domain name resolution requests of the cloud server in this device to the cloud servers in other devices without relying on the DNS server, thereby effectively reducing the deployment complexity and cost of the domain name resolution service.

[0157] Next, combine Figure 9 and Figure 10 First, the situation where the second cloud server is the cloud server in the first device and the first cloud server is not the cloud server in the first device is explained. This situation specifically means that the cloud server in other devices requests to resolve the domain name of the cloud server in the first device.

[0158] Figure 9 The process of the domain name resolution method provided in the embodiment of this application Figure 4 , Figure 10 Schematic diagram of the execution process of the domain name resolution method provided in the embodiment of the present application Figure 3 .

[0159] like Figure 9 As shown, the method includes:

[0160] S901: Receive, through a domain name resolution process in a first device, a domain name resolution request sent by a domain name resolution process in a second device.

[0161] In this embodiment, the first cloud server is a cloud server in a device other than the first device, and the second cloud server is a cloud server in the first device. This means that the cloud server in the other device requests domain name resolution for the cloud server in the first device. Based on the above description, domain name resolution requests for cloud servers not created in this device must be forwarded to the device that created the cloud server, which then performs the domain name resolution.

[0162] Therefore, in this embodiment, the second device needs to forward the domain name resolution request to the first device, and the first device completes the domain name resolution. Therefore, the first device can receive the domain name resolution request sent by the domain name resolution process in the second device through the domain name resolution process.

[0163] For example, combining Figure 10 To understand, Figure 10 In the example of , device 2 can obtain the domain name resolution request initiated by cloud server c through the domain name resolution process. It is assumed that the domain name resolution request is a request to resolve the domain name of cloud server a.

[0164] The cloud server C is the cloud server in device 2, which is equivalent to the first cloud server described above. The cloud server A is the cloud server in device 1, which is equivalent to the second cloud server described above.

[0165] S902: If the first mapping information stored in the first device includes a first mapping relationship between the domain name identifier and the target device identifier, determine the target device identifier corresponding to the domain name identifier according to the first mapping relationship.

[0166] S903: If the first mapping information stored in the first device does not include the first mapping relationship, obtain the first mapping relationship from the central database according to the domain name identifier, and determine the target device identifier corresponding to the domain name identifier according to the first mapping relationship.

[0167] S904: Store the first mapping relationship in the first device to update the first mapping information.

[0168] Among them, the implementation methods of S902, S903, and S904 are similar to the implementation methods of S402, S403, and S404 introduced above, and will not be repeated here.

[0169] S905: Determine the target network address corresponding to the domain name identifier according to the second mapping information stored in the first device.

[0170] Based on the above description, it can be determined that the second mapping information in each device only includes the mapping relationship between the cloud server created in the device and its corresponding IP address.

[0171] The second cloud server in this embodiment is created in the first device, so the target network address can be queried in the second mapping information in the first device.

[0172] Therefore, in this embodiment, the target network address corresponding to the domain name identifier of the second cloud server can be determined directly based on the second mapping information stored in the first device.

[0173] S906. Send the target network address to the second device, where the target network address is the resolution result corresponding to the domain name resolution request.

[0174] After determining the target network address, the first device can send the target network address to the second device. For example, the first device can send the target network address to the second device through the domain name resolution process. Then the second device can return the target network address to the first cloud server through the domain name resolution process to complete the domain name resolution processing.

[0175] For the implementation process introduced in this embodiment, for example, Figure 10 For a complete process introduction, refer to Figure 10 The domain name resolution process in device 2 obtains the domain name resolution request initiated by cloud server c, which is used to request the resolution of the domain name of cloud server a.

[0176] The domain name resolution process can then query the first mapping information in device 2 through the device query service to determine the target device identifier corresponding to the domain name of cloud server a. In the current example, the target device identifier is the device identifier of device 1.

[0177] Because the target device is device 1, that is, only device 1 stores the IP address corresponding to cloud server a. Therefore, device 2 needs to send the domain name resolution request to device 1 through the domain name resolution process.

[0178] The domain name resolution process in device 1 can then, for example, first query the first mapping information in device 1 through the device query service to determine the target device ID corresponding to the domain name of cloud server a. In the current example, the target device ID is the device ID of device 1. The purpose of performing the device ID query here is to further ensure the correctness of the domain name resolution request transmission, so as to prevent the situation where the domain name in the domain name resolution request received by device 1 is not the domain name of the cloud server in device 1 due to data transmission anomalies.

[0179] Device 1 can then use the IP query service to query the second mapping information in device 1 to determine the target IP address corresponding to the domain name of cloud server a, and return the target IP address to the domain name resolution process of device 2. The domain name resolution process of device 2 then returns the target IP address to cloud server c, completing the processing of the domain name resolution request.

[0180] The domain name resolution method provided in the embodiment of the present application can effectively implement the domain name resolution process in the device, complete the processing of domain name resolution requests of cloud servers in other devices to the cloud server in this device, without relying on the DNS server, thereby effectively reducing the deployment complexity and cost of the domain name resolution service.

[0181] Based on the above introduction, the following describes the relevant processing during the cloud server creation process.

[0182] Assuming that the second cloud server is a cloud server in the first device, that is, the second cloud server is created in the first device. In one possible implementation, the second cloud server can be created in the first device and the domain name identifier of the second cloud server can be obtained. The first device then generates a first mapping relationship between the domain name identifier and the device identifier of the first device and stores the first mapping relationship in a central database.

[0183] When the second cloud server is a cloud server in other devices, its implementation is similar and will not be described here.

[0184] It is understandable that the first mapping relationship is stored in the central database, and then any device can obtain the first mapping relationship from the central database when it needs to query the first mapping relationship. In this embodiment, the mapping relationship between the domain name and the device is stored in the central server, and then each device obtains it from the central server when needed. This is because when processing a domain name resolution request in each device, it needs to query the mapping relationship between the domain name and the device, and the domain name resolution request is arbitrarily initiated by the user. If all the mapping relationships between domain names and devices are stored in each device, it will cause the memory in each device to be too occupied and the utilization rate to be relatively low. In this embodiment, the mapping relationship between the domain name and the device is stored in the central server, and then each device can obtain it on demand. On the one hand, it can save memory space in the device, and on the other hand, it can ensure that each device can access all the mapping relationships between domain names and devices.

[0185] Based on the above introduction, the following will explain the relevant processing during the destruction of the cloud server.

[0186] Assuming that the second cloud server is a cloud server in the first device, that is, the second cloud server was created in the first device. Upon receiving a deregistration request instructing the first device to deregister the second cloud server, the first device may delete the third mapping relationship in the second mapping information, where the third mapping relationship is a mapping relationship between a domain name identifier and a target network address. In other words, the first device deletes the mapping relationship between the domain name and the IP address of the second cloud server.

[0187] Furthermore, the first mapping relationship stored in the central database needs to be deleted.

[0188] At the same time, if the first mapping information in the first device includes the first mapping relationship, the first mapping relationship needs to be deleted in the first mapping information in the first device, and deletion indication information needs to be sent to other devices other than the first device. The deletion indication information is used to instruct other devices to delete the first mapping relationship.

[0189] It is understandable that when a cloud server is destroyed, timely deleting the mapping relationship related to the domain name of the cloud server can effectively save memory space in the device and the central database.

[0190] To sum up, the domain name resolution method provided in this application does not require the deployment of dedicated local resolution clusters and authoritative resolution clusters in each AZ and Region, which can effectively reduce the processing cost and deployment complexity of domain name resolution.

[0191] And in this embodiment, the domain name resolution related servers are deployed on the physical machine that creates the cloud server, which can effectively realize the granularity expansion and contraction of the physical machine, so that the expansion and contraction speed can be fast. At the same time, the domain name resolution process in this application is deployed on each physical machine, which can meet the domain name resolution needs of this physical machine, wherein the request bandwidth and QPS capabilities can grow linearly with the instance scale. And, the domain name resolution process can be understood as the authoritative resolver of the domain names of all cloud servers on the same physical machine, wherein the domain name resolution process and the cloud server can be, for example, the same life cycle. Therefore, the maximum number of cloud servers in a single area can be linearly expanded without an upper limit, and the number of new private domain names per second can also be linearly expanded without going online, so the domain name resolution service can be implemented in a fast and efficient rotation manner. And in the specific implementation process, because of the support of various services in the physical machine, the domain name resolution can be changed from the traditional authoritative resolver querying the pre-configured table to the domain name resolution process calling the dependent service to dynamically obtain it.

[0192] Figure 11 This is a schematic diagram of the structure of the domain name resolution device provided in the embodiment of the present application. Figure 11 As shown, the device 110 includes: an acquisition module 1101 , a determination module 1102 , a transmission module 1103 and a processing module 1104 .

[0193] An acquisition module 1101 is configured to acquire a domain name resolution request initiated by the first cloud server, wherein the domain name resolution request includes a domain name identifier of the second cloud server;

[0194] A determination module 1102 is configured to determine a target device identifier corresponding to the domain name identifier based on first mapping information stored in the first device;

[0195] The acquisition module 1101 is further configured to acquire a target network address corresponding to the domain name identifier, where the target network address is determined based on second mapping information stored in a target device, the target device being the device corresponding to the target device identifier, and the second cloud server running on the target device;

[0196] The transmission module 1103 is used to return the target network address to the first cloud server, where the target network address is the resolution result corresponding to the domain name resolution request.

[0197] In one possible design, the acquisition module 1101 is specifically configured to:

[0198] If the target device is the first device, determining the target network address corresponding to the domain name identifier according to the second mapping information stored in the first device; or

[0199] If the target device is not the first device, the domain name resolution request is sent to the target device, and the target network address sent by the target device in response to the domain name resolution request is received, where the target network address is determined by the target device based on the second mapping information stored therein.

[0200] In one possible design, the determining module 1102 is specifically configured to:

[0201] If the first mapping information stored in the first device includes a first mapping relationship between the domain name identifier and the target device identifier, determining the target device identifier corresponding to the domain name identifier according to the first mapping relationship; or

[0202] If the first mapping information stored in the first device does not include the first mapping relationship, the first mapping relationship is obtained from a central database according to the domain name identifier, and the target device identifier corresponding to the domain name identifier is determined according to the first mapping relationship.

[0203] In one possible design, the processing module 1104 is configured to:

[0204] After acquiring the first mapping relationship from the central database according to the domain name identifier, the first mapping relationship is stored in the first device to update the first mapping information.

[0205] In one possible design, the second cloud server is a cloud server in the first device;

[0206] The processing module 1104 is further configured to:

[0207] Before determining the target device identifier corresponding to the domain name identifier according to the first mapping information stored in the first device, creating the second cloud server in the first device and obtaining the domain name identifier of the second cloud server;

[0208] Generating a first mapping relationship between the domain name identifier and the device identifier of the first device;

[0209] The first mapping relationship is stored in the central database.

[0210] In one possible design, the second cloud server is a cloud server in the first device;

[0211] The processing module 1104 is further configured to:

[0212] When a deregistration request for instructing to deregister the second cloud server in the first device is obtained, deleting a third mapping relationship in the second mapping information, the third mapping relationship being a mapping relationship between the domain name identifier and the target network address;

[0213] Deleting the first mapping relationship stored in the central database;

[0214] The first mapping relationship is deleted from the first mapping information, and deletion indication information is sent to other devices except the first device, where the deletion indication information is used to instruct the other devices to delete the first mapping relationship.

[0215] In one possible design, a virtual machine monitor runs in the first device, wherein the virtual machine monitor is used to manage the at least one cloud server, and the virtual machine monitor includes a domain name resolution process.

[0216] In one possible design, the first cloud server is a cloud server in the first device.

[0217] The acquisition module 1101 is specifically used for:

[0218] Obtain a domain name resolution request initiated by the first cloud server through the domain name resolution process in the first device.

[0219] In one possible design, the first cloud server is a cloud server in the second device;

[0220] The acquisition module 1101 is specifically used for:

[0221] The domain name resolution process in the first device receives a domain name resolution request sent by the domain name resolution process in the second device.

[0222] In one possible design, the virtual machine monitor further includes a management and control unit;

[0223] The determining module 1104 is specifically configured to:

[0224] The first mapping information is queried through the management and control unit to determine the target device identifier corresponding to the domain name identifier.

[0225] In one possible design, the virtual machine monitor further includes an execution unit;

[0226] The acquisition module 1101 is specifically used for:

[0227] The second mapping information is queried by the execution unit to determine the target network address corresponding to the domain name identifier.

[0228] The device provided in this embodiment can be used to execute the technical solution of the above method embodiment. Its implementation principle and technical effects are similar and will not be described in detail in this embodiment.

[0229] Figure 12 A schematic diagram of the hardware structure of the domain name resolution device provided in the embodiment of the present application is shown as follows: Figure 12 As shown, the domain name resolution device 120 of this embodiment includes: a processor 1201 and a memory 1202;

[0230] Memory 1202, for storing computer-executable instructions;

[0231] The processor 1201 is configured to execute computer-executable instructions stored in the memory to implement the various steps of the domain name resolution method in the above embodiment. For details, please refer to the relevant description in the above method embodiment.

[0232] Optionally, the memory 1202 may be independent or integrated with the processor 1201 .

[0233] When the memory 1202 is independently provided, the domain name resolution device further includes a bus 1203 for connecting the memory 1202 and the processor 1201 .

[0234] An embodiment of the present application further provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions. When a processor executes the computer-executable instructions, the domain name resolution method performed by the domain name resolution device as described above is implemented.

[0235] In the several embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of the modules is merely a logical function division. In actual implementation, there may be other division methods, such as multiple modules can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interface, device or module, which can be electrical, mechanical or other forms.

[0236] The above-mentioned integrated module implemented in the form of a software functional module can be stored in a computer-readable storage medium. The above-mentioned software functional module is stored in a storage medium and includes a number of instructions for causing a computer device (which can be a personal computer, server, or network device, etc.) or a processor to perform some steps of the method described in various embodiments of the present application.

[0237] It should be understood that the processor described above may be a central processing unit (CPU), other general-purpose processors, digital signal processors (DSP), or application-specific integrated circuits (ASICs). A general-purpose processor may be a microprocessor or any conventional processor. The steps of the method disclosed in the present invention may be directly executed by a hardware processor or by a combination of hardware and software modules within the processor.

[0238] The memory may include a high-speed RAM memory, and may also include non-volatile storage NVM, such as at least one disk memory, and may also be a USB flash drive, a mobile hard disk, a read-only memory, a magnetic disk or an optical disk.

[0239] The bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus. Buses can be classified into address buses, data buses, and control buses. For ease of illustration, the buses in the drawings of this application are not limited to just one bus or just one type of bus.

[0240] The storage medium may be implemented by any type of volatile or non-volatile memory device, or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk. The storage medium may be any available medium that can be accessed by a general-purpose or special-purpose computer.

[0241] Those skilled in the art will appreciate that all or part of the steps in the above-described method embodiments can be implemented using hardware associated with program instructions. The aforementioned program can be stored in a computer-readable storage medium. When executed, the program performs the steps of the above-described method embodiments. The aforementioned storage medium includes various media capable of storing program code, such as ROM, RAM, magnetic disks, or optical disks.

[0242] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some or all of the technical features therein. These modifications or replacements do not deviate the essence of the corresponding technical solutions from the scope of the technical solutions of the embodiments of the present application.

Claims

1. A domain name resolution method, characterized in that: Applied to a first device, where at least one cloud server is running, the method includes: Obtaining a domain name resolution request initiated by the first cloud server, wherein the domain name resolution request includes a domain name identifier of the second cloud server; Determining a target device identifier corresponding to the domain name identifier according to first mapping information stored in the first device; Obtaining a target network address corresponding to the domain name identifier, where the target network address is determined based on second mapping information stored in a target device, the target device being the device corresponding to the target device identifier, and the second cloud server running on the target device; The target network address is returned to the first cloud server, where the target network address is the resolution result corresponding to the domain name resolution request.

2. The method according to claim 1, characterized in that The obtaining of the target network address corresponding to the domain name identifier includes: If the target device is the first device, determining the target network address corresponding to the domain name identifier according to the second mapping information stored in the first device; or If the target device is not the first device, the domain name resolution request is sent to the target device, and the target network address sent by the target device in response to the domain name resolution request is received.

3. The method according to claim 1, characterized in that The determining, according to the first mapping information stored in the first device, the target device identifier corresponding to the domain name identifier includes: If the first mapping information stored in the first device includes a first mapping relationship between the domain name identifier and the target device identifier, determining the target device identifier corresponding to the domain name identifier according to the first mapping relationship; or If the first mapping information stored in the first device does not include the first mapping relationship, the first mapping relationship is obtained from a central database according to the domain name identifier, and the target device identifier corresponding to the domain name identifier is determined according to the first mapping relationship.

4. The method according to claim 3, characterized in that After acquiring the first mapping relationship from the central database according to the domain name identifier, the method further includes: The first mapping relationship is stored in the first device to update the first mapping information.

5. The method according to claim 3, characterized in that The second cloud server is a cloud server in the first device; Before determining the target device identifier corresponding to the domain name identifier based on the first mapping information stored in the first device, the method further includes: Creating the second cloud server in the first device and obtaining a domain name identifier of the second cloud server; Generating a first mapping relationship between the domain name identifier and the device identifier of the first device; The first mapping relationship is stored in the central database.

6. The method according to any one of claims 3 to 5, characterized in that: The second cloud server is a cloud server in the first device; The method further comprises: When a deregistration request for instructing to deregister the second cloud server in the first device is obtained, deleting a third mapping relationship in the second mapping information, the third mapping relationship being a mapping relationship between the domain name identifier and the target network address; Deleting the first mapping relationship stored in the central database; The first mapping relationship is deleted from the first mapping information, and deletion indication information is sent to other devices except the first device, where the deletion indication information is used to instruct the other devices to delete the first mapping relationship.

7. The method according to any one of claims 1 to 5, characterized in that A virtual machine monitor is running in the first device, wherein the virtual machine monitor is used to manage the at least one cloud server, and the virtual machine monitor includes a domain name resolution process.

8. The method according to claim 7, characterized in that The first cloud server is a cloud server in the first device, The obtaining of the domain name resolution request includes: Obtain a domain name resolution request initiated by the first cloud server through the domain name resolution process in the first device.

9. The method according to claim 7, characterized in that The first cloud server is a cloud server in the second device; The obtaining of the domain name resolution request includes: The domain name resolution process in the first device receives a domain name resolution request sent by the domain name resolution process in the second device.

10. The method according to claim 7, characterized in that The virtual machine monitor also includes a management and control unit; The determining, according to the first mapping information stored in the first device, the target device identifier corresponding to the domain name identifier includes: The first mapping information is queried through the management and control unit to determine the target device identifier corresponding to the domain name identifier.

11. A domain name resolution device, characterized in that: include: An acquisition module, configured to acquire a domain name resolution request initiated by the first cloud server, wherein the domain name resolution request includes a domain name identifier of the second cloud server; a determination module, configured to determine a target device identifier corresponding to the domain name identifier based on first mapping information stored in the first device; The acquisition module is further configured to acquire a target network address corresponding to the domain name identifier, where the target network address is determined based on second mapping information stored in a target device, the target device being the device corresponding to the target device identifier, and the second cloud server running on the target device; The transmission module is used to return the target network address to the first cloud server, where the target network address is the resolution result corresponding to the domain name resolution request.

12. A domain name resolution device, characterized in that: include: Memory, used to store programs; A processor is configured to execute the program stored in the memory, wherein when the program is executed, the processor is configured to execute the method according to any one of claims 1 to 10.

13. A computer-readable storage medium, characterized in that The method stores instructions which, when executed on a computer, cause the computer to execute the method according to any one of claims 1 to 10.

14. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the method according to any one of claims 1 to 10 is implemented.

Citation Information

Patent Citations

  • Domain name resolution device, domain name resolution method and computer readable storage medium

    CN107682465A

  • Domain name resolution method and system of container cloud platform, medium and electronic equipment

    CN114785753A