Domain name server configuration method, device, equipment, medium and product

CN123020563APending Publication Date: 2026-10-30BEIJING XIAOMI MOBILE SOFTWARE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510573155.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-30
Publication Date
2026-10-30

AI Technical Summary

Technical Problem

然而,由于电子设备在不同网络环境或不同地理位置进行切换的情况,并且不同地理位置或不同网络环境的域名解析服务所需的性能不同,因此采用固定配置域名服务器的方式,将影响电子设备网络访问的性能,影响用户体验感

Benefits of technology

[0020]本公开的实施例提供的技术方案可以包括以下有益效果:确定待配置域名服务器的电子设备的地理位置,并获取匹配地理位置的域名服务器集合,使得可以精准定位到适用于当前地理位置的域名服务器。从匹配地理位置的域名服务器集合中选择性能最优的目标域名服务器,为电子设备配置性能最优的目标服务器,从而提升电子设备网络通信的性能。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123020563A_ABST
    Figure CN123020563A_ABST
Patent Text Reader

Abstract

The present disclosure relates to a domain name server configuration method, device, equipment, medium and product. The domain name server configuration method comprises: determining the geographical position of an electronic device to be configured with a domain name server; obtaining a domain name server set matching the geographical position, and selecting a target domain name server with the best performance in the domain name server set; and configuring the target domain name server for the electronic device. The domain name server configuration method proposed in the present disclosure improves the performance of network communication of the electronic device.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This disclosure relates to the field of communication technology, and in particular to a method, apparatus, device, medium and product for configuring a domain name server. Background Technology

[0002] With the continuous development of communication technology, domain name resolution services are playing an increasingly important role in the communication process.

[0003] In related technologies, electronic devices typically use a domain name server (DNS) with a fixed configuration at the device's underlying layer for network access. However, because electronic devices switch between different network environments or geographical locations, and the performance requirements for DNS resolution services vary across different locations or network environments, using a fixed DNS server configuration will affect the network access performance of electronic devices and impact user experience. Summary of the Invention

[0004] To overcome the problems existing in related technologies, this disclosure provides a method, apparatus, device, medium and product for configuring a domain name server.

[0005] According to some embodiments of this disclosure, a method for configuring a domain name server is provided, comprising: determining the geographical location information of an electronic device to be configured with a domain name server; obtaining a set of domain name servers matching the geographical location, and selecting the target domain name server with the best performance from the set of domain name servers; and configuring the target domain name server for the electronic device.

[0006] In some implementations, selecting the target domain name server with the best performance from the set of domain name servers includes at least one of the following: selecting the domain name server with the shortest response latency from the set of domain name servers as the target domain name server; selecting the domain name server with the strongest stability from the set of domain name servers as the target domain name server, wherein the stability is determined based on the standard deviation of the response latency of the domain name server at different times; selecting a domain name server with a matching degree greater than a matching degree threshold from the set of domain name servers as the target domain name server, wherein the matching degree is determined based on the distance between the geographical location of the domain name server and the geographical location of the electronic device.

[0007] In some implementations, obtaining the set of domain name servers matching the geographical location includes: retrieving a historical data set corresponding to the geographical location based on the geographical location, wherein at least one domain name server is pre-built and stored in the historical data set, and the at least one domain name server is ordered sequentially based on the response latency; and determining the set of domain name servers matching the geographical location based on the historical data set.

[0008] In some embodiments, the method further includes: monitoring domain name servers corresponding to the geographical location based on preset rules, and using the monitored domain name servers as candidate domain name servers; in response to the candidate domain name servers being different from each domain name server in the historical data set, comparing the performance of the candidate domain name servers with that of each domain name server in the historical data set; and in response to the performance of the candidate domain name servers being better than that of each domain name server in the historical data set, updating the domain name server set based on the candidate domain name servers.

[0009] In some implementations, the historical data set is determined as follows: Domain name server query logs are obtained, including a correspondence between domain name servers, geographical locations, times, and response latency. In this correspondence, multiple domain name servers correspond to the same geographical location, and multiple response latencies correspond to the same domain name server at the same geographical location. Each of these response latencies corresponds to a specific time. Based on the multiple domain name servers corresponding to the same geographical location, an average response latency is determined for each domain name server based on each response latency at different times. Based on the average response latency, the multiple domain name servers corresponding to the same geographical location are sorted from smallest to largest to obtain the historical data set.

[0010] In some embodiments, the method further includes: in response to a change in the geographical location of the electronic device and / or a change in the network environment of the electronic device, re-determining the target domain name server corresponding to the electronic device, and switching the target domain name server corresponding to the electronic device to the re-determined target domain name server.

[0011] According to a second aspect of some embodiments of the present disclosure, a domain name server configuration apparatus is provided, comprising: a determining unit for determining the geographical location of an electronic device to be configured with a domain name server; an obtaining unit for obtaining a set of domain name servers matching the geographical location and selecting a target domain name server with the best performance from the set of domain name servers; and a configuring unit for configuring the target domain name server for the electronic device.

[0012] In some implementations, selecting the target domain name server with the best performance from the set of domain name servers includes at least one of the following: selecting the domain name server with the shortest response latency from the set of domain name servers as the target domain name server; selecting the domain name server with the strongest stability from the set of domain name servers as the target domain name server, wherein the stability is determined based on the standard deviation of the response latency of the domain name server at different times; selecting a domain name server with a matching degree greater than a matching degree threshold from the set of domain name servers as the target domain name server, wherein the matching degree is determined based on the distance between the geographical location of the domain name server and the geographical location of the electronic device.

[0013] In some implementations, the acquisition unit acquires the set of domain name servers matching the geographical location in the following manner: based on the geographical location, it retrieves a historical data set corresponding to the geographical location, wherein at least one domain name server is pre-built and stored in the historical data set, and the at least one domain name server is ordered in order based on the response latency; based on the historical data set, it determines the set of domain name servers matching the geographical location.

[0014] In some embodiments, the acquisition unit is further configured to: monitor domain name servers corresponding to the geographical location based on preset rules, and use the monitored domain name servers as candidate domain name servers; in response to the candidate domain name servers being different from each domain name server in the historical data set, compare the performance of the candidate domain name servers with that of each domain name server in the historical data set; in response to the performance of the candidate domain name servers being better than that of each domain name server in the historical data set, update the domain name server set based on the candidate domain name servers.

[0015] In some implementations, the historical data set is determined as follows: Domain name server query logs are obtained, including a correspondence between domain name servers, geographical locations, times, and response latency. In this correspondence, multiple domain name servers correspond to the same geographical location, and multiple response latencies correspond to the same domain name server at the same geographical location. Each of these response latencies corresponds to a specific time. Based on the multiple domain name servers corresponding to the same geographical location, an average response latency is determined for each domain name server based on each response latency at different times. Based on the average response latency, the multiple domain name servers corresponding to the same geographical location are sorted from smallest to largest to obtain the historical data set.

[0016] In some implementations, the configuration unit is further configured to: in response to a change in the geographical location of the electronic device and / or a change in the network environment of the electronic device, re-determine the target domain name server corresponding to the electronic device, and switch the target domain name server corresponding to the electronic device to the re-determined target domain name server.

[0017] According to a third aspect of the present disclosure, an electronic device is provided, comprising: a processor; a memory for storing processor-executable instructions; wherein the processor is configured to: execute the domain name server configuration method described in the first aspect or any embodiment of the first aspect.

[0018] According to a fourth aspect of the present disclosure, a storage medium is provided, the storage medium storing instructions that, when executed by a processor, enable the processor to execute the domain name server configuration method described in the first aspect or any embodiment of the first aspect.

[0019] According to a fifth aspect of the present disclosure, a computer program product is provided, the computer program product including a computer program, which, when executed by a processor, implements the domain name server configuration method described in the first aspect or any embodiment of the first aspect.

[0020] The technical solutions provided by the embodiments of this disclosure can include the following beneficial effects: determining the geographical location of the electronic device to be configured with a domain name server, and obtaining a set of domain name servers matching the geographical location, so as to accurately locate the domain name server suitable for the current geographical location. Selecting the target domain name server with the best performance from the set of domain name servers matching the geographical location, and configuring the electronic device with the target server with the best performance, thereby improving the network communication performance of the electronic device.

[0021] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit this disclosure. Attached Figure Description

[0022] The accompanying drawings, which are incorporated in and form a part of this specification, illustrate embodiments consistent with this disclosure and, together with the description, serve to explain the principles of this disclosure.

[0023] Figure 1 This is a flowchart illustrating a method for configuring a domain name server according to some embodiments of the present disclosure.

[0024] Figure 2 This is a process for obtaining a domain name server matching a geographical location, as illustrated in some embodiments of this disclosure. Figure 1 .

[0025] Figure 3 This is a flowchart illustrating a method for determining a set of historical data according to some embodiments of this disclosure.

[0026] Figure 4 This is a process for obtaining a domain name server matching a geographical location, as illustrated in some embodiments of this disclosure. Figure 2 .

[0027] Figure 5 This is a schematic diagram illustrating the configuration of a domain name server according to some embodiments of this disclosure.

[0028] Figure 6 This is a block diagram illustrating a configuration apparatus for a domain name server according to some embodiments of the present disclosure.

[0029] Figure 7 This is a configuration device block for a domain name server shown according to some embodiments of the present disclosure. Figure 1 .

[0030] Figure 8 This is a configuration device block for a domain name server shown according to some embodiments of the present disclosure. Figure 2 . Detailed Implementation

[0031] Some embodiments of this disclosure will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings denote the same or similar elements. Various changes, modifications, and equivalents of the methods, apparatus, and / or systems described herein will become apparent upon understanding this disclosure. For example, the order of operations described herein is merely illustrative and is not limited to those orders set forth herein, but can be changed as will become apparent upon understanding this disclosure, except for operations that must be performed in a particular order. Furthermore, for clarity and brevity, descriptions of features known in the art may be omitted.

[0032] With the continuous development of communication technology, people have increasingly higher requirements for the resolution efficiency of domain name resolution services in different scenarios. Taking the scenario of electronic devices making network access requests as an example, in related technologies, when a user uses an electronic device to make a network access request, a domain name server is usually used to perform domain name resolution services for the network access request. This enables the electronic device to convert the domain name entered by the user into the IP address required for inter-machine communication, thereby successfully establishing a connection and accessing network resources.

[0033] In related technologies, when an electronic device makes a network access request, the domain name server configured in the device is usually the default domain name server provided by the ISP, or manually set by the user based on commonly used domain name servers. However, once assigned or set, the domain name server used by the electronic device remains unchanged for a long period. However, with the development of network technology, network conditions vary significantly across different geographical locations and network environments. The response latency of the domain name server is affected by factors such as network environment and geographical location. Therefore, if a fixed domain name server is used in the electronic device, the user's experience of making network access requests varies depending on the geographical location and network environment, and optimal experience cannot be guaranteed. Furthermore, if the fixed domain name server in the electronic device malfunctions, it may prevent the user from accessing the network normally in the current geographical location. In this case, the electronic device cannot automatically obtain the domain name server with the best performance matching the current geographical location, thus causing the user to be unable to communicate with the network for a long time.

[0034] Therefore, in related technologies, there is a problem that electronic devices cannot determine the domain name server with the best network communication performance based on the geographical location of the electronic device during network communication.

[0035] In view of this, some embodiments of this disclosure provide a method for configuring a domain name server, which determines the geographical location of an electronic device, thereby configuring the electronic device with a target domain name server that has the best performance for the corresponding geographical location, and improving the network communication performance of the electronic device.

[0036] It should be noted that the domain name server configuration method provided in this disclosure can be applied to electronic devices. Electronic devices may include, for example, terminals or servers. Terminals include, for example, mobile phones, wearable devices, IoT devices, automobiles with communication capabilities, smart cars, tablets, computers with wireless transceiver capabilities, virtual reality (VR) terminal devices, augmented reality (AR) terminal devices, wireless terminal devices in industrial control, wireless terminal devices in self-driving, wireless terminal devices in remote medical surgery, wireless terminal devices in smart grids, wireless terminal devices in transportation safety, wireless terminal devices in smart cities, and wireless terminal devices in smart homes, but are not limited to these. Servers may include, but are not limited to, independent physical servers, server clusters or distributed systems composed of multiple physical servers, or cloud servers that provide basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, content delivery networks (CDN), and big data and artificial intelligence platforms.

[0037] The embodiments disclosed herein can be applied to various scenarios, including but not limited to network communication scenarios, such as scenarios where electronic devices make network access requests.

[0038] For ease of understanding, some technical terms involved in the embodiments of this disclosure will be explained by way of example below:

[0039] Domain Name Server (DNS): A server that translates domain names into their corresponding IP addresses. In some embodiments of this disclosure, the DNS server maintains a table of domain names and their corresponding IP addresses to resolve the domain names of network communication requests.

[0040] A domain name server set typically refers to a group of domain name servers that provide domain name resolution services for a specific geographical location and network environment, enabling efficient and fast use of the domain name servers in the set for domain name resolution. In some embodiments of this disclosure, the domain name server set corresponds to the geographical location of the electronic device and stores at least one domain name server.

[0041] Response latency refers to the time difference between initiating a request and receiving a response to that request, and is a key indicator for measuring network performance. In some embodiments of this disclosure, response latency refers to the time required from the moment an electronic device sends a query request for a domain name resolution service to the moment it receives the corresponding IP address from the domain name server.

[0042] The embodiments described in the following examples of this disclosure are not representative of all embodiments consistent with this disclosure. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this disclosure as detailed in the appended claims.

[0043] This disclosure provides some implementation methods for configuring domain name servers, which are applied to network communication scenarios.

[0044] Figure 1 This is a flowchart illustrating a method for configuring a domain name server according to some embodiments of the present disclosure. The method for configuring a domain name server is applied to electronic devices (e.g., including terminals or servers), and includes the following steps.

[0045] In step S11, the geographical location of the electronic device to be configured with the domain name server is determined.

[0046] In step S12, a set of domain name servers matching the geographical location is obtained, and the target domain name server with the best performance is selected from the set of domain name servers.

[0047] In step S13, the target domain name server is configured for the electronic device.

[0048] It should be noted that this disclosure does not limit the determination of the geographical location of the electronic device to be configured with the domain name server, for example, by monitoring the IP address of the electronic device or by locating the geographical location of the electronic device according to the Global Positioning System (GPS).

[0049] In this embodiment, a target domain name server with optimal performance that matches the geographical location of the electronic device is selected to improve the performance of subsequent network communication using the electronic device. Furthermore, configuring the electronic device with the optimal target domain name server can reduce the risk of service interruption due to network congestion or server overload, thereby enhancing the stability and reliability of network connections.

[0050] In this embodiment of the disclosure, the above content is described in the following manner.

[0051] Figure 2 This is a process for obtaining a domain name server matching a geographical location, as illustrated in some embodiments of this disclosure. Figure 1 .like Figure 2 As shown, it includes the following steps.

[0052] In step S21, based on the geographical location, the historical data set corresponding to the geographical location is retrieved.

[0053] In step S22, a set of domain name servers matching the geographical location is determined based on the historical data set.

[0054] In some implementations, based on the city where the electronic device is located or the location of the corresponding base station, a pre-stored set of historical data corresponding to the current geographical location is retrieved from a cloud server. This set of historical data, sorted sequentially according to response latency, is determined as a domain name server set, and the domain name server with the best performance is selected from this set as the target domain name server.

[0055] It should be noted that at least one domain name server is pre-built and stored in the historical data set, and the at least one domain name server is ordered in order based on the size of the response latency.

[0056] In this embodiment, by using a pre-built and stored historical data set of domain name servers related to geographical location, data matching the current geographical location can be directly retrieved, thereby improving the lookup speed for determining the required domain name server. Furthermore, since the domain name servers in the historical data set have been sorted according to response latency, the domain name server with the shortest response latency can be quickly selected based on the sorting results.

[0057] Regarding the above discussion, the domain name server set can be determined based on a historical data set, which is typically pre-stored and predetermined. To facilitate understanding of how the historical data set is determined, this disclosure will adopt the following approach... Figure 3 The method shown illustrates the process of determining the historical data set.

[0058] Figure 3This is a flowchart illustrating the determination of a historical data set according to some embodiments of this disclosure. For example... Figure 3 As shown, it includes the following steps.

[0059] In step S31, the domain name server query log is obtained.

[0060] In step S32, based on multiple domain name servers corresponding to the same geographical location, the average response latency is determined for each domain name server based on each response latency at different times.

[0061] In step S33, based on the average response latency, multiple domain name servers corresponding to the same geographical location are sorted in ascending order to obtain a historical data set.

[0062] It's important to understand that the DNS query log includes the correspondence between DNS servers, geographical locations, times, and response times. Specifically, the same geographical location corresponds to multiple DNS servers, the same DNS server at the same geographical location corresponds to multiple response times, and each of these response times corresponds to its own specific time.

[0063] In one example, to facilitate understanding of the correspondence in the DNS query logs, we will use the example of DNS servers A1 and A2 at geographical location P1, and DNS servers A1 and B2 at geographical location P2 to illustrate the correspondence between DNS servers, geographical locations, time, and response latency in the DNS query logs. For the same geographical location P1, there can be multiple DNS servers such as DNS server A1 and DNS server A2. For the same DNS server A1, the response latency can be obtained in both geographical location P1 and geographical location P2. Furthermore, for DNS server A1 in geographical location P1, there is the response latency B1 at time T1 and the response latency B2 at time T2.

[0064] In one example, to facilitate understanding of the average response latency, we will use the example of DNS servers A1, A2, and A3 located at geographical location P1 to illustrate the average response latency. For DNS server A1 at geographical location P1, we obtain a response latency B1 at time T1, B2 at time T2, and B3 at time T3. Let S1 represent the average response latency of DNS server A1 at geographical location P1, then S1 = B1 + B2 + B3 / 3.

[0065] Using the same method as above, the average response latency S2 of domain name server A2 and the average response latency S3 of domain name server A3 at geographical location P1 are determined respectively. The magnitudes of the average response latency S1, S2 and S3 are compared. The domain name servers A1, A2 and A3 at geographical location P1 are then sorted in ascending order according to the magnitudes of their corresponding average response latency S1, S2 and S3 to obtain the historical data set.

[0066] The above example uses three domain name servers located in the same geographical location as an illustration, but it is not a limitation and other values ​​are also possible.

[0067] In some implementations, large-scale data collection mechanisms, such as collaboration with network operators or network service providers, are used to collect DNS query logs from different DNS servers. Alternatively, DNS servers configured in electronic devices can be used to conduct periodic or continuous response latency tests in different geographical locations or network environments to determine their performance and obtain their query logs. Based on these query logs, the response latency of each DNS server in different cities, tracking area codes (TACs), and network environments is determined. The collected DNS server information is then aggregated by city or base station to obtain at least one DNS server corresponding to each geographical location. Data mining and analysis techniques are used to analyze the response performance of each DNS server under different network conditions, resulting in a historical dataset. This database reflects the performance of each DNS server in different geographical locations and network environments. Within this historical dataset, the mean response latency of each DNS server at different times can be used to characterize its response latency, and the standard deviation of the response latency at different times can be used to evaluate the stability of the DNS server performance.

[0068] In this embodiment, by integrating response latency at different times and calculating the average response latency, the impact of individual outliers caused by network fluctuations and other factors can be effectively reduced, thereby obtaining more accurate and reliable performance evaluation results. Determining the target domain name server based on historical data sets matching the geographical location of the electronic device allows for the rapid configuration of the optimal target domain name server for the electronic device, thereby improving the speed of network communication for the electronic device in its current geographical location.

[0069] Based on the above content of this disclosure, electronic devices can also be used to monitor the domain name server corresponding to the current geographical location in real time, thereby optimizing the electronic device's selection of the domain name server in the current geographical location.

[0070] Figure 4 This is a process for obtaining a domain name server matching a geographical location, as illustrated in some embodiments of this disclosure. Figure 2 .like Figure 4 As shown, it includes the following steps.

[0071] In step S41, domain name servers corresponding to the geographical location are monitored based on preset rules, and the monitored domain name servers are used as candidate domain name servers.

[0072] In step S42, in response to the candidate domain name server being different from each domain name server in the historical data set, the performance of the candidate domain name server is compared with that of each domain name server in the historical data set.

[0073] In step S43, in response to the fact that the performance of the candidate domain name server is better than that of each domain name server in the historical data set, the domain name server set is updated based on the candidate domain name server.

[0074] It is important to understand that the preset rules can be either real-time monitoring of the domain name server in the corresponding geographical location, or periodic monitoring of the domain name server in the corresponding geographical location based on a set fixed interval.

[0075] In some implementations, candidate domain name servers obtained from monitoring by preset rules are compared with historical data sets to update the domain name server set. Then, the domain name server with the best performance is selected from the updated domain name server set, which optimizes the selection process of the target domain name server. This enables electronic devices to continuously use the target domain name server with the best performance in the corresponding geographical location.

[0076] In this embodiment, real-time monitoring and dynamic adjustment allow for rapid adaptation to changes in network conditions. For example, some domain name servers may become slower due to increased load or network failures, while others may become more efficient due to optimization or upgrades. Real-time monitoring ensures that electronic devices use the optimal-performing domain name server. Furthermore, selecting the domain name server with the lowest response latency as a candidate domain name server and updating the domain name server set reduces domain name resolution time and improves network access speed. By employing real-time monitoring and updating, electronic devices can access the network using the optimal target domain name server at any time.

[0077] Based on the above discussion, once the set of domain name servers is obtained according to the geographical location of the electronic device, the target domain name server needs to be determined from the set of domain name servers.

[0078] The target domain name server can be determined, for example, by at least one of the following methods (A1) to A3):

[0079] A1) Select the domain name server with the shortest response latency from the set of domain name servers as the target domain name server.

[0080] A2) Select the most stable domain name server from the set of domain name servers as the target domain name server.

[0081] A3) Select a domain name server in the set of domain name servers whose matching degree is greater than the matching degree threshold as the target domain name server.

[0082] For A1), for example, the average response latency of each domain name server collected at different times in the domain name server set can be determined as the standard for comparing the response latency of each domain name server, so that the domain name server with the shortest response latency among all domain name servers can be selected as the target domain name server.

[0083] For A2), for example, it could be that in the set of domain name servers, the standard deviation of the response latency collected at different times for each domain name server is determined, and the standard deviation of the response latency is used as the standard for judging the stability of the domain name server, so that the domain name server with the strongest stability among all domain name servers is selected as the target domain name server.

[0084] It's important to understand that stability is determined based on the standard deviation of the response latency of a domain name server at different times. For example, the smaller the standard deviation of the response latency of each domain name server at different times, the more stable the domain name server is in the current network environment, and thus the more stable the domain name server is in providing domain name resolution services.

[0085] In one example, to facilitate understanding of the standard deviation of response latency, we will use the following examples at geographical location P1: the average response latency of domain name server A1 is S1, the average response latency of domain name server A2 is S2, and the average response latency of domain name server A3 is S3. For the average response latency of domain name server A1 at geographical location P1, we obtain the square of the difference between response latency B1 and the average response latency S1 at time T1, the square of the difference between response latency B2 and the average response latency S1 at time T2, and the square of the difference between response latency B3 and the average response latency S1 at time T3, M3. Based on M1, M2, and M3, we determine the standard deviation of the response latency of domain name server A1 at geographical location P1.

[0086] Using the same method as above, the standard deviation of the response latency of domain name server A2 at geographical location P1 and the standard deviation of the response latency of domain name server A3 are determined respectively. The magnitude of the standard deviation of the response latency between different domain name servers is compared to determine the stability of each domain name server in the current network environment in the domain name server set, and then the target domain name server is determined.

[0087] For A3), for example, it could be to determine the geographical location of each domain name server in the set of domain name servers, calculate the matching degree between the geographical location of each domain name server and the geographical location of the electronic device, and take the domain name server with the highest matching degree as the target domain name server.

[0088] It's important to understand that the matching degree is determined based on the distance between the geographical location of the domain name server and the geographical location of the electronic device. For example, a higher matching degree between the domain name server and the electronic device indicates that the geographical locations of the domain name servers in the set are closer to the geographical location of the electronic device. Since the response latency of a domain name server is affected by geographical location, selecting a domain name server geographically close to the electronic device reduces the network communication request time caused by the distance between the domain name server and the electronic device, thereby improving the speed of network communication for the electronic device in its current geographical location. Furthermore, due to geographical proximity, the electronic device can reduce the number of intermediate transmission nodes during the network request process, thus reducing network request instability caused by too many intermediate nodes and improving network request stability.

[0089] In this embodiment, the method for determining the target domain name server described above can be based on a comprehensive consideration of multiple factors, such as response latency, stability, and geographical location of the domain name server set. This allows for the selection of the optimal-performing domain name server from the set, resulting in the shortest response latency and highest stability of the target domain name server configured for the electronic device, thereby improving domain name resolution speed and network access speed.

[0090] Based on the above, it is clear that the optimal target domain name server should be configured for the electronic device according to its geographical location. When the current state of the electronic device changes, the target domain name server needs to be reconfigured.

[0091] In one example, when the geographical location of the electronic device changes, the target domain name server corresponding to the electronic device is re-determined, and the target domain name server corresponding to the electronic device is switched to the re-determined target domain name server.

[0092] In another example, when the network environment of the electronic device changes, the target domain name server corresponding to the electronic device is re-determined, and the target domain name server corresponding to the electronic device is switched to the re-determined target domain name server.

[0093] In another example, when the geographical location and network environment of the electronic device change, the target domain name server corresponding to the electronic device is re-determined, and the target domain name server corresponding to the electronic device is switched to the re-determined target domain name server.

[0094] In this embodiment of the disclosure, the target domain name server corresponding to the electronic device is re-determined according to changes in the geographical location or network environment of the electronic device. This allows for dynamic adjustment regardless of changes in geographical location or network environment, ensuring that the electronic device always uses the most suitable domain name server. This enhances the adaptability and flexibility of the domain name server configuration and improves the user experience.

[0095] To facilitate understanding of the above-mentioned domain name server configuration methods, this disclosure adopts the following... Figure 5 The method shown will be further explained.

[0096] Figure 5 This is a schematic diagram illustrating the configuration of a domain name server according to some embodiments of this disclosure.

[0097] exist Figure 5This example uses an electronic device as the terminal and historical data stored on a cloud server. The cloud server first collects DNS query response data by gathering data from service provider partners and terminal network data. This data is then aggregated into a dataset containing DNS server response latency for each city and TAC region. The performance stability of the DNS servers is evaluated based on the mean or standard deviation of the response latency. Finally, the cloud server distributes the historically optimal DNS server set to the terminal based on the city and TAC. After establishing a data link with the cloud, the terminal requests the DNS server set from the cloud and periodically tests the response latency of the currently used DNS server. If a candidate DNS server with a lower response latency than the historical dataset is found, the terminal switches to that candidate server and feeds the test results back to the cloud. Alternatively, based on the mean or standard deviation of the response latency, the terminal switches to the currently optimal DNS server and updates the data to the cloud, thus forming a closed-loop optimization process.

[0098] In this embodiment, data from different service providers and terminal networks is collected and analyzed to identify the optimal target domain name server for each city and TAC region. This improves the speed of domain name resolution services and reduces service interruptions caused by overload or failure of specific domain name servers. Terminals monitor domain name server performance in real time and automatically switch to a better server based on actual conditions. This allows for rapid adaptation to changes in geographical location and network environment, reduces latency, and improves network connection stability and reliability, thereby enhancing the user's network communication experience.

[0099] Figure 6 This is a block diagram illustrating a configuration apparatus for a domain name server according to some embodiments of the present disclosure. (Refer to...) Figure 6 The device 100 includes a determining unit 101, an acquiring unit 102, and a configuring unit 103.

[0100] The determining unit 101 is used to determine the geographical location of the electronic device to be configured with the domain name server.

[0101] The acquisition unit 102 is used to acquire a set of domain name servers that match the geographical location, and select the target domain name server with the best performance from the set of domain name servers.

[0102] Configuration unit 103 is used to configure the target domain name server for electronic devices.

[0103] In some implementations, selecting the target domain name server with the best performance from the set of domain name servers includes at least one of the following: selecting the domain name server with the shortest response latency from the set of domain name servers as the target domain name server; selecting the domain name server with the strongest stability from the set of domain name servers as the target domain name server, wherein stability is determined based on the standard deviation of the response latency of the domain name server at different times; selecting a domain name server with a matching degree greater than a matching degree threshold from the set of domain name servers as the target domain name server, wherein the matching degree is determined based on the distance between the geographical location of the domain name server and the geographical location of the electronic device.

[0104] In some implementations, the acquisition unit 102 acquires the set of domain name servers matching the geographical location in the following manner: based on the geographical location, it retrieves the historical data set corresponding to the geographical location, wherein at least one domain name server is pre-built and stored in the historical data set, and the at least one domain name server is sorted in order based on the size of the response latency; based on the historical data set, it determines the set of domain name servers matching the geographical location.

[0105] In some implementations, the acquisition unit 102 is further configured to: monitor domain name servers corresponding to geographical locations based on preset rules, and use the monitored domain name servers as candidate domain name servers; in response to the candidate domain name servers being different from the domain name servers in the historical data set, compare the performance of the candidate domain name servers with that of the domain name servers in the historical data set; and in response to the performance of the candidate domain name servers being better than that of the domain name servers in the historical data set, update the domain name server set based on the candidate domain name servers.

[0106] In some implementations, the historical data set is determined as follows: Domain name server query logs are obtained, which include the correspondence between domain name servers, geographical locations, times, and response latency. In this correspondence, multiple domain name servers correspond to the same geographical location, and the same domain name server corresponds to multiple response latencies at the same geographical location. Each response latency corresponds to its own time. Based on the multiple domain name servers corresponding to the same geographical location, the average response latency is determined for each domain name server based on each response latency at different times. Based on the average response latency, the multiple domain name servers corresponding to the same geographical location are sorted in ascending order to obtain the historical data set.

[0107] In some implementations, the configuration unit 103 is further configured to: in response to a change in the geographical location of the electronic device and / or a change in the network environment of the electronic device, re-determine the target domain name server corresponding to the electronic device and switch the target domain name server corresponding to the electronic device to the re-determined target domain name server.

[0108] Regarding the apparatus in the above embodiments, the specific manner in which each module performs its operation has been described in detail in the embodiments related to the method, and will not be elaborated upon here.

[0109] Figure 7 This is a configuration device block for a domain name server shown according to some embodiments of the present disclosure. Figure 1 For example, device 200 can be a mobile phone, computer, digital broadcasting terminal, messaging device, game console, tablet device, medical device, fitness equipment, personal digital assistant, etc.

[0110] Reference Figure 7 The device 200 may include one or more of the following components: processing component 202, memory 204, power component 206, multimedia component 208, audio component 210, input / output (I / O) interface 212, sensor component 214, and communication component 216.

[0111] Processing component 202 typically controls the overall operation of device 200, such as operations associated with display, telephone calls, data communication, camera operation, and recording. Processing component 202 may include one or more processors 220 to execute instructions to perform all or part of the steps of the methods described above. Furthermore, processing component 202 may include one or more modules to facilitate interaction between processing component 202 and other components. For example, processing component 202 may include a multimedia module to facilitate interaction between multimedia component 208 and processing component 202.

[0112] Memory 204 is configured to store various types of data to support the operation of device 200. Examples of such data include instructions for any application or method operating on device 200, contact data, phonebook data, messages, pictures, videos, etc. Memory 204 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 storage, flash memory, magnetic disk, or optical disk.

[0113] The power supply component 206 provides power to the various components of the device 200. The power supply component 206 may include a power management system, one or more power sources, and other components associated with generating, managing, and distributing power to the device 200.

[0114] Multimedia component 208 includes a screen that provides an output interface between the device 200 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touchscreen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensors may sense not only the boundaries of the touch or swipe action but also the duration and pressure associated with the touch or swipe operation. In some embodiments, multimedia component 208 includes a front-facing camera and / or a rear-facing camera. When the device 200 is in an operating mode, such as a shooting mode or a video mode, the front-facing camera and / or the rear-facing camera may receive external multimedia data. Each front-facing camera and rear-facing camera may be a fixed optical lens system or have focal length and optical zoom capabilities.

[0115] Audio component 210 is configured to output and / or input audio signals. For example, audio component 210 includes a microphone (MIC) configured to receive external audio signals when device 200 is in an operating mode, such as call mode, recording mode, and voice recognition mode. The received audio signals may be further stored in memory 204 or transmitted via communication component 216. In some embodiments, audio component 210 also includes a speaker for outputting audio signals.

[0116] I / O interface 212 provides an interface between processing component 202 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to, home buttons, volume buttons, power buttons, and lock buttons.

[0117] Sensor assembly 214 includes one or more sensors for providing status assessments of various aspects of device 200. For example, sensor assembly 214 may detect the on / off state of device 200, the relative positioning of components such as the display and keypad of device 200, changes in the position of device 200 or a component of device 200, the presence or absence of user contact with device 200, the orientation or acceleration / deceleration of device 200, and temperature changes of device 200. Sensor assembly 214 may include a proximity sensor configured to detect the presence of nearby objects without any physical contact. Sensor assembly 214 may also include an optical sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, sensor assembly 214 may also include an accelerometer, a gyroscope, a magnetometer, a pressure sensor, or a temperature sensor.

[0118] Communication component 216 is configured to facilitate wired or wireless communication between device 200 and other devices. Device 200 can access wireless networks based on communication standards, such as WiFi, 3G, 4G, 5G, other communication standards, or combinations thereof. In some embodiments of this disclosure, communication component 216 receives broadcast signals or broadcast-related information from an external broadcast management system via a broadcast channel. In some embodiments of this disclosure, communication component 216 further includes a near-field communication (NFC) module to facilitate short-range communication. For example, the NFC module may be implemented based on radio frequency identification (RFID) technology, Infrared Data Association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.

[0119] In some embodiments of this disclosure, the apparatus 200 may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field-programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to perform the methods described above.

[0120] In some embodiments of this disclosure, a storage medium including instructions is also provided, such as a memory 204 including instructions, which can be executed by the processor 220 of the device 200 to perform the above-described method. For example, the storage medium may be a ROM, random access memory (RAM), CD-ROM, magnetic tape, floppy disk, and optical data storage device, etc.

[0121] In some embodiments of this disclosure, a storage medium is provided, which may be a non-transitory computer-readable storage medium.

[0122] In some embodiments of this disclosure, when instructions in the storage medium are executed by the processor of an electronic device, the electronic device is able to perform the methods described above.

[0123] Figure 8 This is a configuration device block for a domain name server shown according to some embodiments of the present disclosure. Figure 2 For example, device 300 can be provided as a server. (See reference...) Figure 8 The device 300 includes a processing component 322, which further includes one or more processors, and memory resources represented by memory 332 for storing instructions, such as application programs, that can be executed by the processing component 322. The application programs stored in memory 332 may include one or more modules, each corresponding to a set of instructions. Furthermore, the processing component 322 is configured to execute instructions to perform the methods described above.

[0124] Device 300 may also include a power supply component 326 configured to perform power management of device 300, a wired or wireless network interface 350 configured to connect device 300 to a network, and an input / output (I / O) interface 352. Device 300 may operate on an operating system stored in memory 332, such as Windows Server™, Mac OS X™, Unix™, Linux™, FreeBSD™, or similar.

[0125] In some embodiments of this disclosure, a storage medium including instructions is also provided, such as a memory 332 including instructions, which can be executed by the processing component 322 of the device 300 to perform the above-described method. For example, the storage medium may be a ROM, random access memory (RAM), CD-ROM, magnetic tape, floppy disk, and optical data storage device, etc.

[0126] In some embodiments of this disclosure, a storage medium is provided, which may be a non-transitory computer-readable storage medium.

[0127] In some embodiments of this disclosure, when instructions in the storage medium are executed by the processor of an electronic device, the electronic device is able to perform the methods described above.

[0128] In some embodiments of this disclosure, a computer program product is also provided, including a computer program that, when executed by a processor, implements the domain name server configuration method involved in any of the above embodiments.

[0129] In one exemplary embodiment, the processor executing the computer program may be deployed in an electronic device, for example.

[0130] Those skilled in the art will also understand that the various illustrative logical blocks and steps listed in the embodiments of this application can be implemented by electronic hardware, computer software, or a combination of both. Whether such functionality is implemented through hardware or software depends on the specific application and the overall system design requirements. Those skilled in the art can implement the described functionality using various methods for each specific application, but such implementation should not be construed as exceeding the scope of protection of the embodiments of this application.

[0131] In the above detailed description, reference has been made to the accompanying drawings, which illustrate specific aspects of this disclosure by way of illustration. In this regard, terms indicating direction or positional relationship, such as “center,” “longitudinal,” “lateral,” “length,” “width,” “thickness,” “upper,” “lower,” “front,” “rear,” “left,” “right,” “vertical,” “horizontal,” “top,” “bottom,” “inner,” “outer,” “clockwise,” “counterclockwise,” “axial,” “radial,” and “circumferential,” are used with reference to the orientation of the described figures. Since components of the described device can be positioned in multiple different orientations, directional terms are used for illustrative purposes and not for limitation. It should be understood that other aspects can be utilized and structural or logical changes can be made without departing from the concept of this disclosure. Therefore, the following detailed description should not be considered limiting.

[0132] It should be understood that, unless otherwise specifically indicated, features of various embodiments of this disclosure described herein can be combined with each other. As used herein, the term "and / or" includes any of the associated listed items and any combination of any two or more; it should be understood that, unless otherwise expressly specified and limited, the terms "joining," "attaching," "mounting," "connecting," "linking," "fixing," etc., used in the embodiments of this disclosure should be interpreted broadly, for example, as a fixed connection, a detachable connection, or an integral part; as a mechanical connection, an electrical connection, or a communicative connection; as a direct connection or an indirect connection through an intermediate medium; as a connection within two elements or an interaction between two elements, unless otherwise expressly limited. Those skilled in the art will understand the specific meaning of the above terms herein according to the specific circumstances.

[0133] Furthermore, the term "above" as used herein with respect to components, elements, or material layers formed or located "above" a surface may be used to indicate that the component, element, or material layer is "indirectly" positioned (e.g., placed, formed, deposited, etc.) on the surface such that one or more additional components, elements, or layers are arranged between the surface and the component, element, or material layer. However, the term "above" as used with respect to components, elements, or material layers formed or located "above" a surface may also optionally have a specific meaning: that the component, element, or material layer is "directly" positioned (e.g., placed, formed, deposited, etc.) on the surface, for example, in direct contact with the surface.

[0134] It should be understood that spatial relative terms, such as “above,” “upper,” “below,” and “lower,” are used herein to describe the relationship between one element and another shown in the figures. In addition to the orientation depicted in the figures, these spatial relative terms are also intended to encompass different orientations of the device in use or operation. For example, if the device in the figures is flipped, an element described as “above” or “upper” relative to another element would be “below” or “lower” relative to that other element. Thus, depending on the spatial orientation of the device, the term “above” encompasses both above and below orientations. Devices may have other orientations (e.g., rotated 90 degrees or in other orientations), and the spatial relative terms used herein should be interpreted accordingly.

[0135] Although terms such as “first,” “second,” and “third” may be used herein to describe various components, parts, regions, layers, or sections, these components, parts, regions, layers, or sections are not limited to these terms. Rather, these terms are used only to distinguish one component, part, region, layer, or section from another. Therefore, without departing from the teachings of the examples described herein, a first component, part, region, layer, or section mentioned in the examples may also be referred to as a second component, part, region, layer, or section. Furthermore, the terms “first” and “second” are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features. Thus, a feature defined as “first” or “second” may explicitly or implicitly include at least one of that feature.

[0136] It is further understood that the terms "first," "second," etc., are used to describe various types of information, but this information should not be limited to these terms. These terms are only used to distinguish information of the same type from one another, and do not indicate a specific order or degree of importance. In fact, the expressions "first," "second," etc., are completely interchangeable. For example, without departing from the scope of this disclosure, first information can also be referred to as second information, and similarly, second information can also be referred to as first information.

[0137] In this description, "multiple" means at least two, referring to two or more, such as two, three, etc., unless otherwise explicitly specified. Other quantifiers are similar. The singular forms "a," "the," and "the" are also intended to include the plural forms unless the context clearly indicates otherwise. Furthermore, unless otherwise specified or clearly indicated from the context, the articles "a" and "an" as used in this application and the appended claims are generally understood to mean "one or more."

[0138] It should be understood that, unless otherwise specifically indicated, features of various embodiments of this disclosure described herein can be combined with each other. As used herein, the term "and / or" includes any one of the related listed items and any combination of two or more; "and / or" describes the association relationship between related objects, indicating that three relationships may exist, for example, A and / or B can represent: A alone, A and B simultaneously, and B alone. The character " / " generally indicates that the preceding and following related objects are in an "or" relationship. Similarly, "at least one of..." includes any one of the related listed items and any combination of two or more.

[0139] It is further understood that the terms "first," "second," etc., are used to describe various types of information, but this information should not be limited to these terms. These terms are only used to distinguish information of the same type from one another, and do not indicate a specific order or degree of importance. In fact, the expressions "first," "second," etc., are completely interchangeable. For example, without departing from the scope of this disclosure, first information can also be referred to as second information, and similarly, second information can also be referred to as first information.

[0140] Furthermore, the term "exemplary" is used herein to indicate that it serves as an example, instance, or illustration. Any aspect or design described herein as "exemplary" is not necessarily to be construed as advantageous compared to other aspects or designs. Rather, the use of the term "exemplary" is intended to present concepts in a concrete manner. As used herein, the term "or" is intended to indicate an inclusive "or" rather than an exclusive "or." That is, unless otherwise specified or clear from the context, "X applies A or B" is intended to indicate any of the natural inclusive permutations. That is, if X applies A; X applies B; or X applies both A and B, then applying A or B satisfies the condition under any of the foregoing instances.

[0141] Similarly, although this disclosure has been shown and described with respect to one or more implementations, equivalent variations and modifications will occur to those skilled in the art upon reading and understanding the specification and drawings. This disclosure includes all such modifications and variations and is limited only by the scope of the claims. In particular, with respect to the various functions performed by the components described above (e.g., elements, resources, etc.), unless otherwise indicated, the terminology used to describe such components is intended to correspond to any component (functionally equivalent) that performs the specific function of the described component, even if it is not structurally equivalent to the disclosed structure. Furthermore, although specific features of this disclosure may have been disclosed with respect to only one of several implementations, such features may be combined with one or more other features of other implementations, as may be desired and advantageous to any given or particular application. Moreover, with regard to the terms “comprising,” “owning,” “having,” “having,” or variations thereof as used in this disclosure, such terms are intended to be inclusive in a manner similar to the term “including.”

[0142] Other embodiments of this disclosure will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of this disclosure that follow the general principles of this disclosure and include common knowledge or customary techniques in the art not disclosed herein.

[0143] It should be understood that this disclosure is not limited to the precise structures described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of this disclosure is limited only by the appended claims.

Claims

1. A method for configuring a domain name server, characterized in that, include: Determine the geographical location of the electronic device for which the domain name server is to be configured; Obtain a set of domain name servers that match the geographical location, and select the target domain name server with the best performance from the set of domain name servers; Configure the target domain name server for the electronic device.

2. The method according to claim 1, characterized in that, The selection of the target domain name server with the best performance from the set of domain name servers includes at least one of the following: Select the domain name server with the shortest response latency from the set of domain name servers as the target domain name server; The domain name server with the strongest stability is selected from the set of domain name servers as the target domain name server, wherein the stability is determined based on the standard deviation of the response latency of the domain name server at different times; In the set of domain name servers, a domain name server with a matching degree greater than the matching degree threshold is selected as the target domain name server, wherein the matching degree is determined based on the distance between the geographical location of the domain name server and the geographical location of the electronic device.

3. The method according to claim 1 or 2, characterized in that, The step of obtaining the set of domain name servers matching the geographical location includes: Based on the geographical location, retrieve the historical data set corresponding to the geographical location. The historical data set contains at least one domain name server pre-built and stored, and the at least one domain name server is sorted in order based on the response latency. Based on the historical data set, a set of domain name servers matching the geographical location is determined.

4. The method according to claim 3, characterized in that, The method further includes: Based on preset rules, the domain name servers corresponding to the geographical location are monitored, and the monitored domain name servers are used as candidate domain name servers. In response to the fact that the candidate domain name server is different from each domain name server in the historical data set, the performance of the candidate domain name server is compared with that of each domain name server in the historical data set; In response to the fact that the performance of the candidate domain name server is better than that of each domain name server in the historical data set, the domain name server set is updated based on the candidate domain name server.

5. The method according to claim 3, characterized in that, The historical data set was determined in the following manner: Obtain the domain name server query log, which includes the correspondence between domain name servers, geographical locations, times, and response delays. In the correspondence, multiple domain name servers correspond to the same geographical location, and multiple response delays correspond to the same domain name server at the same geographical location. Each of the multiple response delays corresponds to its own time. Based on multiple domain name servers corresponding to the same geographical location, the average response latency is determined for each domain name server based on each response latency at different times. Based on the average response latency, the multiple domain name servers corresponding to the same geographical location are sorted in ascending order to obtain the historical data set.

6. The method according to claim 1, characterized in that, The method further includes: In response to a change in the geographical location of the electronic device and / or a change in the network environment of the electronic device, the target domain name server corresponding to the electronic device is re-determined, and the target domain name server corresponding to the electronic device is switched to the re-determined target domain name server.

7. A configuration device for a domain name server, characterized in that, include: The determining unit is used to determine the geographical location of the electronic device to be configured with the domain name server; The acquisition unit is used to acquire a set of domain name servers that match the geographical location, and select the target domain name server with the best performance from the set of domain name servers; A configuration unit is used to configure the target domain name server for the electronic device.

8. The apparatus according to claim 7, characterized in that, The selection of the target domain name server with the best performance from the set of domain name servers includes at least one of the following: Select the domain name server with the shortest response latency from the set of domain name servers as the target domain name server; The domain name server with the strongest stability is selected from the set of domain name servers as the target domain name server, wherein the stability is determined based on the standard deviation of the response latency of the domain name server at different times; In the set of domain name servers, a domain name server with a matching degree greater than the matching degree threshold is selected as the target domain name server, wherein the matching degree is determined based on the distance between the geographical location of the domain name server and the geographical location of the electronic device.

9. The apparatus according to claim 7 or 8, characterized in that, The acquisition unit acquires the set of domain name servers matching the geographical location in the following manner: Based on the geographical location, retrieve the historical data set corresponding to the geographical location. The historical data set contains at least one domain name server pre-built and stored, and the at least one domain name server is sorted in order based on the response latency. Based on the historical data set, a set of domain name servers matching the geographical location is determined.

10. The apparatus according to claim 9, characterized in that, The acquisition unit is also used for: Based on preset rules, the domain name servers corresponding to the geographical location are monitored, and the monitored domain name servers are used as candidate domain name servers. In response to the fact that the candidate domain name server is different from each domain name server in the historical data set, the performance of the candidate domain name server is compared with that of each domain name server in the historical data set; In response to the fact that the performance of the candidate domain name server is better than that of each domain name server in the historical data set, the domain name server set is updated based on the candidate domain name server.

11. The apparatus according to claim 9, characterized in that, The historical data set was determined in the following manner: Obtain the domain name server query log, which includes the correspondence between domain name servers, geographical locations, times, and response delays. In the correspondence, multiple domain name servers correspond to the same geographical location, and multiple response delays correspond to the same domain name server at the same geographical location. Each of the multiple response delays corresponds to its own time. Based on multiple domain name servers corresponding to the same geographical location, the average response latency is determined for each domain name server based on each response latency at different times. Based on the average response latency, the multiple domain name servers corresponding to the same geographical location are sorted in ascending order to obtain the historical data set.

12. The apparatus according to claim 7, characterized in that, The configuration unit is also used for: In response to a change in the geographical location of the electronic device and / or a change in the network environment of the electronic device, the target domain name server corresponding to the electronic device is re-determined, and the target domain name server corresponding to the electronic device is switched to the re-determined target domain name server.

13. An electronic device, characterized in that, include: processor; Memory used to store computer programs or instructions that can be executed by a processor; The processor is configured to execute the computer program or instructions to implement the steps of the domain name server configuration method according to any one of claims 1 to 6.

14. A storage medium, characterized in that, The storage medium stores a computer program or instructions that, when executed by a processor of an electronic device, enable the electronic device to perform the domain name server configuration method according to any one of claims 1 to 6.

15. A computer program product, characterized in that, It includes a computer program that, when executed by a processor, implements the configuration method for a domain name server as described in any one of claims 1 to 6.