CN113037680A - Application server access method and device based on domain name resolution result - Google Patents

Application server access method and device based on domain name resolution result Download PDF

Info

Publication number
CN113037680A
CN113037680A CN201911249812.9A CN201911249812A CN113037680A CN 113037680 A CN113037680 A CN 113037680A CN 201911249812 A CN201911249812 A CN 201911249812A CN 113037680 A CN113037680 A CN 113037680A
Authority
CN
China
Prior art keywords
application server
address
network
domain name
addresses
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201911249812.9A
Other languages
Chinese (zh)
Inventor
王进
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhongying Youchuang Information Technology Co Ltd
Original Assignee
Zhongying Youchuang Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhongying Youchuang Information Technology Co Ltd filed Critical Zhongying Youchuang Information Technology Co Ltd
Priority to CN201911249812.9A priority Critical patent/CN113037680A/en
Publication of CN113037680A publication Critical patent/CN113037680A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/10Network architectures or network communication protocols for network security for controlling access to devices or network resources
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • H04L61/45Network directories; Name-to-address mapping
    • H04L61/4505Network directories; Name-to-address mapping using standardised directories; using standardised directory access protocols
    • H04L61/4511Network directories; Name-to-address mapping using standardised directories; using standardised directory access protocols using domain name system [DNS]

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Hardware Design (AREA)
  • Computer Security & Cryptography (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention discloses an application server access method and device based on domain name resolution results, wherein the method comprises the following steps: acquiring a plurality of application server IP addresses corresponding to a domain name to be accessed; obtaining a ping test result corresponding to each application server IP address; extracting one or more network indexes corresponding to the IP address of each application server according to the ping test result; determining the network service quality of each application server IP address according to each network index corresponding to each application server IP address; and returning the IP addresses of the application servers to the client according to the sequence of the network service quality from top to bottom, so that the client can access the application server corresponding to the domain name to be accessed based on the returned IP addresses of the application servers. The invention can return the IP address of the application server with the optimal network service quality according to the real-time change of the network quality under the condition that the same domain name corresponds to a plurality of IP addresses of the application server.

Description

Application server access method and device based on domain name resolution result
Technical Field
The invention relates to the field of internet, in particular to an application server access method and device based on domain name resolution results.
Background
This section is intended to provide a background or context to the embodiments of the invention that are recited in the claims. The description herein is not admitted to be prior art by inclusion in this section.
As is well known, devices on the internet communicate by IP addresses, but since IP addresses are inconvenient to memorize, in order to make it easier for a person to access the internet, DNS servers have appeared which enable mutual mapping between domain names and IP addresses.
After a client initiates a DNS resolution request, a DNS resolution operation is completed by the DNS recursion server issuing a series of requests until the DNS server requesting the record is reached (returning a timeout or error message if no record is found). The presence of DNS caching enables a DNS recursive server to track the records needed to respond to a client without having to issue multiple requests, and it can respond to DNS resolution requests earlier by caching DNS records over a period of time.
Because the DNS recursive server responds to the DNS analysis request of the client based on the DNS cache, before the DNS cache fails, the IP address of the application server obtained based on the same domain name analysis is invariable, and the network quality is changed in real time, the client cannot access the application server with the optimal network service quality by the existing DNS analysis mode.
In view of the above problems, no effective solution has been proposed.
Disclosure of Invention
The embodiment of the invention provides an application server access method based on a domain name resolution result, which is used for solving the technical problems that the existing DNS recursive server responds to a DNS resolution request of a user based on DNS cache, and before the DNS cache fails, the IP address of an application server corresponding to the same domain name remains unchanged, and the application server with the optimal service quality cannot be accessed, and the method comprises the following steps: acquiring a plurality of application server IP addresses corresponding to a domain name to be accessed; obtaining a ping test result corresponding to each application server IP address, wherein the ping test result is a test result obtained by performing ping test on each application server IP address; extracting one or more network indexes corresponding to the IP address of each application server according to the ping test result corresponding to the IP address of each application server; determining the network service quality of each application server IP address according to each network index corresponding to each application server IP address; and returning the IP addresses of the application servers corresponding to the domain names to be accessed to the client according to the sequence of the network service quality from top to bottom, wherein the client accesses the application servers corresponding to the domain names to be accessed based on the returned IP addresses of the application servers.
The embodiment of the invention also provides an application server access device based on the domain name resolution result, which is used for solving the technical problems that the existing DNS recursive server responds to the DNS resolution request of a user based on the DNS cache, and before the DNS cache fails, the IP address of the application server corresponding to the same domain name remains unchanged, and the application server with the optimal service quality cannot be accessed, and the device comprises: the IP address information acquisition module is used for acquiring a plurality of application server IP addresses corresponding to the domain name to be accessed; the ping test module is used for acquiring a ping test result corresponding to each application server IP address, wherein the ping test result is obtained by performing ping test on each application server IP address; the network index extraction module is used for extracting one or more network indexes corresponding to the IP addresses of the application servers according to the ping test results corresponding to the IP addresses of the application servers; the network service quality determining module is used for determining the network service quality of each application server IP address according to each network index corresponding to each application server IP address; and the application server access module is used for returning the IP addresses of the application servers corresponding to the domain names to be accessed to the client according to the sequence of the network service quality from top to bottom, wherein the client accesses the application servers corresponding to the domain names to be accessed based on the returned IP addresses of the application servers.
The embodiment of the invention also provides computer equipment for solving the technical problem that the existing DNS recursive server responds to a DNS analysis request of a user based on DNS cache, before the DNS cache fails, the IP address of an application server corresponding to the same domain name remains unchanged, and the application server with the optimal service quality cannot be accessed.
The embodiment of the invention also provides a computer readable storage medium, which is used for solving the technical problem that the existing DNS recursive server responds to the DNS analysis request of a user based on the DNS cache, and before the DNS cache fails, the IP address of an application server corresponding to the same domain name remains unchanged, so that the application server with the optimal service quality cannot be accessed.
In the embodiment of the invention, after a plurality of application server IP addresses corresponding to a domain name to be accessed are obtained, a ping test result obtained by performing a ping test on each application server IP address is obtained, one or more network indexes corresponding to each application server IP address are extracted according to the ping test result corresponding to each application server IP address, then the network service quality of each application server IP address is evaluated according to each network index corresponding to each application server IP address, and each application server IP address corresponding to the domain name to be accessed is returned to a client according to the sequence of the network service quality from top to bottom, so that the client accesses the application server corresponding to the domain name to be accessed based on the returned application server IP address.
According to the embodiment of the invention, under the condition that the domain name to be accessed corresponds to a plurality of application server IP addresses, the application server IP address with the optimal network service quality is returned according to the real-time network quality change, so that the technical effect of optimal application service access is realized.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts. In the drawings:
fig. 1 is a flowchart of an application server access method based on a domain name resolution result according to an embodiment of the present invention;
FIG. 2 is a schematic diagram of the test results of a 64Bytes test sample according to an embodiment of the present invention;
FIG. 3 is a schematic diagram of the test results of a 128Bytes test sample according to an embodiment of the present invention;
FIG. 4 is a graph illustrating test results of a 512Bytes test sample according to an embodiment of the present invention;
FIG. 5 is a schematic diagram illustrating test results of a 1500Bytes test sample according to an embodiment of the present invention;
fig. 6 is a schematic diagram of an application server access device based on a domain name resolution result according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention more apparent, the embodiments of the present invention are further described in detail below with reference to the accompanying drawings. The exemplary embodiments and descriptions of the present invention are provided to explain the present invention, but not to limit the present invention.
In the description of the present specification, the terms "comprising," "including," "having," "containing," and the like are used in an open-ended fashion, i.e., to mean including, but not limited to. Reference to the description of the terms "one embodiment," "a particular embodiment," "some embodiments," "for example," etc., means that a particular feature, structure, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of the application. In this specification, the schematic representations of the terms used above do not necessarily refer to the same embodiment or example. Furthermore, the particular features, structures, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples. The sequence of steps involved in the embodiments is for illustrative purposes to illustrate the implementation of the present application, and the sequence of steps is not limited and can be adjusted as needed.
An embodiment of the present invention provides an application server access method based on a domain name resolution result, and fig. 1 is a flowchart of an application server access method based on a domain name resolution result provided in an embodiment of the present invention, and as shown in fig. 1, the method may include the following steps:
s101, acquiring a plurality of application server IP addresses corresponding to the domain name to be accessed.
It should be noted that the domain name to be accessed may be a domain name sent by the client when the client accesses the application server; or each domain name stored in the DNS recursive server, where, when the domain name to be accessed is the domain name stored in the recursive server, the step S101 may include the following steps: receiving a DNS domain name resolution request; acquiring response data returned by the DNS recursive server according to the DNS domain name resolution request; generating log information of DNS recursive records according to response data returned by the DNS recursive server according to the DNS domain name resolution request; one or more domain names are extracted according to the log information of the DNS recursive record.
As the number of domain names stored in the DNS recursive server is large, as an optional implementation manner, in the embodiment of the present invention, each domain name may be sorted according to the number of times of domain name resolution request, and a top preset number of domain names (for example, top100 domain names) may be selected. The selection process is described in detail below:
the recursive record format of the DNS recursive server is as follows:
“TIME;VERSION;SRC;DST;PROTOCOL;TTL;SRC_PORT;DST_PORT;TransactionID;QR;Opcode;AA;TC;RD;RA;Z;RCODE;QDCODE;ANCOUNT;NSCOUNT;ARCOUNT;QNAME;QTYPE;QCLASS;Answers;Authorities;Additions”。
the recursive log sample data is as follows:
Sep 6,2019
“14:14:35.827960000;4;114.114.114.114;192.168.3.105;UDP;150;53;58073;0xe93a;1;0;0;0;1;1;0;0;1;2;0;0;t1.baidu.com;A;IN;t1.baidu.com|CNAME|IN|102|17|simage.jomodns.com,simage.jomodns.com|A|IN|34|4|180.163.198.48”。
scanning the recursion recording log according to a preset time interval (for example, in hours), screening out records with both fields of RD and RA being 1 and QTYPE being 'A', extracting QNAME information, intercepting domain name information basic. After the resolution was complete, the following record was formed:
“2019090914,baidu.com,5839234
2019090914,qq.com,2834329
2019090914,Microsoft.com.cn,87324”。
and sorting according to the analysis times, selecting the record before sorting by 100, and storing the record as a file' top-100 _ list.
Alternatively, the IP address list of the application server corresponding to each domain NAME may be extracted, specifically, by analyzing the DNS recursion log IN a preset time period (for example, 5 minutes), extracting the record of the domain NAME IN the TOP100 list, analyzing the response information, extracting the record of TYPE "IN", and obtaining the corresponding relationship between NAME, TTL, and RDATA.
The resource records (Answers/Authorities/Additions) are formatted as follows:
“NAME|TYPE|CLASS|TTL|RDLENGTH|RDATA”;
examples of data are:
“www.a.shifen.com|A|IN|159|4|180.101.49.12”。
after the resolution is completed, the following records are formed for a scenario that a single domain name is resolved to multiple application servers (a single domain name is resolved to only one application server IP, which is not considered in the present invention, and the present invention is suitable for a scenario that a same domain name correspondingly reads multiple application server IP addresses):
“www.a.shifen.com,180.101.49.12|180.101.49.13
www.qq.com,61.151.166.146|61.151.166.139”。
after the above process, an application server IP address list corresponding to each domain name can be extracted and stored as a file "server _ IP _ list.
S102, obtaining ping test results corresponding to the IP addresses of the application servers, wherein the ping test results are obtained by performing ping tests on the IP addresses of the application servers.
It should be noted that, in the embodiment of the present invention, the device that performs ping test on the IP address of each application server and the device that resolves the domain name to be accessed may be the same device, or may be different devices, and when the two devices are the same device, in an optional implementation manner, the step S102 may include the following steps: sending ping test requests to IP addresses of all application servers according to a preset time interval; and receiving a ping test result returned by the IP address of each application server. It should be noted that the preset time interval in the embodiment of the present invention may be arbitrarily set according to a specific application scenario, and a smaller time interval may be set to reflect a real-time network quality change.
For example, for each application server IP address in the file "server _ IP _ list.txt", ping tests of different samples are respectively executed according to a preset time interval (for example, 5 minutes), and a service perception index (i.e., each network index) is obtained.
Taking the domain name "www.qq.com" as an example, the description is as follows:
the packet size specifications for ping test samples are: 64Bytes, 128Bytes, 512Bytes and 1500Bytes, and the actual ping packet size is 22Bytes, 86Bytes, 470Bytes and 1458Bytes respectively, except for network fixed overhead.
FIG. 2 is a schematic diagram of the test results of a 64Bytes test sample according to an embodiment of the present invention; FIG. 3 is a schematic diagram of the test results of a 128Bytes test sample according to an embodiment of the present invention; FIG. 4 is a graph illustrating test results of a 512Bytes test sample according to an embodiment of the present invention; FIG. 5 is a schematic diagram illustrating test results of a 1500Bytes test sample according to an embodiment of the present invention;
and extracting various network indexes such as packet loss rate, RTT minimum time delay, RTT average time delay, RTT maximum time delay, RTT average deviation and the like according to ping measurement results of different samples.
As shown in fig. 2 to 5, four numbers in the ping test result "RTT min/avg/max/mdev ═ 4.116/4.224/4.608/0.146" respectively represent RTT minimum delay, RTT average delay, RTT maximum delay, and RTT average deviation; "0% packet loss" indicates that the packet loss rate is 0%.
Further, in order to calculate each index conveniently, the following normalization logic is performed on the data:
for the packet loss rate of 100%, the minimum RTT time delay is assigned to be 0, the average RTT time delay is assigned to be 500000, and the maximum RTT time delay and the average RTT deviation are assigned to be 1000000, which indicates that the network is unavailable.
② for the packet loss rate of 0%, the packet loss rate is assigned to 0.001%.
Calculating the RTT time delay jitter according to the RTT minimum time delay, the RTT average time delay and the RTT maximum time delay:
RTT delay jitter
Max { abs (RTT average delay-RTT minimum delay), abs (RTT average delay-RTT maximum delay) };
through the above logical processing, a single sample network quality is formed as shown in table 1.
TABLE 1 Single sample network quality
Figure BDA0002308704470000061
Figure BDA0002308704470000071
Further, the test results of different samples corresponding to each application server IP address are subjected to weighted average calculation to obtain the network quality of each application server IP address. Taking the domain name "www.qq.com" as an example, the network service quality obtained by the following formula 61.151.166.146 and 61.151.166.139 are shown in table 2 and table 3, respectively.
TABLE 2 network indices corresponding to IP address 61.151.166.146
Index item 64Bytes 128Bytes 512Bytes 1500Bytes Weighted result
Packet loss rate 0.001 0.001 0.001 0.001 0.001
RTT average time delay 2.973 3.072 3.16 4.224 3.2125
RTT delay jitter 0.536 0.2 0.08 0.384 0.204
Mean variance of RTT 0.252 0.146 0.046 0.146 0.1166
TABLE 3 network metrics corresponding to IP Address 61.151.166.139
Index item 64Bytes 128Bytes 512Bytes 1500Bytes Weighted result
Packet loss rate 0.001 0.001 0.001 0.001 0.001
RTT average time delay 3.134 3.378 3.237 4.061 3.3655
RTT delay jitter 0.437 1.213 0.413 0.16 0.7101
Mean variance of RTT 0.193 0.423 0.147 0.129 0.2602
Assuming that the IP of the application server in the domain name is 61.151.166.x, the 1500Bytes packet sample of the server is tested for 100% packet loss, and then the network index shown in table 4 is obtained:
table 4 network index corresponding to IP address 61.151.166.x
Index item 64Bytes 128Bytes 512Bytes 1500Bytes Weighted result
Packet loss rate 0.001 0.001 0.001 100 10.0009
RTT average time delay 2.973 3.072 3.16 500000 50002.79
RTT delay jitter 0.536 0.2 0.08 500000 50000.17
Mean variance of RTT 0.252 0.146 0.046 500000 50000.1
In summary, the network index corresponding to the IP address of each application server for the domain name "www.qq.com" is shown in table 5.
Table 5 network indices for each IP address corresponding to domain name "www.qq.com
Figure BDA0002308704470000072
Figure BDA0002308704470000081
And S103, extracting one or more network indexes corresponding to the IP addresses of the application servers according to the ping test results corresponding to the IP addresses of the application servers.
It should be noted that each network index extracted from the ping test result through the above-mentioned S103 in the embodiment of the present invention is an index that can be used for evaluating the network service quality of each application server IP address, and may include, but is not limited to, one or more of the following: packet loss rate, RTT average delay, RTT delay jitter, RTT average variance.
And S104, determining the network service quality of the IP address of each application server according to each network index corresponding to the IP address of each application server.
It should be noted that, since the network changes in real time, the network service quality of each application server also changes in real time, and in order to provide the application service with the optimal network service quality, in the embodiment of the present invention, after determining each network index for evaluating the network service quality of each application server IP address, the real-time network service quality of each application server may be determined according to the real-time network index of each application server IP address through the above S104, so that when the domain name to be accessed corresponds to a plurality of application server IP addresses, the application server IP address with good network service quality is preferentially returned.
Optionally, when determining the network service quality of each application server IP address according to each network index corresponding to each application server IP address, an embodiment of the present invention may be implemented by using a Grey correlation Analysis (GRA), and specifically, the S104 may include the following steps: configuring reference values of various network indexes; calculating a correlation coefficient between the index value and the reference value of each network index corresponding to the IP address of each application server; and calculating an average correlation coefficient corresponding to each application server IP address according to the correlation coefficient between the index value of each network index corresponding to each application server IP address and the reference value, wherein the average correlation coefficient corresponding to each application server IP address is used for representing the network service quality of each application server IP address. The reference value of each network index may be an index value corresponding to each network index when the application server provides the optimal network service.
For n IP addresses of the application server, the network service quality of m network indicators is calculated, and a gray relevance analysis algorithm is described below with n being 3 and m being 4 as examples. Assuming that the four network indexes are packet loss rate, RTT average delay, RTT delay jitter, and RTT average variance, respectively, in the embodiment of the present invention, under the condition that the standard network service quality can be defined, the reference value x of each network index corresponding to each application server IP address0Respectively as follows: packet loss rate 0%, RTT average delay 0, RTT delay jitter 0, and RTT average variance 0, then:
Figure BDA0002308704470000091
Figure BDA0002308704470000092
and calculating the correlation coefficient between the index value and the reference value of each network index corresponding to the IP address of each application server by using a grey correlation degree analysis algorithm through the following formula:
Figure BDA0002308704470000093
where ρ ∈ (0, ∞); 1, …, n; k is 1, …, m;
therein, ζi(k) The correlation coefficient between the index value of the kth network index corresponding to the IP address of the ith application server and the reference value is represented; i represents the ith application server IP address; k represents the kth network index; ρ represents a resolution coefficient; x is the number of0(k) A reference value representing a k-th network metric; x is the number ofi(k) Indicating the k network corresponding to the IP address of the ith application serverThe index value of the collateral index.
Figure BDA0002308704470000094
Denotes xi(k) And x0(k) The minimum value of the absolute value of the difference;
Figure BDA0002308704470000095
denotes xi(k) And x0(k) The maximum value of the absolute value of the difference.
It should be noted that the smaller ρ is, the stronger the resolution is, and the value interval of ρ is generally (0,1), and the specific value may be determined according to the circumstances; when ρ ≦ 0.5463, the resolution is best, typically, ρ is 0.5.
Assuming that the three application server IP addresses corresponding to the domain name "www.qq.com" are 61.151.166.146, 61.151.166.139 and 61.151.166.x, respectively, the correlation coefficients between the index values and the reference values of the four network indexes corresponding to the three application server IP addresses are shown in table 6.
TABLE 6 correlation coefficients of four network indexes corresponding to three application server IP addresses
61.151.166.146 61.151.166.139 61.151.166.x
Packet loss rate 1 1 0.00015
Time delay systemNumber of 1 0.999 0.333
Coefficient of jitter 1 0.999 0.333
Coefficient of variance 1 0.999 0.333
Average coefficient 1 0.99925 0.2497875
The network indexes corresponding to the same application server are used as a group, and an average correlation coefficient is calculated, as shown in table 7.
TABLE 7 average correlation coefficient for three application server IP addresses
61.151.166.146 61.151.166.139 61.151.166.x
Correlation coefficient 1 0.99925 0.2497875
From the calculation results shown in table 7, it can be seen that the average correlation coefficient of the IP address 61.151.166.146 is 1, the correlation with the network index of the standard network service quality is strongest, and the correlation of the IP address 61.151.166.x is the worst after the IP address 61.151.166.139 times.
As an alternative implementation, the records may be recorded in the order from high to low network quality, and the file "server _ IP _ pre reference. txt" is stored, so that when the DNS recursive server returns the domain name resolution result, the IP address with high network service quality is preferentially returned. The file internal storage format is as follows:
“www.qq.com,61.151.166.146|61.151.166.139”。
and S105, returning IP addresses of the application servers corresponding to the domain names to be accessed to the client according to the sequence of the network service quality from top to bottom, wherein the client accesses the application servers corresponding to the domain names to be accessed based on the returned IP addresses of the application servers.
For example, when the DNS recursive server returns a domain name resolution result corresponding to the domain name resolution request, it may read a file "server _ IP _ preference.txt", rewrite the domain name response result in the order of the application service IP addresses in the file "server _ IP _ preference.txt", and send the rewritten response packet to the client, thereby implementing application service preference and improving the access perception of the user.
As can be seen from the above, in the application server access method based on the domain name resolution result provided in the embodiment of the present invention, after a plurality of application server IP addresses corresponding to a domain name to be accessed are obtained, a ping test result obtained by performing a ping test on each application server IP address is obtained, one or more network indicators corresponding to each application server IP address are further extracted according to the ping test result corresponding to each application server IP address, then, the network service quality of each application server IP address is evaluated according to each network indicator corresponding to each application server IP address, and each application server IP address corresponding to the domain name to be accessed is returned to the client according to the sequence of network service quality from top to bottom, so that the client accesses the application server corresponding to the domain name to be accessed based on the returned application server IP address.
According to the application server access method based on the domain name resolution result provided by the embodiment of the invention, under the condition that the domain name to be accessed corresponds to a plurality of application server IP addresses, the application server IP address with the optimal network service quality is returned according to the real-time network quality change, so that the technical effect of optimal application service access is realized.
Based on the same inventive concept, an embodiment of the present invention further provides an application server access device based on a domain name resolution result, as described in the following embodiments. Because the principle of solving the problem of the embodiment of the device is similar to the access method of the application server based on the domain name resolution result, the implementation of the embodiment of the device can refer to the implementation of the method, and repeated parts are not described again.
Fig. 6 is a schematic diagram of an application server access device based on a domain name resolution result according to an embodiment of the present invention, and as shown in fig. 6, the device may include: an IP address information acquisition module 61, a ping test module 62, a network index extraction module 63, a network quality of service determination module 64, and an application server access module 65.
The IP address information obtaining module 61 is configured to obtain a plurality of IP addresses of the application server corresponding to the domain name to be accessed; the ping test module 62 is configured to obtain a ping test result corresponding to each application server IP address, where the ping test result is a test result obtained by performing a ping test on each application server IP address; a network index extracting module 63, configured to extract one or more network indexes corresponding to each application server IP address according to a ping test result corresponding to each application server IP address; a network service quality determining module 64, configured to determine the network service quality of each application server IP address according to each network indicator corresponding to each application server IP address; and the application server accessing module 65 is configured to return, to the client, the IP addresses of the application servers corresponding to the domain names to be accessed according to the sequence of the network service quality from top to bottom, where the client accesses the application server corresponding to the domain name to be accessed based on the returned IP address of the application server.
As can be seen from the above, the application server access device based on the domain name resolution result provided in the embodiment of the present invention obtains the ping test result obtained by performing the ping test on the IP address of each application server after obtaining the IP addresses of the multiple application servers corresponding to the domain name to be accessed, further extracts one or more network indicators corresponding to the IP address of each application server according to the ping test result corresponding to the IP address of each application server, then evaluates the network service quality of the IP address of each application server according to each network indicator corresponding to the IP address of each application server, and returns the IP address of each application server corresponding to the domain name to be accessed to the client according to the sequence of the network service quality from top to bottom, so that the client accesses the application server corresponding to the domain name to be accessed based on the returned IP address of the application server.
By the application server access device based on the domain name resolution result provided by the embodiment of the invention, under the condition that the domain name to be accessed corresponds to a plurality of application server IP addresses, the application server IP address with the optimal network service quality is returned according to the real-time network quality change, so that the technical effect of optimal application service access is realized.
In an optional embodiment, in the application server access device based on the domain name resolution result provided in the embodiment of the present invention, the ping test module 62 includes: a ping test request sending module 621, configured to send a ping test request to each application server IP address according to a preset time interval; a ping test result receiving module 622, configured to receive ping test results returned by the IP addresses of the application servers.
In an optional embodiment, in the application server access device based on the domain name resolution result provided in the embodiment of the present invention, the network quality of service determining module 64 includes: a configuration module 641, configured to configure reference values of the network metrics; a first calculating module 642, configured to calculate, according to the formula (3), a correlation coefficient between an index value and a reference value of each network index corresponding to each IP address of the application server; a second calculating module 643, configured to calculate, according to a correlation coefficient between an index value of each network indicator corresponding to each application server IP address and a reference value, an average correlation coefficient corresponding to each application server IP address, where the average correlation coefficient corresponding to each application server IP address is used to characterize network service quality of each application server IP address.
In an optional embodiment, in the application server access device based on the domain name resolution result provided in the embodiment of the present invention, the IP address information obtaining module 61 includes: a domain name resolution request receiving module 611, configured to receive a DNS domain name resolution request; a domain name resolution response data obtaining module 612, configured to obtain response data returned by the DNS recursive server according to the DNS domain name resolution request; a recursive record generating module 613, configured to generate log information of a DNS recursive record according to response data returned by the DNS recursive server according to the DNS domain name resolution request; and a domain name extracting module 614, configured to extract one or more domain names according to the log information of the DNS recursive record.
Optionally, in the application server access device based on the domain name resolution result provided in the embodiment of the present invention, the network indicator includes any one of the following: packet loss rate, RTT average delay, RTT delay jitter, RTT average variance.
The embodiment of the invention also provides computer equipment for solving the technical problem that the existing DNS recursive server responds to a DNS analysis request of a user based on DNS cache, before the DNS cache fails, the IP address of an application server corresponding to the same domain name remains unchanged, and the application server with the optimal service quality cannot be accessed.
The embodiment of the invention also provides a computer readable storage medium, which is used for solving the technical problem that the existing DNS recursive server responds to the DNS analysis request of a user based on the DNS cache, and before the DNS cache fails, the IP address of an application server corresponding to the same domain name remains unchanged, so that the application server with the optimal service quality cannot be accessed.
In summary, embodiments of the present invention provide an application server access method, an application server access device, a computer device, and a computer readable storage medium based on a domain name resolution result, where each domain name and an application server IP address list corresponding to each domain name are extracted based on a DNS recursive log, an active ping test is periodically initiated to each application server IP address to obtain a ping test result, a grey correlation analysis algorithm is used to calculate a correlation coefficient between each network index corresponding to each application service IP address and each network index corresponding to a standard network server quality, to obtain network service quality ranking information of each application server IP address of the same domain name, and accordingly, a DNS resolution result is optimized, so as to achieve an application service preference and improve a service quality perception technical effect.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, system, or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present invention is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may 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 instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may 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 flow or flows and/or block diagram block or blocks.
The above-mentioned embodiments are intended to illustrate the objects, technical solutions and advantages of the present invention in further detail, and it should be understood that the above-mentioned embodiments are only exemplary embodiments of the present invention, and are not intended to limit the scope of the present invention, and any modifications, equivalent substitutions, improvements and the like made within the spirit and principle of the present invention should be included in the scope of the present invention.

Claims (12)

1. An application server access method based on domain name resolution results is characterized by comprising the following steps:
acquiring a plurality of application server IP addresses corresponding to a domain name to be accessed;
obtaining a ping test result corresponding to each application server IP address, wherein the ping test result is a test result obtained by performing ping test on each application server IP address;
extracting one or more network indexes corresponding to the IP address of each application server according to the ping test result corresponding to the IP address of each application server;
determining the network service quality of each application server IP address according to each network index corresponding to each application server IP address;
and returning the IP addresses of the application servers corresponding to the domain names to be accessed to the client according to the sequence of the network service quality from top to bottom, wherein the client accesses the application servers corresponding to the domain names to be accessed based on the returned IP addresses of the application servers.
2. The method of claim 1, wherein obtaining the ping test result corresponding to each application server IP address comprises:
sending ping test requests to IP addresses of all application servers according to a preset time interval;
and receiving a ping test result returned by the IP address of each application server.
3. The method of claim 1, wherein determining the network quality of service for each application server IP address based on each network indicator corresponding to each application server IP address comprises:
configuring reference values of various network indexes;
calculating a correlation coefficient between the index value and the reference value of each network index corresponding to the IP address of each application server by the following formula:
Figure FDA0002308704460000011
therein, ζi(k) The correlation coefficient between the index value of the kth network index corresponding to the IP address of the ith application server and the reference value is represented; i denotes the ith application server IP address(ii) a k represents the kth network index; ρ represents a resolution coefficient; x is the number of0(k) A reference value representing a k-th network metric; x is the number ofi(k) An index value representing a kth network index corresponding to the ith application server IP address;
and calculating an average correlation coefficient corresponding to each application server IP address according to the correlation coefficient between the index value of each network index corresponding to each application server IP address and the reference value, wherein the average correlation coefficient corresponding to each application server IP address is used for representing the network service quality of each application server IP address.
4. The method of claim 1, wherein obtaining a plurality of application server IP addresses corresponding to domain names to be accessed comprises:
receiving a DNS domain name resolution request;
acquiring response data returned by the DNS recursive server according to the DNS domain name resolution request;
generating log information of DNS recursive records according to response data returned by the DNS recursive server according to the DNS domain name resolution request;
one or more domain names are extracted according to the log information of the DNS recursive record.
5. The method of any of claims 1 to 4, wherein the network metrics comprise any of: packet loss rate, RTT average delay, RTT delay jitter, RTT average variance.
6. An access device for an application server based on domain name resolution results, comprising:
the IP address information acquisition module is used for acquiring a plurality of application server IP addresses corresponding to the domain name to be accessed;
the ping test module is used for acquiring a ping test result corresponding to each application server IP address, wherein the ping test result is obtained by performing ping test on each application server IP address;
the network index extraction module is used for extracting one or more network indexes corresponding to the IP addresses of the application servers according to the ping test results corresponding to the IP addresses of the application servers;
the network service quality determining module is used for determining the network service quality of each application server IP address according to each network index corresponding to each application server IP address, and returning each application server IP address corresponding to the domain name to be accessed according to the sequence of the network service quality from top to bottom;
and the application server access module is used for returning the IP addresses of the application servers corresponding to the domain names to be accessed to the client according to the sequence of the network service quality from top to bottom, wherein the client accesses the application servers corresponding to the domain names to be accessed based on the returned IP addresses of the application servers.
7. The apparatus of claim 6, wherein the ping test module comprises:
the ping test request sending module is used for sending ping test requests to IP addresses of the application servers according to a preset time interval;
and the ping test result receiving module is used for receiving the ping test result returned by the IP address of each application server.
8. The apparatus of claim 6, wherein the network quality of service determination module comprises:
the configuration module is used for configuring the reference value of each network index;
the first calculation module is used for calculating the correlation coefficient between the index value and the reference value of each network index corresponding to the IP address of each application server through the following formula:
Figure FDA0002308704460000031
therein, ζi(k) Index value and reference of k network index corresponding to IP address of i application serverA correlation coefficient between values; i represents the ith application server IP address; k represents the kth network index; ρ represents a resolution coefficient; x is the number of0(k) A reference value representing a k-th network metric; x is the number ofi(k) An index value representing a kth network index corresponding to the ith application server IP address;
and the second calculation module is used for calculating the average correlation coefficient corresponding to each application server IP address according to the correlation coefficient between the index value of each network index corresponding to each application server IP address and the reference value, wherein the average correlation coefficient corresponding to each application server IP address is used for representing the network service quality of each application server IP address.
9. The apparatus of claim 6, wherein the IP address information obtaining module comprises:
a domain name resolution request receiving module for receiving a DNS domain name resolution request;
a domain name resolution response data acquisition module used for acquiring the response data returned by the DNS recursive server according to the DNS domain name resolution request;
the recursive record generating module is used for generating the log information of the DNS recursive record according to the response data returned by the DNS recursive server according to the DNS domain name resolution request;
and the domain name extraction module is used for extracting one or more domain names according to the log information of the DNS recursive record.
10. The apparatus of any of claims 6 to 9, wherein the network metrics comprise any of: packet loss rate, RTT average delay, RTT delay jitter, RTT average variance.
11. A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor implements the method for accessing an application server based on domain name resolution results according to any one of claims 1 to 5 when executing the computer program.
12. A computer-readable storage medium storing a computer program for executing the method for accessing an application server based on a domain name resolution result according to any one of claims 1 to 5.
CN201911249812.9A 2019-12-09 2019-12-09 Application server access method and device based on domain name resolution result Pending CN113037680A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911249812.9A CN113037680A (en) 2019-12-09 2019-12-09 Application server access method and device based on domain name resolution result

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911249812.9A CN113037680A (en) 2019-12-09 2019-12-09 Application server access method and device based on domain name resolution result

Publications (1)

Publication Number Publication Date
CN113037680A true CN113037680A (en) 2021-06-25

Family

ID=76451011

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911249812.9A Pending CN113037680A (en) 2019-12-09 2019-12-09 Application server access method and device based on domain name resolution result

Country Status (1)

Country Link
CN (1) CN113037680A (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114039944A (en) * 2021-10-08 2022-02-11 中移(杭州)信息技术有限公司 Website access address selection method, equipment, storage medium and device
CN114338817A (en) * 2021-12-22 2022-04-12 中国人民银行清算总中心 Multi-plane network access control method and multi-plane network
CN114553820A (en) * 2022-02-11 2022-05-27 北京云思智学科技有限公司 DNS analysis method, system and storage medium for refined analysis control
CN115022278A (en) * 2022-06-02 2022-09-06 上海哔哩哔哩科技有限公司 CDN processing method and system
CN115297086A (en) * 2022-08-03 2022-11-04 明阳产业技术研究院(沈阳)有限公司 Domain name address resolution method, device, equipment and medium
CN115361357A (en) * 2022-07-22 2022-11-18 中国电信股份有限公司 Network scheduling system, method, device, electronic equipment and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105225033A (en) * 2015-09-08 2016-01-06 国家电网公司 A kind of substation energy efficiency evaluating method based on analytical hierarchy process
CN107192954A (en) * 2017-05-02 2017-09-22 杭州科工电子科技有限公司 A kind of performance of lithium ion battery inline diagnosis method
CN109981805A (en) * 2017-12-28 2019-07-05 中国移动通信集团山东有限公司 A kind of method and device of domain name mapping
CN110070290A (en) * 2019-04-22 2019-07-30 广东工业大学 A kind of power distribution automation Integrated Assessment On The Level method and its corresponding assembly

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105225033A (en) * 2015-09-08 2016-01-06 国家电网公司 A kind of substation energy efficiency evaluating method based on analytical hierarchy process
CN107192954A (en) * 2017-05-02 2017-09-22 杭州科工电子科技有限公司 A kind of performance of lithium ion battery inline diagnosis method
CN109981805A (en) * 2017-12-28 2019-07-05 中国移动通信集团山东有限公司 A kind of method and device of domain name mapping
CN110070290A (en) * 2019-04-22 2019-07-30 广东工业大学 A kind of power distribution automation Integrated Assessment On The Level method and its corresponding assembly

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114039944A (en) * 2021-10-08 2022-02-11 中移(杭州)信息技术有限公司 Website access address selection method, equipment, storage medium and device
CN114338817A (en) * 2021-12-22 2022-04-12 中国人民银行清算总中心 Multi-plane network access control method and multi-plane network
CN114338817B (en) * 2021-12-22 2023-11-10 中国人民银行清算总中心 Multi-plane network access control method and multi-plane network
CN114553820A (en) * 2022-02-11 2022-05-27 北京云思智学科技有限公司 DNS analysis method, system and storage medium for refined analysis control
CN115022278A (en) * 2022-06-02 2022-09-06 上海哔哩哔哩科技有限公司 CDN processing method and system
CN115022278B (en) * 2022-06-02 2024-04-26 上海哔哩哔哩科技有限公司 CDN processing method and system
CN115361357A (en) * 2022-07-22 2022-11-18 中国电信股份有限公司 Network scheduling system, method, device, electronic equipment and storage medium
CN115361357B (en) * 2022-07-22 2024-05-14 中国电信股份有限公司 Network scheduling system, method and device, electronic equipment and storage medium
CN115297086A (en) * 2022-08-03 2022-11-04 明阳产业技术研究院(沈阳)有限公司 Domain name address resolution method, device, equipment and medium

Similar Documents

Publication Publication Date Title
CN113037680A (en) Application server access method and device based on domain name resolution result
US10027564B2 (en) Unobtrusive methods and systems for collecting information transmitted over a network
CN107395683B (en) Method for selecting return path and server
KR101668272B1 (en) Characterizing unregistered domain names
CN107342913B (en) Detection method and device for CDN node
US8504673B2 (en) Traffic like NXDomains
CN103873604B (en) Network access method based on analysis of CDN data
CN109302418B (en) Malicious domain name detection method and device based on deep learning
CN111447304B (en) Anycast node IP address enumeration method and system for anycast recursive domain name system
CN109327559B (en) Domain name resolution method and device based on hybrid cloud platform
CN109194749B (en) Method for monitoring network request and storage medium
US20090259666A1 (en) Unobtrusive methods and systems for collecting information transmitted over a network
CN112449371B (en) Performance evaluation method of wireless router and electronic equipment
CN108089972A (en) interface test method and device
CN114500456A (en) DNS scheduling optimization method and device based on full-network sniffing and computing equipment
CN107888714B (en) Method and device for selecting local cache DNS
CN111049941A (en) DNS scheduling method, domain name server and computer readable storage medium
JP4851566B2 (en) DNS test apparatus, DNS test method, and DNS test program
CN113055420A (en) HTTPS service identification method and device and computing equipment
CN113766046B (en) Iterative traffic tracking method, DNS server and computer readable storage medium
KR100342107B1 (en) Methods for deciding Internet address groups distinguished by assigned organizations or locations and for resolving the geographical information for each address group, which are intended to set up Internet address supplementary system and its applications
CN106789979B (en) Method and device for diagnosing effectiveness of active domain name in IDC machine room
CN111371826B (en) CDN node performance detection method, device and system
JP6170001B2 (en) Communication service classification device, method and program
CN113626186A (en) Load balancing method and system of server and computer readable storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20210625