CN112333048B - Method and device for detecting connectivity of opened service online user - Google Patents

Method and device for detecting connectivity of opened service online user Download PDF

Info

Publication number
CN112333048B
CN112333048B CN202011317748.6A CN202011317748A CN112333048B CN 112333048 B CN112333048 B CN 112333048B CN 202011317748 A CN202011317748 A CN 202011317748A CN 112333048 B CN112333048 B CN 112333048B
Authority
CN
China
Prior art keywords
gateway
address
test
ping test
service
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.)
Active
Application number
CN202011317748.6A
Other languages
Chinese (zh)
Other versions
CN112333048A (en
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.)
Unihub China Information Technology Co Ltd
Original Assignee
Unihub China 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 Unihub China Information Technology Co Ltd filed Critical Unihub China Information Technology Co Ltd
Priority to CN202011317748.6A priority Critical patent/CN112333048B/en
Publication of CN112333048A publication Critical patent/CN112333048A/en
Application granted granted Critical
Publication of CN112333048B publication Critical patent/CN112333048B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

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/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
    • 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

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 provides a method and a device for detecting the connectivity of an online user with opened service. Responding to a successful message of equipment login, searching equipment information according to an equipment identifier, and searching a first service address actually allocated to a current service work order according to a reference service number; judging the gateway type of the address on the port of the equipment, and if the address is an independent gateway, detecting the online service address according to the ping test method of the independent gateway; if the gateway is the shared gateway, detecting the online service address according to a ping test method of the shared gateway; and performing connectivity test on the online service address to obtain a connectivity test result. The invention can realize the automatic detection of online users and connectivity, can distinguish the independent gateway and the shared gateway, can carry out the connectivity detection on each service address in batch, and supports the ping connectivity test of common services or the vrf ping connectivity test of the vpn service, and the test result is more accurate, economic and efficient.

Description

Method and device for detecting connectivity of opened service online user
Technical Field
The embodiments of the present invention generally relate to the technical field of server testing, and in particular, to a method and an apparatus for detecting connectivity of an online user with an opened service.
Background
After the service is opened, the user needs to perform an acceptance test. And the connectivity of online users and user addresses is the most common verification index.
Connectivity test is a very common service detection method, but the acceptance staff of the user is limited by the post and often does not know the detailed information of the specific service work order, and even if production and acceptance are the same department staff, because the generation of the work order and the final acceptance often have a certain time difference, the existing data needs to be consulted to perform the acceptance work. Therefore, the efficiency of connectivity test performed manually is low, time and labor are wasted, and the detection result is inaccurate.
Disclosure of Invention
According to the embodiment of the invention, an online user connectivity detection scheme of the opened service is provided.
In a first aspect of the present invention, a method for detecting connectivity of an online user with an opened service is provided. The method comprises the following steps:
responding to the successful message of equipment login, searching equipment information according to the equipment identifier, and searching a first service address actually allocated to the current service work order according to a reference service number in the equipment information;
judging the gateway type of the address on the port of the equipment, and if the gateway type is an independent gateway, detecting the online service address according to the ping test method of the independent gateway; if the gateway type is a shared gateway, detecting an online service address according to a ping test method of the shared gateway;
and performing connectivity test on the online service address to obtain a connectivity test result.
Further, the detecting an online service address according to the ping test method of the independent gateway includes:
judging the ping test type of the entry, if the ping test type of the entry is the vrf ping test, extracting a vpn example according to the corresponding keywords, and extracting an independent gateway address according to the corresponding keywords; if the participating ping test type is a common ping test, extracting an independent gateway address directly according to the corresponding key words;
and extracting all addresses under the port according to the keywords, and taking the intersection of the dependent gateway address under the port and the first service address as the online service address of the current access reference service number.
Further, the detecting an online service address according to the ping test method of the shared gateway includes:
judging the ping test type of the entry, if the ping test type of the entry is the vrf ping test, extracting a vpn example according to the corresponding keywords, and extracting all addresses under the port according to the corresponding keywords; if the participating ping test type is a common ping test, all addresses under the port are directly extracted according to the corresponding keywords;
and taking the intersection of all the addresses under the port and the first service address as the online service address of the current access reference service number.
Further, the performing connectivity test on the online service address includes:
judging the ping test type of the online service address, and if the ping test type of the online service address is a vrf ping test, executing a vrf ping test command to carry out a connectivity test to obtain a first test result; if the ping test type of the online service address is a common ping test, executing a common ping test command to carry out connectivity test to obtain a second test result;
and recording the first test result or the second test result, and returning in a standard json data format.
Further, still include: if the access service number in the equipment information does not exist, returning to a failure state that the service number does not exist and ending.
Further, still include: if the gateway type of the address on the port of the equipment can not be judged, returning a failure state that the gateway type can not be judged, and ending.
Further, still include: and if all the addresses under the port are not intersected with the first service address or the non-independent gateway address under the port is not intersected with the first service address, returning to a failure state of the offline service address and ending.
In a second aspect of the present invention, an apparatus for detecting online user connectivity of an opened service is provided. The device includes:
the searching module is used for responding to the successful message of equipment login and searching equipment information according to the equipment identifier and searching a first service address actually allocated to the current service work order according to the reference service number in the equipment information;
the judging module is used for judging the gateway type of the address on the port of the equipment, and if the gateway type is an independent gateway, the online service address is detected according to the ping test method of the independent gateway; if the gateway type is a shared gateway, detecting an online service address according to a ping test method of the shared gateway;
and the testing module is used for carrying out connectivity test on the online service address to obtain a connectivity test result.
In a third aspect of the invention, an electronic device is provided. The electronic device includes: a memory having a computer program stored thereon and a processor implementing the method as described above when executing the program.
In a fourth aspect of the invention, a computer-readable storage medium is provided, on which a computer program is stored which, when being executed by a processor, carries out the method as according to the first aspect of the invention.
It should be understood that the statements herein reciting aspects are not intended to limit the critical or essential features of any embodiment of the invention, nor are they intended to limit the scope of the invention. Other features of the present invention will become apparent from the following description.
The invention can realize the automatic detection of online users and connectivity, can distinguish the independent gateway and the shared gateway, can carry out the connectivity detection on each service address in batch, and supports the ping connectivity test of common services or the vrf ping connectivity test of the vpn service, and the test result is more accurate, economic and efficient.
Drawings
The above and other features, advantages and aspects of various embodiments of the present invention will become more apparent by referring to the following detailed description when taken in conjunction with the accompanying drawings. In the drawings, like or similar reference characters designate like or similar elements, and wherein:
fig. 1 shows a flow chart of a method for online user connectivity detection of an provisioned service according to an embodiment of the invention;
fig. 2 shows a flow diagram of a method for ping a stand-alone gateway according to an embodiment of the invention;
fig. 3 shows a flow diagram of a method for shared gateway ping testing, according to an embodiment of the invention;
FIG. 4 shows a block diagram of an apparatus for online user connectivity detection of provisioned services according to an embodiment of the invention;
FIG. 5 illustrates a block diagram of an exemplary electronic device capable of implementing embodiments of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, but not all, embodiments of the present invention. All other embodiments, which can be obtained by a person skilled in the art without any inventive step based on the embodiments of the present invention, are within the scope of the present invention.
In addition, the term "and/or" herein is only one kind of association relationship describing an associated object, and means that there may be three kinds of relationships, for example, a and/or B, which may mean: a exists alone, A and B exist simultaneously, and B exists alone. In addition, the character "/" herein generally indicates that the former and latter related objects are in an "or" relationship.
According to the invention, automatic detection of online user connectivity can be realized, the accuracy is high, independent gateways and shared gateways can be distinguished, the connectivity detection is carried out on each service address in batches, and ping connectivity test of common services or vrf ping connectivity test of vpn services is supported, so that the test result is more accurate; specific information of each service address and the connectivity test is returned, so that the method is real-time, efficient and good in visual readability; the standardized data interface is standard, the secondary repeated development cost is reduced, various interface calling modes are supported, other interface calling protocols can be conveniently expanded after simple packaging, and the method is economical and efficient.
Fig. 1 shows a flowchart of a method for detecting connectivity of an online user of an opened service according to an embodiment of the present invention.
The method comprises the following steps:
s101, responding to the successful login message of the equipment, searching equipment information according to the equipment identification, and searching a first service address actually allocated to the current service work order according to the reference service number in the equipment information.
Before the method, the equipment is required to be logged in, and if the equipment is logged in successfully, an equipment login success message is sent out.
The device information includes a device IP, a login account, a device model, and the like.
Extracting an access reference service number from the device information, for example (S20190301100102); if the access reference service number does not exist, returning failure, and the service number does not exist; if the access service number exists, the IP address actually distributed by the service function in the system is searched according to the access service number.
And when the equipment fails to log in or the unique equipment information cannot be searched, returning the failure state of the equipment which cannot log in and ending.
And executing the instruction of the corresponding equipment after logging in the equipment of different manufacturers. For example, the devices include Huacheng, Zhongxing devices.
S102, judging the gateway type of the address on the port of the equipment, and if the gateway type is an independent gateway, detecting the online service address according to the ping test method of the independent gateway; if the gateway type is a shared gateway, detecting an online service address according to a ping test method of the shared gateway;
and judging the type of the gateway according to the access port.
As an embodiment of the present invention, the gateway type determination process of the huawei device is as follows:
if the echo does not contain bas but contains ip address in the normal ping test, recording the address of each IPv4 independent gateway for the independent gateway.
If the test is the vrf ping test, if the feedback does not contain bas, but contains ip binding VPN-instance and ip address, the VPN instance name and each IPv4 independent gateway address are recorded for the independent gateway.
If the common ping test is carried out, the echoing contains bas but does not contain ip address, the VPN instance name is recorded for the shared gateway.
If the VPN test is a vrf ping test, the information contains bas and VPN-instance but does not contain ip address, and the VPN instance name is recorded for the shared gateway.
As an embodiment of the present invention, the gateway type determination process of the zhongxing device is as follows:
command: show running-config-interface smart group 1.93121850-in port. If the playback is empty, the program ends the flow and returns the result:
IsPass 1, NoPassDetail, failure in obtaining online user command execution, and TestResult;
if the common ping test is carried out, the echoing contains the ip address, the gateway is an independent gateway, and each IPv4 gateway address is recorded according to the keyword ip address;
if the Virtual Private Network (VPN) is subjected to the vrf ping test, the echoing comprises 'ip vrf forwarding' and 'ip address', the recorded keywords are independent gateways, and the recorded keywords are 'ip vrf forwarding' and 'ip address' to record the VPN instance name and each IPv4 gateway address.
And if the echoed display does not contain the ip address, the shared gateway is obtained. If the ping test is normal, the online users are continuously collected. If the test is the vrf ping test, recording the VPN instance name according to the keyword' ip vrf forwarding
Otherwise, the program ends and returns: IsPass ═ 1, NoPassDetail ═ illegal leased line type, TestDescr ═ user online: no online user; and ping test: there is no online user.
As an embodiment of the present invention, if the gateway type of the address on the port of the device cannot be determined, a failure state in which the gateway type cannot be determined is returned and the process is ended.
As an embodiment of the present invention, as shown in fig. 2, if the gateway type is an independent gateway, detecting an online service address according to a ping test method of the independent gateway includes:
s201, judging the participating ping test type:
and if the participating ping test type is a vrf ping test, executing the instruction, extracting a vpn example according to the corresponding keyword, and then combining the vpn example execution instruction and extracting an independent gateway address according to the corresponding keyword. For example, vrf instance names are extracted from vrf-name keywords and matched with the previously recorded vpn instance names, and then user addresses are extracted from the playback under the corresponding vpn instance names by using ipv4-address keywords.
And if the participating ping test type is a common ping test, extracting the independent gateway address directly according to the corresponding key words. For example, the user address is extracted directly from the ipv4-address keyword.
S202, executing the instruction, extracting all addresses under the port according to the keywords, and removing the independent gateway address from the addresses under the port, namely using the intersection of the dependent gateway address under the port and the first service address as the online service address of the current access reference service number.
As an embodiment of the present invention, if all addresses under the port do not intersect with the first service address, or the dependent gateway address under the port does not intersect with the first service address, a failure status of an offline service address is returned and ended.
As an embodiment of the present invention, as shown in fig. 3, if the gateway type is a shared gateway, detecting an online service address according to a ping test method of the shared gateway includes:
s301, judging the participating ping test type:
if the participating ping test type is a vrf ping test, extracting a vpn example according to the corresponding keywords, executing an instruction by combining the vpn example, and extracting all addresses under the port according to the corresponding keywords.
If the participating ping test type is a common ping test, all addresses under the port are directly extracted according to the corresponding keywords.
S302, taking the intersection of all the addresses under the port and the first service address as the online service address of the current access reference service number.
As an embodiment of the present invention, if all addresses under the port do not intersect with the first service address, or the dependent gateway address under the port does not intersect with the first service address, a failure status of an offline service address is returned and ended.
By distinguishing the independent gateways and the shared gateways, the connectivity detection is carried out on each service address in batches, the ping connectivity test of common services or the vrf ping connectivity test of the vpn service are supported, the test result is more accurate, the specific information of each service address and the connectivity test is returned, and the method is real-time, efficient, and good in intuition and readability.
S103, performing connectivity test on the online service address to obtain a connectivity test result.
If the online address is subjected to the vrf ping test, executing the vrf ping test command, and sequentially performing ping test on each online address;
if the ping test is a common ping test, executing a common ping command, and sequentially performing ping test on each online address;
and analyzing the returned result, and recording the packet sending number, the packet loss rate and the time delay, wherein the time delay comprises the minimum time delay, the average time delay and the maximum time delay.
As an embodiment of the present invention, the online user information and the ping test result of each online user are as follows:
IsPass 0, TestDescr user online: online users are 172.17.45.118, 172.17.45.115, 172.17.45.122;
and ping test: the target is as follows: 172.17.45.118 bale count: 5; packet loss rate: 0; latency (min/average/max): 7/8/12 ms; the target is as follows: 172.17.45.115 bale count: - -; packet loss rate: - -; latency (min/average/max): -/- -/- -/-ms.
According to the embodiment of the invention, a plurality of interface calling modes are supported, and other interface calling protocols can be conveniently expanded after simple packaging; automatically judging the type of the address gateway, automatically opening data according to actual data on equipment and service in a work order, and returning to the current online user address; performing ping test on the online user address, and supporting 2 ping test formats; detailed information is returned to each online user address and ping test result, and readability is good; the method can be widely applied to the acceptance of various services, such as cloud special lines, three-layer vpn and other services.
It should be noted that, for simplicity of description, the above-mentioned method embodiments are described as a series of acts or combination of acts, but those skilled in the art will recognize that the present invention is not limited by the order of acts, as some steps may occur in other orders or concurrently in accordance with the invention. Further, those skilled in the art should also appreciate that the embodiments described in the specification are exemplary embodiments and that the acts and modules illustrated are not necessarily required to practice the invention.
The above is a description of method embodiments, and the embodiments of the present invention are further described below by way of apparatus embodiments.
As shown in fig. 4, the apparatus 400 includes:
the searching module 410, in response to the device login success message, is configured to search device information according to the device identifier, and search a first service address actually allocated to the current service work order according to a reference service number in the device information; if the access service number in the equipment information does not exist, returning to a failure state that the service number does not exist and ending.
A judging module 420, configured to judge a gateway type of an address on a port of the device, and if the gateway type is an independent gateway, detect an online service address according to a ping test method of the independent gateway; and if the gateway type is the shared gateway, detecting the online service address according to a ping test method of the shared gateway. If the gateway type of the address on the port of the equipment can not be judged, returning a failure state that the gateway type can not be judged, and ending.
The determining module 420 further includes an independent gateway detecting module 421 and a shared gateway detecting module 422; wherein
The independent gateway detection module 421 further includes:
the first judgment module 421-1 is configured to judge a ping test type of the entry, and if the ping test type of the entry is a vrf ping test, extract a vpn instance according to a corresponding keyword, and extract an independent gateway address according to the corresponding keyword; and if the participating ping test type is a common ping test, extracting the independent gateway address directly according to the corresponding key words.
The first online service identification module 421-2 is configured to extract all addresses under the port according to the keyword, and use an intersection of the dependent gateway address under the port and the first service address as an online service address of the current access reference service number. And if all the addresses under the port are not intersected with the first service address or the non-independent gateway address under the port is not intersected with the first service address, returning to a failure state of the offline service address and ending.
The shared gateway detection module 422 further includes:
the second judging module 422-1 is used for judging the participating ping test type, if the participating ping test type is the vrf ping test, extracting a vpn instance according to the corresponding keywords, and extracting all addresses under the port according to the corresponding keywords; if the participating ping test type is a common ping test, all addresses under the port are directly extracted according to the corresponding keywords.
And a second online service identification module 422-2, configured to use an intersection of all addresses under the port and the first service address as an online service address of the current access reference service number. And if all the addresses under the port are not intersected with the first service address or the non-independent gateway address under the port is not intersected with the first service address, returning to a failure state of the offline service address and ending.
The testing module 430 is configured to perform connectivity testing on the online service address to obtain a connectivity testing result.
The test module 430 further includes:
a third determining module 431, configured to determine a ping test type of the online service address, and if the ping test type of the online service address is a vrf ping test, execute a vrf ping test command to perform a connectivity test, so as to obtain a first test result; and if the ping test type of the online service address is a common ping test, executing a common ping test command to perform connectivity test to obtain a second test result.
And a result returning module 432, configured to record the first test result or the second test result, and return the first test result or the second test result in a standard json data format.
It can be clearly understood by those skilled in the art that, for convenience and brevity of description, the specific working process of the described module may refer to the corresponding process in the foregoing method embodiment, and is not described herein again.
As shown in fig. 5, the device includes a Central Processing Unit (CPU) that can perform various appropriate actions and processes according to computer program instructions stored in a Read Only Memory (ROM) or computer program instructions loaded from a storage unit into a Random Access Memory (RAM). In the RAM, various programs and data required for the operation of the device can also be stored. The CPU, ROM, and RAM are connected to each other via a bus. An input/output (I/O) interface is also connected to the bus.
A plurality of components in the device are connected to the I/O interface, including: an input unit such as a keyboard, a mouse, etc.; an output unit such as various types of displays, speakers, and the like; storage units such as magnetic disks, optical disks, and the like; and a communication unit such as a network card, modem, wireless communication transceiver, etc. The communication unit allows the device to exchange information/data with other devices via a computer network such as the internet and/or various telecommunication networks.
The processing unit executes the respective methods and processes described above, for example, methods S101 to S103. For example, in some embodiments, methods S101-S103 may be implemented as a computer software program tangibly embodied in a machine-readable medium, such as a storage unit. In some embodiments, part or all of the computer program may be loaded and/or installed onto the device via ROM and/or the communication unit. When the computer program is loaded into RAM and executed by the CPU, one or more of the steps of methods S101-S103 described above may be performed. Alternatively, in other embodiments, the CPU may be configured to perform methods S101-S103 by any other suitable means (e.g., by way of firmware).
The functions described herein above may be performed, at least in part, by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: a Field Programmable Gate Array (FPGA), an Application Specific Integrated Circuit (ASIC), an Application Specific Standard Product (ASSP), a system on a chip (SOC), a load programmable logic device (CPLD), and the like.
Program code for implementing the methods of the present invention may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable data processing apparatus, such that the program codes, when executed by the processor or controller, cause the functions/operations specified in the flowchart and/or block diagram to be performed. The program code may execute entirely on the machine, partly on the machine, as a stand-alone software package partly on the machine and partly on a remote machine or entirely on the remote machine or server.
In the context of the present invention, a machine-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
Further, while operations are depicted in a particular order, this should be understood as requiring that such operations be performed in the particular order shown or in sequential order, or that all illustrated operations be performed, to achieve desirable results. Under certain circumstances, multitasking and parallel processing may be advantageous. Likewise, while several specific implementation details are included in the above discussion, these should not be construed as limitations on the scope of the invention. Certain features that are described in the context of separate embodiments can also be implemented in combination in a single implementation. Conversely, various features that are described in the context of a single implementation can also be implemented in multiple implementations separately or in any suitable subcombination.
Although the subject matter has been described in language specific to structural features and/or methodological acts, it is to be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or acts described above. Rather, the specific features and acts described above are disclosed as example forms of implementing the claims.

Claims (10)

1. A method for detecting the connectivity of an on-line user with opened service is characterized by comprising the following steps:
responding to the successful message of equipment login, searching equipment information according to the equipment identifier, and searching a first service address actually allocated to the current service work order according to a reference service number in the equipment information;
judging the gateway type of the address on the port of the equipment, and if the gateway type is an independent gateway, detecting the online service address according to the ping test method of the independent gateway; if the gateway type is a shared gateway, detecting an online service address according to a ping test method of the shared gateway;
and performing connectivity test on the online service address to obtain a connectivity test result.
2. The method of claim 1, wherein detecting an online service address according to a ping test method of an independent gateway comprises:
judging the ping test type of the entry, if the ping test type of the entry is the vrf ping test, extracting a vpn example according to the corresponding keywords, and extracting an independent gateway address according to the corresponding keywords; if the participating ping test type is a common ping test, extracting an independent gateway address directly according to the corresponding key words;
and extracting all addresses under the port according to the keywords, and taking the intersection of the dependent gateway address under the port and the first service address as the online service address of the current access reference service number.
3. The method of claim 1, wherein detecting an online service address according to a ping test method of a shared gateway comprises:
judging the ping test type of the entry, if the ping test type of the entry is the vrf ping test, extracting a vpn example according to the corresponding keywords, and extracting all addresses under the port according to the corresponding keywords; if the participating ping test type is a common ping test, all addresses under the port are directly extracted according to the corresponding keywords;
and taking the intersection of all the addresses under the port and the first service address as the online service address of the current access reference service number.
4. The method of claim 1, wherein the performing connectivity tests on the online service address comprises:
judging the ping test type of the online service address, and if the ping test type of the online service address is a vrf ping test, executing a vrf ping test command to carry out a connectivity test to obtain a first test result; if the ping test type of the online service address is a common ping test, executing a common ping test command to carry out connectivity test to obtain a second test result;
and recording the first test result or the second test result, and returning in a standard json data format.
5. The method of claim 1, further comprising: if the access service number in the equipment information does not exist, returning to a failure state that the service number does not exist and ending.
6. The method of claim 1, further comprising: if the gateway type of the address on the port of the equipment can not be judged, returning a failure state that the gateway type can not be judged, and ending.
7. The method of claim 1, further comprising: and if all the addresses under the port are not intersected with the first service address or the non-independent gateway address under the port is not intersected with the first service address, returning to a failure state of the offline service address and ending.
8. An apparatus for detecting connectivity of an online user with an opened service, comprising:
the searching module is used for responding to the successful message of equipment login and searching equipment information according to the equipment identifier and searching a first service address actually allocated to the current service work order according to the reference service number in the equipment information;
the judging module is used for judging the gateway type of the address on the port of the equipment, and if the gateway type is an independent gateway, the online service address is detected according to the ping test method of the independent gateway; if the gateway type is a shared gateway, detecting an online service address according to a ping test method of the shared gateway;
and the testing module is used for carrying out connectivity test on the online service address to obtain a connectivity test result.
9. An electronic device comprising a memory and a processor, the memory having stored thereon a computer program, wherein the processor, when executing the program, implements the method of any of claims 1-7.
10. A computer-readable storage medium, on which a computer program is stored, which program, when being executed by a processor, carries out the method according to any one of claims 1 to 7.
CN202011317748.6A 2020-11-23 2020-11-23 Method and device for detecting connectivity of opened service online user Active CN112333048B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011317748.6A CN112333048B (en) 2020-11-23 2020-11-23 Method and device for detecting connectivity of opened service online user

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011317748.6A CN112333048B (en) 2020-11-23 2020-11-23 Method and device for detecting connectivity of opened service online user

Publications (2)

Publication Number Publication Date
CN112333048A CN112333048A (en) 2021-02-05
CN112333048B true CN112333048B (en) 2022-03-11

Family

ID=74321951

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011317748.6A Active CN112333048B (en) 2020-11-23 2020-11-23 Method and device for detecting connectivity of opened service online user

Country Status (1)

Country Link
CN (1) CN112333048B (en)

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8411683B2 (en) * 2009-09-04 2013-04-02 Comcast Cable Communications, Llc Method and apparatus for providing connectivity in a network with multiple packet protocols
CN104168157B (en) * 2014-08-14 2017-05-03 中国联合网络通信集团有限公司 Network connectivity detection method and device
CN106301997A (en) * 2015-06-29 2017-01-04 中兴通讯股份有限公司 Gateway device response to network connectedness method and apparatus
CN112994975A (en) * 2016-02-26 2021-06-18 华为技术有限公司 Method and apparatus for connectivity detection
CN106059853B (en) * 2016-05-26 2019-05-31 中国建设银行股份有限公司 A kind of network connectivty test method and device
CN107800555B (en) * 2016-09-05 2023-01-24 中兴通讯股份有限公司 Service diagnosis method and device
US10673737B2 (en) * 2018-04-17 2020-06-02 Cisco Technology, Inc. Multi-VRF universal device internet protocol address for fabric edge devices
CN111371645B (en) * 2020-02-28 2022-04-29 平安养老保险股份有限公司 Method, system, computer equipment and storage medium for testing service connectivity

Also Published As

Publication number Publication date
CN112333048A (en) 2021-02-05

Similar Documents

Publication Publication Date Title
CN108683562B (en) Anomaly detection positioning method and device, computer equipment and storage medium
CN109361562B (en) Automatic testing method based on associated network equipment access
CN108255725B (en) Test method and device
CN110691009B (en) Network equipment inspection method and device
CN109660533B (en) Method and device for identifying abnormal flow in real time, computer equipment and storage medium
CN114064208A (en) Method and device for detecting application service state, electronic equipment and storage medium
CN110598008A (en) Data quality inspection method and device for recorded data and storage medium
CN113157536A (en) Alarm analysis method, device, equipment and storage medium
CN113312260A (en) Interface testing method, device, equipment and storage medium
CN113347060B (en) Method, device and system for detecting power network fault based on process automation
CN112311574A (en) Method, device and equipment for checking network topology connection
CN112333048B (en) Method and device for detecting connectivity of opened service online user
CN114499984A (en) Identity authentication method, device, equipment and medium based on AI and RPA
CN115604343A (en) Data transmission method, system, electronic equipment and storage medium
CN110457187B (en) TPC-E test method and test server capable of conveniently running based on backup test data
CN114553678A (en) Diagnosis method for soft SLB traffic problem of cloud network
CN110348984B (en) Automatic credit card data input method and related equipment under different transaction channels
CN114093392A (en) Audio labeling method, device, equipment and storage medium
CN115499861A (en) Service same-route detection method, device, equipment and storage medium
CN112631929A (en) Test case generation method and device, storage medium and electronic equipment
CN112131611A (en) Data correctness verification method, device, equipment, system and storage medium
CN115622752B (en) Session management method, device, electronic equipment and storage medium
CN113094078B (en) Security detection method, device, equipment and medium
CN114448848B (en) Switch testing method and device, electronic equipment and storage medium
CN115543747B (en) Method for automatically inspecting front-end webpage performance

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
GR01 Patent grant
GR01 Patent grant
CP02 Change in the address of a patent holder

Address after: Room 702-2, No. 4811 Caoan Road, Jiading District, Shanghai, 201800

Patentee after: CHINA UNITECHS

Address before: Room 1004-4, 10 / F, 1112 Hanggui Road, Anting Town, Jiading District, Shanghai 201800

Patentee before: CHINA UNITECHS

CP02 Change in the address of a patent holder