CN113572657A - System link connectivity compensation method and system - Google Patents

System link connectivity compensation method and system Download PDF

Info

Publication number
CN113572657A
CN113572657A CN202110833570.9A CN202110833570A CN113572657A CN 113572657 A CN113572657 A CN 113572657A CN 202110833570 A CN202110833570 A CN 202110833570A CN 113572657 A CN113572657 A CN 113572657A
Authority
CN
China
Prior art keywords
overtime
address
target system
retransmission
request
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
CN202110833570.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.)
China Citic Bank Corp Ltd
Original Assignee
China Citic Bank Corp 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 China Citic Bank Corp Ltd filed Critical China Citic Bank Corp Ltd
Priority to CN202110833570.9A priority Critical patent/CN113572657A/en
Publication of CN113572657A publication Critical patent/CN113572657A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/08Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
    • H04L43/0805Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters by checking availability
    • H04L43/0811Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters by checking availability by checking connectivity
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/10Active monitoring, e.g. heartbeat, ping or trace-route
    • H04L43/103Active monitoring, e.g. heartbeat, ping or trace-route with adaptive polling, i.e. dynamically adapting the polling rate
    • 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)
  • Environmental & Geological Engineering (AREA)
  • Health & Medical Sciences (AREA)
  • Cardiology (AREA)
  • General Health & Medical Sciences (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention relates to the technical field of network connection, in particular to a system link connectivity compensation method and a system, which comprises the steps of monitoring the connection of a target system overtime; the target system automatically carries out overtime retransmission request when being connected overtime, and simultaneously records the number of times of the overtime retransmission request; and when the overtime retransmission request times reach a retransmission preset threshold value, automatically accessing the DNS server to reacquire the IP address of the target system. The invention automatically judges whether the DNS server needs to be revisited to obtain a new IP address in the TTL time range or not by monitoring whether the connection in the TTL time range is overtime or not, improves the link connectivity of the system on the premise of not shortening the TTL time or increasing additional manpower input, and does not influence the automatic operation of the system.

Description

System link connectivity compensation method and system
Technical Field
The present invention relates to the field of network connection technologies, and in particular, to a method and a system for compensating system link connectivity.
Background
At present, when a request system accesses a target system in a domain name mode, a DNS server acquires an IP address corresponding to a domain name, because the corresponding relation between the domain name and the IP address changes infrequently, the DNS server adopts a TTL (time to live) mechanism to reduce the huge pressure brought by frequent access to the DNS server, and the request server can acquire the IP address through a local cache without accessing the DNS server within the TTL time range. The above general scheme has a problem for systems with high real-time requirements (e.g. bank online transaction type systems): when the IP address changes within the TTL time range, the request system cannot access the target system, the system link is interrupted, and the recovery cannot be carried out until the TTL is invalid and a new IP is obtained again. The system has the risk that the system connectivity service cannot be ensured, once the IP address changes in the TTL time range, the target system cannot be accessed, the user experience of the system can be seriously influenced, and the system availability is reduced.
To solve this problem, the prior art generally adopts two technical solutions: the method has the advantages that firstly, the TTL time is shortened, the influence of IP address change in a TTL time range on the system link connectivity is reduced through shorter TTL time, but the work load of a DNS (domain name system) server is obviously increased due to the shorter TTL time, and the DNS server becomes a connectivity bottleneck when a large number of access requests are met, so that the performance of the whole system link is tired; secondly, when the IP address is sent and changed within the TTL time range, the service is restarted and the cache is refreshed through manual intervention, a new IP address is obtained to ensure the connectivity, but extra labor cost and operation and maintenance cost are required to be invested, and the automatic operation of the system is not facilitated.
Disclosure of Invention
In order to solve the defects of the prior art, the invention provides a system link connectivity compensation method and a system, which automatically judge whether to need to revisit a DNS server to obtain a new IP address in a TTL time range by monitoring whether the connection in the TTL time range is overtime, improve the system link connectivity on the premise of not shortening the TTL time or increasing additional manpower input, and simultaneously do not influence the automatic operation of the system.
In order to achieve the above purpose, the technical scheme adopted by the invention comprises the following steps:
a method for compensating for system link connectivity, comprising:
monitoring the connection of a target system overtime;
the target system automatically carries out overtime retransmission request when being connected overtime, and simultaneously records the number of times of the overtime retransmission request;
and when the overtime retransmission request times reach a retransmission preset threshold value, automatically accessing the DNS server to reacquire the IP address of the target system.
Further, still include:
and when the overtime retransmission request times reach a retransmission preset threshold value, automatically accessing the DNS server to reacquire the IP address of the target system and new TTL time.
Further, still include:
and storing the IP address of the target system obtained again and the new TTL time in a DNS cache of the request system.
Further, still include:
and after the IP address of the target system and the new TTL time are obtained again, recording the overtime retransmission request times to zero.
Further, still include:
the timeout resend request is automatically made using the target system IP address stored in the requesting system DNS cache.
Further, still include:
and when the number of the overtime retransmission requests reaches a retransmission preset threshold value, automatically accessing the DNS server to reacquire the IP address of the target system, and simultaneously stopping automatically performing the overtime retransmission requests or simultaneously keeping automatically performing the overtime retransmission requests.
Further, still include:
the retransmission preset threshold value is configured using parameterization.
Further, still include:
the request system verifies whether an IP address corresponding to a target system exists in the DNS cache;
and when the IP address of the corresponding target system does not exist in the DNS cache, accessing the DNS server to obtain the IP address of the target system and the new TTL time again.
The invention also relates to a system link connectivity compensation system, which is characterized by comprising:
the DNS cache is used for storing the IP address and the TTL time of a target system;
the overtime monitoring module is used for monitoring the connection of the target system overtime;
the overtime retransmission counter module is used for recording the overtime retransmission request times;
and the DNS request module is used for sending an access request to the DNS server.
The invention also relates to a computer-readable storage medium, characterized in that the storage medium has stored thereon a computer program which, when being executed by a processor, carries out the above-mentioned method.
The invention has the beneficial effects that:
by adopting the method and the system for compensating the link connectivity of the system, the connectivity of the system is ensured when the IP address changes in the TTL time range of the DNS through a mode of adding a connectivity compensation mechanism in an application system, so the method and the system are suitable for most scenes for ensuring the connectivity, the system can be ensured to have the capability of timely replying the connection when the IP address changes in the TTL time, the high availability of the system is greatly improved, and the communication fault-tolerant capability of the system is improved.
Drawings
Fig. 1 is a schematic flow chart of a system link connectivity compensation method of the present invention.
FIG. 2 is a schematic flow diagram of a prior art method.
Fig. 3 is a schematic diagram of the system link connectivity compensation system of the present invention.
Fig. 4 is a schematic diagram of a prior art system architecture.
Detailed Description
For a clearer understanding of the contents of the present invention, reference will be made to the accompanying drawings and examples.
The existing DNS server technical scheme can meet the access requirements of most systems, but the system with higher real-time requirement has the risk that system connectivity service cannot be ensured, once an IP address changes in a TTL time range, a target system cannot be accessed, so that the user experience of the system is influenced, and the high availability of the system is reduced. Therefore, further optimization of the mechanism is needed to ensure the connectivity of the system.
The invention provides a technical solution for improving the system connectivity and provides a complete processing logic aiming at the scene that the IP address changes in the TTL time range of the DNS. The problems mainly solved by the invention comprise: on the premise of ensuring that the TTL time is not changed (not reduced), the connectivity between the request system and the target system is judged by increasing the system access overtime monitoring, if the target system is not reachable, the program initiates a DNS analysis request again, the latest IP address is obtained in time, and the system connectivity is greatly ensured.
Fig. 1 is a schematic flow chart of a preferred embodiment of the method for compensating link connectivity of the system of the present invention, which mainly comprises the following steps:
s1, the request system initiates an access request to the target system by adopting a domain name mode;
s2, the operating system inquires whether the DNS CACHE (DNS CACHE) has the corresponding relation between the domain name and the IP, if so, the step S3 is carried out, otherwise, the step S4 is carried out;
s3, acquiring TTL time from the DNS cache, judging whether the time is overtime, if not, performing the step S6, otherwise, performing the step S4;
s4, accessing a DNS server;
s5, the DNS server returns the IP address and the TTL time and stores the IP address and the TTL time into a DNS cache of the request system;
s6, acquiring the IP address from the cache, assembling a communication message and sending the communication message to a target system, and starting an overtime monitoring function;
s7, if the request is not overtime, the connection is successful, and the subsequent operation is carried out, otherwise, the step S8 is carried out;
s8, accessing the overtime resending counter;
s9, judging whether the overtime retransmission times exceed the limit (the retransmission preset threshold value of the overtime retransmission times can be configured in a parameterization way), if so, performing the step S10, otherwise, performing the step S11;
s10, initiating a DNS analysis request to the DNS again, and jumping to the step S4;
s11, the access request to the target system is initiated again, the number of records of the timeout retransmission counter is incremented by 1, and the process proceeds to step S6.
Compared with the typical execution flow of the prior art shown in fig. 2, the method of the present invention mainly solves the problem that all requests in the TTL time period will fail if the IP address changes within the TTL time range, and especially has a large impact on the system with high real-time requirements. In the application process, the retransmission preset threshold value can be automatically determined according to actual requirements, so that a second dynamic automatic access DNS server mechanism beyond the original TTL time is realized, particularly, the specific setting of the retransmission preset threshold value is changed, the tightness of the dynamic mechanism can be adjusted to match the work bearing capacity of the DNS server, the execution of the original TTL time is not influenced, and any existing access system can be highly compatible.
The present invention also relates to a system link connectivity compensation system, as shown in fig. 3, which is a preferred embodiment of the system, and on the basis of the existing system structure as shown in fig. 4, a timeout monitoring module for monitoring timeout of a target system connection, a timeout retransmission counter module for recording the number of times of timeout retransmission requests, and a DNS request module for sending an access request to a DNS server are added, and are connected to a DNS cache in the original structure, and an IP address and TTL time obtained by the compensation system are stored in the DNS cache and called. The system shown in fig. 3 can be used to implement the above compensation method for system link connectivity, so as to provide sufficient compensation for system link connectivity, and is particularly suitable for a scenario with high real-time requirement.
In practical use, the method and the system can be directly added into an original request system to be executed as an inherent part of the request system, and can also be packaged into an independent functional module package for the request system to call when needed, for example, the implementation of the method and the system can be packaged into a jar package, and the request system can call the jar package through an API (application program interface), so that the functional effect of connectivity compensation is realized.
For example, taking writing jar packets as an example, the system link connectivity compensation method and system of the present invention creates and forms jar packets named connectionmechanism. The jar packet runs as an independent process and needs to be invoked independently when an application (a request system) is started (embedded invocation of the application, invocation of a shell script and other modes can be adopted, for example, a startconnmanager. The jar packet can provide a function of reinitiating the DNS domain name resolution request, and can also provide a resend () timeout resending method in the form of API, so that a resending function is provided for a system lacking a timeout resending mechanism.
When calling the jar package, a configuration file needs to be added under the root directory of the application program: properties, for configuring important parameters, such as:
ResendTimes-timeout retransmission counter
overTime-timeout time
DNSaddress DNS Domain name resolution Server Address
overtime code is a timeout response code
When the overtime times exceed the limit of the retransmission counter, jar empties the DNS cache of the application server and retransmits the DNS domain name resolution request, so that the effect of updating the IP address in time is achieved. A typical parameter configuration may be:
ResendTimes is 3 (timeout retransmission times is 3)
overTime 20(20s timeout)
DNSaddress 128.22.6.122(DNS name resolution server address)
For a system lacking a timeout resending mechanism, the timeout resending function can be realized by calling a resume () method, and the resending times can be set according to the system requirements.
The above description is only for the preferred embodiment of the present invention, but the scope of the present invention is not limited thereto, and any changes or substitutions that can be easily conceived by those skilled in the art within the technical scope of the present invention are included in the scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.

Claims (10)

1. A method for compensating for system link connectivity, comprising:
monitoring the connection of a target system overtime;
the target system automatically carries out overtime retransmission request when being connected overtime, and simultaneously records the number of times of the overtime retransmission request;
and when the overtime retransmission request times reach a retransmission preset threshold value, automatically accessing the DNS server to reacquire the IP address of the target system.
2. The method of claim 1, further comprising:
and when the overtime retransmission request times reach a retransmission preset threshold value, automatically accessing the DNS server to reacquire the IP address of the target system and new TTL time.
3. The method of claim 2, further comprising:
and storing the IP address of the target system obtained again and the new TTL time in a DNS cache of the request system.
4. The method of claim 3, further comprising:
and after the IP address of the target system and the new TTL time are obtained again, recording the overtime retransmission request times to zero.
5. The method of claim 4, further comprising:
the timeout resend request is automatically made using the target system IP address stored in the requesting system DNS cache.
6. The method of claim 5, further comprising:
and when the number of the overtime retransmission requests reaches a retransmission preset threshold value, automatically accessing the DNS server to reacquire the IP address of the target system, and simultaneously stopping automatically performing the overtime retransmission requests or simultaneously keeping automatically performing the overtime retransmission requests.
7. The method of any of claims 1 to 6, further comprising:
the retransmission preset threshold value is configured using parameterization.
8. The method of any of claims 1 to 6, further comprising:
the request system verifies whether an IP address corresponding to a target system exists in the DNS cache;
and when the IP address of the corresponding target system does not exist in the DNS cache, accessing the DNS server to obtain the IP address of the target system and the new TTL time again.
9. A system link connectivity compensation system, comprising:
the DNS cache is used for storing the IP address and the TTL time of a target system;
the overtime monitoring module is used for monitoring the connection of the target system overtime;
the overtime retransmission counter module is used for recording the overtime retransmission request times;
and the DNS request module is used for sending an access request to the DNS server.
10. A computer-readable storage medium, characterized in that the storage medium has stored thereon a computer program which, when being executed by a processor, carries out the method of any one of claims 1-8.
CN202110833570.9A 2021-07-23 2021-07-23 System link connectivity compensation method and system Pending CN113572657A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110833570.9A CN113572657A (en) 2021-07-23 2021-07-23 System link connectivity compensation method and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110833570.9A CN113572657A (en) 2021-07-23 2021-07-23 System link connectivity compensation method and system

Publications (1)

Publication Number Publication Date
CN113572657A true CN113572657A (en) 2021-10-29

Family

ID=78166506

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110833570.9A Pending CN113572657A (en) 2021-07-23 2021-07-23 System link connectivity compensation method and system

Country Status (1)

Country Link
CN (1) CN113572657A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115314419A (en) * 2022-06-21 2022-11-08 清华大学 Self-adaptive connectivity analysis method, system, equipment and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105847184A (en) * 2016-02-22 2016-08-10 乐视移动智能信息技术(北京)有限公司 Network request method, device and processing system for android operation system
CN105991798A (en) * 2016-07-01 2016-10-05 北京奇虎科技有限公司 Method and device for network access by mobile terminal
CN106412144A (en) * 2016-09-20 2017-02-15 乐视控股(北京)有限公司 Network access method and device
CN110086895A (en) * 2019-04-11 2019-08-02 天津字节跳动科技有限公司 Domain name analytic method, device, medium and electronic equipment
CN110830606A (en) * 2019-10-31 2020-02-21 瑞斯康达科技发展股份有限公司 Method and device for solving abnormal DNS cache and computer readable storage medium

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105847184A (en) * 2016-02-22 2016-08-10 乐视移动智能信息技术(北京)有限公司 Network request method, device and processing system for android operation system
CN105991798A (en) * 2016-07-01 2016-10-05 北京奇虎科技有限公司 Method and device for network access by mobile terminal
CN106412144A (en) * 2016-09-20 2017-02-15 乐视控股(北京)有限公司 Network access method and device
CN110086895A (en) * 2019-04-11 2019-08-02 天津字节跳动科技有限公司 Domain name analytic method, device, medium and electronic equipment
CN110830606A (en) * 2019-10-31 2020-02-21 瑞斯康达科技发展股份有限公司 Method and device for solving abnormal DNS cache and computer readable storage medium

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115314419A (en) * 2022-06-21 2022-11-08 清华大学 Self-adaptive connectivity analysis method, system, equipment and storage medium

Similar Documents

Publication Publication Date Title
US10063599B2 (en) Controlling registration floods in VOIP networks via DNS
CN103905397B (en) Data synchronization method and system
US6973506B2 (en) Position identifier management apparatus and method, mobile computer, and position identifier processing method
WO2019214292A1 (en) Resource acquisition method, terminal apparatus, computer device, and readable medium
CN103338279B (en) Based on optimization sequencing method and the system of domain name mapping
CN110730196B (en) Network resource access method, computer equipment and storage medium
TW202021315A (en) Network service system and network service method
CN109714443A (en) Name server, domain name backup method and computer readable storage medium
CN103905574A (en) DNS service access method and DNS data synchronization method and device
US9344363B2 (en) Information processing system, relay device, information processing device, and information processing method
CN106470251A (en) Domain name analytic method and virtual DNS authority server
US20230254312A1 (en) Service processing method and device
CN109597693A (en) The application method of GRPC communication protocol in distributed software system
US11122138B2 (en) Enhanced domain name system response caching
CN113572657A (en) System link connectivity compensation method and system
CN108989420A (en) The method and system of registration service, the method and system for calling service
CN110417876A (en) Node server and main control device in session method, distributed system
CN105812503A (en) Root server address update method and recursive server
US8464331B2 (en) Data transmission management server and method
CN113949708B (en) Service bus design method supporting gray scale upgrade access flow control
CN111901449B (en) Method and device for optimizing domain name access
CN110865845B (en) Method for improving interface access efficiency and storage medium
CN112751950B (en) Address updating method and device
CN116781780A (en) Request processing method, device, server and storage medium
CN113472909A (en) DNS query processing method and device

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