CN104811343A - Network detection method and system of peer-to-peer network - Google Patents

Network detection method and system of peer-to-peer network Download PDF

Info

Publication number
CN104811343A
CN104811343A CN201510241157.8A CN201510241157A CN104811343A CN 104811343 A CN104811343 A CN 104811343A CN 201510241157 A CN201510241157 A CN 201510241157A CN 104811343 A CN104811343 A CN 104811343A
Authority
CN
China
Prior art keywords
network
checkout gear
main frame
destination host
peer
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
CN201510241157.8A
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.)
Beijing Jingdong Century Trading Co Ltd
Beijing Jingdong Shangke Information Technology Co Ltd
Original Assignee
Beijing Jingdong Century Trading Co Ltd
Beijing Jingdong Shangke 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 Beijing Jingdong Century Trading Co Ltd, Beijing Jingdong Shangke Information Technology Co Ltd filed Critical Beijing Jingdong Century Trading Co Ltd
Priority to CN201510241157.8A priority Critical patent/CN104811343A/en
Publication of CN104811343A publication Critical patent/CN104811343A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/104Peer-to-peer [P2P] networks
    • H04L67/1044Group management mechanisms 
    • H04L67/1048Departure or maintenance mechanisms
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/104Peer-to-peer [P2P] networks
    • H04L67/1074Peer-to-peer [P2P] networks for supporting data block transmission mechanisms

Abstract

The invention provides a network detection method and system of a peer-to-peer network. Network detection between an appointed host and a target host can be realized and the network detection frequency can be flexibly set, so that the network detection is automatically carried out. The network detection method of the peer-to-peer network comprises the following steps that one or more target hosts are determined by a detection device located on a first host; the detection device detects whether a network between the first host and the target hosts is connected normally or not according to a pre-set period; the detection device outputs a detection result.

Description

The network detecting method of peer-to-peer network and system
Technical field
The present invention relates to technical field of the computer network, particularly relate to a kind of network detecting method and system of peer-to-peer network.
Background technology
In technical field of the computer network, P2P computing (Peer to Peer, be called for short p2p) can simply be defined as by directly exchanging Sharing computer resource and service, and the network that P2P computing models applying layer is formed is commonly referred to peer-to-peer network.In P2P network environment, thousands of the computers be connected to each other all are in the status of equity, and in general whole network does not rely on special centralized servers.Each computer in network can serve as the requestor of network service, makes response again to the request of other computer, provides resource and service.
Ping order is method connective between the most common checkout equipment, it is the troubleshooting function order be built in planting in Linux, Unix and Microsoft Windows, transmit packet to particular ip address by ICMP agreement, and receive response, judge the congestion situations of network with this.Network detection scheme based on Ping order mostly is following two kinds.
The first, be manually connected on source host by terminal, performed the Network Check orders such as Ping order check network-in-dialing situation by order line.But thisly carry out detection method by artificial means, cannot monitor at any time, the very first time that can not go wrong at network, with regard to orientation problem reason, can not carry out persistent storage to detection data automatically.
The second, is detected network in real time by various monitor system software of increasing income.This detection mode is varied, needs in the choice to spend certain hour, and real-time and stability cannot ensure the changes in demand of user.Such as popular at present Nagios, Cacti and Zabbix, although they all support to detect based on the network of Ping order, but be all that the machine that their its own system run detects to the network of target machine, instead of the source host that actual user needs detects to the network of destination host, and due to for the consideration to performance, it is thicker that their network detection frequency is all arranged, like this when network generation problem, response can not be made to problem in a short period of time.
Summary of the invention
In view of this, the invention provides a kind of network detecting method and system of peer-to-peer network, the network that can realize between given host to destination host detects; And network detects frequency and can arrange flexibly, ensure that network detects automation and carries out.
For achieving the above object, according to an aspect of the present invention, a kind of network detecting method of peer-to-peer network is provided.
The network detecting method of peer-to-peer network of the present invention comprises: the checkout gear being positioned at the first main frame determines one or more destination host; Whether the network of described checkout gear according to the cycle detection preset between the first main frame with described destination host is normally communicated with; Described checkout gear output detections result.
Alternatively, describedly determine that the step of one or more destination host comprises: obtain the configuration file in described first main frame, in configuration file, comprise the mark of one or more destination host.
Alternatively, the step whether network of described checkout gear according to the cycle detection preset between the first main frame with described destination host is normally communicated with comprises: described checkout gear scans the configuration file in described first main frame, to obtain the IP address of destination host and default packet loss threshold value; Described checkout gear performs Ping order according to the cycle of presetting to the IP address of described destination host, then receives return data, then carries out contrast with described packet loss threshold value and judge.
Alternatively, described method also comprises: described checkout gear obtains the configuration file in described first main frame, comprises checkout gear and take threshold value to the first host calculating resource in configuration file; Described checkout gear, stops running if take threshold value described in exceeding to the seizure condition of the computational resource of described first main frame by the cycle monitoring preset.
Alternatively, described method also comprises: the running status judging described checkout gear by the sense cycle preset, if be not in running status, and start detection device.
According to a further aspect in the invention, a kind of network detection system of peer-to-peer network is provided.
The network detection system of peer-to-peer network of the present invention comprises checkout gear, and this checkout gear comprises checkout gear, and this checkout gear comprises: determination module, for determining one or more destination host; Whether detection module, be normally communicated with for the network according to the cycle detection preset between the first main frame with described destination host; Output module, for exporting the testing result of described detection module.
Alternatively, described determination module also for: obtain the configuration file in described first main frame, in configuration file, comprise the mark of one or more destination host.
Alternatively, described detection module also for: scan the configuration file in described first main frame, to obtain the IP address of destination host and default packet loss threshold value; According to the cycle of presetting, Ping order is performed to the IP address of described destination host, then receive return data, then carry out contrast with described packet loss threshold value and judge.
Alternatively, described checkout gear also comprises monitoring modular, and monitoring modular is used for: obtain the configuration file in described first main frame, comprises checkout gear and take threshold value to the first host calculating resource in configuration file; By the cycle monitoring preset to the seizure condition of the computational resource of described first main frame, if take threshold value described in exceeding, stop running.
Alternatively, described network detection system also comprises monitoring arrangement, and this monitoring arrangement is used for the running status judging described checkout gear by the sense cycle preset, if be not in running status, and start detection device.
According to technical scheme of the present invention, by being installed on the first main frame by checkout gear, and determine destination host, the network realized between given host to destination host detects; And network detects frequency and can arrange flexibly, ensure that network detects automation and carries out.In addition, due to by the cycle detection preset taking situation and making and stop judging the computational resource of the first main frame, thus ensure that Detection task safety and stability is carried out.Further, by the monitoring at any time to checkout gear running status, thus the real-time that network detects can be ensured.
Accompanying drawing explanation
Accompanying drawing is used for understanding the present invention better, does not form inappropriate limitation of the present invention.Wherein:
Fig. 1 is the schematic diagram of the network detecting method key step of peer-to-peer network according to the embodiment of the present invention;
Fig. 2 is the schematic diagram of the main device of the network detection system of peer-to-peer network according to the embodiment of the present invention.
Embodiment
Below in conjunction with accompanying drawing, one exemplary embodiment of the present invention is explained, comprising the various details of the embodiment of the present invention to help understanding, they should be thought it is only exemplary.Therefore, those of ordinary skill in the art will be appreciated that, can make various change and amendment, and can not deviate from scope and spirit of the present invention to the embodiments described herein.Equally, for clarity and conciseness, the description to known function and structure is eliminated in following description.
Fig. 1 is the schematic diagram of the network detecting method key step of peer-to-peer network according to the embodiment of the present invention.As shown in Figure 1, the network detecting method of the peer-to-peer network of the embodiment of the present invention mainly comprises the steps:
Step S11: the checkout gear being positioned at the first main frame determines one or more destination host.Can be such as by checkout gear, as the client in the present embodiment, be arranged on and need on the first main frame of Sampling network state, then scanning and network detect the configuration file that file under client same directory is called config.cfg, to obtain the IP address of destination host and default packet loss threshold value.
After the determination of this step, process from step S12.
Step S12: whether the network of described checkout gear according to the cycle detection preset between the first main frame with described destination host is normally communicated with.Here the cycle of presetting can be judge once for every 30 seconds.
Step S13: described checkout gear output detections result.
In step s 12, specifically can carry out as follows:
Checkout gear performs Ping order to the IP address of described destination host, detects 3 times, every minor tick 1 second; Checkout gear receives Ping order return data, carry out contrast with described packet loss threshold value and judge as 30% again, such as, if packet loss exceedes 30% set threshold value, then judge that network-in-dialing is abnormal, warning message is write journal file, or mail can be sent by the addresses of items of mail of described configuration, direct transmission alert notice related personnel, finally stores the data persistence after parsing; If do not exceed packet loss threshold decision, then judge that network-in-dialing is normal, the data after resolving are carried out persistent storage.
Or can be to have opened and in unappropriated situation at destination host designated port, execution telnet order is set up TCP with destination host designated port and is connected, if successful connection, then judges that network-in-dialing is normal, if connection failure, then judge that network-in-dialing is abnormal.
Can also be perform wget order, detect and download file destination host allowing download, if download successfully, then judge that network-in-dialing is normal, if failed download, then judge that network-in-dialing is abnormal.
Other can be adopted in addition to order such as tracert order to carry out Sampling network connected state.
Can find out according to above-mentioned steps, be installed to by checkout gear on the first main frame, and send network sense command to the destination host determined, the network that can realize between given host to destination host detects; And network detects frequency and can arrange flexibly, ensure that network detects automation and carries out.
In above step, the network detecting method of peer-to-peer network also comprises can arrange a checkout gear by the cycle monitoring preset to the step of the situation that takies of the computational resource of the first main frame.Can be such as that checkout gear obtains and comprises checkout gear and take threshold value to the first host calculating resource from the configuration file of step S11, as CPU=10 (percentage), Memery=512000 (KB); Then by preset cycle, as can be every 30 seconds once, monitor the seizure condition of the computational resource to the first main frame, take threshold value if exceed, stop run.
While the network carrying out peer-to-peer network detects, said method also can comprise: the running status judging described checkout gear by the sense cycle preset, if be not in running status, and start detection device.Such as, the cycle of presetting can be monitor once for every 10 seconds.
Judge that the method whether checkout gear runs can be use shell language compilation test and monitoring shell script, utilize ps order, whether monitor network detects client exists.Exist if network detects client process, then dormancy re-executes ps order Sampling network and detects client process after 10 seconds; Do not exist if network detects client process, then start network and detect client.
Or can also be the test and monitoring program utilizing system crontab order to substitute shell script, start crond finger daemon on backstage, within every 1 minute, check whether that predetermined operation needs to perform.
Judge that the running status of described checkout gear contributes to guaranteeing network checkout gear real time execution according to by the sense cycle preset.
Fig. 2 is the main device schematic diagram of the network detection system of peer-to-peer network according to the embodiment of the present invention.
As shown in Figure 2, the network detection system of the peer-to-peer network of the embodiment of the present invention mainly comprises checkout gear 20, and this checkout gear 20 comprises: determination module 201, detection module 202, output module 203.
Determination module 201 is for determining one or more destination host; Whether detection module 202 is normally communicated with for the network according to the cycle detection preset between the first main frame with described destination host; Output module 203 is for output detections result.
Determination module 201 also can be used for obtaining the configuration file in described first main frame, comprises the mark of one or more destination host in configuration file.
Detection module 202 also can be used for scanning the configuration file in described first main frame, to obtain the IP address of destination host and default packet loss threshold value, and according to the cycle of presetting, Ping order is performed to the IP address of described destination host, then receive return data, then carry out contrast with described packet loss threshold value and judge.
In the embodiment of the present invention, the checkout gear of the network detection system of peer-to-peer network can also comprise monitoring modular 204 (with shown in Figure 2), monitoring modular 204 is for obtaining the configuration file in described first main frame, comprise checkout gear in configuration file and threshold value is taken to the first host calculating resource, and by the cycle monitoring preset to the seizure condition of the computational resource of described first main frame, if take threshold value described in exceeding, stop running.
The network detection system of the peer-to-peer network of the embodiment of the present invention can also comprise monitoring arrangement 21 (with shown in Figure 2).This monitoring arrangement 21 for judging the running status of described checkout gear by the sense cycle preset, if be not in running status, start detection device.Herein preset sense cycle can arrange flexibly, as can be every 10 seconds monitor once.
According to technical scheme of the present invention, by being positioned at checkout gear determination destination host on the first main frame, so the network that can realize between given host to destination host detects, and by setting sense cycle flexibly, ensure that the automation that network detects is carried out.In addition, due to by the cycle detection preset taking situation and making and stop judging the computational resource of the first main frame, thus ensure that Detection task safety and stability is carried out.Further, by the monitoring at any time to checkout gear running status, thus the real-time that network detects can be ensured.
Above-mentioned embodiment, does not form limiting the scope of the invention.It is to be understood that depend on designing requirement and other factors, various amendment, combination, sub-portfolio can be there is and substitute in those skilled in the art.Any amendment done within the spirit and principles in the present invention, equivalent replacement and improvement etc., all should be included within scope.

Claims (10)

1. a network detecting method for peer-to-peer network, is characterized in that, comprising:
The checkout gear being positioned at the first main frame determines one or more destination host;
Whether the network of described checkout gear according to the cycle detection preset between the first main frame with described destination host is normally communicated with;
Described checkout gear output detections result.
2. method according to claim 1, is characterized in that, describedly determines that the step of one or more destination host comprises:
Obtain the configuration file in described first main frame, in configuration file, comprise the mark of one or more destination host.
3. method according to claim 1, is characterized in that, the step whether network of described checkout gear according to the cycle detection preset between the first main frame with described destination host is normally communicated with comprises:
Configuration file in described first main frame of described checkout gear scanning, to obtain the IP address of destination host and default packet loss threshold value;
Described checkout gear performs Ping order according to the cycle of presetting to the IP address of described destination host, then receives return data, then carries out contrast with described packet loss threshold value and judge.
4. method according to claim 1, is characterized in that, described method also comprises:
Described checkout gear obtains the configuration file in described first main frame, comprises checkout gear and take threshold value to the first host calculating resource in configuration file;
Described checkout gear, stops running if take threshold value described in exceeding to the seizure condition of the computational resource of described first main frame by the cycle monitoring preset.
5. method according to any one of claim 1 to 4, is characterized in that, described method also comprises:
The running status of described checkout gear is judged by the sense cycle preset, if be not in running status, start detection device.
6. a network detection system for peer-to-peer network, is characterized in that, comprises checkout gear, and this checkout gear comprises:
Determination module, for determining one or more destination host;
Whether detection module, be normally communicated with for the network according to the cycle detection preset between the first main frame with described destination host;
Output module, for exporting the testing result of described detection module.
7. system according to claim 6, is characterized in that, described determination module also for:
Obtain the configuration file in described first main frame, in configuration file, comprise the mark of one or more destination host.
8. system according to claim 6, is characterized in that, described detection module also for:
Scan the configuration file in described first main frame, to obtain the IP address of destination host and default packet loss threshold value;
According to the cycle of presetting, Ping order is performed to the IP address of described destination host, then receive return data, then carry out contrast with described packet loss threshold value and judge.
9. system according to claim 6, is characterized in that, described checkout gear also comprises monitoring modular, and monitoring modular is used for:
Obtain the configuration file in described first main frame, comprise checkout gear in configuration file and threshold value is taken to the first host calculating resource;
By the cycle monitoring preset to the seizure condition of the computational resource of described first main frame, if take threshold value described in exceeding, stop running.
10. the system according to any one of claim 6 to 9, it is characterized in that, described network detection system also comprises monitoring arrangement, and this monitoring arrangement is used for the running status judging described checkout gear by the sense cycle preset, if be not in running status, and start detection device.
CN201510241157.8A 2015-05-12 2015-05-12 Network detection method and system of peer-to-peer network Pending CN104811343A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510241157.8A CN104811343A (en) 2015-05-12 2015-05-12 Network detection method and system of peer-to-peer network

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510241157.8A CN104811343A (en) 2015-05-12 2015-05-12 Network detection method and system of peer-to-peer network

Publications (1)

Publication Number Publication Date
CN104811343A true CN104811343A (en) 2015-07-29

Family

ID=53695854

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510241157.8A Pending CN104811343A (en) 2015-05-12 2015-05-12 Network detection method and system of peer-to-peer network

Country Status (1)

Country Link
CN (1) CN104811343A (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105357076A (en) * 2015-11-20 2016-02-24 中国建设银行股份有限公司 Method and device used for detecting network connectivity between nodes
CN108234152A (en) * 2016-12-12 2018-06-29 北京京东尚科信息技术有限公司 The method and system for the network monitoring that remote interface calls
CN108282381A (en) * 2017-09-15 2018-07-13 广州市动景计算机科技有限公司 Network packet loss rate monitoring method, device and test server
CN108462612A (en) * 2017-02-22 2018-08-28 北京京东尚科信息技术有限公司 Adjust method, apparatus, electronic equipment and the storage medium of RTP media flow transmissions
CN109067620A (en) * 2018-09-27 2018-12-21 深圳壹账通智能科技有限公司 The monitoring method and device of gateway

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1741480A (en) * 2004-08-29 2006-03-01 华为技术有限公司 Method and equipment for detecting signalling or media path fault in next generation method
CN101001179A (en) * 2006-01-11 2007-07-18 中兴通讯股份有限公司 Detection method for carrier network
CN101013975A (en) * 2007-01-24 2007-08-08 中国人民解放军理工大学指挥自动化学院 Method and system for testing performance parameter between random two terminal systems in IP network
CN101159669A (en) * 2007-10-09 2008-04-09 华为技术有限公司 Service flow switching method and apparatus
US20100251370A1 (en) * 2009-03-26 2010-09-30 Inventec Corporation Network intrusion detection system

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1741480A (en) * 2004-08-29 2006-03-01 华为技术有限公司 Method and equipment for detecting signalling or media path fault in next generation method
CN101001179A (en) * 2006-01-11 2007-07-18 中兴通讯股份有限公司 Detection method for carrier network
CN101013975A (en) * 2007-01-24 2007-08-08 中国人民解放军理工大学指挥自动化学院 Method and system for testing performance parameter between random two terminal systems in IP network
CN101159669A (en) * 2007-10-09 2008-04-09 华为技术有限公司 Service flow switching method and apparatus
US20100251370A1 (en) * 2009-03-26 2010-09-30 Inventec Corporation Network intrusion detection system

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105357076A (en) * 2015-11-20 2016-02-24 中国建设银行股份有限公司 Method and device used for detecting network connectivity between nodes
CN105357076B (en) * 2015-11-20 2019-01-29 中国建设银行股份有限公司 Network connectivty detection method and device between a kind of node
CN108234152A (en) * 2016-12-12 2018-06-29 北京京东尚科信息技术有限公司 The method and system for the network monitoring that remote interface calls
CN108234152B (en) * 2016-12-12 2021-08-10 北京京东尚科信息技术有限公司 Method and system for network monitoring of remote interface calls
CN108462612A (en) * 2017-02-22 2018-08-28 北京京东尚科信息技术有限公司 Adjust method, apparatus, electronic equipment and the storage medium of RTP media flow transmissions
CN108462612B (en) * 2017-02-22 2021-01-26 北京京东尚科信息技术有限公司 Method, device, electronic equipment and storage medium for adjusting RTP media stream transmission
CN108282381A (en) * 2017-09-15 2018-07-13 广州市动景计算机科技有限公司 Network packet loss rate monitoring method, device and test server
CN109067620A (en) * 2018-09-27 2018-12-21 深圳壹账通智能科技有限公司 The monitoring method and device of gateway

Similar Documents

Publication Publication Date Title
CN110036600B (en) Network health data convergence service
CN110036599B (en) Programming interface for network health information
US8208381B2 (en) Root-cause approach to problem diagnosis in data networks
CN104811343A (en) Network detection method and system of peer-to-peer network
CN109075996B (en) Monitoring controller for monitoring network performance and method performed thereby
US20160330067A1 (en) Network Service Fault Handling Method, Service Management System, and System Management Module
JP5342696B2 (en) Download plug-ins in instant messaging client
US20060074946A1 (en) Point of view distributed agent methodology for network management
US20080016115A1 (en) Managing Networks Using Dependency Analysis
CN102761461B (en) A kind of link health examination method and device
US11522765B2 (en) Auto discovery of network proxies
CN114157554B (en) Fault checking method and device, storage medium and computer equipment
US20110099273A1 (en) Monitoring apparatus, monitoring method, and a computer-readable recording medium storing a monitoring program
CN105553731A (en) Automatic inspection method and device
Bahl et al. Discovering dependencies for network management
US9854042B2 (en) Automated assessment report generation
US9935867B2 (en) Diagnostic service for devices that employ a device agent
JP2010198491A (en) Virtual machine server, and virtual machine network monitoring system using the same
US10659289B2 (en) System and method for event processing order guarantee
CN109997337B (en) Visualization of network health information
CN106713038B (en) remote transmission line quality detection method and system
WO2024036043A1 (en) Method and apparatus for controlling electronic devices
WO2023124127A1 (en) Communication connection method, apparatus and device for host and storage system, and medium
Tsubouchi et al. Low overhead TCP/UDP socket-based tracing for discovering network services dependencies
Iswari et al. Network performance evaluation of container server-based LoRaWAN IoT for field worker monitoring system

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
EXSB Decision made by sipo to initiate 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: 20150729