Domain name resolution method and system, and device, storage medium and program product
By adding a private domain name resolution system to the public domain name resolution system, and utilizing the correspondence between domain name query results and availability zones maintained by the centralized domain name server, the problem of authoritative domain name server failures during the domain name resolution process was solved, and the success rate of domain name resolution was improved.
Patent Information
- Application Number
- PCT/CN2025/112388
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2024-08-02
- Filing Date
- 2025-08-04
- Publication Date
- 2026-02-05
AI Technical Summary
During the domain name resolution process, instability in the link between the local server and the authoritative domain name server or an abnormality of the authoritative domain name server may cause the query to fail, affecting the normal operation of the DNS client.
A private domain name resolution system is added on the basis of the public domain name resolution system, including a centralized domain name server and a local domain name server. The query results of the public domain name server are collected by the resolution data collection device and reported to the centralized domain name server. The centralized domain name server maintains the correspondence between the domain name query results and the availability zone, so that the local domain name server can provide recursive domain name queries in the order of local cache, public domain name server and centralized domain name server.
Even if the link between the local DNS server and the public DNS server is unstable or abnormal, the application server can still be provided with recursive domain name queries through the mapping relationship of the centralized DNS server, which improves the success rate of domain name resolution.
Smart Images

Figure CN2025112388_05022026_PF_FP_ABST
Abstract
Description
Domain name resolution method, device, system, storage medium and program product Cross-reference to Related Applications
[0001] The present disclosure claims priority to Chinese Patent Application No. 202411063470.2, filed on August 02, 2024, the entire contents of which are incorporated herein by reference. TECHNICAL FIELD
[0002] The present disclosure relates to the technical field of cloud computing, and particularly relates to a domain name resolution method, device, system, storage medium and program product. BACKGROUND
[0003] Domain name resolution refers to a process of resolving a domain name into a corresponding IP (Internet Protocol) address by querying a domain name system (DNS). Currently, the DNS includes multiple levels of domain name servers, such as a root domain name server, a top-level domain name server, an authoritative domain name server, and a local domain name server.
[0004] Among them, recursive query is the most commonly used domain name resolution method, that is, starting from the local domain name server, if the local domain name server does not have the IP address corresponding to the domain name, the recursive query is continued to the upper-level domain name server (i.e., the authoritative domain name server), until the IP address corresponding to the domain name can be returned.
[0005] In actual application, due to unstable link between the local domain name server and the authoritative domain name server, or abnormality of the authoritative domain name server itself, etc., the query to the authoritative domain name server fails, which finally affects the normal operation of the DNS client. SUMMARY
[0006] The aspects of the present disclosure provide a domain name resolution method, device, system, storage medium and program product, to solve the problem of query failure to the authoritative domain name server, and improve the success rate of domain name resolution.
[0007] The embodiment of the present disclosure provides a domain name resolution system, comprising: a public domain name resolution system and a private domain name resolution system; the public domain name resolution system comprises a public domain name server; the private domain name resolution system comprises a centralized domain name server, a local domain name server and a resolution data collection device deployed in at least one availability zone; wherein the local domain name server is interconnected with the centralized domain name server and the public domain name server respectively, and is used for providing a domain name recursive query service for an application server in the availability zone to which the local domain name server belongs in sequence according to a local cache, the public domain name server and the centralized domain name server, and stopping the domain name recursive query service when a domain name query result is obtained; the resolution data collection device is used for collecting a domain name query result returned by the public domain name server in the process of the domain name recursive query service and reporting the domain name query result to the centralized domain name server, wherein the domain name query result comprises a domain name to be queried and an IP address corresponding to the domain name to be queried; and the centralized domain name server is used for maintaining the domain name query result reported by the resolution data collection device and a corresponding relationship between the domain name query result and an availability zone, and the corresponding relationship is used for providing the domain name recursive query service by the local domain name server.
[0008] The embodiment of the present disclosure also provides a domain name resolution method applied to a local domain name server in any availability zone, wherein the local domain name server belongs to a private domain name resolution system, and the method comprises the following steps: receiving a first domain name query request of an application server in the availability zone, wherein the first domain name query request comprises a domain name to be queried; performing a recursive query to a public domain name server in a public domain name resolution system in a case where an IP address corresponding to the domain name to be queried does not exist in a local cache; and in a case where the public domain name server does not return a domain name query result, sending the domain name to be queried and an identifier of the availability zone to a centralized domain name server in the private domain name resolution system, so that the centralized domain name server performs a recursive query according to a maintained domain name query result, a corresponding relationship between the domain name query result and an availability zone, the identifier of the availability zone and the domain name to be queried; and the domain name query result comprises a domain name to be queried and an IP address corresponding to the domain name to be queried.
[0009] The embodiment of the present disclosure further provides a domain name resolution method, which is applied to a resolution data collection device in any available zone, the available zone further comprises a local domain name server, the resolution data collection device and the local domain name server belong to a private domain name resolution system, and the method comprises the following steps: collecting a domain name query result returned by a public domain name server in a process in which the local domain name server sequentially provides a domain name recursive query service for an application server in the available zone according to an order of a local cache, the public domain name server in a public domain name resolution system, and a centralized domain name server in the private domain name resolution system; stopping the domain name recursive query service after the domain name query result returned by the public domain name server is collected, wherein the domain name query result comprises a to-be-queried domain name and an IP address corresponding to the to-be-queried domain name; and reporting the domain name query result to the centralized domain name server, so that the centralized domain name server maintains a correspondence between the domain name query result and the available zone, and the correspondence is used for providing the domain name recursive query service by the local domain name server.
[0010] The embodiment of the present disclosure further provides an electronic device, which comprises a memory and a processor, the memory is used for storing one or more computer instructions, and the processor is used for executing the one or more computer instructions to execute the steps in the domain name resolution method.
[0011] The embodiment of the present disclosure further provides a computer readable storage medium storing a computer program, when the computer program is executed by a processor, the processor can implement the steps in the domain name resolution method.
[0012] The embodiment of the present disclosure further provides a computer program product, which comprises a computer program / instruction, when the computer program / instruction is executed by a processor, the domain name resolution method is executed.
[0013] In the embodiment of the present disclosure, on the basis of a public domain name resolution system, a private domain name resolution system is additionally provided, a resolution data collection device in the system can collect a domain name query result successfully returned by a public domain name server and report the domain name query result to a centralized domain name server, the centralized domain name server can maintain a correspondence between the domain name query result and an available zone, and thus the local domain name server can provide a domain name recursive query for an application server according to an order of a local cache, the public domain name server and the centralized domain name server. In this way, even if a link between the local domain name server and the public domain name server is unstable or the public domain name server is abnormal, the local domain name server can provide the domain name recursive query for the application server in the available zone to which the local domain name server belongs according to the correspondence maintained by the centralized domain name server, thereby solving the problem of query failure of an authoritative domain name server and improving a domain name resolution success rate. BRIEF DESCRIPTION OF DRAWINGS
[0014] The accompanying drawings, which are included to provide a further understanding of the disclosure and are incorporated in and constitute a part of this disclosure, illustrate embodiments of the disclosure and together with the description serve to explain the disclosure. In the drawings:
[0015] FIG. 1 is a schematic diagram of a domain name resolution method according to an example embodiment of the present disclosure;
[0016] FIG. 2 is a schematic diagram of a domain name resolution system according to an example embodiment of the present disclosure;
[0017] FIG. 3 is a schematic diagram of a domain name resolution method according to an example embodiment of the present disclosure;
[0018] FIG. 4 is a schematic diagram of a domain name resolution method according to another example embodiment of the present disclosure;
[0019] FIGS. 5a-5b are schematic diagrams of a domain name resolution apparatus according to an example embodiment of the present disclosure;
[0020] FIG. 6 is a schematic diagram of an electronic device according to an example embodiment of the present disclosure. DETAILED DESCRIPTION
[0021] To make the objectives, technical solutions, and advantages of the present disclosure clearer, the technical solutions of the present disclosure will be described below in conjunction with specific embodiments of the present disclosure and corresponding drawings. Obviously, the described embodiments are only some of the embodiments of the present disclosure, rather than all the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by those of ordinary skill in the art without creative work fall within the scope of the present disclosure.
[0022] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data for analysis, stored data, displayed data, etc.) involved in the present disclosure are all information and data authorized by the user or authorized by all parties, and the collection, use, and processing of related data need to comply with relevant laws, regulations, and standards of the country and region, and provide corresponding operation portal for the user to choose authorization or refusal. In addition, the various models (including but not limited to language models or large models) involved in the present disclosure are in compliance with relevant legal and standard regulations.
[0023] In the embodiments of the present disclosure, as shown in FIG. 1, in the field of cloud computing, a cloud vendor can establish at least one availability zone (AZ) according to application requirements or for some network system such as a virtual private cloud (VPC). The availability zone refers to a cluster of data centers with independent power, network, cooling and other infrastructures established by a cloud computing service provider in a geographical area. Each availability zone can operate as an independent entity. Even if a failure (such as power interruption, network problem or natural disaster) occurs in one availability zone, other availability zones can continue to provide services, thereby ensuring high availability and fault tolerance. FIG. 1 only shows two availability zones, availability zone 1 and availability zone 2, and does not limit the number of availability zones in the actual scenario. Each availability zone can deploy a local domain name server and an application server. The local domain name server can directly query an authoritative server in a public domain name resolution system to provide domain name recursive query service for the corresponding application server.
[0024] However, based on the recursive query mode, in the process of domain name resolution, the query of the authoritative domain name server can fail due to unstable link between the local and the authoritative domain name server or abnormality of the authoritative domain name server itself, thereby affecting the normal operation of the DNS client.
[0025] Further, as shown in FIG. 2, in order to solve the domain name resolution problem of the application server in the availability zone, the present disclosure adds a private domain name resolution system on the basis of a public domain name resolution system. The private domain name resolution system can include a centralized domain name server, a local domain name server and a resolution data collection device deployed in at least one availability zone. The technical solutions provided by the embodiments of the present disclosure will be described in detail below in combination with FIG. 2.
[0026] FIG. 2 is a system architecture diagram of a domain name resolution system 1 provided by the present disclosure. As shown in FIG. 2, the domain name resolution system 1 can include a public domain name resolution system 11 and a private domain name resolution system 12.
[0027] The public domain name resolution system 11 can include a public domain name server 111. The private domain name resolution system 12 can include a local domain name server 121 and a resolution data collection device 122 deployed in at least one availability zone, and a centralized domain name service 123. Each availability zone can include an application server 124. The application server 124 can be a physical server or a cloud server such as a virtual machine, ECS, various computing nodes, etc.
[0028] It should be noted that the number of available zones can be one or more, and the two available zones shown in FIG. 2 are merely illustrative and do not limit the number of available zones.
[0029] As shown in FIG. 2, the resolution data collection device 122 can be deployed outside the local domain name server 121, and in addition, the resolution data collection device 122 can also be deployed inside the local domain name server 121 in the available zone to which it belongs, which is not limited by the present embodiment. When the resolution data collection device 122 is deployed inside the local domain name server 121 in the available zone to which it belongs, it can be a functional module, a work unit or a work component inside the local domain name server 121, which is not limited by the present embodiment.
[0030] In the present embodiment, as shown in FIG. 2, the public domain name server 111 can include multiple levels of servers, for example, the levels from top to bottom are root domain name server, top-level domain name server and authoritative domain name server. The domain name servers of the three levels are all domain name servers in the public domain name resolution system and belong to the public domain name server. The devices of various manufacturers and the devices of various regions can use the multiple levels of servers for domain name resolution. Among them, the root domain name server is responsible for resolving the IP addresses of the top-level domain names (such as.com,.org,.net,.edu, etc.) to their corresponding domain name servers. Among them, the top-level domain name server (Top-Level Domain Name Server) is responsible for managing the DNS records of a specific top-level domain name (such as.com,.net,.org,.cn, etc.). The authoritative domain name server (Authoritative Name Server) is responsible for providing the final domain name to IP address mapping confirmation information. Based on this, the domain name query request can be guided to the corresponding top-level domain name server, authoritative domain name server by means of the root server, until the final domain name query result, such as the IP address corresponding to the domain name query request, is found, thereby realizing the response of the web page browsing or other network services requested by the user. Among them, in the public domain name resolution system, the process of domain name recursive query is also recursively upwards level by level, that is, the first domain name query request of the local domain name server will first go to the root domain name server and recursively upwards level by level, through the top-level domain name server, and then through the authoritative domain name server to obtain the domain name query result.
[0031] In contrast to the public domain name server 111, the private domain name resolution system 12 can only be used to provide domain name resolution services for the devices of the cloud service manufacturer to which it belongs.
[0032] In this embodiment, the local domain name server 121 can be interconnected with the centralized domain name server 123 and the public domain name server 111 respectively, and can provide the application server 124 in the available area to which the local domain name server 121 belongs with the domain name recursive query service in the order of the local cache, the public domain name server 111 and the centralized domain name server 123, and stop the domain name recursive query service when the domain name query result is obtained. The stop of the domain name recursive query service means that the domain name recursive query is no longer performed on the subsequent server. As shown in ①-③ in FIG. 2, that is, the domain name query request can be processed based on the local cache, the public domain name server 111 and the centralized domain name server 123 in turn. For example, the local domain name server 121 can first perform the first step processing on the received domain name query request through the local cache, then perform the second step processing through the public domain name server 111, and then perform the third step processing through the centralized domain name server 123, thereby providing the application server 124 in the available area to which the local domain name server 121 belongs with the domain name recursive query service.
[0033] In this embodiment, the public domain name server 111 can return the domain name query result to the resolution data collection device 122 during the domain name recursive query service, as shown in ④ in FIG. 2. The domain name query result can include the domain name to be queried and the IP address corresponding to the domain name to be queried. The resolution data collection device 122 can collect the domain name query result returned by the public domain name server 111 during the domain name recursive query service and report it to the centralized domain name server 123, as shown in ⑤ in FIG. 2.
[0034] Correspondingly, the centralized domain name server 123 can maintain the domain name query result reported by the resolution data collection device 122 and the corresponding relationship between the domain name query result and the available area, as shown in ⑥ in FIG. 2. For example, the domain name query result G1 is reported by the data collection device 122 in the available area 1, and the centralized domain name server can maintain the following corresponding relationship: domain name query result G1-available area 1.
[0035] In this embodiment, the corresponding relationship maintained by the centralized domain name server 123 can provide a basis for the local domain name server 121 to provide the domain name recursive query service, in other words, the corresponding relationship can be used by the local domain name server to provide the domain name recursive query service. Even if the link between the local domain name server 121 and the public domain name server 123 is unstable or the public domain name server itself has an abnormality, the local domain name server 121 can provide the application server 124 in the available area to which the local domain name server 121 belongs with the domain name recursive query service according to the corresponding relationship maintained by the centralized domain name server 123.
[0036] In the embodiment, a private domain name resolution system is added, wherein the local domain name server can provide domain name recursive query service for the application servers in the available area to which the local domain name server belongs in the order of local cache, public domain name server and centralized domain name server; the resolution data collection device can collect the domain name query result returned by the public domain name server and report the centralized domain name server; the centralized domain name server can maintain the domain name query result and the corresponding relationship between the domain name query result and the available area. In this way, even if the link between the local domain name server and the public domain name server is unstable or the public domain name server is abnormal, the local domain name server can provide domain name recursive query service for the application servers in the available area to which the local domain name server belongs according to the corresponding relationship maintained by the centralized domain name server, thereby solving the problem of failure to query the authoritative domain name server and improving the domain name resolution success rate.
[0037] In some optional embodiments, when the local domain name server 121 provides domain name recursive query service for the application servers 124 in the available area to which the local domain name server 121 belongs in the order of local cache, public domain name server 111 and centralized domain name server 123, the specific implementation can be based on the following implementation.
[0038] First, a first domain name query request of the application server 124 in the available area to which the local domain name server 121 belongs can be received, and the first domain name query request can include a domain name to be queried. The first domain name query request can be sent in response to a request sending instruction issued by a user through a host held by the user, or can be sent according to a set instruction sending rule of an application program on the host held by the user, and the embodiment does not limit the same.
[0039] Secondly, if the local cache does not exist the IP address corresponding to the domain name to be queried, recursive query is performed on the public domain name server. It should be noted that at a historical time, the local domain name server 121 can cache the historical domain name to be queried and the corresponding IP address received within a preset cache time period, and the historical domain name to be queried and the corresponding IP address cached within the cache time period can be cleaned up whenever the cache time period is exceeded, so as to prevent the cache space from being insufficient. Based on this, the local domain name server 121 can search for the IP address corresponding to the domain name to be queried in the local cache, and if the local cache does not exist the IP address corresponding to the domain name to be queried, recursive query can be performed on the public domain name server.
[0040] Afterwards, in the case that the public domain name server 111 does not return the domain name query result, a recursive query can be performed to the centralized domain name server 123 according to the domain name to be queried and the identifier of the available zone to which the local domain name server 121 belongs. In the recursive query performed to the centralized domain name server 123 according to the domain name to be queried and the identifier of the available zone to which the local domain name server 121 belongs, the local domain name server 121 can send the domain name to be queried and the identifier of the available zone to which the local domain name server 121 belongs to the centralized domain name server in the private domain name resolution system, and the centralized domain name server can perform a recursive query according to the maintained domain name query result, the correspondence between the domain name query result and the available zone, the identifier of the available zone, and the domain name to be queried, to obtain the IP address corresponding to the domain name to be queried. The domain name query result can include the domain name to be queried and the IP address corresponding to the domain name to be queried.
[0041] In the above embodiment, the authoritative server in the public domain name server 111 can be multiple, and the local domain name server 121 polls (asks in turn) multiple authoritative servers. If multiple authoritative servers are not reachable, it is considered that the query of the authoritative server fails, that is, the public domain name server 111 does not return the domain name query result. Here, the unreachability can be generally judged by a timeout time, which can be configured as 1-2 seconds, etc., and the embodiment does not limit it. Different IP addresses can correspond to the same domain name, which are suitable for different available zones, so the same domain name query result (i.e., domain name + IP address) can be suitable for one or more available zones. The domain name query result containing the domain name can be determined by the domain name, and the domain name query result suitable for the available zone identified by the identifier of the available zone can be determined by the identifier of the available zone. In the centralized domain name server, the domain name resolution result is maintained and managed according to the identifier of the available zone, but in the public domain name resolution system, the available zone is not concerned, and only the domain name query result corresponding to the domain name and the IP address is stored.
[0042] Further, in the execution of the above embodiment, the local domain name server 121 can be specifically configured to: query whether the IP address corresponding to the domain name to be queried exists in the local cache according to the first domain name query request; and in the case that the IP address corresponding to the domain name to be queried does not exist in the local cache, send a second domain name query request to the public domain name server 111, the second domain name query request including the domain name to be queried, to perform a recursive query to the public domain name server 111.
[0043] In the case that the public domain name server 111 does not return the domain name query result, a third domain name query request can be sent to the centralized domain name server 123, the third domain name query request including the domain name to be queried and the identifier of the available zone to which the local domain name server 121 belongs, so as to perform recursive query on the centralized domain name server 123. In the case that the public domain name server 111 returns the domain name query result, the local domain name server 121 can receive the domain name query result, on one hand, save the domain name query result into the local cache, and on the other hand, return the IP address of the domain name to be queried included in the domain name query result to the application server 124, so as to provide the application server 124 with the domain name recursive query service, as shown in ⑦ in FIG. 2.
[0044] It should be noted that the above use of “first”, “second” and “third” to limit the domain name query request is only used to distinguish different domain name query requests, and does not limit the implementation manner of the domain name query request. Alternatively, the second domain name query request and the third domain name query request can be directly implemented by using the implementation manner of the first domain name query request.
[0045] In this way, the local domain name server 121 can provide the application server 124 in the available zone to which it belongs with the domain name recursive query service in the order of the local cache, the public domain name server 111 and the centralized domain name server 123.
[0046] In some optional embodiments, when collecting the domain name query result returned by the public domain name server 111 in the process of the domain name recursive query service and reporting to the centralized domain name server 123, the resolution data collection device 122 can obtain the domain name query result returned by the public domain name server 111 from the local cache of the local domain name server 121 in the available zone to which it belongs, and when the domain name query result accumulates to a set number, report the set number of domain name query results to the centralized domain name server 123. The set number supports custom configuration, which can be configured as 5, 10 or 15, etc., and the present embodiment does not limit it.
[0047] That is, the local domain name server 121 in the available zone to which the resolution data collection device 122 belongs can cache the domain name query result returned by the public domain name server 111 in the domain name recursive query service process into the local cache space (i.e., the local cache), and then the resolution data collection device 122 can obtain the domain name query result returned by the public domain name server 111 from the local cache of the local domain name server 121. In addition, in the case where the domain name query result accumulates to a set number, the set number of domain name query results are reported to the centralized domain name server 123, the transmission process between the resolution data collection device 122 and the centralized domain name server 123 is optimized, and the signaling transmission pressure of the resolution data collection device 122 and the centralized domain name server 123 is reduced. Through this accumulation to a certain number for reporting mode, the interaction times between the resolution data collection device 122 and the centralized domain name server 123 can be reduced, and the IO (Input / Output) operation can be reduced. However, it is not limited to this, in order to facilitate the centralized domain name server 123 to save the domain name query result returned by the public domain name server 111 more timely, the resolution data collection device 122 can also report once for each obtained domain name query result, and the present embodiment does not limit this.
[0048] In the foregoing embodiment, when the resolution data collection device 122 obtains the domain name query result returned by the public domain name server 111 from the local cache of the local domain name server 121, the following implementation modes can be specifically implemented.
[0049] Implementation mode A: periodically polling the local cache of the local domain name server 121 in the available zone to which it belongs, and reading the new domain name query result from the local cache when a new domain name query result is found. The polling frequency can be configured, such as polling every half an hour, polling every hour, etc., and the present embodiment does not limit it. The resolution data collection device 122 can periodically inquire whether the local cache of the local domain name server 121 adds a new domain name query result, if the local domain name server 121 replies that the local cache adds a new domain name query result, the resolution data collection device 122 can read the new domain name query result, and if the local domain name server 121 replies that the local cache does not add a new domain name query result, the resolution data collection device 122 can not read.
[0050] In the embodiment B, the local domain name server 121 in the availability zone to which the resolving data collection device 122 belongs sends a notification message, which is sent by the local domain name server upon receiving the new domain name query result returned by the public domain name server. The resolving data collection device 122 reads the new domain name query result from the local cache of the local domain name server 121 according to the notification message. In other words, the local domain name server 121 actively sends a notification message to the resolving data collection device 122 upon receiving the new domain name query result returned by the public domain name server 111. The resolving data collection device 122 reads the new domain name query result from the local cache of the local domain name server 121 in response to the notification message.
[0051] In the embodiment B, the local domain name server 121 in the availability zone to which the resolving data collection device 122 belongs sends a notification message, which is sent by the local domain name server upon receiving the new domain name query result returned by the public domain name server. The resolving data collection device 122 reads the new domain name query result from the local cache of the local domain name server 121 according to the notification message. In other words, the local domain name server 121 actively sends a notification message to the resolving data collection device 122 upon receiving the new domain name query result returned by the public domain name server 111. The resolving data collection device 122 reads the new domain name query result from the local cache of the local domain name server 121 in response to the notification message.
[0052] In the embodiments A and B, the resolving data collection device 122 only needs to read the new domain name query result returned by the public domain name server 111, thereby avoiding repeated acquisition of the domain name query result returned by the public domain name server 111 by the resolving data collection device 122 and saving storage space and hardware resources.
[0053] It should be noted that the resolving data collection device 122 can provide a data caching function. When collecting the domain name query result returned by the public domain name server 111 in the domain name recursive query service process, the resolving data collection device 122 can obtain the domain name query result returned by the public domain name server 111 from the local cache of the local domain name server 121 in the availability zone to which the resolving data collection device 122 belongs, and cache the domain name query result in a target cache space previously configured for the resolving data collection device 122. The resolving data collection device 122 can also provide a data storage function. When collecting the domain name query result returned by the public domain name server 111 in the domain name recursive query service process, the resolving data collection device 122 can obtain the domain name query result returned by the public domain name server 111 from the local cache of the local domain name server 121 in the availability zone to which the resolving data collection device 122 belongs, and store the domain name query result in a target storage space previously configured for the resolving data collection device 122. The present embodiment is not limited in this regard.
[0054] In some optional embodiments, in addition to the centralized domain name server 123, the local cache of the local domain name server 121 itself, and the public domain name server 111, the resolution data collection device 122 can also provide domain name recursive query service, further reducing the risk of query omission.
[0055] Specifically, the local domain name server 121 can send a fourth domain name query request to the resolution data collection device 122 in the available area to which it belongs to perform recursive query before performing recursive query to the centralized domain name server 123, or in the case of query failure from the centralized domain name server 123. The fourth domain name query request includes the domain name to be queried.
[0056] In the case of querying the IP address corresponding to the domain name to be queried from the resolution data collection device 122, the IP address corresponding to the domain name to be queried is returned to the application server 124.
[0057] Wherein, the use of "fourth" to limit the domain name query request is only for the purpose of distinguishing from the "first domain name query request", "second domain name query request" and "third domain name query request" in the foregoing, and does not limit the implementation mode of the domain name query request. Alternatively, the fourth domain name query request can be directly implemented in the implementation mode of the first domain name query request.
[0058] In this way, the risk of query omission is further reduced, and the success rate of domain name query is improved.
[0059] In some optional embodiments, the local domain name server 121 can also determine whether the communication connection between the local domain name server and the public domain name server 111 is maintained according to the latest received heartbeat message from the public domain name server 111 before performing recursive query to the public domain name server 111. In other optional embodiments, the local domain name server 121 can also determine whether the communication connection between the local domain name server and the centralized domain name server 123 is maintained according to the latest received heartbeat message from the centralized domain name server 123 before performing recursive query to the centralized domain name server 123.
[0060] The heartbeat message can be a small data packet periodically sent by the public domain name server 111 or the centralized domain name server 123 to the local domain name server 121, and is used to detect whether the communication connection between the two is active, such as Keep-Alive of Transmission Control Protocol (TCP).
[0061] Optionally, after receiving the heartbeat message from the public domain name server 111 or the centralized domain name server 123, the local domain name server 121 can determine the data integrity of the heartbeat message. If there is no data packet loss in the heartbeat message, it indicates that the communication connection between the local domain name server 121 and the public domain name server 111 or the centralized domain name server 123 is maintained. If there is a loss in the heartbeat message, it indicates that the communication connection between the local domain name server 121 and the public domain name server 111 or the centralized domain name server 123 is not maintained.
[0062] Optionally, since the heartbeat message is periodically sent, if no heartbeat message is received for a certain time interval, it is considered that the communication connection between the local domain name server 121 and the public domain name server 111 or the centralized domain name server 123 is disconnected, i.e., the communication connection is not maintained. Based on this, the local domain name server 121 can determine whether the time interval from the reception time of the latest received heartbeat message to the current time exceeds the set time interval (i.e., the time interval of the heartbeat message). If it exceeds, it indicates that the communication connection between the local domain name server 121 and the public domain name server 111 or the centralized domain name server 123 is not maintained. If it does not exceed, it indicates that the communication connection between the local domain name server 121 and the public domain name server 111 or the centralized domain name server 123 is maintained.
[0063] In the case where it is determined that the communication connection between the local domain name server 121 and the public domain name server 111 or the centralized domain name server 123 is maintained, a recursive query can be made to the public domain name server 111 or the centralized domain name server 123.
[0064] In the case where it is determined that the communication connection between the local domain name server 121 and the public domain name server 111 is not maintained, a recursive query can be directly made to the centralized domain name server 123, thereby improving the domain name query efficiency. In the case where it is determined that the communication connection between the local domain name server 121 and the centralized domain name server 123 is not maintained, the query failure result returned by the centralized domain name server 123 can be directly accepted.
[0065] In the above manner, the heartbeat message sent between the public domain name server 111 or the centralized domain name server 123 and the local domain name server 121 can be used to further improve the domain name query efficiency.
[0066] In some optional embodiments, for the public domain name server 111, due to the large number of available zones to be served and the large number of local domain name servers 121 connected thereto, if the heartbeat mechanism is adopted with all the local domain name servers 121, the burden of the public domain name server 111 will be heavier. Therefore, the present embodiment proposes the following optimization solutions:
[0067] One solution is that the public domain name server 111 with a small amount of domain name queries (i.e., the query amount is less than a preset query amount threshold) can establish a heartbeat mechanism, or the public domain name server 111 with a large amount of queries (i.e., the query amount is greater than a preset query amount threshold) deployed in the cloud (such as com, net, org, amazon, google, etc.) can establish a heartbeat mechanism.
[0068] Another solution is that for the available zones of the same cloud vendor, a number of local domain name servers 121 not exceeding a preset number are selected as local basic domain name servers, and the local basic domain name servers establish a heartbeat mechanism with the public domain name server 111. After the local basic domain name server identifies that the connection state of the public domain name server is disconnected based on the latest received heartbeat message, it can synchronize to other local domain name servers 121.
[0069] In some optional embodiments, when the centralized domain name server 123 maintains the domain name query results reported by the resolution data collection device 122 and the correspondence relationship between the domain name query results and the available zones, the centralized domain name server 123 is specifically configured to: perform deduplication on the domain name query results reported by the resolution data collection device 122, and store each domain name query result after deduplication as a storage object. In other words, the centralized domain name server 123 can determine duplicate domain name query results among the numerous domain name query results reported by the resolution data collection device 122, and only retain any one of the duplicate domain name query results, and store each domain name query result after deduplication. Then, an available zone list can be maintained for each domain name query result, and the available zone list can be used to store the identifiers of the available zones applicable to the corresponding domain name query result. For example, the following provides an example of a data storage structure: domain name a1-IP address b1-{identifier of available zone 1, identifier of available zone 3}, domain name a2-IP address b2-{identifier of available zone 2, identifier of available zone 3}.
[0070] In this way, the centralized domain name server 123 can more efficiently maintain the correspondence relationship between the domain name query results reported by the resolution data collection device 122 and the available zones based on the deduplication manner and the available zone list.
[0071] In some optional embodiments, the number of centralized domain name servers 123 can be multiple and distributed in different locations. The local domain name server 111 can also select a most suitable centralized domain name server from the multiple centralized domain name servers 123 to perform the recursive query more efficiently through the following implementation.
[0072] In implementation 1, the target centralized domain name server is determined according to the load conditions of the multiple centralized domain name servers 123, and the recursive query is performed to the target centralized domain name server. The load conditions can include memory usage or the number of running tasks, etc. The higher the memory usage or the more the number of running tasks, the higher the load condition. The local domain name server 111 can determine the first selection weight of each of the multiple centralized domain name servers 123 according to the load conditions of the multiple centralized domain name servers 123 and the preset correspondence between the load conditions and the first selection weight, and select the centralized domain name server 123 with the highest first selection weight as the target centralized domain name server. The higher the load condition, the smaller the first selection weight. In other words, the local domain name server 111 should select a centralized domain name server 123 with a lower load condition as the target centralized domain name server as much as possible.
[0073] For example, the memory usage of the multiple centralized domain name servers 123 is 10%, 20%, 30%, and 40% in turn, and the first selection weight of each of the multiple centralized domain name servers 123 is 0.4, 0.3, 0.2, and 0.1 in turn. Therefore, the centralized domain name server 123 with the first selection weight of 0.4 can be selected as the target centralized domain name server.
[0074] In implementation 2, the target centralized domain name server is determined according to the distance from the multiple centralized domain name servers 123 to the availability zone to which they belong, and the recursive query is performed to the target centralized domain name server.
[0075] The local domain name server 111 can determine the second selection weight of each of the plurality of centralized domain name servers 123 according to the distance of the plurality of centralized domain name servers 123 to the availability zone to which the plurality of centralized domain name servers 123 belong and the preset correspondence between the distance and the second selection weight, and select the centralized domain name server 123 with the highest second selection weight as the target centralized domain name server. The farther the distance, the smaller the second selection weight. In other words, the local domain name server 111 should select the centralized domain name server 123 with a shorter distance to the availability zone to which the plurality of centralized domain name servers 123 belong as the target centralized domain name server as far as possible. For example, the distances of the plurality of centralized domain name servers 123 to the availability zone to which the plurality of centralized domain name servers 123 belong are 100 km, 200 km, 300 km, and 400 km in turn, and the second selection weights of the plurality of centralized domain name servers 123 are 0.4, 0.3, 0.2, and 0.1 respectively. Then, the centralized domain name server 123 with the second selection weight of 0.4 can be selected as the target centralized domain name server.
[0076] In the third implementation, the target centralized domain name server is determined according to the resource specifications of the plurality of centralized domain name servers 123, and the recursive query is performed on the target centralized domain name server. The resource specification refers to the specific configuration of the centralized domain name server, such as the number of CPU cores, the size of memory, the storage capacity, the network bandwidth, and the like.
[0077] The local domain name server 111 can determine the third selection weight of each of the plurality of centralized domain name servers 123 according to the resource specifications of the plurality of centralized domain name servers 123 and the preset correspondence between the resource specifications and the third selection weight, and select the centralized domain name server 123 with the highest third selection weight as the target centralized domain name server. The higher the resource specification, the larger the third selection weight. In other words, the local domain name server 111 should select the centralized domain name server 123 with a higher resource specification as the target centralized domain name server as far as possible.
[0078] The above-mentioned first to third implementations can be executed alone or in any combination, and the present embodiment is not limited thereto. For example, the first to third implementations are combined, the weights of the load condition, the distance, and the resource specification are obtained, and the first selection weight, the second selection weight, and the third selection weight of each of the plurality of centralized domain name servers 123 are weighted and summed according to the respective weights to obtain the target weight of each of the plurality of centralized domain name servers 123. Then, the centralized domain name server 123 with the highest target weight can be selected from the plurality of centralized domain name servers 123 as the target centralized domain name server.
[0079] In this way, the local domain name server 111 can select the most suitable centralized domain name server from the plurality of centralized domain name servers 123 to perform the recursive query more efficiently.
[0080] It should be emphasized that the domain name resolution system described in various embodiments of the present disclosure provides a passive domain name resolution method. Among them, the collection is carried out by the analysis data collection device 122, the centralized domain name service 123 is saved, and then when the public domain name server 111 fails, the query is carried out through the centralized domain name server 123. The way is a passive domain name resolution method.
[0081] In addition to the domain name resolution system in the foregoing embodiments, the present disclosure also provides a domain name resolution method. The domain name resolution method is applied to a local domain name server in any available zone, and the local domain name server belongs to a private domain name resolution system.
[0082] The method can include steps 31 to 33 as shown in FIG. 3.
[0083] Step 31, receiving a first domain name query request of an application server in an available zone, the first domain name query request including a domain name to be queried.
[0084] Step 32, in the case that the local cache does not exist the IP address corresponding to the domain name to be queried, performing recursive query to the public domain name server in the public domain name resolution system.
[0085] Step 33, in the case that the public domain name server does not return the domain name query result, sending the domain name to be queried and the identifier of the available zone to the centralized domain name server in the private domain name resolution system, so that the centralized domain name server performs recursive query according to the maintained domain name query result and the corresponding relationship between the domain name query result and the available zone, the identifier of the available zone and the domain name to be queried; the domain name query result includes the domain name to be queried and the IP address corresponding to the domain name to be queried.
[0086] Optionally, in the case that the local cache does not exist the IP address corresponding to the domain name to be queried, performing recursive query to the public domain name server in the public domain name resolution system, including: according to the first domain name query request, querying whether the local cache exists the IP address corresponding to the domain name to be queried; in the case that the local cache does not exist the IP address corresponding to the domain name to be queried, sending a second domain name query request to the public domain name server, the second domain name query request including the domain name to be queried, so as to perform recursive query to the public domain name server.
[0087] Optionally, in the case that the public domain name server does not return the domain name query result, a recursive query is performed on a centralized domain name server in the private domain name resolution system according to the domain name to be queried and the identifier of the available zone, including: in the case that the public domain name server does not return the domain name query result, a third domain name query request is sent to the centralized domain name server, the third domain name query request comprising the domain name to be queried and the identifier of the available zone, so as to perform a recursive query on the centralized domain name server.
[0088] Optionally, further comprising: before performing the recursive query on the centralized domain name server, or in the case that the recursive query on the centralized domain name server fails, sending a fourth domain name query request to a resolution data collection device affiliated to the available zone in the private domain name resolution system, the fourth domain name query request comprising the domain name to be queried, so as to perform a recursive query on the resolution data collection device; in the case that the IP address corresponding to the domain name to be queried is queried from the resolution data collection device, returning the IP address corresponding to the domain name to be queried to the application server; wherein the resolution data collection device is configured to collect the domain name query result returned by the public domain name server and report to the centralized domain name server.
[0089] Optionally, before performing the recursive query on the public domain name server or the centralized domain name server, further comprising: according to the latest heartbeat message received from the public domain name server or the centralized domain name server, determining whether a communication connection is maintained between the local domain name server and the public domain name server or the centralized domain name server; in the case that it is determined that the communication connection is maintained between the local domain name server and the public domain name server or the centralized domain name server, performing the recursive query on the public domain name server or the centralized domain name server.
[0090] The detailed implementation and beneficial effects of each step in the method of the embodiment have been described in the foregoing embodiments, and will not be described in detail here.
[0091] In the embodiment, a private domain name resolution system is additionally provided, wherein the local domain name server can provide domain name recursive query service for application servers in the available zone to which the local domain name server belongs in the order of local cache, public domain name server and centralized domain name server; the resolution data collection device can collect domain name query results returned by the public domain name server and report the centralized domain name server; and the centralized domain name server can maintain the correspondence between domain name query results and available zones. In this way, even if the link between the local domain name server and the public domain name server is unstable or the public domain name server is abnormal, the local domain name server can provide domain name recursive query service for application servers in the available zone to which the local domain name server belongs according to the correspondence maintained by the centralized domain name server, thereby solving the problem of failure to query the authoritative domain name server and improving the success rate of domain name resolution.
[0092] In addition to the domain name resolution system in the foregoing embodiments, the disclosure also provides a domain name resolution method. The domain name resolution method is applied to a resolution data collection device in any available zone, the available zone further includes a local domain name server, and the resolution data collection device and the local domain name server belong to a private domain name resolution system.
[0093] The method can include steps 41 to 43 as shown in FIG. 4.
[0094] Step 41, in the process in which the local domain name server sequentially provides domain name recursive query service for application servers in the available zone in the order of local cache, a public domain name server in a public domain name resolution system and a centralized domain name server in a private domain name resolution system, the domain name query results returned by the public domain name server are collected.
[0095] Step 42, after the domain name query results returned by the public domain name server are collected, the domain name recursive query service is stopped, and the domain name query results include a domain name to be queried and an IP address corresponding to the domain name to be queried.
[0096] Step 43, the domain name query results are reported to the centralized domain name server, so that the centralized domain name server maintains the correspondence between the domain name query results and the available zone, and the correspondence is used for the local domain name server to provide domain name recursive query service.
[0097] Optionally, collecting the domain name query results returned by the public domain name server includes: obtaining the domain name query results returned by the public domain name server from the local cache of the local domain name server; and in the case where the domain name query results accumulate to a set number, reporting the set number of domain name query results to the centralized domain name server.
[0098] Optionally, the domain name query result returned by the public domain name server is obtained from the local cache of the local domain name server, including: periodically polling the local cache of the local domain name server, and reading the new domain name query result from the local cache in the case of finding new domain name query result; or receiving a notification message sent by the local domain name server, the notification message being sent by the local domain name server in the case of receiving new domain name query result returned by the public domain name server; and reading the new domain name query result from the local cache of the local domain name server according to the notification message.
[0099] The detailed implementation and beneficial effects of each step in the method of the embodiment have been described in the foregoing embodiments, and will not be described in detail here.
[0100] In the embodiment, a private domain name resolution system is added, wherein the local domain name server can provide domain name recursive query service for application servers in the available area to which the local domain name server belongs in the order of local cache, public domain name server and centralized domain name server; the resolution data collection device can collect domain name query result returned by the public domain name server and report to the centralized domain name server; and the centralized domain name server can maintain the domain name query result and the corresponding relationship between the domain name query result and the available area. In this way, even if the link between the local domain name server and the public domain name server is unstable or the public domain name server is abnormal, the local domain name server can provide domain name recursive query service for the application servers in the available area to which the local domain name server belongs according to the corresponding relationship maintained by the centralized domain name server, thereby solving the problem of failure to query the authoritative domain name server and improving the success rate of domain name resolution.
[0101] It should be noted that the execution subject of each step of the method provided in the above embodiments can be the same device, or the method can also be executed by different devices as the execution subject. For example, the execution subject of steps 31 to 33 can be device A; for another example, the execution subject of steps 31 and 32 can be device A, and the execution subject of step 33 can be device B; and so on.
[0102] In addition, in some of the processes described in the above embodiments and the accompanying drawings, a plurality of operations appearing in a certain order are included, but it should be clearly understood that these operations can be executed in the order appearing in this text or in parallel, and the serial numbers of the operations, such as 31, 32, etc., are only used to distinguish different operations, and the serial numbers themselves do not represent any execution order. In addition, these processes can include more or fewer operations, and the operations can be executed in sequence or in parallel. It should be noted that the "first", "second" and the like in this text are used to distinguish different messages, devices, modules, etc., and do not represent the order, nor do "first" and "second" represent different types.
[0103] FIG. 5a and FIG. 5b are structural schematic diagrams of a domain name resolution apparatus according to another example embodiment of the present disclosure. In some embodiments, as shown in FIG. 5a, the domain name resolution apparatus can include: a receiving module 501 configured to receive a first domain name query request of an application server in the available region, the first domain name query request including a domain name to be queried; a first recursive query module 502 configured to, in a case where the IP address corresponding to the domain name to be queried does not exist in a local cache, perform recursive query on a public domain name server in a public domain name resolution system; and a second recursive query module 503 configured to, in a case where the public domain name server does not return a domain name query result, send the domain name to be queried and an identifier of the available region to a centralized domain name server in a private domain name resolution system, so that the centralized domain name server performs recursive query according to a maintained domain name query result, a correspondence between the domain name query result and the available region, the identifier of the available region, and the domain name to be queried; the domain name query result including the domain name to be queried and an IP address corresponding to the domain name to be queried.
[0104] Optionally, when the first recursive query module 502 performs recursive query on the public domain name server in a case where the IP address corresponding to the domain name to be queried does not exist in the local cache, the first recursive query module 502 is specifically configured to: query whether the IP address corresponding to the domain name to be queried exists in the local cache according to the first domain name query request; and in a case where the IP address corresponding to the domain name to be queried does not exist in the local cache, send a second domain name query request to the public domain name server, the second domain name query request including the domain name to be queried, so as to perform recursive query on the public domain name server.
[0105] Optionally, when the first recursive query module 502 performs recursive query on the centralized domain name server in the private domain name resolution system in a case where the public domain name server does not return the domain name query result according to the domain name to be queried and the identifier of the available region, the first recursive query module 502 is specifically configured to: in a case where the public domain name server does not return the domain name query result, send a third domain name query request to the centralized domain name server, the third domain name query request including the domain name to be queried and the identifier of the available region, so as to perform recursive query on the centralized domain name server.
[0106] Optionally, the second recursive query module 503 is further configured to: before the recursive query to the centralized domain name server, or in the case of failure of the recursive query from the centralized domain name server, send a fourth domain name query request to a resolution data collection device affiliated to the availability zone in the private domain name resolution system, the fourth domain name query request comprising the domain name to be queried, to perform a recursive query to the resolution data collection device; in the case of querying the IP address corresponding to the domain name to be queried from the resolution data collection device, return the IP address corresponding to the domain name to be queried to the application server; wherein the resolution data collection device is configured to collect the domain name query result returned by the public domain name server and report to the centralized domain name server.
[0107] Optionally, before the recursive query to the public domain name server or the centralized domain name server, the second recursive query module 503 is further configured to: according to the latest received heartbeat message from the public domain name server or the centralized domain name server, determine whether the communication connection between the local domain name server and the public domain name server or the centralized domain name server is maintained; in the case of determining that the communication connection between the local domain name server and the public domain name server or the centralized domain name server is maintained, perform the recursive query to the public domain name server or the centralized domain name server.
[0108] In some embodiments, as shown in FIG. 5b, the domain name resolution device can comprise: a collection module 504 configured to, in the process that the local domain name server provides the domain name recursive query service for the application server in the availability zone in the order of the local cache, the public domain name server in the public domain name resolution system, and the centralized domain name server in the private domain name resolution system, collect the domain name query result returned by the public domain name server; stop the domain name recursive query service after collecting the domain name query result returned by the public domain name server, the domain name query result comprising a domain name to be queried and an IP address corresponding to the domain name to be queried; a reporting module 505 configured to report the domain name query result to the centralized domain name server, so that the centralized domain name server maintains the correspondence between the domain name query result and the availability zone, and the correspondence is used for the local domain name server to provide the domain name recursive query service.
[0109] Optionally, when the collection module 504 collects the domain name query result returned by the public domain name server, it is specifically configured to: acquire the domain name query result returned by the public domain name server from the local cache of the local domain name server; and in the case of accumulating the domain name query result to a set number, report the set number of domain name query results to the centralized domain name server.
[0110] Optionally, the collecting module 504 acquires the domain name query result returned by the public domain name server from the local cache of the local domain name server, and specifically configured to: periodically poll the local cache of the local domain name server, and read the new domain name query result from the local cache in the case of finding new domain name query result; or receive a notification message sent by the local domain name server, the notification message being sent by the local domain name server in the case of receiving the new domain name query result returned by the public domain name server; and read the new domain name query result from the local cache of the local domain name server according to the notification message.
[0111] In the embodiment, a private domain name resolution system is additionally provided, wherein the local domain name server can provide domain name recursive query service for the application server in the available area to which the local domain name server belongs in the order of local cache, public domain name server and centralized domain name server; the resolution data collecting device can collect the domain name query result returned by the public domain name server and report to the centralized domain name server; and the centralized domain name server can maintain the domain name query result and the corresponding relationship between the domain name query result and the available area. In this way, even if the link between the local domain name server and the public domain name server is unstable or the public domain name server is abnormal, the local domain name server can provide domain name recursive query service for the application server in the available area to which the local domain name server belongs according to the corresponding relationship maintained by the centralized domain name server, thereby solving the problem of failure to query the authoritative domain name server and improving the success rate of domain name resolution.
[0112] The internal functions and structures of the domain name resolution device are described above, and as shown in FIG. 6, in practice, the domain name resolution device can be implemented as an electronic device, including a memory 601, a processor 602 and a communication component 603.
[0113] The memory 601 is configured to store computer programs and can be configured to store other various data to support operation on the computing platform. Examples of these data include instructions of any application program or method for operating on the computing platform, contact data, phonebook data, messages, pictures, videos, etc.
[0114] The memory 601 can be implemented by any type of volatile or non-volatile storage 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 memory, flash memory, magnetic disk or optical disk.
[0115] In some embodiments, the processor 602, coupled with the memory 601, is configured to execute a computer program in the memory 601 for: receiving a first domain name query request of an application server in the available region, the first domain name query request comprising a domain name to be queried; in a case where the local cache does not exist an IP address corresponding to the domain name to be queried, performing a recursive query to a public domain name server in a public domain name resolution system; in a case where the public domain name server does not return a domain name query result, sending the domain name to be queried and an identifier of the available region to a centralized domain name server in the private domain name resolution system, so that the centralized domain name server performs a recursive query according to a maintained domain name query result and a corresponding relationship between the domain name query result and the available region, the identifier of the available region, and the domain name to be queried; the domain name query result comprising the domain name to be queried and an IP address corresponding to the domain name to be queried.
[0116] Optionally, when the processor 602 performs the recursive query to the public domain name server in a case where the local cache does not exist the IP address corresponding to the domain name to be queried, the processor 602 is specifically configured to: query whether the local cache exists the IP address corresponding to the domain name to be queried according to the first domain name query request; in a case where the local cache does not exist the IP address corresponding to the domain name to be queried, send a second domain name query request to the public domain name server, the second domain name query request comprising the domain name to be queried, so as to perform the recursive query to the public domain name server.
[0117] Optionally, when the processor 602 performs the recursive query to the centralized domain name server in the private domain name resolution system according to the domain name to be queried and the identifier of the available region in a case where the public domain name server does not return the domain name query result, the processor 602 is specifically configured to: in a case where the public domain name server does not return the domain name query result, send a third domain name query request to the centralized domain name server, the third domain name query request comprising the domain name to be queried and the identifier of the available region, so as to perform the recursive query to the centralized domain name server.
[0118] Optionally, the processor 602 is further configured to: before performing the recursive query to the centralized domain name server, or in a case where the recursive query to the centralized domain name server fails, send a fourth domain name query request to a resolution data collection device belonging to the available region in the private domain name resolution system, the fourth domain name query request comprising the domain name to be queried, so as to perform the recursive query to the resolution data collection device; in a case where the resolution data collection device returns the IP address corresponding to the domain name to be queried, return the IP address corresponding to the domain name to be queried to the application server; wherein the resolution data collection device is configured to collect the domain name query result returned by the public domain name server and report to the centralized domain name server.
[0119] Optionally, the processor 602 is further configured to, before performing the recursive query to the public domain name server or the centralized domain name server, determine whether a communication connection is maintained between the local domain name server and the public domain name server or the centralized domain name server according to a latest heartbeat message received from the public domain name server or the centralized domain name server, and perform the recursive query to the public domain name server or the centralized domain name server in a case where it is determined that the communication connection is maintained between the local domain name server and the public domain name server or the centralized domain name server.
[0120] In some other embodiments, the processor 602, coupled with the memory 601, is configured to execute a computer program in the memory 601, so as to: collect a domain name query result returned by the public domain name server in a process in which the local domain name server sequentially provides a domain name recursive query service for an application server in the available zone according to an order of a local cache, the public domain name server in the public domain name resolution system, and the centralized domain name server in the private domain name resolution system; stop the domain name recursive query service after the domain name query result returned by the public domain name server is collected, the domain name query result comprising a domain name to be queried and an IP address corresponding to the domain name to be queried; and report the domain name query result to the centralized domain name server, so that the centralized domain name server maintains a correspondence between the domain name query result and the available zone, and the correspondence is used for the local domain name server to provide the domain name recursive query service.
[0121] Optionally, when the processor 602 collects the domain name query result returned by the public domain name server, the processor 602 is specifically configured to: acquire the domain name query result returned by the public domain name server from a local cache of the local domain name server; and report the set number of domain name query results to the centralized domain name server in a case where the domain name query results accumulate to a set number.
[0122] Optionally, when the processor 602 acquires the domain name query result returned by the public domain name server from the local cache of the local domain name server, the processor 602 is specifically configured to: periodically poll the local cache of the local domain name server, and read a new domain name query result from the local cache in a case where the new domain name query result is found; or receive a notification message sent by the local domain name server, the notification message being sent by the local domain name server in a case where the local domain name server receives a new domain name query result returned by the public domain name server; and read the new domain name query result from the local cache of the local domain name server according to the notification message.
[0123] Further, as shown in FIG. 6, the electronic device also includes other components such as a power supply component 604. Only some components are shown in FIG. 6, and the computing platform is not meant to include only the components shown in FIG. 6.
[0124] Accordingly, the embodiments of the present disclosure further provide a computer readable storage medium storing a computer program, which is executed to implement each step that can be executed by the electronic device in the above method embodiments.
[0125] Accordingly, the embodiments of the present disclosure further provide a computer program product, which includes computer programs / instructions, when executed by a processor, performs the domain name resolution method.
[0126] In the present embodiment, a private domain name resolution system is added, in which the local domain name server can provide domain name recursive query service for the application servers in the available zone to which the local domain name server belongs in the order of local cache, public domain name server and centralized domain name server; the resolution data collection device can collect the domain name query result returned by the public domain name server and report it to the centralized domain name server; the centralized domain name server can maintain the domain name query result and the corresponding relationship between the domain name query result and the available zone. In this way, even if the link between the local domain name server and the public domain name server is unstable or the public domain name server is abnormal, the local domain name server can provide domain name recursive query service for the application servers in the available zone to which the local domain name server belongs according to the corresponding relationship maintained by the centralized domain name server, thereby solving the problem of failure to query the authoritative domain name server and improving the success rate of domain name resolution.
[0127] The memory can be implemented by any type of volatile or nonvolatile storage devices 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.
[0128] The communication component is configured to facilitate wired or wireless communication between the device on which the communication component is located and other devices. The device on which the communication component is located can access a wireless network based on a communication standard, such as WiFi, a 2G, 3G, 4G / LTE, 5G, or the like mobile communication network, or a combination thereof. In an example embodiment, the communication component receives broadcast signals or broadcast related information from an external broadcast management system via a broadcast channel. In an example embodiment, the communication component also includes a Near Field Communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on Radio Frequency Identification (RFID) technology, Infrared Data Association (IrDA) technology, Ultra Wide Band (UWB) technology, BlueTooth (BT) technology, and other technologies.
[0129] The power supply component provides power to various components of the device on which the power supply component is located. The power supply component can include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the device on which the power supply component is located.
[0130] Those skilled in the art will understand that embodiments of the present disclosure can be provided as a method, a system, or a computer program product. Accordingly, the present disclosure can take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present disclosure can take the form of a computer program product on one or more computer-readable storage media (including, but not limited to, disk memory, Compact Disc Read-Only Memory (CD-ROM), optical memory, and the like) embodying computer usable program code.
[0131] The present disclosure is described with reference to the accompanying drawings, which show example embodiments of the present disclosure. The drawings provided are for illustrative purposes only and, as such, should not limit the scope or applicability of the present disclosure. In fact, this disclosure can apply to any device, component, or system that is configured to function according to the principles of the present disclosure. Based on the disclosure and its principles, a person of ordinary skill in the art can utilize any number of techniques already known or later developed for carrying out the functions described herein.
[0132] These computer program instructions can also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instructions which implement the function specified in the flowchart or flow diagram block or blocks and / or the flowchart or flow diagram block or blocks.
[0133] These computer program instructions can also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart or flow diagram block or blocks and / or the flowchart or flow diagram block or blocks.
[0134] In one typical configuration, the computing device includes one or more processors (Central Processing Unit, CPU), input / output interfaces, network interfaces, and memory.
[0135] The memory can include non-persistent memory and / or volatile memory, such as random access memory (RAM) and / or cache memory. The memory can also include non-volatile memory, such as read-only memory (ROM), electrically programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), flash memory, or non-volatile random access memory (NVRAM). The memory is an example of computer readable media.
[0136] Computer readable media includes permanent and non-permanent, removable and non-removable media implemented in any method or technology for storage of information such as computer readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase-change random access memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disc read-only memory (CD-ROM), digital video disc (DVD), or other optical storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other non-transmission medium that can be used to store information accessible to a computing device. According to the definition herein, computer readable media does not include transitory media, such as modulated data signals and carrier waves.
[0137] It should also be noted that the terms "comprising", "comprises", "including", "includes" or any other variation thereof are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but can include other elements not expressly listed or inherent to such process, method, article, or apparatus. An element proceeded by "comprises a... " does not, without more constraints, exclude the existence of additional identical elements in the process, method, article, or apparatus that comprises the element.
[0138] The above embodiments of the present disclosure are only used to illustrate the technical solutions of the present disclosure, and not intended to limit the present disclosure. Although the present disclosure has been described in detail with reference to the embodiments, the technical solutions in the embodiments are only used to explain the present disclosure, and not intended to limit the present disclosure.
Claims
1. A domain name resolution system, wherein, include: Public domain name resolution systems and private domain name resolution systems; The public domain name resolution system includes: a public domain name server; the private domain name resolution system includes: a centralized domain name server, and a local domain name server and resolution data collection device deployed in at least one availability zone; The local domain name server is interconnected with the centralized domain name server and the public domain name server, respectively, and is used to provide recursive domain name query services to the application servers in their respective availability zones in the order of local cache, the public domain name server and the centralized domain name server, and to stop the recursive domain name query service when the domain name query result is obtained. The data collection device is used to collect the domain name query results returned by the public domain name server during the domain name recursive query service, and report them to the centralized domain name server. The domain name query results include the domain name to be queried and the IP address corresponding to the domain name to be queried. The centralized domain name server is used to maintain the domain name query results reported by the resolution data collection device and their correspondence with availability zones. The correspondence is used to provide domain name recursive query services to the local domain name server.
2. A domain name resolution method, wherein, The method, which applies to a local domain name server in any availability zone, wherein the local domain name server belongs to a private domain name resolution system, includes: Receive a first domain name query request from the application server within the availability zone, wherein the first domain name query request includes the domain name to be queried; If the IP address corresponding to the domain name to be queried does not exist in the local cache, a recursive query is performed on the public domain name server in the public domain name resolution system; If the public domain name server does not return a domain name query result, the domain name to be queried and the identifier of the availability zone are sent to the centralized domain name server in the private domain name resolution system. The centralized domain name server then performs a recursive query based on the maintained domain name query results and their correspondence with the availability zone, the identifier of the availability zone, and the domain name to be queried. The domain name query result includes the domain name to be queried and the IP address corresponding to the domain name to be queried.
3. The method of claim 2, wherein, If the IP address corresponding to the domain name to be queried does not exist in the local cache, a recursive query is performed on the public domain name server in the public domain name resolution system, including: Based on the first domain name query request, check whether the IP address corresponding to the domain name to be queried exists in the local cache; If the IP address corresponding to the domain name to be queried does not exist in the local cache, a second domain name query request is sent to the public domain name server. The second domain name query request includes the domain name to be queried, so as to perform a recursive query to the public domain name server.
4. The method of claim 2, wherein, If the public domain name server does not return a domain name query result, a recursive query is performed on the centralized domain name server in the private domain name resolution system based on the domain name to be queried and the identifier of the availability zone, including: In the case that the public domain name server does not return the domain name query result, a third domain name query request is sent to the centralized domain name server, the third domain name query request comprising the domain name to be queried and the identifier of the available zone, so as to perform recursive query on the centralized domain name server.
5. The method of claim 2, wherein, Also comprising: Before performing recursive query on the centralized domain name server, or in the case that recursive query on the centralized domain name server fails, a fourth domain name query request is sent to a resolution data collection device belonging to the available zone in the private domain name resolution system, the fourth domain name query request comprising the domain name to be queried, so as to perform recursive query on the resolution data collection device; In the case that the IP address corresponding to the domain name to be queried is queried from the resolution data collection device, the IP address corresponding to the domain name to be queried is returned to the application server; wherein the resolution data collection device is configured to collect the domain name query result returned by the public domain name server and report to the centralized domain name server.
6. The method according to any one of claims 2-5, wherein, Before performing recursive query on the public domain name server or the centralized domain name server, further comprising: According to the latest received heartbeat message from the public domain name server or the centralized domain name server, it is determined whether the local domain name server and the public domain name server or the centralized domain name server maintain communication connection; In the case that it is determined that the local domain name server and the public domain name server or the centralized domain name server maintain communication connection, recursive query is performed on the public domain name server or the centralized domain name server.
7. A domain name resolution method wherein, The resolution data collection device applied to any available zone, the available zone further comprising a local domain name server, the resolution data collection device and the local domain name server belonging to a private domain name resolution system, the method comprising: In the process that the local domain name server provides domain name recursive query service for application servers in the available zone in the order of local cache, public domain name server in a public domain name resolution system and centralized domain name server in the private domain name resolution system, the domain name query result returned by the public domain name server is collected; After the domain name query result returned by the public domain name server is collected, the domain name recursive query service is stopped, the domain name query result comprising a domain name to be queried and an IP address corresponding to the domain name to be queried; The domain name query result is reported to the centralized domain name server, so that the centralized domain name server maintains the correspondence between the domain name query result and the available zone, and the correspondence is used for the local domain name server to provide domain name recursive query service.
8. The method of claim 7, wherein, The domain name query result returned by the public domain name server is collected, comprising: The domain name query result returned by the public domain name server is obtained from the local cache of the local domain name server; and In the case that the domain name query result accumulates to a set number, the set number of domain name query results are reported to the centralized domain name server.
9. The method of claim 8, wherein, obtaining the domain name query result returned by the public domain name server from a local cache of the local domain name server, comprising: periodically polling the local cache of the local domain name server, and in the case of finding new domain name query result, reading the new domain name query result from the local cache; or receiving a notification message sent by the local domain name server, the notification message being sent by the local domain name server in the case of receiving new domain name query result returned by the public domain name server; and reading the new domain name query result from the local cache of the local domain name server according to the notification message.
10. An electronic device, comprising: comprising: a memory and a processor; the memory is configured to store one or more computer instructions; the processor is configured to execute the one or more computer instructions to perform the steps in the method of any one of claims 2-9.
11. A computer readable storage medium storing a computer program, wherein, When the computer program is executed by the processor, the processor is enabled to implement the steps in the method of any one of claims 2-9.
12. A computer program product, wherein, comprising computer program / instructions, when the computer program / instructions are executed by the processor, the method of any one of claims 2-9 is performed.
Citation Information
Patent Citations
Method for resolving with public DNS (Domain Name System) server, system and server
CN106453685A
Domain name resolution method and device based on available area, equipment and machine readable medium
CN113596185A
Domain name resolution method and device
CN116112466A
Domain name system (DNS) optimization for wide area networks
US20200120024A1