CN110213132A - Network connectivity methods, electronic equipment, system and medium - Google Patents
Network connectivity methods, electronic equipment, system and medium Download PDFInfo
- Publication number
- CN110213132A CN110213132A CN201910493108.1A CN201910493108A CN110213132A CN 110213132 A CN110213132 A CN 110213132A CN 201910493108 A CN201910493108 A CN 201910493108A CN 110213132 A CN110213132 A CN 110213132A
- Authority
- CN
- China
- Prior art keywords
- node
- network
- destination node
- outer net
- service ability
- 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.)
- Granted
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L41/00—Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
- H04L41/08—Configuration management of networks or network elements
- H04L41/0803—Configuration setting
- H04L41/0806—Configuration setting for initial configuration or provisioning, e.g. plug-and-play
- H04L41/0809—Plug-and-play configuration
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L43/00—Arrangements for monitoring or testing data switching networks
- H04L43/08—Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L43/00—Arrangements for monitoring or testing data switching networks
- H04L43/08—Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
- H04L43/0805—Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters by checking availability
- H04L43/0811—Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters by checking availability by checking connectivity
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L43/00—Arrangements for monitoring or testing data switching networks
- H04L43/10—Active monitoring, e.g. heartbeat, ping or trace-route
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L43/00—Arrangements for monitoring or testing data switching networks
- H04L43/50—Testing arrangements
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/14—Session management
- H04L67/141—Setup of application sessions
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 discloses a kind of network connectivity methods, electronic equipment, system and media, which comprises when having detected that destination node will connect network, determines whether the destination node has outer net service ability;When the destination node has outer net service ability, Bootstrap node is connected;Based on the Bootstrap node, at least one network node is obtained from the network;Probe node is searched from least one described network node;By the probe node, the destination node is reversely detected;When detecting reversed detect successfully, the destination node is connected to the network.The present invention can filter out the good node of connectivity, to reduce the ratio of invalid node, improve the connected ratio of nodes, and then optimize the service ability of network.
Description
Technical field
The present invention relates to Internet technical field more particularly to network connectivity methods, electronic equipment, system and media.
Background technique
There is no central server in decentralization network, therefore, when the meshed network in network is unstable, node it
Between connectivity also just do not ensure.If the node being added in network can not be with establishing connection between other node, such as: TCP
(Transmission Control Protocol, transmission control protocol) connection or UDP (User Datagram
Protocol, User Datagram Protocol) connection, such network, search efficiency and data transmission efficiency can be very low, therefore,
If improving the performance of network, it is necessary to improve the connected ratio between system interior joint.
That is, the node being only added in network can be connected to, the connectivity of that whole network is only secure
, therefore, the good node of connectivity how is filtered out, becomes the key point of optimization network performance.
Summary of the invention
The main purpose of the present invention is to provide network connectivity methods, electronic equipment, system and media, it is intended to the company of filtering out
The good node of general character energy improves the connected ratio of nodes, and then optimize the service of network to reduce the ratio of invalid node
Ability.
To achieve the above object, the present invention provides a kind of network connectivity methods, which comprises
When having detected that destination node will connect network, determine whether the destination node has outer net service ability;
When the destination node has outer net service ability, Bootstrap node is connected;
Based on the Bootstrap node, at least one network node is obtained from the network;
Probe node is searched from least one described network node;
By the probe node, the destination node is reversely detected;
When detecting reversed detect successfully, the destination node is connected to the network.
Preferably, whether the determination destination node has outer net service ability and includes:
Detection is performed network address translation to the destination node;
When being detected with outer net IP, determine that the destination node has outer net service ability.
Preferably, the method also includes:
When the destination node does not have outer net service ability, universal plug and play port is carried out to the destination node
Mapping;
When detect map successfully when, determine that the destination node has outer net service ability.
Preferably, described by the probe node, carrying out reversed detection to the destination node includes:
Signaling packet is sent to the probe node, the signaling packet is for notifying the probe node to send data packet to institute
State the configuration port of destination node;
Every prefixed time interval, detect whether the configuration port receives the data packet;
When detecting that the configuration port receives the data packet, stop detection.
Preferably, the method also includes:
When detecting that the configuration port is not received by the data packet, described in the retransmission of Xiang Suoshu probe node
Signaling packet.
Preferably, the configuration port includes any of the following:
When the destination node has outer net service ability, the configuration port includes the arbitrary end of the destination node
Mouthful;Or
When the destination node does not have outer net service ability, the configuration port includes successfully carrying out general insert i.e.
With the port of port mapping.
To achieve the above object, the present invention further provides a kind of electronic equipment, the electronic equipment includes:
Memory stores at least one instruction;And
Processor executes the instruction stored in the memory to realize the network connectivity methods.
Preferably, the electronic equipment is the node of component content distribution network or block chain network.
To achieve the above object, the present invention further provides a kind of network-in-dialing system, the system comprises:
Determination unit, for determining whether the destination node has when having detected that destination node will connect network
Outer net service ability;
Connection unit, for connecting Bootstrap node when the destination node has outer net service ability;
Acquiring unit obtains at least one network node for being based on the Bootstrap node from the network;
Searching unit, for searching probe node from least one described network node;
Probe unit, for reversely being detected to the destination node by the probe node;
The connection unit is also used to that the destination node is connected to the net when detecting reversed detect successfully
Network.
Preferably, the determination unit determines whether the destination node has outer net service ability and include:
Detection is performed network address translation to the destination node;
When being detected with outer net IP, determine that the destination node has outer net service ability.
Preferably, the system also includes:
Map unit, for leading to the destination node when the destination node does not have outer net service ability
With plug and play port mapping;
The determination unit, be also used to when detect map successfully when, determine that the destination node has outer net service energy
Power.
Preferably, the probe unit is specifically used for:
Signaling packet is sent to the probe node, the signaling packet is for notifying the probe node to send data packet to institute
State the configuration port of destination node;
Every prefixed time interval, detect whether the configuration port receives the data packet;
When detecting that the configuration port receives the data packet, stop detection.
Preferably, the system also includes:
Transmission unit, for being saved to the detection when detecting that the configuration port is not received by the data packet
Point retransmits the signaling packet.
Preferably, the configuration port includes any of the following:
When the destination node has outer net service ability, the configuration port includes the arbitrary end of the destination node
Mouthful;Or
When the destination node does not have outer net service ability, the configuration port includes successfully carrying out general insert i.e.
With the port of port mapping.
To achieve the above object, the present invention further provides a kind of computer program products, including computer instruction, when it
When running on computers, computer is allowed to execute the network connectivity methods.
In conclusion the present invention can determine that the destination node is when having detected that destination node will connect network
It is no to have outer net service ability, the node of standby outer net service ability is provided with preliminary screening, when the destination node has outer net
When service ability, Bootstrap node is connected, and be based on the Bootstrap node, obtain at least one from the network
Network node further searches probe node from least one described network node, has had due to the probe node
Connectivity, therefore can be improved detection success rate, and by the probe node, reversely detected to the destination node,
When detecting reversed detect successfully, the destination node is connected to the network, and then filter out the good section of connectivity
Point improves the connected ratio of nodes, and then optimize the service ability of network to reduce the ratio of invalid node.
Detailed description of the invention
Fig. 1 is the flow diagram of one embodiment of the invention;
Fig. 2 is the schematic diagram of internal structure for the electronic equipment that one embodiment of the invention discloses;
Fig. 3 is the functional block diagram of inventive network connected system;
The embodiments will be further described with reference to the accompanying drawings for the realization, the function and the advantages of the object of the present invention.
Main element symbol description
Electronic equipment | 1 |
Memory | 12 |
Processor | 13 |
Network-in-dialing system | 11 |
Determination unit | 110 |
Connection unit | 111 |
Acquiring unit | 112 |
Searching unit | 113 |
Probe unit | 114 |
Map unit | 116 |
Transmission unit | 117 |
Specific embodiment
In order to make the objectives, technical solutions, and advantages of the present invention clearer, with reference to the accompanying drawings and embodiments, right
The present invention is further elaborated.It should be appreciated that described herein, specific examples are only used to explain the present invention, not
For limiting the present invention.Based on the embodiments of the present invention, those of ordinary skill in the art are not before making creative work
Every other embodiment obtained is put, shall fall within the protection scope of the present invention.
The description and claims of this application and term " first ", " second ", " third ", " in above-mentioned attached drawing
The (if present)s such as four " are to be used to distinguish similar objects, without being used to describe a particular order or precedence order.It should manage
The data that solution uses in this way are interchangeable under appropriate circumstances, so that the embodiments described herein can be in addition to illustrating herein
Or the sequence other than the content of description is implemented.In addition, term " includes " and " having " and their any deformation, it is intended that
Cover it is non-exclusive include, for example, containing the process, method, system, product or equipment of a series of steps or units need not limit
In step or unit those of is clearly listed, but may include be not clearly listed or for these process, methods, produce
The other step or units of product or equipment inherently.
It should be noted that the description for being related to " first ", " second " etc. in the present invention is used for description purposes only, and cannot
It is interpreted as its relative importance of indication or suggestion or implicitly indicates the quantity of indicated technical characteristic.Define as a result, " the
One ", the feature of " second " can explicitly or implicitly include at least one of the features.In addition, the skill between each embodiment
Art scheme can be combined with each other, but must be based on can be realized by those of ordinary skill in the art, when technical solution
Will be understood that the combination of this technical solution is not present in conjunction with there is conflicting or cannot achieve when, also not the present invention claims
Protection scope within.
The present invention provides a kind of network connectivity methods.
Referring to Fig.1, Fig. 1 is the flow diagram of one embodiment of the invention.According to different requirements, in the flow diagram
The sequence of step can change, and certain steps can be omitted.
The network connectivity methods are applied in one or more electronic equipment, and the electronic equipment is that one kind can be by
According to the instruction for being previously set or storing, the automatic equipment for carrying out numerical value calculating and/or information processing, the hardware of the electronic equipment
Including but not limited to microprocessor, specific integrated circuit (Application Specific Integrated Circuit,
ASIC), programmable gate array (Field-Programmable Gate Array, FPGA), digital processing unit (Digital
Signal Processor, DSP), embedded device etc..
The electronic equipment can be any electronic product that human-computer interaction can be carried out with user, for example, personal meter
Calculation machine, tablet computer, smart phone, personal digital assistant (Personal Digital Assistant, PDA), game machine, friendship
Mutual formula Web TV (Internet Protocol Television, IPTV), intellectual wearable device etc..
The electronic equipment can also include the network equipment and/or user equipment.Wherein, the network equipment includes, but
It is not limited to single network server, the server group of multiple network servers composition or based on cloud computing (Cloud
Computing the cloud being made of a large amount of hosts or network server).
Network locating for the electronic equipment include but is not limited to internet, wide area network, Metropolitan Area Network (MAN), local area network, it is virtual specially
With network (Virtual Private Network, VPN) etc..
In one embodiment, this method comprises:
S10 determines whether the destination node has outer net service energy when having detected that destination node will connect network
Power.
In at least one embodiment of the present invention, the electronic equipment determines whether the destination node has outer net clothes
Business ability includes:
The electronic equipment performs network address translation (Network Address to the destination node
Translation, NAT) detection, also, work as and be detected with outer net IP (Internet Protocol Address, internet protocol
Discuss address) when, the electronic equipment can determine that the destination node has outer net service ability.
Specifically, the electronic equipment can execute NAT detection to the destination node using the NAT server of profession.
By above embodiment, the electronic equipment can carry out preliminary screening to the destination node first.
In at least one embodiment of the present invention, when the destination node does not have outer net service ability, the side
Method further include:
The electronic equipment to the destination node carry out universal plug and play (Universal Plug and Play,
UPNP) port mapping, and when detecting that the electronic equipment determines that the destination node has outer net service when mapping successfully
Ability.
Specifically, by carrying out universal plug and play port mapping, the electronic equipment can be such that the destination node becomes
Be it is open, so that other servers is found the destination node, the destination node can have outer net service ability.
By above embodiment, the electronic equipment can become the destination node for not having outer net service ability
To have outer net service ability, and then it is able to carry out subsequent detection.
S11 connects Bootstrap node when the destination node has outer net service ability.
In at least one embodiment of the present invention, the Bootstrap node is a kind of starter node.
Specifically, the Bootstrap node is a kind of tree node, has and grabs other network nodes from network
Ability.
S12 is based on the Bootstrap node, at least one network node is obtained from the network.
In at least one embodiment of the present invention, after connecting the Bootstrap node, the electronic equipment
Network node is obtained from the network.
Specifically, due to the influence of system performance etc., the electronic equipment can not get whole from the network
Network node.
Therefore, the operating condition current according to system, and the not different performance of homologous ray, the electronic equipment are got
The quantity of network node also will be different.
Simultaneously, it should be noted that even if the electronic equipment has only got the subnetwork node in the network
(that is: at least one described network node), still, the subsequent electronic equipment can still use web crawlers technology, according to
All nodes of the subnetwork node traverses got into the network.
S13 searches probe node from least one described network node.
In at least one embodiment of the present invention, the electronic equipment searches spy from least one described network node
Surveying node includes:
The electronic equipment obtains the outer net mark of each network node at least one described network node, and according to institute
It states outer net mark and determines whether each network node can be used as the probe node.
Specifically, when outer net mark shows that the first network node at least one described network node has outer net
When service ability, the electronic equipment determines that the first network node can be used as the probe node.
Alternatively, when outer net mark shows that the second network node at least one described network node does not have outer net
When service ability, the electronic equipment determines that second network node cannot function as the probe node.
Such as: the electronic equipment detects 3 network nodes, respectively network node A, network node B and network section
The parameter value of the outer net mark of point C, the network node A is 1, and the parameter value of the outer net mark of the network node B is 0, and
And the parameter value of the outer net mark of the network node C is also 0, then it is outer to determine that the network node A has for the electronic equipment
Net service ability, and the network node B and the network node C do not have outer net service ability, the electronic equipment is by institute
It states network node A and is determined as the probe node.
By above embodiment, the electronic equipment only needs the attribute according to the network node itself, can be fast
Speed determines the probe node.
S14 reversely detects the destination node by the probe node.
In at least one embodiment of the present invention, the electronic equipment is by the probe node, to the target section
Point carries out reversed detection
The electronic equipment sends signaling packet to the probe node, and the signaling packet is for notifying the probe node to send out
Data packet is sent to detect whether the configuration port receives every prefixed time interval to the configuration port of the destination node
The data packet, and when detecting that the configuration port receives the data packet, the electronic equipment stops detection.
Wherein, the signaling packet can be a User Datagram Protocol (User Datagram Protocol, UDP) number
According to packet, the present invention is not limited.
Further, the data packet can be arbitrary data packet, and the data packet is served only for determining whether effectively to be connect
It receives.
Further, the prefixed time interval can be custom-configured, such as: 3 minutes, the present invention was unlimited
System.
By above embodiment, the electronic equipment can be realized the reversed detection to the destination node, and lead to
It crosses and is periodically detected whether the configuration port receives the data packet, detection result is timely responded to realizing.
In at least one embodiment of the present invention, the method also includes:
When detecting that the configuration port is not received by the data packet, the electronic equipment is to the probe node
Retransmit the signaling packet.
By above embodiment, the electronic equipment constantly can reversely be detected the destination node, and
When detecting failure, reversed detection is re-initiated, to guarantee that the destination node when meeting access conditions, accesses net in time
Network.
In at least one embodiment of the present invention, the configuration port include, but are not limited to it is following any one:
(1) when the destination node has outer net service ability, the configuration port includes appointing for the destination node
Meaning port.
It is understood that illustrating any of the destination node when the destination node has outer net service ability
Port is all that can connect outer net, and receive data, and therefore, the electronic equipment can configure configuration port to described
The arbitrary port of destination node.
(2) when the destination node does not have outer net service ability, the configuration port include successfully carry out it is general i.e.
The port of plug-and-play port mapping.
It is understood that when the destination node does not have outer net service ability, then only being inserted by general
Outer net can be connected with the port of port mapping, and other ports are the data that can not receive outer net transmission, therefore, institute
It states electronic equipment to be configured to the configuration port successfully to carry out the port of universal plug and play port mapping, so as not to influence pair
The reception of the data packet, to guarantee the validity reversely detected.
The destination node is connected to the network when detecting reversed detect successfully by S15.
It at least one embodiment of the present invention, will be described when the electronic equipment, which detects, reversely to be detected successfully
Destination node is connected to the network.
Further, after the destination node is connected to the network, the electronic equipment can be realized with it is described
The data interaction of network.
In conclusion the present invention can determine that the destination node is when having detected that destination node will connect network
It is no to have outer net service ability, the node of standby outer net service ability is provided with preliminary screening, when the destination node has outer net
When service ability, Bootstrap node is connected, and be based on the Bootstrap node, obtain at least one from the network
Network node further searches probe node from least one described network node, has had due to the probe node
Connectivity, therefore can be improved detection success rate, and by the probe node, reversely detected to the destination node,
When detecting reversed detect successfully, the destination node is connected to the network, and then filter out the good section of connectivity
Point improves the connected ratio of nodes, and then optimize the service ability of network to reduce the ratio of invalid node.
Referring to fig. 2, in the present embodiment, the electronic equipment 1 be it is a kind of can according to the instruction for being previously set or storing,
The automatic equipment for carrying out numerical value calculating and/or information processing, hardware includes but is not limited to microprocessor, specific integrated circuit
(Application Specific Integrated Circuit, ASIC), programmable gate array (Field-
Programmable Gate Array, FPGA), it is digital processing unit (Digital Signal Processor, DSP), embedded
Equipment etc..
The electronic equipment 1, which can also be but not limited to any one, to pass through keyboard, mouse, remote controler, touching with user
The modes such as template or voice-operated device carry out the electronic product of human-computer interaction, for example, personal computer (Personal Computer,
PC), tablet computer, smart phone, personal digital assistant (Personal Digital Assistant, PDA), game machine, friendship
Mutual formula Web TV (Internet Protocol Television, IPTV), intellectual wearable device, palm PC, just
The calculating such as computer, intelligent router, mine machine, network storage equipment terminal device, desktop PC, cloud server are taken to set
It is standby etc..
Network locating for the electronic equipment 1 include but is not limited to internet, wide area network, Metropolitan Area Network (MAN), local area network, it is virtual specially
With network (Virtual Private Network, VPN) etc..
The electronic equipment 1 can be the node of component content distribution network or block chain network.
The electronic equipment 1 may include memory 12, processor 13 and bus, can also include being stored in the storage
In device 12 and the computer program that can be run on the processor 13, such as network-in-dialing program.
It will be understood by those skilled in the art that the schematic diagram is only the example of electronic equipment 1, not structure paired electrons
The restriction of equipment 1 may include perhaps combining certain components or different components, example than illustrating more or fewer components
Such as described electronic equipment 1 can also include input-output equipment, network access equipment.
Wherein, memory 12 include at least a type of readable storage medium storing program for executing, the readable storage medium storing program for executing include flash memory,
Mobile hard disk, multimedia card, card-type memory (for example, SD or DX memory etc.), magnetic storage, disk, CD etc..Storage
Device 12 can be the internal storage unit of electronic equipment 1, such as the mobile hard disk of the electronic equipment 1 in some embodiments.It deposits
What reservoir 12 was also possible to be equipped on the External memory equipment of electronic equipment 1, such as electronic equipment 1 in further embodiments inserts
Formula mobile hard disk, intelligent memory card (Smart Media Card, SMC) are connect, secure digital (Secure Digital, SD) blocks,
Flash card (Flash Card) etc..Further, memory 12 can also both include the internal storage unit of electronic equipment 1 or wrap
Include External memory equipment.Memory 12 can be not only used for the application software and Various types of data that storage is installed on electronic equipment 1, example
Such as code of network-in-dialing program can be also used for temporarily storing the data that has exported or will export.
Processor 13 can be in some embodiments a central processing unit (Central Processing Unit,
CPU), controller, microcontroller, microprocessor or other data processing chips, the program for being stored in run memory 12
Code or processing data, such as execute network-in-dialing program etc..
The processor 13 executes the operating system of the electronic equipment 1 and the types of applications program of installation.The place
Reason device 13 executes the application program to realize the step in above-mentioned each network connectivity methods embodiment, such as shown in FIG. 1
Step S10, S11, S12, S13, S14, S15.
Alternatively, the processor 13 realizes each module in above-mentioned each Installation practice/mono- when executing the computer program
The function of member, such as: when having detected that destination node will connect network, determine whether the destination node has outer net service
Ability;When the destination node has outer net service ability, Bootstrap node is connected;It is saved based on the Bootstrap
Point obtains at least one network node from the network;Probe node is searched from least one described network node;Pass through
The probe node reversely detects the destination node;When detecting reversed detect successfully, by the destination node
It is connected to the network.
The bus can be Peripheral Component Interconnect standard (peripheral component interconnect, abbreviation
PCI) bus or expanding the industrial standard structure (extended industry standard architecture, abbreviation EISA)
Bus etc..The bus can be divided into address bus, data/address bus, control bus etc..For convenient for indicating, only with an arrow in Fig. 2
Head indicates, it is not intended that an only bus or a type of bus.
Illustratively, the computer program can be divided into one or more module/units, one or more
A module/unit is stored in the memory 12, and is executed by the processor 13, to complete the present invention.It is one
Or multiple module/units can be the series of computation machine program instruction section that can complete specific function, the instruction segment is for retouching
State implementation procedure of the computer program in the electronic equipment 1.For example, the computer program can be divided into really
Order member 110, connection unit 111, acquiring unit 112, searching unit 113, probe unit 114, map unit 116 and transmission are single
Member 117.
Further, electronic equipment can also include network interface, network interface optionally may include wireline interface and/
Or wireless interface (such as WI-FI interface, blue tooth interface), commonly used in being built between the electronic equipment 1 and other electronic equipments
Vertical communication connection.
Optionally, the electronic equipment 1 can also include user interface, user interface may include display (Display),
Input unit such as keyboard (Keyboard), optional user interface can also include standard wireline interface and wireless interface.It can
Selection of land, in some embodiments, display can be light-emitting diode display, liquid crystal display, touch-control liquid crystal display and OLED
(Organic Light-Emitting Diode, Organic Light Emitting Diode) touches device etc..Wherein, display can also be appropriate
Referred to as display screen or display unit, for showing the information handled in the electronic device 1 and for showing visual user
Interface.
If the integrated module/unit of the electronic equipment 1 is realized in the form of SFU software functional unit and as independent
Product when selling or using, can store in a computer readable storage medium.Based on this understanding, the present invention is real
All or part of the process in existing above-described embodiment method, can also instruct relevant hardware come complete by computer program
At the computer program can be stored in a computer readable storage medium, which is being executed by processor
When, it can be achieved that the step of above-mentioned each embodiment of the method.
Wherein, the computer program includes computer program code, and the computer program code can be source code
Form, object identification code form, executable file or certain intermediate forms etc..The computer-readable medium may include: can
Carry any entity or device, recording medium, USB flash disk, mobile hard disk, magnetic disk, CD, computer of the computer program code
Memory, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access
Memory), electric carrier signal, telecommunication signal and software distribution medium etc..It should be noted that the computer-readable medium
The content for including can carry out increase and decrease appropriate according to the requirement made laws in jurisdiction with patent practice, such as in certain departments
Method administrative area does not include electric carrier signal and telecommunication signal according to legislation and patent practice, computer-readable medium.
Fig. 2 is illustrated only with component 12-13 and the electronic equipment of network-in-dialing program 1, and those skilled in the art can
With understanding, Fig. 2 shows structure do not constitute the restriction to the electronic equipment 1, may include than illustrate it is less or
More components perhaps combine certain components or different component layouts.
In conjunction with Fig. 1, the memory 12 in the electronic equipment 1 stores multiple instruction to realize a kind of network-in-dialing side
The multiple instruction can be performed to realize in method, the processor 13: when having detected that destination node will connect network, determining
Whether the destination node has outer net service ability;When the destination node has outer net service ability, connection
Bootstrap node;Based on the Bootstrap node, at least one network node is obtained from the network;From it is described to
Probe node is searched in a few network node;By the probe node, the destination node is reversely detected;Work as inspection
It measures reversely when detecting successfully, the destination node is connected to the network.
Preferred embodiment according to the present invention, the processor 13 also execute multiple instruction and include:
Detection is performed network address translation to the destination node;
When being detected with outer net IP, determine that the destination node has outer net service ability.
Preferred embodiment according to the present invention, the processor 13 also execute multiple instruction and include:
When the destination node does not have outer net service ability, universal plug and play port is carried out to the destination node
Mapping;
When detect map successfully when, determine that the destination node has outer net service ability.
Preferred embodiment according to the present invention, the processor 13 also execute multiple instruction and include:
Signaling packet is sent to the probe node, the signaling packet is for notifying the probe node to send data packet to institute
State the configuration port of destination node;
Every prefixed time interval, detect whether the configuration port receives the data packet;
When detecting that the configuration port receives the data packet, stop detection.
Preferred embodiment according to the present invention, the processor 13 also execute multiple instruction and include:
When detecting that the configuration port is not received by the data packet, described in the retransmission of Xiang Suoshu probe node
Signaling packet.
Preferred embodiment according to the present invention, the configuration port include any of the following:
When the destination node has outer net service ability, the configuration port includes the arbitrary end of the destination node
Mouthful;Or
When the destination node does not have outer net service ability, the configuration port includes successfully carrying out general insert i.e.
With the port of port mapping.
It is the functional block diagram of inventive network connected system referring to Fig. 3.The network-in-dialing system 11 includes true
Order member 110, connection unit 111, acquiring unit 112, searching unit 113, probe unit 114, map unit 116 and transmission are single
Member 117.So-called module/the unit of the present invention refers to that one kind can be performed by processor 13, and can complete fixed function
Series of computation machine program segment, storage in memory 12.It in the present embodiment, will about the function of each module/unit
It is described in detail in subsequent embodiment.
When having detected that destination node will connect network, it is outer that determination unit 110 determines whether the destination node has
Net service ability.
In at least one embodiment of the present invention, it is outer to determine whether the destination node has for the determination unit 110
Net service ability includes:
The determination unit 110 performs network address translation (Network Address to the destination node
Translation, NAT) detection, also, work as and be detected with outer net IP (Internet Protocol Address, internet protocol
Discuss address) when, the determination unit 110 can determine that the destination node has outer net service ability.
Specifically, the determination unit 110 can execute NAT to the destination node using the NAT server of profession and visit
It surveys.
By above embodiment, the determination unit 110 can carry out preliminary screening to the destination node first.
In at least one embodiment of the present invention, when the destination node does not have outer net service ability, the side
Method further include:
Map unit 116 to the destination node carry out universal plug and play (Universal Plug and Play,
UPNP) port mapping, and when detecting that the determination unit 110 determines that the destination node has outer net when mapping successfully
Service ability.
Specifically, by carrying out universal plug and play port mapping, the map unit 116 can make the destination node
Become open, other servers is enable to find the destination node, the destination node can have outer net service energy
Power.
By above embodiment, the target section that the map unit 116 can not will have outer net service ability
Point becomes having outer net service ability, and then is able to carry out subsequent detection.
When the destination node has outer net service ability, connection unit 111 connects Bootstrap node.
In at least one embodiment of the present invention, the Bootstrap node is a kind of starter node.
Specifically, the Bootstrap node is a kind of tree node, has and grabs other network nodes from network
Ability.
Acquiring unit 112 is based on the Bootstrap node, at least one network node is obtained from the network.
In at least one embodiment of the present invention, after connecting the Bootstrap node, the acquiring unit 112
Network node can be obtained from the network.
Specifically, due to the influence of system performance etc., the acquiring unit 112 can not get whole from the network
Network node.
Therefore, the operating condition current according to system, and the not different performance of homologous ray, the acquiring unit 112 obtain
The quantity for the network node got also will be different.
Simultaneously, it should be noted that even if the acquiring unit 112 has only got the subnetwork section in the network
Point (that is: at least one described network node), still, the subsequent acquiring unit 112 can still use web crawlers technology,
According to all nodes of the subnetwork node traverses got into the network.
Searching unit 113 searches probe node from least one described network node.
In at least one embodiment of the present invention, the searching unit 113 is looked into from least one described network node
The probe node is looked for include:
The searching unit 113 obtains the outer net mark of each network node at least one described network node, and root
Determine whether each network node can be used as the probe node according to outer net mark.
Specifically, when outer net mark shows that the first network node at least one described network node has outer net
When service ability, the searching unit 113 determines that the first network node can be used as the probe node.
Alternatively, when outer net mark shows that the second network node at least one described network node does not have outer net
When service ability, the searching unit 113 determines that second network node cannot function as the probe node.
Such as: the searching unit 113 detects 3 network nodes, respectively network node A, network node B and network
The parameter value of the outer net mark of node C, the network node A is 1, and the parameter value of the outer net mark of the network node B is 0,
And the parameter value of the outer net mark of the network node C is also 0, then the searching unit 113 determines the network node A tool
Standby outer net service ability, and the network node B and the network node C do not have outer net service ability, the searching unit
The network node A is determined as the probe node by 113.
By above embodiment, the searching unit 113 attributes needed according to the network node itself
Quickly determine the probe node.
Probe unit 114 reversely detects the destination node by the probe node.
In at least one embodiment of the present invention, the probe unit 114 is by the probe node, to the target
Node carries out reversed detection
The probe unit 114 sends signaling packet to the probe node, and the signaling packet is for notifying the detection to save
Point sends data packet and detects whether the configuration port connects every prefixed time interval to the configuration port of the destination node
The data packet is received, and when detecting that the configuration port receives the data packet, the probe unit 114 stops
Detection.
Wherein, the signaling packet can be a User Datagram Protocol (User Datagram Protocol, UDP) number
According to packet, the present invention is not limited.
Further, the data packet can be arbitrary data packet, and the data packet is served only for determining whether effectively to be connect
It receives.
Further, the prefixed time interval can be custom-configured, such as: 3 minutes, the present invention was unlimited
System.
By above embodiment, the probe unit 114 can be realized the reversed detection to the destination node, and
By being periodically detected whether the configuration port receives the data packet, detection result is timely responded to realizing.
In at least one embodiment of the present invention, the method also includes:
When detecting that the configuration port is not received by the data packet, transmission unit 117 is to the probe node
Retransmit the signaling packet.
By above embodiment, the probe unit 114 constantly can reversely be detected the destination node, and
And when detecting failure, reversed detection is re-initiated, to guarantee that the destination node when meeting access conditions, accesses net in time
Network.
In at least one embodiment of the present invention, the configuration port include, but are not limited to it is following any one:
(1) when the destination node has outer net service ability, the configuration port includes appointing for the destination node
Meaning port.
It is understood that illustrating any of the destination node when the destination node has outer net service ability
Port is all that can connect outer net, and receive data, and therefore, the determination unit 110 can configure configuration port to
The arbitrary port of the destination node.
(2) when the destination node does not have outer net service ability, the configuration port include successfully carry out it is general i.e.
The port of plug-and-play port mapping.
It is understood that when the destination node does not have outer net service ability, then only being inserted by general
Outer net can be connected with the port of port mapping, and other ports are the data that can not receive outer net transmission, therefore, institute
It states determination unit 110 to be configured to the configuration port successfully to carry out the port of universal plug and play port mapping, so as not to shadow
The reception to the data packet is rung, to guarantee the validity reversely detected.
When detecting reversed detect successfully, the destination node is connected to the network by the connection unit 111.
In at least one embodiment of the present invention, when detecting that the connection unit 111 is by institute when reversely detecting successfully
It states destination node and is connected to the network.
Further, after the destination node is connected to the network, it can be realized and handed over the data of the network
Mutually.
In conclusion the present invention can determine that the destination node is when having detected that destination node will connect network
It is no to have outer net service ability, the node of standby outer net service ability is provided with preliminary screening, when the destination node has outer net
When service ability, Bootstrap node is connected, and be based on the Bootstrap node, obtain at least one from the network
Network node further searches probe node from least one described network node, has had due to the probe node
Connectivity, therefore can be improved detection success rate, and by the probe node, reversely detected to the destination node,
When detecting reversed detect successfully, the destination node is connected to the network, and then filter out the good section of connectivity
Point improves the connected ratio of nodes, and then optimize the service ability of network to reduce the ratio of invalid node.
In the above-described embodiments, can come wholly or partly by software, hardware, firmware or any combination thereof real
It is existing.When implemented in software, it can entirely or partly realize in the form of a computer program product.
The computer program product includes one or more computer instructions.Load and execute on computers the meter
When calculation machine program instruction, entirely or partly generate according to process or function described in the embodiment of the present invention.The computer can
To be general purpose computer, special purpose computer, computer network or other programmable devices.The computer instruction can be deposited
Storage in a computer-readable storage medium, or from a computer readable storage medium to another computer readable storage medium
Transmission, for example, the computer instruction can pass through wired (example from a web-site, computer, server or data center
Such as coaxial cable, optical fiber, Digital Subscriber Line (DSL)) or wireless (such as infrared, wireless, microwave) mode to another website
Website, computer, server or data center are transmitted.The computer readable storage medium can be computer and can deposit
Any usable medium of storage either includes that the data storages such as one or more usable mediums integrated server, data center are set
It is standby.The usable medium can be magnetic medium, (for example, floppy disk, mobile hard disk, tape), optical medium (for example, DVD) or
Semiconductor medium (such as solid-state mobile hard disk Solid State Disk (SSD)) etc..
It is apparent to those skilled in the art that for convenience and simplicity of description, the system of foregoing description,
The specific work process of device and unit, can refer to corresponding processes in the foregoing method embodiment, and details are not described herein.
In several embodiments provided herein, it should be understood that disclosed system, device and method can be with
It realizes by another way.For example, the apparatus embodiments described above are merely exemplary, for example, the unit
It divides, only a kind of logical function partition, there may be another division manner in actual implementation, such as multiple units or components
It can be combined or can be integrated into another system, or some features can be ignored or not executed.Another point, it is shown or
The mutual coupling, direct-coupling or communication connection discussed can be through some interfaces, the indirect coupling of device or unit
It closes or communicates to connect, can be electrical property, mechanical or other forms.
The unit as illustrated by the separation member may or may not be physically separated, aobvious as unit
The component shown may or may not be physical unit, it can and it is in one place, or may be distributed over multiple
In network unit.It can select some or all of unit therein according to the actual needs to realize the mesh of this embodiment scheme
's.
It, can also be in addition, each functional unit in each embodiment of the application can integrate in one processing unit
It is that each unit physically exists alone, can also be integrated in one unit with two or more units.Above-mentioned integrated list
Member both can take the form of hardware realization, can also realize in the form of software functional units.
If the integrated unit is realized in the form of SFU software functional unit and sells or use as independent product
When, it can store in a computer readable storage medium.Based on this understanding, the technical solution of the application is substantially
The all or part of the part that contributes to existing technology or the technical solution can be in the form of software products in other words
It embodies, which is stored in a storage medium, including some instructions are used so that a computer
Equipment (can be personal computer, server or the network equipment etc.) executes the complete of each embodiment the method for the application
Portion or part steps.And storage medium above-mentioned includes: USB flash disk, mobile mobile hard disk, read-only memory (ROM, Read-Only
Memory), random access memory (RAM, Random Access Memory), magnetic or disk etc. are various can store journey
The medium of sequence code.
It should be noted that the serial number of the above embodiments of the invention is only for description, do not represent the advantages or disadvantages of the embodiments.And
The terms "include", "comprise" herein or any other variant thereof is intended to cover non-exclusive inclusion, so that packet
Process, device, article or the method for including a series of elements not only include those elements, but also including being not explicitly listed
Other element, or further include for this process, device, article or the intrinsic element of method.Do not limiting more
In the case where, the element that is limited by sentence "including a ...", it is not excluded that including process, device, the article of the element
Or there is also other identical elements in method.
The above is only a preferred embodiment of the present invention, is not intended to limit the scope of the invention, all to utilize this hair
Equivalent structure or equivalent flow shift made by bright specification and accompanying drawing content is applied directly or indirectly in other relevant skills
Art field, is included within the scope of the present invention.
Claims (10)
1. a kind of network connectivity methods, which is characterized in that the described method includes:
When having detected that destination node will connect network, determine whether the destination node has outer net service ability;
When the destination node has outer net service ability, Bootstrap node is connected;
Based on the Bootstrap node, at least one network node is obtained from the network;
Probe node is searched from least one described network node;
By the probe node, the destination node is reversely detected;
When detecting reversed detect successfully, the destination node is connected to the network.
2. network connectivity methods as described in claim 1, which is characterized in that whether the determination destination node has outer
Net service ability includes:
Detection is performed network address translation to the destination node;
When being detected with outer net IP, determine that the destination node has outer net service ability.
3. network connectivity methods as described in claim 1, which is characterized in that the method also includes:
When the destination node does not have outer net service ability, universal plug and play port is carried out to the destination node and is reflected
It penetrates;
When detect map successfully when, determine that the destination node has outer net service ability.
4. network connectivity methods as described in claim 1, which is characterized in that it is described by the probe node, to the mesh
Mark node carries out reversed detection
Signaling packet is sent to the probe node, the signaling packet is for notifying the probe node to send data packet to the mesh
Mark the configuration port of node;
Every prefixed time interval, detect whether the configuration port receives the data packet;
When detecting that the configuration port receives the data packet, stop detection.
5. network connectivity methods as claimed in claim 4, which is characterized in that the method also includes:
When detecting that the configuration port is not received by the data packet, Xiang Suoshu probe node retransmits the signaling
Packet.
6. network connectivity methods as described in claim 3 or 4, which is characterized in that the configuration port includes following any one
Kind:
When the destination node has outer net service ability, the configuration port includes the arbitrary port of the destination node;
Or
When the destination node does not have outer net service ability, the configuration port includes successfully carrying out universal plug and play end
The port of mouth mapping.
7. a kind of electronic equipment, which is characterized in that the electronic equipment includes:
Memory stores at least one instruction;And
Processor executes the instruction stored in the memory to realize the network as described in any one of claim 1 to 6
Connection method.
8. electronic equipment according to claim 7, which is characterized in that the electronic equipment be component content distribution network or
The node of person's block chain network.
9. a kind of network-in-dialing system, which is characterized in that the system comprises:
Determination unit, for determining whether the destination node has outer net when having detected that destination node will connect network
Service ability;
Connection unit, for connecting Bootstrap node when the destination node has outer net service ability;
Acquiring unit obtains at least one network node for being based on the Bootstrap node from the network;
Searching unit, for searching probe node from least one described network node;
Probe unit, for reversely being detected to the destination node by the probe node;
The connection unit is also used to that the destination node is connected to the network when detecting reversed detect successfully.
10. a kind of computer readable storage medium, which is characterized in that be stored with network company on the computer readable storage medium
Logical program, the network-in-dialing program can be executed by one or more processor, to realize as any in claim 1 to 6
Network connectivity methods described in.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910493108.1A CN110213132B (en) | 2019-06-06 | 2019-06-06 | Network connection method, electronic device, system and medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910493108.1A CN110213132B (en) | 2019-06-06 | 2019-06-06 | Network connection method, electronic device, system and medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN110213132A true CN110213132A (en) | 2019-09-06 |
CN110213132B CN110213132B (en) | 2021-02-26 |
Family
ID=67791343
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910493108.1A Active CN110213132B (en) | 2019-06-06 | 2019-06-06 | Network connection method, electronic device, system and medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN110213132B (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110601890A (en) * | 2019-09-17 | 2019-12-20 | 深圳市网心科技有限公司 | Network performance analysis method, device, equipment and readable storage medium |
Citations (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1866880A (en) * | 2005-08-05 | 2006-11-22 | 华为技术有限公司 | Fault detecting method in next generation network |
US7948890B2 (en) * | 2004-12-14 | 2011-05-24 | Industrial Technology Research Institute | System and method for providing a communication channel |
CN103441891A (en) * | 2013-08-19 | 2013-12-11 | 广东电网公司电力调度控制中心 | Network topology safety testing method and device of power data network |
US8813074B2 (en) * | 2011-08-05 | 2014-08-19 | Vmware, Inc. | Detecting and correcting network interruptions using network address translation |
CN105049300A (en) * | 2015-08-28 | 2015-11-11 | 北京奇艺世纪科技有限公司 | Method and device for detecting NAT network type |
CN105376254A (en) * | 2015-12-08 | 2016-03-02 | 尹绍华 | Method for detecting whether UPNP (Universal Plug and Play) successfully passes through NAT (Network Address Translators) |
CN105827748A (en) * | 2016-05-12 | 2016-08-03 | 东莞市南星电子有限公司 | Method for traversing Symmetric NAT (Network Address Translator) device by SIP (Session Initiation Protocol) based on ICE (Interactive Connectivity Establishment) |
CN106055976A (en) * | 2016-05-16 | 2016-10-26 | 杭州华三通信技术有限公司 | Document detection method and sandbox controller |
EP3373550A1 (en) * | 2017-03-08 | 2018-09-12 | Verisign, Inc. | Gtld domain name registries rdap architecture |
CN108881295A (en) * | 2018-07-24 | 2018-11-23 | 瑞典爱立信有限公司 | For detecting and solving the method and the network equipment of anomalous routes |
CN109067905A (en) * | 2018-09-05 | 2018-12-21 | 黄秋琼 | A kind of implementation method of the network application of decentralization |
-
2019
- 2019-06-06 CN CN201910493108.1A patent/CN110213132B/en active Active
Patent Citations (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US7948890B2 (en) * | 2004-12-14 | 2011-05-24 | Industrial Technology Research Institute | System and method for providing a communication channel |
CN1866880A (en) * | 2005-08-05 | 2006-11-22 | 华为技术有限公司 | Fault detecting method in next generation network |
US8813074B2 (en) * | 2011-08-05 | 2014-08-19 | Vmware, Inc. | Detecting and correcting network interruptions using network address translation |
CN103441891A (en) * | 2013-08-19 | 2013-12-11 | 广东电网公司电力调度控制中心 | Network topology safety testing method and device of power data network |
CN105049300A (en) * | 2015-08-28 | 2015-11-11 | 北京奇艺世纪科技有限公司 | Method and device for detecting NAT network type |
CN105376254A (en) * | 2015-12-08 | 2016-03-02 | 尹绍华 | Method for detecting whether UPNP (Universal Plug and Play) successfully passes through NAT (Network Address Translators) |
CN105827748A (en) * | 2016-05-12 | 2016-08-03 | 东莞市南星电子有限公司 | Method for traversing Symmetric NAT (Network Address Translator) device by SIP (Session Initiation Protocol) based on ICE (Interactive Connectivity Establishment) |
CN106055976A (en) * | 2016-05-16 | 2016-10-26 | 杭州华三通信技术有限公司 | Document detection method and sandbox controller |
EP3373550A1 (en) * | 2017-03-08 | 2018-09-12 | Verisign, Inc. | Gtld domain name registries rdap architecture |
CN108881295A (en) * | 2018-07-24 | 2018-11-23 | 瑞典爱立信有限公司 | For detecting and solving the method and the network equipment of anomalous routes |
CN109067905A (en) * | 2018-09-05 | 2018-12-21 | 黄秋琼 | A kind of implementation method of the network application of decentralization |
Non-Patent Citations (2)
Title |
---|
BIAO WANG,ET AL.,: ""A Network Boundary Gap Technique Scheme Based on Dual Unilateral Path"", 《 2011 INTERNATIONAL CONFERENCE ON NETWORK COMPUTING AND INFORMATION SECURITY》 * |
张楠,: ""SIP穿越NAT的研究与实现"", 《中国优秀硕士学位论文全文数据库-信息科技辑》 * |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110601890A (en) * | 2019-09-17 | 2019-12-20 | 深圳市网心科技有限公司 | Network performance analysis method, device, equipment and readable storage medium |
Also Published As
Publication number | Publication date |
---|---|
CN110213132B (en) | 2021-02-26 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US10581801B2 (en) | Context-aware distributed firewall | |
US11128600B2 (en) | Global object definition and management for distributed firewalls | |
US11665205B2 (en) | Location services on a data exchange layer | |
CN109600449A (en) | A kind of P2P penetrating method, device, system and storage medium | |
US8750311B2 (en) | Fibre channel host virtualization | |
CN109922156A (en) | A kind of data communications method and its relevant device | |
CN111901177B (en) | Bare metal server network configuration method, system and related equipment | |
US20110022688A1 (en) | Obtaining and displaying network topology information | |
US9009782B2 (en) | Steering traffic among multiple network services using a centralized dispatcher | |
CN109951562A (en) | NAT penetrating method and system, electronic equipment and storage medium | |
CA2895304A1 (en) | System and method for managing data integrity in electronic data storage | |
CN110191204A (en) | A kind of Intranet communication between devices method, system, device and computer storage medium | |
CN109981415A (en) | Condition judgement method, electronic equipment, system and medium | |
CN109788051A (en) | Network resource transmission method and system based on distributed file system | |
CN111405052A (en) | P2P penetration method based on port prediction, electronic device and medium | |
CN110417789A (en) | Server connection method, electronic equipment, system and medium | |
CN110213132A (en) | Network connectivity methods, electronic equipment, system and medium | |
CN109462527A (en) | Network congestion analysis method, device and storage medium | |
CN110855784A (en) | Proxy server node selection method, electronic device, system and medium | |
CN109905397A (en) | A kind of method and intranet server for establishing data connection | |
CN110347648A (en) | File dispositions method and device, computer installation and storage medium | |
CN108089968A (en) | A kind of method of host's machine monitoring virtual-machine data storehouse state | |
CN109614180A (en) | Webpage deployment method, electronic equipment, system and storage medium | |
CN116016448A (en) | Service network access method, device, equipment and storage medium | |
US10003527B1 (en) | Devices and methods to assist with network cabling |
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 |