CN110875857B - Method, device and system for reporting disconnected network state - Google Patents

Method, device and system for reporting disconnected network state Download PDF

Info

Publication number
CN110875857B
CN110875857B CN201811014357.XA CN201811014357A CN110875857B CN 110875857 B CN110875857 B CN 110875857B CN 201811014357 A CN201811014357 A CN 201811014357A CN 110875857 B CN110875857 B CN 110875857B
Authority
CN
China
Prior art keywords
terminal
message
communication
identifier
preset
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201811014357.XA
Other languages
Chinese (zh)
Other versions
CN110875857A (en
Inventor
纪永亮
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
ZTE Corp
Original Assignee
ZTE Corp
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 ZTE Corp filed Critical ZTE Corp
Priority to CN201811014357.XA priority Critical patent/CN110875857B/en
Priority to PCT/CN2019/103873 priority patent/WO2020043209A1/en
Publication of CN110875857A publication Critical patent/CN110875857A/en
Application granted granted Critical
Publication of CN110875857B publication Critical patent/CN110875857B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/54Presence management, e.g. monitoring or registration for receipt of user log-on information, or the connection status of the users
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/10Active monitoring, e.g. heartbeat, ping or trace-route
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Health & Medical Sciences (AREA)
  • Cardiology (AREA)
  • General Health & Medical Sciences (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The invention provides a method, a device and a system for reporting a disconnected network state, wherein the method comprises the following steps: and when the first terminal is determined to be in the disconnected state, starting a preset communication mode, wherein the communication identifier of the preset communication mode meets a preset rule, and the preset rule is used for enabling a second terminal currently in the networking state to sense that the first terminal is currently in the disconnected state, so that the disconnected state of the first terminal is reported to the server through the second terminal. According to the invention, the problem that the management and control capability of the terminal is lost due to the fact that the service center usually only can give up management and control of the lost terminal for the lost terminal in the related technology is solved, and the technical effects that the server can accurately judge the lost reason and the current state of the terminal, so that the fault of the service center or the frequently connected service is eliminated, and further management and control operation is carried out on the disconnected network equipment are achieved.

Description

Method, device and system for reporting disconnected network state
Technical Field
The invention relates to the field of communication, in particular to a method, a device and a system for reporting a network disconnection state.
Background
In the process of developing a mobile terminal management control system (MDM) function, a special scene exists, and important attention and solution are urgently needed. Namely, the mobile terminal is under the control of the loss of connection state.
Most of mobile terminal applications in the related art need to interact with respective cloud service centers. The service center determines whether the mobile terminal is in an offline state, usually according to a heartbeat (Heart Beat) mechanism. The heartbeat mechanism is that a long connection is established between a service center and a mobile terminal through a computer network on a Transmission Control Protocol (TCP) layer, and a message (namely a data packet) is sent to the other party at preset time intervals to indicate the current state of the terminal. The service center can judge whether the terminal is lost through receiving the stable heartbeat message sent by the mobile terminal.
It follows that the service center is primarily maintaining a heartbeat (Heart Beat) connection with the mobile terminal over the network. If the network residence state of the service center is normal, but the heartbeat connection is disconnected, it indicates that the mobile terminal is in the offline state at this time, and then the service center will also lose the control capability of the terminal, which is also a general processing scheme for the offline terminal by the similar product in the field.
However, the above scheme for determining the terminal loss of connection by sending the service data through heartbeat or at regular time has an obvious defect: the service center cannot accurately locate the reason of the loss of contact of the mobile terminal. The loss of the terminal may be due to the fact that the terminal itself is abnormally in a disconnected state, but the loss of the terminal due to the abnormal function of the service center, the software failure, the abnormal heartbeat service and the like cannot be eliminated. Therefore, the service center can only generally adopt a scheme of giving up controlling the lost terminal for the lost terminal.
Disclosure of Invention
At least some embodiments of the present invention provide a method, an apparatus, and a system for reporting a network disconnection state, so as to at least solve a problem in the related art that a service center generally only can give up management and control of an offline terminal for the offline terminal, thereby losing the management and control capability of the offline terminal.
According to an embodiment of the present invention, a method for reporting a network outage state is provided, including:
and when the first terminal is determined to be in the disconnected state, starting a preset communication mode, wherein the communication identifier of the preset communication mode meets a preset rule, and the preset rule is used for enabling a second terminal currently in the networking state to sense that the first terminal is currently in the disconnected state, so that the disconnected state of the first terminal is reported to the server through the second terminal.
According to another embodiment of the present invention, another method for reporting a network outage state is provided, including:
monitoring whether a first terminal starts a preset communication mode or not; when the first terminal starts a preset communication mode, determining that a communication identifier of the preset communication mode meets a preset rule, wherein the preset rule is used for sensing that the first terminal is in a disconnected state currently and the second terminal is in a networking state currently by the second terminal; and reporting the network disconnection state of the first terminal to a server.
According to another embodiment of the present invention, another method for reporting a network outage state is provided, including:
receiving a first message reported by a second terminal establishing communication with a first terminal, wherein the second terminal is currently in a networking state; analyzing the first message to obtain a first message type identifier and identifier information of the first terminal; and determining that the first terminal is in the disconnected state according to the first message type identifier and the identifier information of the first terminal.
According to another embodiment of the present invention, an apparatus for reporting a network outage status is provided, including:
the starting module is used for starting a preset communication mode when the first terminal is determined to be in the network disconnection state, wherein the communication identification of the preset communication mode meets a preset rule, and the preset rule is used for enabling a second terminal in the networking state to sense that the first terminal is in the network disconnection state currently, so that the network disconnection state of the first terminal is reported to the server through the second terminal.
According to another embodiment of the present invention, another apparatus for reporting a network outage status is provided, including:
the monitoring module is used for monitoring whether the first terminal starts a preset communication mode or not; the determining module is used for determining that the communication identifier of the preset communication mode meets a preset rule when the first terminal is monitored to start the preset communication mode, wherein the preset rule is used for sensing that the first terminal is in a network disconnection state and the second terminal is currently in a network connection state by the second terminal; and the first reporting module is used for reporting the network disconnection state of the first terminal to the server.
According to another embodiment of the present invention, another apparatus for reporting a network outage status is provided, including:
the first receiving module is used for receiving a first message reported by a second terminal which establishes communication with the first terminal, wherein the second terminal is currently in a networking state; analyzing the first message to obtain a first message type identifier and identifier information of the first terminal; and the determining module is used for determining that the first terminal is in the disconnected state according to the first message type identifier and the identifier information of the first terminal.
According to a further embodiment of the present invention, there is also provided a storage medium having a computer program stored therein, wherein the computer program is arranged to perform the steps of any of the above method embodiments when executed.
According to yet another embodiment of the present invention, there is also provided an electronic device, including a memory in which a computer program is stored and a processor configured to execute the computer program to perform the steps in any of the above method embodiments.
Through at least some embodiments of the present invention, when the terminal is in the disconnected state, the current state of the disconnected terminal can be actively reported to the service center through a non-direct connection path, so that the service center can adopt more technical measures to implement management and control on the disconnected terminal, instead of only adopting a policy of giving up management and control, thereby solving the problem that the service center in the related art can only generally adopt to give up management and control on the disconnected terminal, which results in losing the management and control capability of the terminal, and achieving the technical effects that the server can accurately judge the reason and the current state of the disconnected terminal, thereby eliminating the fault of the service center or the frequently connected service, and further managing and controlling the disconnected device.
Drawings
The accompanying drawings, which are included to provide a further understanding of the invention and are incorporated in and constitute a part of this application, illustrate embodiment(s) of the invention and together with the description serve to explain the invention without limiting the invention. In the drawings:
fig. 1 is a schematic diagram of an operating environment of a reporting method of a network outage state according to an embodiment of the present invention;
fig. 2 is a flowchart of a method for reporting a network outage state according to an embodiment of the present invention;
fig. 3 is a flowchart of another method for reporting a network outage status according to an embodiment of the present invention;
fig. 4 is a flowchart of a reporting method of a network outage status according to another embodiment of the present invention;
fig. 5 is a flowchart illustrating that a terminal reports a disconnected network and disconnected network state by starting a Wi-Fi hotspot function in a disconnected network environment according to an optional embodiment of the present invention;
fig. 6 is a flowchart illustrating a network disconnection terminal connecting to a surrounding network terminal and reporting a network disconnection/disconnection status thereof in a network disconnection environment according to an alternative embodiment of the present invention;
FIG. 7 is a flowchart of a service center maintaining a terminal password and interacting with the terminal to update the password according to an alternative embodiment of the present invention;
fig. 8 is a block diagram of a reporting apparatus of a network outage state according to an embodiment of the present invention;
fig. 9 is a block diagram of a device for reporting a network outage state according to an alternative embodiment of the present invention;
fig. 10 is a block diagram of another apparatus for reporting a network outage state according to an embodiment of the present invention;
fig. 11 is a block diagram of another apparatus for reporting a network outage status according to an alternative embodiment of the present invention;
fig. 12 is a block diagram of a device for reporting a network outage state according to another embodiment of the present invention;
fig. 13 is a block diagram of a device for reporting a network outage status according to an alternative embodiment of the present invention.
Detailed Description
The invention will be described in detail hereinafter with reference to the accompanying drawings in conjunction with embodiments. It should be noted that, in the present application, the embodiments and features of the embodiments may be combined with each other without conflict.
It should be noted that the terms "first," "second," and the like in the description and claims of the present invention and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order.
Example 1
The method embodiments provided by the application can be run on a server and/or a terminal. Fig. 1 is a schematic diagram of an operating environment of a method for reporting a disconnected network status according to an embodiment of the present invention, and as shown in fig. 1, the method for reporting a disconnected network status according to the present invention may be executed on a first terminal 1 (i.e., a disconnected network terminal), a second terminal 2 (i.e., a networked terminal), or a server 3 (hereinafter, also referred to as a service center) shown in fig. 1. In an embodiment, the reporting of the disconnected network status of the first terminal 1 is implemented by using the interaction among the first terminal 1, the second terminal 2 and the server 3 as shown in fig. 1. In one embodiment, each of the first terminal 1, the second terminal 2 and the server 3 may include: one or more processors (which may include, but are not limited to, a processing device such as a Microprocessor (MCU) or a programmable logic device (FPGA)) and memory for storing data. In an embodiment, each of the devices may further include a transmission device for a communication function and an input-output device. It will be understood by those of ordinary skill in the art that the drawings shown in fig. 1 are for illustration purposes only and are not intended to limit the implementation of the present invention.
The memory may be configured to store a computer program, for example, a software program and a module of an application software, such as a computer program corresponding to the reporting method of the network disconnection state in the embodiment of the present invention, and the processor executes various functional applications and data processing by running the computer program stored in the memory, that is, implements the reporting method of the network disconnection state. The memory may include high speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory may further include memory located remotely from the processor, and these remote memories may be connected to the various devices described above via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The transmission device is used for receiving or transmitting data via a network. Specific examples of the network described above may include a wireless network provided by a communication provider of a terminal or a server. In one example, the transmission device includes a Network adapter (NIC), which can be connected to other Network devices through a base station so as to communicate with the internet. In one example, the transmission device may be a Radio Frequency (RF) module, which is used for communicating with the internet in a wireless manner.
In order to realize that the terminal actively reports the loss of connection state in the network disconnection environment, a service center system arranged at the cloud end of a computer network and an application installed on the mobile terminal are required to be deployed.
When the method embodiment provided by the application runs on a server, the main functions of the service center system include the following aspects:
(1) And receiving the data with the specific format reported by the terminal application through a computer network, and analyzing the data to judge whether the data is the network disconnection and loss information reported by the mobile terminal.
(2) Feature information for each terminal is stored, which may include, but is not limited to: unique identification of the terminal and a communication key. The unique Identifier may be one or more combinations of International Mobile Equipment Identity (IMEI), mobile Equipment Identity (MEID), international Mobile Subscriber Identity (IMSI), and the like, which may uniquely identify the terminal Identity. The communication key can be a password used for a local area network or near field communication function, such as a terminal Wi-Fi hotspot, bluetooth and Near Field Communication (NFC).
(3) And formulating naming rules of Wi-Fi hotspots, bluetooth and NFC of each terminal.
(4) Issuing commands to terminals in the network, which may include but is not limited to: the terminal is started in a network disconnection state, and comprises a Wi-Fi hotspot name (or near field communication identification such as Bluetooth and NFC), a Wi-Fi hotspot password (or near field communication function passwords such as Bluetooth and NFC), a network disconnection message format reported by the terminal and the like.
When the method embodiment provided by the present application is executed on a terminal, the main functions of the terminal application may include the following aspects:
(1) And monitoring the computer network state of the terminal, wherein the computer network refers to the computer network where the service center is located, and only the terminal and the service center which are in the same network environment are determined to be in a connection state. When the terminal finds that the network is disconnected, it actively starts its own network or near field communication function, which may include but is not limited to: wi-Fi hot spot, bluetooth, NFC, these functions that open possess certain characteristic identification, for example: the name of the Wi-Fi hotspot meets a preset rule. Hereinafter, the specific implementation process of the present invention will be described in detail mainly by taking the default communication mode as a Wi-Fi hotspot as an example.
(2) All the networking terminals monitor whether other terminals with network or near field communication functions of Wi-Fi hotspots, bluetooth, NFC and the like exist around and whether the names meet the offline naming rules set by the service center. And if so, requesting the service center to connect the password of the loss of contact terminal so as to actively initiate the connection.
(3) And receiving connection requests initiated by other terminals in the network disconnection state, and sending the network disconnection and loss message to other terminals which request to establish success according to a preset format.
(4) And sending the received data sent by the disconnected network terminal to a service center through a computer network.
The network-breaking reporting method is suitable for an interactive scene of connecting the terminal and the cloud service center, and the terminal needs to be constantly connected with the cloud service center due to business requirements. When the constant connection is disconnected, the service center can receive the network disconnection information reported by the terminal to accurately judge the loss of connection reason and the current state of the terminal, so that the fault of the service center or the constant connection service is eliminated, and the network disconnection equipment is further managed and controlled.
Specific application scenarios may include, but are not limited to, one of the following: (1) The mobile communication terminal carries Own equipment office (BYOD) application, namely mobile office, and the scene comprises a mobile phone, a tablet and other terminals with communication modules used in office; (2) Various intelligent hardware in the intelligent home are interconnected and communicated through home Wi-Fi, so that the monitoring and positioning of home network states and the networking states of all intelligent terminals are facilitated, and the management and troubleshooting of the intelligent terminals are enhanced; (3) networking the vehicles; (4) industrial internetworks, such as: water, electricity and gas monitoring terminal with wireless communication module.
In this embodiment, a method for reporting a network disconnection state of the network disconnection terminal is provided, and fig. 2 is a flowchart of a method for reporting a network disconnection state according to an embodiment of the present invention, as shown in fig. 2, the method includes the following steps:
step S202, when the first terminal is determined to be in the network disconnection state, a preset communication mode is started, wherein a communication identifier of the preset communication mode meets a preset rule, and the preset rule is used for enabling a second terminal currently in the networking state to sense that the first terminal is currently in the network disconnection state, so that the network disconnection state of the first terminal is reported to a server through the second terminal.
Through the steps, under the condition that the terminal is in the offline state, the current state of the offline terminal can be actively reported to the service center through a non-direct connection way, so that the service center can adopt more technical measures to realize the management and control of the offline terminal instead of only adopting a strategy of giving up the management and control, the problem that the management and control capability of the offline terminal is lost due to the fact that the service center can only give up the management and control of the offline terminal to the offline terminal in the related technology can be solved, the server can accurately judge the offline reason and the current state of the terminal, accordingly faults of the service center or the frequently connected service can be eliminated, and further management and control operation can be carried out on the offline device.
In an embodiment, the execution subject of the method steps involved in the method embodiment may be a network disconnection terminal, and the like, but is not limited thereto.
In one embodiment, the sequence numbers of the method steps involved in the method embodiment do not represent the execution order.
In one embodiment, the preset rules include: the first part is designated by the server, and the second part is identification information of the first terminal, so that the second terminal reports the network disconnection state of the first terminal to the server through the identification information.
In an optional embodiment, the network disconnection terminal monitors and confirms network disconnection, and starts a preset Wi-Fi hotspot. The Wi-Fi hotspot is automatically started by software after the terminal is disconnected, and the name of the Wi-Fi hotspot meets the requirements of preset rules: [ PREFIX ] [ SUFFIX ], where [ PREFIX ] (corresponding to the first part above) is specified by the service center, for example: a fixed string, [ SUFFIX ] (corresponding to the second part above) is a unique identification for each terminal, for example: IMEI, MEID, IMSI or a terminal unique identity generated by the service center.
In one embodiment, the preset rule further comprises one of: a third part, wherein the third part is a password with a preset communication function; the third part and the fourth part, wherein the fourth part is the updating period of the password of the preset communication function.
In addition, in the preset rule, a Wi-Fi hotspot password (equivalent to the third part) can be selectively set, the password is randomly generated when the Wi-Fi hotspot is started, and the password is selectively dynamically updated according to a certain time interval (equivalent to the fourth part), so that any other device is prevented from accessing.
The random password generation policy includes, but is not limited to, one of the following:
(1) Generating based on a time stamp, wherein the time stamp can be the opening time of the Wi-Fi hotspot or the related time of other attributes of the current equipment;
(2) Based on current device attributes, it may include, but is not limited to: some hardware attributes (e.g., mac address);
(3) Various combinations of information, such as: timestamp + device attributes;
(4) Encoding or encrypting on the basis of various information listed in (1) to (3) above.
In one embodiment, the preset rules include: a first portion, wherein the first portion is specified by the server.
In another optional embodiment, the network disconnection terminal monitors and confirms network disconnection, and starts a preset Wi-Fi hotspot, the Wi-Fi hotspot is automatically started by software after the network disconnection of the terminal, and the Wi-Fi hotspot name meets the requirement of a preset rule, and the rule is specified by the service center, for example: a fixed string (corresponding to the first part).
In an embodiment, after the step S202, the method further includes the following steps:
step S204, monitoring a connection request of a second terminal through a preset communication function;
step S206, in response to the connection request, sending a first message to the second terminal, so that the second terminal reports the first message to the server, where the first message is used to indicate that the first terminal is currently in a disconnected state, and the first message includes: identification information of the first terminal.
And the terminal in a normal networking state monitors the Wi-Fi hotspots in the periphery, if the hotspot name is found to meet the rule set by the service center, the hotspot name is sent to the service center in a specific format message, the service center is requested to return the Wi-Fi hotspot password, wherein the message comprises the Wi-Fi hotspot name and the identifier of the Wi-Fi hotspot password request message. And the service center maintains the corresponding relation between the Wi-Fi hotspot names of all the terminals and the Wi-Fi hotspot passwords. And the service center analyzes all the messages reported by the terminal, and if the analyzed message type is a Wi-Fi hotspot password request message, the service center searches for a corresponding password according to the Wi-Fi hotspot name in the message and returns the password. And the networking terminal uses the password returned by the service center to connect the Wi-Fi hotspot of the disconnected terminal. The method comprises the steps that a disconnected network terminal monitors a Wi-Fi hotspot connection event, and sends a disconnected network report message (equivalent to the first message) to a networking terminal after the connection is successful, wherein the message comprises the following steps: and (4) unique identification of the disconnected network terminal.
In an embodiment, the first message further comprises at least one of: the network outage time of the first terminal and the geographic position of the first terminal.
In an optional embodiment, the network disconnection reporting message sent by the network disconnection terminal to the networking terminal after the connection is successful may further include additional information, for example: additional offline time, additional geographic location, and additional offline time and geographic location at the same time.
In an embodiment, after the step S202, the method further includes the following steps:
step S208, receiving a second message from the second terminal, wherein the second message is used for indicating that the server knows that the first terminal is currently in the disconnected state;
step S210, in response to the second message, performing one of the following operations:
(1) Closing a preset communication mode;
(2) Keeping the communication connection with the second terminal and hiding the preset communication mode;
(3) Keeping opening a preset communication mode;
(4) And keeping opening the preset communication mode and limiting the number of terminals accessed through the preset communication mode.
In an optional embodiment, after the service center confirms the disconnected network terminal, the message of confirming the disconnection of the disconnected network is replied to the networked terminal. And the networking terminal forwards the message for confirming the disconnection and the loss of the network replied by the service center to the disconnection terminal. The disconnected network terminal can implement one of the following behaviors according to actual conditions:
(1) The network-breaking terminal finishes the network-breaking and loss-of-connection reporting operation, and actively closes the Wi-Fi hotspot in order to reduce power consumption or avoid discovery of other equipment;
(2) The disconnected network terminal finishes the operation of reporting the disconnected network and the lost connection, but keeps the current connection with the networked terminal in order to keep the subsequent communication with the service center, and hides the Wi-Fi hot spot in order to avoid the increase of power consumption caused by the connection of other equipment;
(3) In order to avoid the network disconnection of the network disconnection terminal and the service center again caused by the network disconnection of the network connection terminal, the network disconnection terminal always keeps the opening state of the Wi-Fi hotspot and allows other devices to be connected, and the upper limit of the number of the connected terminals can be selectively set to avoid power consumption caused by excessive terminal connection.
In this embodiment, another method for reporting a network disconnection state running in a networked terminal is further provided, and fig. 3 is a flowchart of another method for reporting a network disconnection state according to an embodiment of the present invention, as shown in fig. 3, the flowchart includes the following steps:
step S302, monitoring whether a first terminal starts a preset communication mode;
step S304, when it is monitored that the first terminal starts the preset communication mode, determining that the communication identifier of the preset communication mode meets a preset rule, wherein the preset rule is used for sensing that the first terminal is currently in a network disconnection state and the second terminal is currently in a network connection state by the second terminal;
and step S306, reporting the network disconnection state of the first terminal to a server.
In an embodiment, the execution subject of the method steps involved in the method embodiment may be a networked terminal or the like, but is not limited thereto.
In one embodiment, the sequence numbers of the method steps involved in the method embodiment do not represent the execution order.
In one embodiment, in step S304, determining that the communication identifier satisfies the preset rule may include the following steps:
step S3041, determining that the communication identifier includes a first part and a second part of a preset rule, where the first part is specified by the server and the second part is identifier information of the first terminal.
In an optional embodiment, the network disconnection terminal monitors and confirms network disconnection, and starts a preset Wi-Fi hotspot. The Wi-Fi hotspot is automatically started by software after the terminal is disconnected, and the name of the Wi-Fi hotspot meets the requirement of a preset rule: [ PREFIX ] [ SUFFIX ], where [ PREFIX ] (corresponding to the first part above) is specified by the service center, for example: a fixed string, [ SUFFIX ] (corresponding to the second part above) is a unique identification for each terminal, for example: IMEI, MEID, IMSI or a terminal unique identity generated by the service center. All terminals with normal networking state monitor surrounding Wi-Fi hotspots, and if the hotspot names include [ PREFIX ] and [ SUFFIX ], the hotspot names are determined to meet the [ PREFIX ] [ SUFFIX ] rule.
In an embodiment, the reporting the disconnected state of the first terminal to the server in step S306 may include the following processing steps:
step S3061, analyzing the identification information of the first terminal from the communication identification;
step S3062, encapsulate the identification information of the first terminal and the reporting identification of the network-cut-off message into a first message;
step S3063, report the first message to the server.
If the networking terminal finds that the hotspot name meets the [ PREFIX ] [ SUFFIX ] rule, resolving the [ SUFFIX ] from the hotspot name and reporting the message to the service center in a specific format (equivalent to the first message), wherein the message comprises the [ SUFFIX ] and a network breaking reporting message identifier.
In one embodiment, in step S304, determining that the communication identifier satisfies the preset rule may include the following steps:
step S3042, determining that the communication identifier includes a first part of the preset rule, where the first part is specified by the server.
The network disconnection terminal monitors and confirms network disconnection, a preset Wi-Fi hotspot is started, the Wi-Fi hotspot is automatically started by software after the network disconnection of the terminal, the name of the Wi-Fi hotspot meets the requirement of a preset rule, and the rule is specified by a service center, for example: a fixed string (corresponding to the first part). And if the networking terminal finds the fixed character string from the Wi-Fi hotspot name, determining that the Wi-Fi hotspot name meets the requirement of a preset rule.
In an embodiment, before reporting the network disconnection status of the first terminal to the server in step S306, the method may further include the following steps:
step S308, packaging the communication identifier and the communication password message identifier into a second message;
step S310, reporting the second message to a server;
step S312, receiving a communication password corresponding to a preset communication mode from the server;
step S314, sending a connection request to the first terminal by adopting a communication password;
step S316, after the connection is successfully established, receiving a third message from the first terminal, where the third message is used to indicate that the first terminal is currently in a disconnected state, and the third message includes: identification information of the first terminal.
And if the networking terminal finds that the hotspot name meets the rule set by the service center, the networking terminal sends the hotspot name to the service center in a specific format message (equivalent to the second message) and requests the service center to return the Wi-Fi hotspot password, wherein the message comprises the Wi-Fi hotspot name and a message identifier for requesting the Wi-Fi hotspot password. And the service center maintains the corresponding relation between the Wi-Fi hotspot names of all the terminals and the Wi-Fi hotspot passwords. And the service center analyzes all the messages reported by the terminal, and if the analyzed message type is a request Wi-Fi hotspot password message, the service center searches for a corresponding password according to the Wi-Fi hotspot name in the message and returns the password. And the networking terminal uses the password returned by the service center to connect the Wi-Fi hotspot of the disconnected terminal. The disconnected network terminal monitors a Wi-Fi hotspot connection event, and sends a disconnected network report message (equivalent to the third message) to the networking terminal after the connection is successful, wherein the message comprises: the unique identifier of the disconnected network terminal can be added with other additional information, such as: additional offline time, additional geographic location, and additional offline time and geographic location at the same time.
In an embodiment, in step S306, reporting the network disconnection status of the first terminal to the server may include the following steps:
step S3064, forward the third message to the server.
The networking terminal forwards the network disconnection report message sent by the network disconnection terminal to the service center, and the networking terminal can add other additional information in the message sent by the network disconnection terminal before forwarding.
In an embodiment, after the step S306 reports the network disconnection status of the first terminal to the server, the method may further include the following steps:
step S318, receiving a fourth message from the server, wherein the fourth message is used for indicating that the server knows that the first terminal is currently in the disconnected state;
step S320, forwarding the fourth message to the first terminal.
The service center analyzes all the messages reported by the terminal, if the analyzed message type is the network breaking reporting message, the unique identifier of the network breaking equipment is extracted from the message body and the equipment is further processed. Then, the service center replies a message (corresponding to the fourth message) confirming the disconnection of the network to the networking terminal. And the networking terminal forwards the message of confirming the disconnection and the loss of the network replied by the service center to the disconnection terminal.
Fig. 4 is a flowchart of a reporting method for a network outage state according to an embodiment of the present invention, where as shown in fig. 4, the process includes the following steps:
step S402, receiving a first message reported by a second terminal establishing communication with a first terminal, wherein the second terminal is currently in a networking state;
step S404, analyzing the first message to obtain a first message type identifier and identifier information of the first terminal;
step S406, determining that the first terminal is in a disconnected state according to the first message type identifier and the identifier information of the first terminal.
In an embodiment, the execution subject of the method steps involved in the method embodiment may be a server or the like, but is not limited thereto.
In one embodiment, the sequence numbers of the method steps involved in the method embodiments do not represent the order of execution.
In one embodiment, in step S406, determining that the first terminal is in the network disconnection state according to the first message type identifier and the identifier information of the first terminal may include the following steps:
step S4061, according to the first message type identification, determining the first message as the message reporting the disconnected state;
step S4062, determining that the first terminal is in the disconnected state according to the identification information of the first terminal.
The service center analyzes all the messages reported by the networking terminal, if the analyzed message type is the network breaking reporting message (equivalent to the first message), the service center extracts the unique identifier of the network breaking equipment from the message body and further processes the equipment.
In an embodiment, before receiving the first message reported by the second terminal in step S402, the method may further include the following steps:
step S408, receiving a second message reported by the second terminal, where the second message includes: the second message type identifier and a communication identifier of a preset communication mode adopted by the first terminal;
step S410, obtaining a communication password corresponding to the communication identifier according to the second message type identifier and the communication identifier;
step S412, returning the communication password to the second terminal, where the communication password is used to obtain the identification information of the first terminal.
And the terminal in the normal networking state monitors the surrounding Wi-Fi hotspots, and if the hotspot name is found to meet the rule set by the service center, the hotspot name is sent to the service center in a specific format message (equivalent to the second message) to request the service center to return the Wi-Fi hotspot password, wherein the message comprises the Wi-Fi hotspot name and the Wi-Fi hotspot password message identifier. And the service center maintains the corresponding relation between the Wi-Fi hotspot names of all the terminals and the Wi-Fi hotspot passwords.
In one embodiment, in step S410, acquiring the communication password corresponding to the communication identifier according to the second message type identifier and the communication identifier may include the following steps:
step S4101, determining the second message as the message for acquiring the communication password according to the second message type identifier;
step S4102, searching a corresponding communication password from a preset corresponding relation according to the communication identifier.
The service center analyzes all messages reported by the networking terminal, and if the analyzed message type is a Wi-Fi hotspot password request message, the service center searches for a corresponding password according to the Wi-Fi hotspot name in the message and returns the password.
In an embodiment, before receiving the first message reported by the second terminal in step S402, the method may further include the following steps:
step S414, generating a first communication key and issuing the first communication key to the first terminal;
step S416, receiving an update result reported by the first terminal, wherein the update result is obtained by the first terminal updating a local existing second communication key by using the first communication key;
step S418, if the update result indicates that the update is successful, updating the mapping relationship between the identification information of the first terminal and the second communication key to the mapping relationship between the identification information of the first terminal and the first communication key;
step S420, a third message is returned to the first terminal, wherein the third message is used for indicating that the mapping relation between the identification information of the first terminal and the first communication key is updated successfully;
step S422, if the confirmation reply from the first terminal is not received within the preset time range, the mapping relationship between the identification information of the first terminal and the first communication key is restored to the mapping relationship between the identification information of the first terminal and the second communication key.
The service center generates a new password and sends the new password to the terminal, and the mapping relation between the terminal and the original password is not updated at the moment. And the terminal updates the new password sent by the service center to the local, records the original password, reports the updating result to the service center, and starts a timer to wait for the service center to reply. And after receiving the successful password updating information reported by the terminal, the service center establishes a mapping relation between the new password and the terminal. After the mapping relationship is updated successfully, the service center sends a mapping relationship modification success confirmation (equivalent to the third message) to the terminal, and starts a timer to wait for the terminal to reply. And if the terminal does not receive the modification reply of the service center within the timeout time range, restoring the local password from the new password to the original password. And if the terminal receives the modification reply of the service center within the overtime time range, discarding the record of the original password and sending a reply confirming the receipt to the service center again. If the service center does not receive the terminal confirmation reply within the overtime time range, the mapping relation between the terminal and the new password is restored to the mapping relation between the terminal and the old password.
In an embodiment, in step S406, after determining that the first terminal is in the network disconnection state according to the first message type identifier and the identifier information of the first terminal, the method may further include the following steps:
step S424, a fourth message is returned to the second terminal, where the fourth message is used to indicate that the server has learned that the first terminal is currently in the disconnected state.
The service center replies a message (equivalent to the fourth message) for confirming the network disconnection and loss to the networking terminal. And the networking terminal forwards the message for confirming the disconnection and the loss of the network replied by the service center to the disconnection terminal.
The above implementation will be described in further detail below with reference to the exemplary embodiments shown in fig. 5 to 7.
Fig. 5 is a flowchart of reporting a disconnected network and offline state of a terminal in a disconnected network environment by starting a Wi-Fi hotspot function according to an optional embodiment of the present invention, where as shown in fig. 5, the process may include the following steps:
step S501, the disconnected network terminal monitors the self networking state, wherein the network refers to the same computer network where the service center is located.
And step S502, the network disconnection terminal monitors and confirms the network disconnection, and starts a preset Wi-Fi hotspot. The Wi-Fi hotspot is automatically started by software after the terminal is disconnected, and the name of the Wi-Fi hotspot meets the requirements of preset rules: [ PREFIX ] [ SUFFIX ], wherein [ PREFIX ] is specified by the service center, for example: a fixed string, [ SUFFIX ] is a unique identification for each terminal, such as: IMEI, MEID, IMSI or a terminal unique identity generated by the service center. And selectively setting a Wi-Fi hotspot password, randomly generating the password when the Wi-Fi hotspot is opened, and selectively and dynamically updating according to a certain time interval to prevent any other equipment from accessing.
The random password generation policy includes, but is not limited to, one of:
(1) Generating based on a time stamp, wherein the time stamp can be the opening time of the Wi-Fi hotspot or the related time of other attributes of the current equipment;
(2) Based on current device attributes, it may include, but is not limited to: some hardware attributes (e.g., mac address);
(3) Various combinations of information, such as: timestamp + device attributes;
(4) Encoding or encrypting on the basis of various information listed in (1) to (3) above.
Step S503, all terminals in a normal networking state monitor surrounding Wi-Fi hotspots, and if finding that the hotspot name satisfies the [ PREFIX ] [ SUFFIX ] rule, parse [ SUFFIX ] from the hotspot name and report the message in a specific format to the service center, where the message includes [ SUFFIX ] and a network disconnection report message identifier, for example: { "type": disconnect "," device ":" [ SUFFIX ] "};
step S504, the service center analyzes the information reported by the terminal, if the analyzed information type is the network breaking report information, the unique identifier of the network breaking equipment is extracted from the information body and the equipment is further processed.
Fig. 6 is a flowchart of a network disconnection terminal connecting to a surrounding network terminal under a network disconnection environment and reporting a network disconnection and disconnection status of the network disconnection terminal according to an alternative embodiment of the present invention, and as shown in fig. 6, the flowchart may include the following processing steps:
step S601, the disconnected network terminal monitors the self networking state, wherein the network refers to the same computer network where the service center is located.
Step S602, the network disconnection terminal monitors and confirms network disconnection, and starts a preset Wi-Fi hotspot, the Wi-Fi hotspot is automatically started by software after the network disconnection of the terminal, the Wi-Fi hotspot name meets the requirement of a preset rule, and the rule is specified by a service center, for example: a fixed string of characters.
Step S603, all terminals in a normal networking state monitor surrounding Wi-Fi hotspots, and if finding that the hotspot name satisfies a rule formulated by the service center, send the hotspot name to the service center in a message in a specific format, and request the service center to return the Wi-Fi hotspot password, where the message includes the Wi-Fi hotspot name and a message identifier requesting the Wi-Fi hotspot password, for example:
{"type":"password","wifi-hotspot":"***"}。
step S604, the service center maintains the corresponding relation between the Wi-Fi hotspot names and the Wi-Fi hotspot passwords of all the terminals. And the service center analyzes all the messages reported by the terminal, and if the analyzed message type is a Wi-Fi hotspot password request message, the service center searches for a corresponding password according to the Wi-Fi hotspot name in the message and returns the password.
And step S605, the networking terminal uses the password returned by the service center to connect the Wi-Fi hotspot of the disconnected terminal.
Step S606, the disconnected network terminal monitors Wi-Fi hotspot connection events and sends disconnected network report messages to the networking terminal after the connection is successful, wherein the messages comprise: the unique identifier of the disconnected terminal can be added with other additional information, such as: additional offline time, additional geographic location, and additional offline time and geographic location at the same time.
Step S607, the networking terminal forwards the network breaking report message sent by the network breaking terminal to the service center, and the networking terminal can add other additional information in the message sent by the network breaking terminal before forwarding.
Step S608, the service center analyzes all the messages reported by the terminal, if the analyzed message type is the network breaking report message, the unique identifier of the network breaking equipment is extracted from the message body and the equipment is further processed.
Step S609: and the service center replies the message of confirming the disconnection and the loss of the network to the networking terminal.
Step S610: and the networking terminal forwards the message of confirming the disconnection and the loss of the network replied by the service center to the disconnection terminal.
Step S611: the disconnected network terminal can implement one of the following behaviors according to actual conditions:
(1) The disconnected network terminal finishes the disconnected network loss reporting operation, and actively closes the Wi-Fi hot spot in order to reduce power consumption or avoid other equipment discovery;
(2) The disconnected network terminal finishes the operation of reporting the disconnected network and the lost connection, but keeps the current connection with the networked terminal in order to keep the subsequent communication with the service center, and hides the Wi-Fi hot spot in order to avoid the increase of power consumption caused by the connection of other equipment;
(3) In order to avoid that the disconnected network terminal is disconnected with the service center again due to the fact that the networking terminal is disconnected from the network, the disconnected network terminal always keeps the opening state of the Wi-Fi hot spot and allows other devices to be connected, and the upper limit of the number of the connected terminals can be selectively set to avoid power consumption caused by excessive terminal connection.
Fig. 7 is a flowchart of a service center maintaining a terminal password and performing password update interaction with a terminal according to an alternative embodiment of the present invention, as shown in fig. 7, the flowchart may include the following processing steps:
step S701, the service center updates the password of the terminal, which may include but is not limited to one of the following ways:
in the first method, the terminal requests the service center to update the password, which may be triggered at regular time or by specific events, for example: triggering after the terminal is disconnected from the network and reconnected successfully;
and in the second mode, the service center triggers the operation of updating the terminal password at regular time.
Step S702, the service center generates a new password and sends the new password to the terminal, and the mapping relation between the terminal and the original password is not updated at this time.
And step S703, the terminal updates the new password sent by the service center to the local, records the original password, reports the update result to the service center, and starts a timer to wait for the service center to reply.
Step S704, after receiving the successful password update information reported by the terminal, the service center establishes a mapping relationship between the new password and the terminal.
Step S705, after the service center successfully updates the mapping relationship, the service center sends a mapping relationship modification success confirmation to the terminal, and starts a timer to wait for the terminal to reply.
Step S706, if the terminal does not receive the modification reply of the service center within the timeout time range, the local password is restored from the new password to the original password.
Step S707, if the terminal receives the modification reply from the service center within the timeout period, the terminal discards the record of the original password and sends a reply confirming the reception to the service center again.
Step S708, if the service center does not receive the terminal confirmation reply within the timeout time range, the service center restores the mapping relationship between the terminal and the new password to the mapping relationship between the terminal and the old password.
Through the above description of the embodiments, those skilled in the art can clearly understand that the method according to the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but the former is a better implementation mode in many cases. Based on such understanding, the technical solutions of the present invention may be embodied in the form of a software product, which is stored in a storage medium (e.g., ROM/RAM, magnetic disk, optical disk) and includes instructions for enabling a terminal device (e.g., a mobile phone, a computer, a server, or a network device) to execute the method according to the embodiments of the present invention.
Example 2
In this embodiment, a device for reporting a network outage state is further provided, where the device is used to implement the foregoing embodiment and the preferred embodiments, and details of the description already made are omitted. As used below, the term "module" may be a combination of software and/or hardware that implements a predetermined function. Although the means described in the embodiments below are preferably implemented in software, an implementation in hardware, or a combination of software and hardware is also possible and contemplated.
Fig. 8 is a block diagram of a device for reporting a network outage state according to an embodiment of the present invention, and as shown in fig. 8, the device includes: the starting module 100 is configured to start a preset communication mode when it is determined that the first terminal is in the network disconnection state, where a communication identifier of the preset communication mode meets a preset rule, and the preset rule is used to enable a second terminal currently in a networking state to sense that the first terminal is currently in the network disconnection state, so as to report the network disconnection state of the first terminal to the server through the second terminal.
In one embodiment, the preset rules include: a first portion, wherein the first portion is specified by the server.
In one embodiment, the preset rule further comprises one of: a second part, wherein the second part is identification information of the first terminal; the third part is a password with a preset communication function; the second part, the third part and the fourth part, wherein the fourth part is the update cycle of the password of the preset communication function.
In an embodiment, fig. 9 is a block diagram of a structure of a device for reporting a network outage state according to an alternative embodiment of the present invention, and as shown in fig. 9, the device includes, in addition to all modules shown in fig. 8, further: the monitoring module 102 is configured to monitor a connection request of the second terminal through a preset communication function; a sending module 104, configured to send a second message to the second terminal in response to the connection request, so that the second terminal reports the second message to the server, where the second message is used to indicate that the first terminal is currently in a network disconnection state, and the second message includes: identification information of the first terminal.
In an embodiment, the second message further comprises at least one of: the network outage time of the first terminal and the geographical position of the first terminal.
In one embodiment, as shown in fig. 9, the apparatus further comprises: a receiving module 106, configured to receive a third message from the second terminal, where the third message is used to indicate that the server knows that the first terminal is currently in a network disconnection state; an execution module 108, configured to, in response to the third message, perform one of the following operations: closing a preset communication mode; keeping the communication connection with the second terminal and hiding the preset communication mode; keeping opening a preset communication mode; and keeping opening the preset communication mode and limiting the number of the terminals accessed through the preset communication mode.
In this embodiment, another apparatus for reporting a network outage state is further provided, where the apparatus is used to implement the foregoing embodiments and preferred embodiments, and details of the foregoing description are omitted. As used below, the term "module" may be a combination of software and/or hardware that implements a predetermined function. Although the means described in the embodiments below are preferably implemented in software, an implementation in hardware, or a combination of software and hardware is also possible and contemplated.
Fig. 10 is a block diagram of another structure of a device for reporting a network outage state according to an embodiment of the present invention, and as shown in fig. 10, the device includes: the monitoring module 200 is configured to monitor whether the first terminal starts a preset communication mode; the determining module 202 is configured to determine that a communication identifier of a preset communication mode meets a preset rule when it is monitored that the first terminal starts the preset communication mode, where the preset rule is used for the second terminal to sense that the first terminal is in a network disconnection state and the second terminal is currently in a network connection state; the first reporting module 204 is configured to report the network outage status of the first terminal to the server.
In an embodiment, the determining module 202 is configured to determine that the communication identifier includes a first part and a second part of a preset rule, where the first part is specified by the server, and the second part is identification information of the first terminal.
In one embodiment, the first reporting module 204 includes: an analyzing unit (not shown in the figure) for analyzing the identification information of the first terminal from the communication identification; an encapsulating unit (not shown in the figure), configured to encapsulate the identifier information of the first terminal and the network disconnection message reporting identifier into a first message; a reporting unit (not shown in the figure) configured to report the first message to the server.
In one embodiment, the determining module 202 is configured to determine that the communication identifier includes a first part of a preset rule, where the first part is specified by the server.
In an embodiment, fig. 11 is a block diagram of a structure of another apparatus for reporting a network outage state according to an alternative embodiment of the present invention, and as shown in fig. 11, the apparatus includes, in addition to all modules shown in fig. 10: an encapsulating module 206, configured to encapsulate the communication identifier and the communication password message identifier into a second message; a second reporting module 208, configured to report the second message to the server; a first receiving module 210, configured to receive a communication password corresponding to a preset communication manner from a server; a sending module 212, configured to send a connection request to the first terminal by using the communication password; a second receiving module 214, configured to receive a third message from the first terminal after the connection is successfully established, where the third message is used to indicate that the first terminal is currently in a disconnected state, and the third message includes: identification information of the first terminal.
In an embodiment, the first reporting module 204 is configured to forward the third message to the server.
In one embodiment, as shown in fig. 11, the apparatus further comprises: a third receiving module 216, configured to receive a fourth message from the server, where the fourth message is used to indicate that the server knows that the first terminal is currently in a disconnected state; a forwarding module 218, configured to forward the fourth message to the first terminal.
In this embodiment, a further device for reporting a network outage state is further provided, where the device is used to implement the foregoing embodiment and the preferred embodiments, and details of the foregoing description are omitted for brevity. As used below, the term "module" may be a combination of software and/or hardware that implements a predetermined function. Although the means described in the embodiments below are preferably implemented in software, an implementation in hardware or a combination of software and hardware is also possible and contemplated.
Fig. 12 is a block diagram of a structure of another apparatus for reporting a network outage status according to an embodiment of the present invention, as shown in fig. 12, the apparatus includes: a first receiving module 300, configured to receive a first message reported by a second terminal that establishes communication with a first terminal, where the second terminal is currently in a networking state; the parsing module 302 is configured to parse the first message to obtain a first message type identifier and identifier information of the first terminal; the determining module 304 is configured to determine that the first terminal is in a network disconnection state according to the first message type identifier and the identifier information of the first terminal.
In one embodiment, the determining module 304 includes: a first determining unit (not shown in the figure), configured to determine, according to the first message type identifier, that the first message is a message reporting a network disconnection status; and a second determining unit (not shown in the figure) configured to determine that the first terminal is in a network disconnection state according to the identification information of the first terminal.
In an embodiment, fig. 13 is a block diagram of a structure of a device for reporting a network outage state according to an alternative embodiment of the present invention, and as shown in fig. 13, the device includes, in addition to all modules shown in fig. 12, further: a second receiving module 306, configured to receive a second message reported by the second terminal, where the second message includes: the second message type identifier and a communication identifier of a preset communication mode adopted by the first terminal; an obtaining module 308, configured to obtain, according to the second message type identifier and the communication identifier, a communication password corresponding to the communication identifier; the first feedback module 310 is configured to return a communication password to the second terminal, where the communication password is used to obtain identification information of the first terminal.
In one embodiment, the obtaining module 308 includes: a third determining unit (not shown in the figure), configured to determine, according to the second message type identifier, that the second message is a message for acquiring a communication password; and an obtaining unit (not shown in the figure) for searching the corresponding communication password from the preset corresponding relationship according to the communication identifier.
In one embodiment, as shown in fig. 13, the apparatus further comprises: the issuing module 312 is configured to generate a first communication key and issue the first communication key to the first terminal; a third receiving module 314, configured to receive an update result reported by the first terminal, where the update result is obtained by the first terminal updating an existing local second communication key with the first communication key; an updating module 316, configured to update the mapping relationship between the identifier information of the first terminal and the second communication key to the mapping relationship between the identifier information of the first terminal and the first communication key if the updating result indicates that the updating is successful; a second feedback module 318, configured to return a third message to the first terminal, where the third message is used to indicate that the mapping relationship between the identifier information of the first terminal and the first communication key has been updated successfully; the restoring module 320 is configured to restore the mapping relationship between the identification information of the first terminal and the first communication key to the mapping relationship between the identification information of the first terminal and the second communication key if the confirmation reply from the first terminal is not received within the preset time range.
In one embodiment, as shown in fig. 13, the apparatus further comprises: the third feedback module 322 is configured to return a fourth message to the second terminal, where the fourth message is used to indicate that the server knows that the first terminal is currently in the offline state.
It should be noted that, the above modules may be implemented by software or hardware, and for the latter, the following may be implemented, but not limited to: the modules are all positioned in the same processor; alternatively, the modules are located in different processors in any combination.
Example 3
Embodiments of the present invention also provide a storage medium having a computer program stored therein, wherein the computer program is arranged to perform the steps of any of the above method embodiments when executed.
In one embodiment, in the present embodiment, the storage medium may be configured to store a computer program for executing the following steps:
s1, when the first terminal is determined to be in a disconnected network state, a preset communication mode is started, wherein a communication identifier of the preset communication mode meets a preset rule, and the preset rule is used for enabling a second terminal in a networking state to sense that the first terminal is in the disconnected network state currently, so that the disconnected network state of the first terminal is reported to a server through the second terminal.
In an embodiment, the storage medium is further arranged to store a computer program for performing the steps of:
s1, monitoring whether a first terminal starts a preset communication mode or not;
s2, when the first terminal is monitored to start the preset communication mode, determining that the communication identifier of the preset communication mode meets a preset rule, wherein the preset rule is used for sensing that the first terminal is in a disconnected state currently and the second terminal is in a connected state currently by the second terminal;
and S3, reporting the network disconnection state of the first terminal to a server.
In an embodiment, the storage medium is further arranged to store a computer program for performing the steps of:
the method comprises the steps that S1, a first message reported by a second terminal which establishes communication with a first terminal is received, wherein the second terminal is in a networking state currently;
s2, analyzing the first message to obtain a first message type identifier and identifier information of the first terminal;
and S3, determining that the first terminal is in a disconnected state according to the first message type identifier and the identifier information of the first terminal.
In an embodiment, in this embodiment, the storage medium may include, but is not limited to: various media capable of storing computer programs, such as a usb disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a removable hard disk, a magnetic disk, or an optical disk.
Example 4
Embodiments of the present invention also provide an electronic device comprising a memory having a computer program stored therein and a processor arranged to run the computer program to perform the steps of any of the above method embodiments.
In an embodiment, the electronic apparatus may further include a transmission device and an input/output device, wherein the transmission device is connected to the processor, and the input/output device is connected to the processor.
In an embodiment, in this embodiment, the processor may be configured to execute the following steps by a computer program:
the method comprises the steps of S1, when the first terminal is determined to be in the disconnected state, starting a preset communication mode, wherein a communication identifier of the preset communication mode meets a preset rule, and the preset rule is used for enabling a second terminal in the networking state to sense that the first terminal is in the disconnected state at present, so that the disconnected state of the first terminal is reported to a server through the second terminal.
In an embodiment, in this embodiment, the processor may be further configured to execute the following steps by a computer program:
s1, monitoring whether a first terminal starts a preset communication mode or not;
s2, when the first terminal is monitored to start the preset communication mode, determining that the communication identifier of the preset communication mode meets a preset rule, wherein the preset rule is used for sensing that the first terminal is in a disconnected state currently and the second terminal is in a connected state currently by the second terminal;
and S3, reporting the network disconnection state of the first terminal to a server.
In an embodiment, in this embodiment, the processor may be further configured to execute the following steps by a computer program:
the method comprises the steps that S1, a first message reported by a second terminal establishing communication with a first terminal is received, wherein the second terminal is in a networking state currently;
s2, analyzing the first message to obtain a first message type identifier and identifier information of the first terminal;
and S3, determining that the first terminal is in a disconnected state according to the first message type identifier and the identifier information of the first terminal.
In an embodiment, for a specific example in this embodiment, reference may be made to the examples described in the above embodiment and optional embodiments, and this embodiment is not described herein again.
It will be apparent to those skilled in the art that the modules or steps of the present invention described above may be implemented in a general purpose computing device, they may be centralized in a single computing device or distributed across a network of multiple computing devices, and in one embodiment, they may be implemented in program code executable by a computing device, such that they may be stored in a memory device and executed by a computing device, and in some cases, the steps shown or described may be executed in an order different from that described, or they may be separately fabricated as individual integrated circuit modules, or multiple modules or steps therein may be fabricated as a single integrated circuit module. Thus, the present invention is not limited to any specific combination of hardware and software.
The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, or improvement made within the principle of the present invention shall be included in the protection scope of the present invention.

Claims (27)

1. A method for reporting a network failure state is characterized by comprising the following steps:
and when the first terminal is determined to be in the network disconnection state, starting a preset communication mode, wherein the communication identifier of the preset communication mode meets a preset rule, and the preset rule is used for enabling a second terminal in the networking state to sense that the first terminal is in the network disconnection state currently, so that the network disconnection state of the first terminal is reported to a server through the second terminal.
2. The method of claim 1, wherein the preset rules comprise: a first portion, wherein the first portion is specified by the server.
3. The method of claim 2, wherein the preset rule further comprises one of:
a second part, wherein the second part is identification information of the first terminal;
the communication terminal comprises a second part and a third part, wherein the third part is a password with a preset communication function; or
The fourth part is the updating period of the password of the preset communication function.
4. The method of claim 2, further comprising, after the opening the predetermined communication mode:
monitoring a connection request of the second terminal through a preset communication function;
responding to the connection request, sending a first message to the second terminal, so that the second terminal reports the first message to a server, wherein the first message is used for indicating that the first terminal is currently in a disconnected state, and the first message includes: identification information of the first terminal.
5. The method of claim 4, wherein the first message further comprises at least one of: the network outage time of the first terminal and the geographic position of the first terminal.
6. The method of claim 4, further comprising, after the opening of the predetermined communication mode:
receiving a second message from the second terminal, wherein the second message is used for indicating that the server knows that the first terminal is currently in a disconnected state;
in response to the second message, performing one of:
closing the preset communication mode;
keeping the communication connection with the second terminal and hiding the preset communication mode;
keeping starting the preset communication mode;
and keeping opening the preset communication mode and limiting the number of the terminals accessed through the preset communication mode.
7. A method for reporting a network failure state is characterized by comprising the following steps:
monitoring whether a first terminal starts a preset communication mode or not;
when the first terminal is monitored to start the preset communication mode, determining that the communication identifier of the preset communication mode meets a preset rule, wherein the preset rule is used for a second terminal to sense that the first terminal is currently in a network disconnection state and the second terminal is currently in a network connection state;
and reporting the network disconnection state of the first terminal to a server.
8. The method of claim 7, wherein determining that the communication identifier satisfies the predetermined rule comprises:
and determining that the communication identifier comprises a first part and a second part of the preset rule, wherein the first part is designated by the server, and the second part is the identifier information of the first terminal.
9. The method of claim 8, wherein reporting the disconnected state of the first terminal to the server comprises:
analyzing the identification information of the first terminal from the communication identification;
packaging the identification information of the first terminal and the network-breaking message reporting identification into a first message;
and reporting the first message to the server.
10. The method of claim 7, wherein determining that the communication identifier satisfies the predetermined rule comprises:
determining that the communication identifier comprises a first part of the preset rule, wherein the first part is specified by the server.
11. The method of claim 10, wherein before reporting the network outage status of the first terminal to the server, further comprising:
encapsulating the communication identifier and the communication password message identifier into a second message;
reporting the second message to the server;
receiving a communication password corresponding to the preset communication mode from the server;
sending a connection request to the first terminal by adopting the communication password;
after the connection is successfully established, receiving a third message from the first terminal, where the third message is used to indicate that the first terminal is currently in a disconnected state, and the third message includes: identification information of the first terminal.
12. The method of claim 11, wherein reporting the disconnected state of the first terminal to the server comprises:
forwarding the third message to the server.
13. The method according to claim 7 or 11, wherein after reporting the network outage status of the first terminal to the server, the method further comprises:
receiving a fourth message from the server, wherein the fourth message is used for indicating that the server knows that the first terminal is currently in a disconnected state;
forwarding the fourth message to the first terminal.
14. A method for reporting a network failure state is characterized by comprising the following steps:
receiving a first message reported by a second terminal establishing communication with a first terminal, wherein the second terminal is currently in a networking state;
analyzing the first message to obtain a first message type identifier and identifier information of the first terminal;
determining that the first terminal is in a disconnected state according to the first message type identifier and the identifier information of the first terminal;
before receiving the first message reported by the second terminal, the method further includes:
receiving a second message reported by the second terminal, wherein the second message includes: a second message type identifier and a communication identifier of a preset communication mode adopted by the first terminal;
acquiring a communication password corresponding to the communication identifier according to the second message type identifier and the communication identifier;
and returning the communication password to the second terminal, wherein the communication password is used for acquiring the identification information of the first terminal.
15. The method of claim 14, wherein determining that the first terminal is in a disconnected state according to the first message type identifier and the identifier information of the first terminal comprises:
determining the first message as a message reporting a disconnected network state according to the first message type identifier;
and determining that the first terminal is in a disconnected state according to the identification information of the first terminal.
16. The method of claim 14, wherein obtaining the communication password corresponding to the communication identifier according to the second message type identifier and the communication identifier comprises:
determining the second message as a message for acquiring a communication password according to the second message type identifier;
and searching a corresponding communication password from a preset corresponding relation according to the communication identifier.
17. The method of claim 14, wherein before receiving the first message reported by the second terminal, further comprising:
generating a first communication key and issuing the first communication key to the first terminal;
receiving an updating result reported by the first terminal, wherein the updating result is obtained by updating a second communication key existing locally by the first terminal by using the first communication key;
if the updating result shows that the updating is successful, updating the mapping relation between the identification information of the first terminal and the second communication key into the mapping relation between the identification information of the first terminal and the first communication key;
returning a third message to the first terminal, wherein the third message is used for indicating that the mapping relation between the identification information of the first terminal and the first communication key is updated successfully;
and if the confirmation reply from the first terminal is not received within the preset time range, restoring the mapping relation between the identification information of the first terminal and the first communication key into the mapping relation between the identification information of the first terminal and the second communication key.
18. The method of claim 14, wherein after determining that the first terminal is in a network outage state according to the first message type identifier and the identifier information of the first terminal, further comprising:
and returning a fourth message to the second terminal, wherein the fourth message is used for indicating that the server knows that the first terminal is in the offline state currently.
19. A device for reporting a network disconnection state is characterized by comprising:
the starting module is used for starting a preset communication mode when the first terminal is determined to be in the network disconnection state, wherein the communication identifier of the preset communication mode meets a preset rule, and the preset rule is used for enabling a second terminal which is currently in the networking state to sense that the first terminal is currently in the network disconnection state, so that the network disconnection state of the first terminal is reported to a server through the second terminal.
20. A device for reporting a network disconnection state is characterized by comprising:
the monitoring module is used for monitoring whether the first terminal starts a preset communication mode or not;
the determining module is used for determining that the communication identifier of the preset communication mode meets a preset rule when the first terminal is monitored to start the preset communication mode, wherein the preset rule is used for a second terminal to sense that the first terminal is currently in a disconnected state and the second terminal is currently in a networking state;
and the first reporting module is used for reporting the network disconnection state of the first terminal to a server.
21. A device for reporting a network disconnection state is characterized by comprising:
a first receiving module, configured to receive a first message reported by a second terminal that establishes communication with a first terminal, where the second terminal is currently in a networking state,
the analysis module is used for analyzing the first message to obtain a first message type identifier and identifier information of the first terminal;
the determining module is used for determining that the first terminal is in a disconnected state according to the first message type identifier and the identifier information of the first terminal;
before receiving the first message reported by the second terminal, the reporting apparatus further includes:
receiving a second message reported by the second terminal, wherein the second message includes: a second message type identifier and a communication identifier of a preset communication mode adopted by the first terminal;
acquiring a communication password corresponding to the communication identifier according to the second message type identifier and the communication identifier;
and returning the communication password to the second terminal, wherein the communication password is used for acquiring the identification information of the first terminal.
22. A storage medium, in which a computer program is stored, wherein the computer program is arranged to perform the method of any of claims 1 to 6 when executed.
23. A storage medium, in which a computer program is stored, wherein the computer program is arranged to perform the method of any of claims 7 to 13 when executed.
24. A storage medium, in which a computer program is stored, wherein the computer program is arranged to perform the method of any of claims 14 to 18 when executed.
25. An electronic device comprising a memory and a processor, wherein the memory has a computer program stored therein, and the processor is configured to execute the computer program to perform the method of any of claims 1 to 6.
26. An electronic device comprising a memory and a processor, wherein the memory has a computer program stored therein, and the processor is configured to execute the computer program to perform the method of any one of claims 7 to 13.
27. An electronic device comprising a memory and a processor, wherein the memory has stored therein a computer program, and wherein the processor is arranged to execute the computer program to perform the method of any of claims 14 to 18.
CN201811014357.XA 2018-08-31 2018-08-31 Method, device and system for reporting disconnected network state Active CN110875857B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201811014357.XA CN110875857B (en) 2018-08-31 2018-08-31 Method, device and system for reporting disconnected network state
PCT/CN2019/103873 WO2020043209A1 (en) 2018-08-31 2019-08-30 Disconnected network state reporting method and apparatus, and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811014357.XA CN110875857B (en) 2018-08-31 2018-08-31 Method, device and system for reporting disconnected network state

Publications (2)

Publication Number Publication Date
CN110875857A CN110875857A (en) 2020-03-10
CN110875857B true CN110875857B (en) 2023-03-07

Family

ID=69643414

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811014357.XA Active CN110875857B (en) 2018-08-31 2018-08-31 Method, device and system for reporting disconnected network state

Country Status (2)

Country Link
CN (1) CN110875857B (en)
WO (1) WO2020043209A1 (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112601270A (en) * 2020-11-19 2021-04-02 广东沃科融合通讯有限公司 Terminal wake-up control method and device, electronic equipment and storage medium
CN112615733B (en) * 2020-12-08 2023-04-18 广东沃科融合通讯有限公司 Terminal fault judgment method and device, electronic equipment and storage medium
CN112788576B (en) * 2020-12-16 2022-12-02 青岛海尔科技有限公司 Equipment offline processing method and system, storage medium and electronic device
CN117041305B (en) * 2023-10-10 2024-01-23 成都秦川物联网科技股份有限公司 Offline data management method, device and medium for gas flowmeter based on Internet of things

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101431761A (en) * 2007-11-09 2009-05-13 中国移动通信集团公司 Network fault reporting method, equipment and system
WO2014153770A1 (en) * 2013-03-29 2014-10-02 Broadcom Corporation Method and apparatus for reestablishing communication with a network
CN106817671A (en) * 2017-02-14 2017-06-09 腾讯科技(深圳)有限公司 A kind of networked information sharing method, first terminal and system
JP2017224295A (en) * 2017-06-08 2017-12-21 株式会社リコー Client terminal, computer program, and information processing method
CN108174400A (en) * 2017-12-27 2018-06-15 瑞斯康达科技发展股份有限公司 Data processing method and system, the equipment of a kind of terminal device

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103152374B (en) * 2011-12-07 2016-08-10 华为终端有限公司 Know the method and apparatus of terminal presence
CN104836598B (en) * 2014-02-10 2017-11-28 深圳中兴网信科技有限公司 Method for processing business, apparatus and system based on near-field communication
CN105337642B (en) * 2014-06-17 2018-08-24 阿里巴巴集团控股有限公司 A kind of offline terminal accesses the method and system of network data
CN106793007B (en) * 2016-12-05 2020-07-31 爱国者电子科技有限公司 Interactive communication method and system of cloud and Bluetooth device and wireless router

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101431761A (en) * 2007-11-09 2009-05-13 中国移动通信集团公司 Network fault reporting method, equipment and system
WO2014153770A1 (en) * 2013-03-29 2014-10-02 Broadcom Corporation Method and apparatus for reestablishing communication with a network
CN106817671A (en) * 2017-02-14 2017-06-09 腾讯科技(深圳)有限公司 A kind of networked information sharing method, first terminal and system
JP2017224295A (en) * 2017-06-08 2017-12-21 株式会社リコー Client terminal, computer program, and information processing method
CN108174400A (en) * 2017-12-27 2018-06-15 瑞斯康达科技发展股份有限公司 Data processing method and system, the equipment of a kind of terminal device

Also Published As

Publication number Publication date
WO2020043209A1 (en) 2020-03-05
CN110875857A (en) 2020-03-10

Similar Documents

Publication Publication Date Title
CN110875857B (en) Method, device and system for reporting disconnected network state
CN1985470B (en) System, network entities for configuration management of a dynamic host configuration protocol framework
EP2577946B1 (en) Keep-alive hiatus declaration
US20080104221A1 (en) Method and system for simple network management protocol based data management
JP2022502926A (en) UE migration method, equipment, system, and storage medium
CN113453213B (en) Authentication data synchronization method and device
TWI384894B (en) Updating routing and outage information in a communications network
CN112218342A (en) Method, device and system for realizing core network sub-slice disaster tolerance
US9699139B2 (en) Communications system
US9374710B2 (en) Mediation server, control method therefor, communication device, control method therefor, communication system, and computer program
WO2020043006A1 (en) Terminal connection restoration method and apparatus
CN113132227A (en) Method, device, computer equipment and storage medium for updating routing information
CN110913028B (en) Method, device and system for processing virtual address
CN112566104B (en) Roaming coordination method based on Mesh network, wireless access point and storage medium
CN114143904B (en) CPE management method based on 5G fusion network shunt
US20230164596A1 (en) Alarm log management system and method during failure in o-ran
CN113824595B (en) Link switching control method and device and gateway equipment
CN112104888B (en) Method and system for grouping live broadcast users
CN110635927B (en) Node switching method, network node and network system
CN111885601A (en) Keep-alive processing method and device for Mesh equipment
CN115190168B (en) Edge server management system and server cluster
CN111556485B (en) Mobile wireless communication device for data-restricted communication comprising an iSIM and a counter
CN113015155B (en) eSIM server discovery method and device
CN111556484B (en) Mobile radio communication device for redundant communication with two iSIMs
US10701111B2 (en) Method and apparatus for device management

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