CN107547264B - Data backup method and device based on Internet of things - Google Patents

Data backup method and device based on Internet of things Download PDF

Info

Publication number
CN107547264B
CN107547264B CN201710627601.9A CN201710627601A CN107547264B CN 107547264 B CN107547264 B CN 107547264B CN 201710627601 A CN201710627601 A CN 201710627601A CN 107547264 B CN107547264 B CN 107547264B
Authority
CN
China
Prior art keywords
repeater
internet
things
terminal
relay
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
CN201710627601.9A
Other languages
Chinese (zh)
Other versions
CN107547264A (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.)
Shenzhen Shenglu IoT Communication Technology Co Ltd
Original Assignee
Shenzhen Shenglu IoT Communication Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Shenglu IoT Communication Technology Co Ltd filed Critical Shenzhen Shenglu IoT Communication Technology Co Ltd
Priority to CN201710627601.9A priority Critical patent/CN107547264B/en
Publication of CN107547264A publication Critical patent/CN107547264A/en
Application granted granted Critical
Publication of CN107547264B publication Critical patent/CN107547264B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

The embodiment of the invention discloses a data backup method and device based on the Internet of things. A data backup method based on the Internet of things comprises the following steps: acquiring uplink data traffic of a second repeater and a third repeater which are backup repeaters with a first repeater when the first repeater in the Internet of things is abnormal; comparing the uplink data traffic of the second repeater with the uplink data traffic of the third repeater; when the uplink data flow of the second repeater is larger than the uplink data flow of the third repeater, backing up the currently cached service data of the first repeater to the second repeater so that the second repeater uploads the service data; and establishing a connection relation between the terminal of the internet of things which currently has a connection relation with the first repeater and the third repeater so as to disconnect the connection relation between the terminal of the internet of things and the first repeater. The technical scheme of the invention can improve the fault resistance of the Internet of things.

Description

Data backup method and device based on Internet of things
Technical Field
The invention relates to the technical field of Internet of things, in particular to a data backup method and device based on the Internet of things.
Background
The technology of the internet of things is an important component of a new generation of information technology and an important development stage of the information era, and the internet of things realizes information exchange and communication between articles on the basis of the internet. The Internet of things is applied to various fields such as intelligent transportation, safe home, intelligent illumination and the like through communication sensing technologies such as intelligent sensing, identification technology and pervasive computing.
In order to make data transmission farther, repeaters are often used in the internet of things for signal regeneration and signal restoration, and usually, a plurality of terminals of the internet of things can be connected under one repeater, and the terminals of the internet of things transmit their own data from one network to another network through the repeater. However, when a problem occurs in a repeater in the internet of things, transmission delay or even interruption can be caused, and an internet of things terminal connected to the repeater cannot continue to communicate in the internet of things, so that the fault resistance is poor.
Disclosure of Invention
The invention provides a data backup method and device based on the Internet of things, which can backup business data cached by a repeater and transfer terminals connected with the repeater to other repeaters when the repeater is in an abnormal condition, so that the normal communication of the terminals of the Internet of things is ensured, and the fault resistance is improved.
A first aspect of an embodiment of the present invention provides a data backup method based on an internet of things, where the method includes:
acquiring uplink data traffic of a second repeater and a third repeater which are backup repeaters with a first repeater when the first repeater in the Internet of things is abnormal;
comparing the uplink data traffic of the second repeater with the uplink data traffic of the third repeater;
when the uplink data flow of the second repeater is larger than the uplink data flow of the third repeater, backing up the currently cached service data of the first repeater to the second repeater so that the second repeater uploads the service data;
and establishing a connection relation between the terminal of the internet of things which currently has a connection relation with the first repeater and the third repeater so as to disconnect the connection relation between the terminal of the internet of things and the first repeater.
The service data comprises service data uploaded by the Internet of things terminal currently connected to the first repeater.
In an optional embodiment, the backup relationship among the first repeater, the second repeater, and the third repeater may be obtained from the first repeater, or the backup relationship among the first repeater, the second repeater, and the third repeater may be obtained from a data table of the apparatus, that is, the apparatus that performs the method of the first aspect of the embodiment of the present invention stores the backup relationship among the first repeater, the second repeater, and the third repeater.
In an optional embodiment, an apparatus for performing the method of the first aspect of the present invention includes an upper management device of the first relay, where the upper management device includes an Access Point (AP) or a router and other management devices.
In a first possible implementation manner of the first aspect of the present invention, when the uplink data traffic of the second relay is greater than the uplink data traffic of the third relay, backing up the service data currently cached by the first relay to the second relay so that the second relay uploads the service data includes:
when the uplink data traffic of the second repeater is greater than the uplink data traffic of the third repeater, transmitting the repeater identification information of the second repeater to the first repeater;
and informing the first repeater to backup the currently cached service data to the second repeater so that the second repeater uploads the service data.
Wherein the repeater identification information of the second repeater includes bluetooth identification information of the second repeater, IP address information of the second repeater, MAC address information of the second repeater, or device identification code information of the second repeater.
In an optional embodiment, the relay identification information of the second relay is obtained from a data table of the second relay, or the relay identification information of the second relay is obtained while the uplink data traffic of the second relay is obtained.
In a specific embodiment, the repeater identification information of the second repeater is IP address information of the second repeater, the apparatus for performing the method is a wireless AP, the wireless AP sends the IP address information of the second repeater to the first repeater and also sends a backup instruction to the first repeater, after receiving the IP address information of the second repeater and the backup instruction, the first repeater establishes a connection relationship with the second repeater according to the IP address information of the second repeater and backs up service data cached by the first repeater to the second repeater, and after receiving the service data cached by the first repeater, the second repeater transmits the service data according to a target address of the service data.
In another specific embodiment, the apparatus for implementing the method obtains the service data cached by the first relay from the first relay and forwards the service data to the second relay for backup, and the second relay transmits the service data according to the destination address of the service data after receiving the service data cached by the first relay.
With reference to the first aspect of the embodiment of the present invention or the first possible implementation manner of the first aspect of the embodiment of the present invention, in a second possible implementation manner of the first aspect of the embodiment of the present invention, the establishing a connection relationship between the terminal of the internet of things currently having a connection relationship with the first relay and the third relay so as to disconnect the connection relationship between the terminal of the internet of things and the first relay includes:
and sending the repeater identification information of the third repeater to the first repeater so that the first repeater informs the internet of things terminal which has a connection relation with the first repeater to establish a connection relation with the third repeater and disconnect the connection relation with the first repeater.
Wherein the repeater identification information of the third repeater includes bluetooth identification information of the third repeater, IP address information of the third repeater, MAC address information of the third repeater, or device identification code information of the third repeater.
In an optional embodiment, the terminal of the internet of things establishes a connection relationship with the third repeater through internet of things connection technologies such as a bluetooth connection technology, an infrared connection technology, a Wifi connection technology, or a ZigBee connection technology.
In a specific embodiment, the repeater identification information of the third repeater is MAC address information of the third repeater, the apparatus for executing the method is a wireless AP, the wireless AP sends the MAC address of the third repeater to the first repeater and simultaneously sends a terminal migration instruction to the first repeater, after receiving the MAC address of the third repeater and the terminal migration instruction, the first repeater sends the MAC address of the third repeater to the internet of things terminal that establishes a connection relationship with the first repeater and disconnects the connection with the internet of things terminal, and after receiving the MAC address of the third repeater, the internet of things terminal establishes a connection relationship with the third repeater for subsequent data transmission.
With reference to the first aspect of the embodiment of the present invention or the first possible implementation manner of the first aspect of the embodiment of the present invention, in a third possible implementation manner of the first aspect of the embodiment of the present invention, the establishing a connection relationship between the terminal of the internet of things currently having a connection relationship with the first relay and the third relay so as to disconnect the connection relationship between the terminal of the internet of things and the first relay includes:
acquiring terminal identification information of the terminal of the Internet of things which currently establishes a connection relation with the first repeater;
transmitting the terminal identification information to the third repeater;
and informing the third repeater of establishing a connection relationship with the Internet of things terminal so as to disconnect the connection relationship between the Internet of things terminal and the first repeater.
The terminal identification information of the terminal of the internet of things comprises information such as Bluetooth identification information of the terminal of the internet of things, MAC address information of the terminal of the internet of things or equipment identification code information of the terminal of the internet of things.
In an optional embodiment, the first repeater stores terminal identification information of an internet of things terminal currently connected with the first repeater, and the device for executing the method acquires the terminal identification information of the internet of things terminal currently connected with the first repeater from the first repeater.
In a specific embodiment, the terminal identification information of the internet of things is sent to the third repeater and a connection instruction is sent to the third repeater, and after receiving the terminal identification information of the internet of things and the connection instruction, the third repeater establishes a connection relationship with the terminal of the internet of things according to the terminal identification information and notifies the terminal of the internet of things to disconnect the connection relationship with the first repeater.
With reference to the first aspect of the embodiment of the present invention, or the first possible implementation manner of the first aspect of the embodiment of the present invention, or the second possible implementation manner of the first aspect of the embodiment of the present invention, or the third possible implementation manner of the first aspect of the embodiment of the present invention, in a fourth possible implementation manner of the embodiment of the present invention, after establishing a connection relationship between the terminal of the internet of things currently having a connection relationship with the first relay and the third relay to disconnect the connection relationship between the terminal of the internet of things and the first relay, the method includes:
and performing abnormal condition cold treatment on the first repeater to prevent other terminals of the Internet of things from establishing a connection relation with the first repeater.
In an alternative embodiment, the processing of the abnormal cold condition may include adding a preset flag to the information identifier of the first relay to indicate that the relay is currently in an abnormal state or hiding the information identifier of the first relay.
A second aspect of an embodiment of the present invention provides a data backup device for an internet of things, where the device includes:
the system comprises an uplink data traffic acquisition module, a first relay and a second relay, wherein the uplink data traffic acquisition module is used for acquiring uplink data traffic of a second relay and a third relay which are backup relays with a first relay when the first relay in the Internet of things is abnormal;
a comparing module, configured to compare the uplink data traffic of the second repeater with the uplink data traffic of the third repeater;
the service data backup module is used for backing up the service data currently cached by the first repeater to the second repeater so that the second repeater uploads the service data when the uplink data flow of the second repeater is greater than the uplink data flow of the third repeater;
and the Internet of things terminal migration module is used for establishing a connection relationship between the Internet of things terminal which is currently connected with the first repeater and the third repeater so as to disconnect the connection relationship between the Internet of things terminal and the first repeater.
The service data comprises service data uploaded by the Internet of things terminal currently connected to the first repeater.
In an optional embodiment, the apparatus includes an upper management device of the first relay, where the upper management device includes an AP (Access Point) or a router and other management devices.
In an alternative embodiment, the device stores a backup relationship among the first repeater, the second repeater, and the third repeater.
In a first possible implementation manner of the second aspect of the embodiment of the present invention, the service data backup module is specifically configured to:
when the uplink data traffic of the second repeater is greater than the uplink data traffic of the third repeater, transmitting the repeater identification information of the second repeater to the first repeater;
and informing the first repeater to backup the currently cached service data to the second repeater so that the second repeater uploads the service data.
Wherein the repeater identification information of the second repeater includes bluetooth identification information of the second repeater, IP address information of the second repeater, MAC address information of the second repeater, or device identification code information of the second repeater.
In an optional embodiment, the apparatus stores therein repeater identification information of the first repeater and second and third repeaters that are backup information with respect to the first repeater.
In an optional embodiment, the uplink data traffic acquiring module acquires the relay identification information of the second relay and the third relay while acquiring the uplink data traffic of the second relay and the third relay.
In a specific embodiment, the repeater identification information of the second repeater is IP address information of the second repeater, the service data backup module sends the IP address information of the second repeater to the first repeater and also sends a backup instruction to the first repeater, the first repeater establishes a connection relationship with the second repeater according to the IP address information of the second repeater after receiving the IP address information of the second repeater and the backup instruction, and backs up service data cached by the first repeater to the second repeater, and the second repeater transmits the service data according to a target address of the service data after receiving the service data cached by the first repeater.
In another specific embodiment, the apparatus for implementing the method obtains the service data cached by the first relay from the first relay and forwards the service data to the second relay for backup, and the second relay transmits the service data according to the destination address of the service data after receiving the service data cached by the first relay.
With reference to the second aspect of the embodiment of the present invention or the first possible implementation manner of the second aspect of the embodiment of the present invention, in a second possible implementation manner of the second aspect of the embodiment of the present invention, the terminal migration module of the internet of things is specifically configured to:
and sending the repeater identification information of the third repeater to the first repeater so that the first repeater informs the internet of things terminal which has a connection relation with the first repeater to establish a connection relation with the third repeater and disconnect the connection relation with the first repeater.
Wherein the repeater identification information of the third repeater includes bluetooth identification information of the third repeater, IP address information of the third repeater, MAC address information of the third repeater, or device identification code information of the third repeater.
In an optional embodiment, the terminal of the internet of things establishes a connection relationship with the third repeater through internet of things connection technologies such as a bluetooth connection technology, an infrared connection technology, a Wifi connection technology, or a ZigBee connection technology.
In a specific embodiment, the repeater identification information of the third repeater is MAC address information of the third repeater, the terminal migration module of the internet of things sends the MAC address of the third repeater to the first repeater and simultaneously sends a terminal migration instruction to the first repeater, after receiving the MAC address of the third repeater and the terminal migration instruction, the first repeater sends the MAC address of the third repeater to the terminal of the internet of things establishing a connection relationship with the first repeater and disconnects the connection with the terminal of the internet of things, and after receiving the MAC address of the third repeater, the terminal of the internet of things establishes a connection relationship with the third repeater to perform subsequent data transmission.
With reference to the second aspect of the embodiment of the present invention or the first possible implementation manner of the second aspect of the embodiment of the present invention, in a third possible implementation manner of the second aspect of the embodiment of the present invention, the internet of things terminal migration module includes:
a terminal identification information obtaining unit, configured to obtain terminal identification information of an internet of things terminal currently establishing a connection relationship with the first repeater;
a terminal identification information transmitting unit for transmitting the terminal identification information to the third repeater;
and the notification unit is used for notifying the third repeater of establishing a connection relationship with the internet of things terminal so as to disconnect the connection relationship between the internet of things terminal and the first repeater.
The terminal identification information of the terminal of the internet of things comprises information such as Bluetooth identification information of the terminal of the internet of things, MAC address information of the terminal of the internet of things or equipment identification code information of the terminal of the internet of things.
In an optional embodiment, the first repeater stores terminal identification information of an internet of things terminal currently connected with the first repeater, and the terminal identification information obtaining unit obtains the terminal identification information of the internet of things terminal currently connected with the first repeater from the first repeater.
In a specific embodiment, the terminal identification information sending unit sends the terminal identification information of the internet of things to the third repeater and sends a connection instruction to the third repeater, and after receiving the terminal identification information of the internet of things and the connection instruction, the third repeater establishes a connection relationship with the terminal of the internet of things according to the terminal identification information and notifies the terminal of the internet of things to disconnect the connection relationship with the first repeater.
With reference to the second aspect of the embodiment of the present invention or the first possible implementation manner of the second aspect of the embodiment of the present invention or the second possible implementation manner of the second aspect of the embodiment of the present invention or the third possible implementation manner of the second aspect of the embodiment of the present invention, in a fourth possible implementation manner of the embodiment of the present invention, the apparatus further includes:
and the abnormal condition cold processing module is used for performing abnormal condition cold processing on the first repeater so as to prevent other terminals of the internet of things from establishing a connection relation with the first repeater.
In an alternative embodiment, the processing of the abnormal cold condition may include adding a preset flag to the information identifier of the first relay to indicate that the relay is currently in an abnormal state or hiding the information identifier of the first relay.
According to the embodiment of the invention, when the first repeater is abnormal, the service data currently cached by the first repeater is backed up to the second repeater with larger uplink data flow according to the uplink data flow of the second repeater and the third repeater which are mutually backup repeaters with the first repeater, the Internet of things terminal connected to the first repeater is migrated to the third repeater with smaller uplink data flow, the two backup repeaters ensure that the data can be normally transmitted and the normal communication of the Internet of things terminal, and the service data and the Internet of things terminal are respectively backed up to improve the fault resistance.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings needed to be used in the embodiments will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art that other drawings can be obtained according to these drawings without creative efforts.
Fig. 1 is a schematic flowchart of a data backup method based on the internet of things in an embodiment of the present invention;
fig. 2 is a schematic diagram of the first repeater after performing abnormal cooling processing on the first repeater in the embodiment of the present invention;
fig. 3 is a schematic flow chart of another data backup method based on the internet of things in the embodiment of the present invention;
fig. 4-a is a schematic diagram of a network structure of an internet of things in the embodiment of the present invention;
fig. 4-b is a schematic network structure diagram of another internet of things in the embodiment of the invention;
fig. 5 is a flowchart of interaction between devices in the internet of things network according to the embodiment of the present invention;
fig. 6 is a schematic structural diagram of a data backup device based on the internet of things in the embodiment of the present invention;
fig. 7 is a schematic structural diagram illustrating a composition of an internet of things terminal migration module of the data backup device based on the internet of things in the embodiment of the present invention;
fig. 8 is a schematic diagram of a hardware component structure of a data backup device based on the internet of things in the embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The terms "first," "second," "third," and the like in the description and in the claims, and in the above-described drawings, are used for distinguishing between different objects and not for describing a particular order. Furthermore, the terms "include" and "have," as well as any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, method, system, article, or apparatus that comprises a list of steps or elements is not limited to only those steps or elements listed, but may alternatively include other steps or elements not listed, or inherent to such process, method, article, or apparatus.
Referring to fig. 1, fig. 1 is a schematic flow chart of a data backup method based on the internet of things in an embodiment of the present invention, where as shown in the figure, the method at least includes:
s101, when a first repeater in the Internet of things is abnormal, acquiring uplink data traffic of a second repeater and a third repeater which are backup repeaters with the first repeater.
Optionally, the abnormal situation warning information uploaded by the first repeater may be acquired before acquiring uplink data traffic of a second repeater and a third repeater that are backup repeaters for the first repeater.
Optionally, before acquiring uplink data traffic of a second repeater and a third repeater that are backup repeaters for each other with the first repeater, transmission state information of the first repeater, the second repeater and the third repeater may be periodically acquired, and it is determined from the transmission state information of the first repeater that an abnormal condition occurs in the first repeater.
Optionally, the backup relationship among the first repeater, the second repeater, and the third repeater may be acquired from the first repeater, or the backup relationship among the first repeater, the second repeater, and the third repeater may be acquired from a data table thereof.
And S102, comparing the uplink data traffic of the second repeater with the uplink data traffic of the third repeater.
S103, when the uplink data flow of the second repeater is larger than that of the third repeater, backing up the currently cached service data of the first repeater to the second repeater so that the second repeater uploads the service data.
The service data comprises service data uploaded by the Internet of things terminal currently connected to the first repeater.
Optionally, when the uplink data traffic of the second relay is greater than the uplink data traffic of the third relay, the relay identification information of the second relay may be sent to the first relay and notify the first relay to backup the currently cached service data to the second relay, so that the second relay uploads the service data.
Optionally, the repeater identification information of the second repeater includes, but is not limited to, bluetooth identification information of the second repeater, IP address information of the second repeater, MAC address information of the second repeater, and device identification code information of the second repeater.
Optionally, the relay identifier information of the second relay may be acquired from a data table of the second relay, or the relay identifier information of the second relay may be acquired while acquiring the uplink data traffic of the second relay.
In a specific implementation, the repeater identification information of the second repeater may be IP address information of the second repeater, the IP address information of the second repeater may be sent to the first repeater, and a backup instruction may also be sent to the first repeater, after receiving the IP address information of the second repeater and the backup instruction, the first repeater establishes a connection relationship with the second repeater according to the IP address information of the second repeater and backs up service data cached by the first repeater to the second repeater, and after receiving the service data cached by the first repeater, the second repeater transmits the service data according to a target address of the service data.
And S104, establishing a connection relationship between the terminal of the Internet of things which is currently connected with the first repeater and the third repeater so as to disconnect the connection relationship between the terminal of the Internet of things and the first repeater.
Optionally, the repeater identification information of the third repeater may be sent to the first repeater, so that the first repeater notifies the internet of things terminal, which currently has a connection relationship with the first repeater, to establish a connection relationship with the third repeater and disconnect the connection relationship with the first repeater.
Wherein the repeater identification information of the third repeater includes bluetooth identification information of the third repeater, IP address information of the third repeater, MAC address information of the third repeater, or device identification code information of the third repeater.
Optionally, the internet of things terminal establishes a connection relationship with the third repeater through internet of things connection technologies such as a bluetooth connection technology, an infrared connection technology, a Wifi connection technology, or a ZigBee connection technology.
In a specific implementation, the repeater identification information of the third repeater is MAC address information of the third repeater, the MAC address of the third repeater may be sent to the first repeater, and a terminal migration instruction may be sent to the first repeater at the same time, after receiving the MAC address of the third repeater and the terminal migration instruction, the first repeater sends the MAC address of the third repeater to the internet of things terminal that establishes a connection relationship with the first repeater and disconnects the connection with the internet of things terminal, and after receiving the MAC address of the third repeater, the internet of things terminal establishes a connection relationship with the third repeater to perform subsequent data transmission.
Optionally, the establishing a connection relationship between the terminal of the internet of things currently having a connection relationship with the first repeater and the third repeater to disconnect the connection relationship between the terminal of the internet of things and the first repeater may include:
acquiring terminal identification information of the terminal of the Internet of things which currently establishes a connection relation with the first repeater;
and sending the terminal identification information to the third repeater and informing the third repeater of establishing a connection relation with the Internet of things terminal so as to disconnect the connection relation between the Internet of things terminal and the first repeater.
The terminal identification information of the terminal of the internet of things comprises information such as Bluetooth identification information of the terminal of the internet of things, MAC address information of the terminal of the internet of things or equipment identification code information of the terminal of the internet of things.
In a specific implementation, the terminal identification information of the internet of things may be sent to the third repeater and a connection instruction is sent to the third repeater, and after receiving the terminal identification information of the internet of things and the connection instruction, the third repeater establishes a connection relationship with the terminal of the internet of things according to the terminal identification information and notifies the terminal of the internet of things to disconnect the connection relationship with the first repeater.
Optionally, after establishing a connection relationship between the terminal of the internet of things currently having a connection relationship with the first repeater and the third repeater to disconnect the connection relationship between the terminal of the internet of things and the first repeater, the method includes:
and performing abnormal condition cold treatment on the first repeater to prevent other terminals of the Internet of things from establishing a connection relation with the first repeater.
Optionally, the processing of the abnormal condition cold may include adding a preset flag to the information identifier of the first relay to indicate that the relay is currently in an abnormal state or hide the state information identifier of the first relay.
Alternatively, the predetermined mark may be a "! "," x ","? "and the like.
Specifically, as shown in fig. 2, fig. 2 is a schematic diagram of the first repeater after performing abnormal cooling processing on the first repeater in the embodiment of the present invention. The repeater identifications searched by the terminal of the internet of things under the normal condition are respectively a repeater a, a repeater B and a repeater C, as shown in fig. 2-1 in fig. 2, and when the repeater a is in an abnormal condition, the repeater a, the repeater B and the repeater C searched by the terminal of the internet of things are shown in fig. 2-2.
According to the embodiment of the invention, when the first repeater is abnormal, the service data currently cached by the first repeater is backed up to the second repeater with larger uplink data flow according to the uplink data flow of the second repeater and the third repeater which are mutually backup repeaters with the first repeater, the Internet of things terminal connected to the first repeater is migrated to the third repeater with smaller uplink data flow, the two backup repeaters ensure that the data can be normally transmitted and the normal communication of the Internet of things terminal, and the service data and the Internet of things terminal are respectively backed up to improve the fault resistance.
Referring to fig. 3 again, fig. 3 is a schematic flowchart of another data backup method based on the internet of things in the embodiment of the present invention, where the method at least includes:
s201, when a first repeater in the Internet of things is abnormal, acquiring uplink data traffic of a second repeater and uplink data traffic of a third repeater, wherein the second repeater and the first repeater are backup repeaters.
Optionally, the abnormal situation warning information uploaded by the first repeater may be acquired before acquiring uplink data traffic of a second repeater and a third repeater that are backup repeaters for the first repeater.
Optionally, before acquiring uplink data traffic of a second repeater and a third repeater that are backup repeaters for each other with the first repeater, transmission state information of the first repeater, the second repeater and the third repeater may be periodically acquired, and it is determined from the transmission state information of the first repeater that an abnormal condition occurs in the first repeater.
Optionally, the backup relationship among the first repeater, the second repeater, and the third repeater may be acquired from the first repeater, or the backup relationship among the first repeater, the second repeater, and the third repeater may be acquired from a data table thereof.
S202, comparing the uplink data traffic of the second repeater with the uplink data traffic of the third repeater.
S203, when the uplink data traffic of the second relay is greater than the uplink data traffic of the third relay, sending the relay identification information of the second relay to the first relay and notifying the first relay to backup the currently cached service data to the second relay, so that the second relay uploads the service data.
The service data comprises service data uploaded by the Internet of things terminal currently connected to the first repeater.
Optionally, the repeater identification information of the second repeater includes, but is not limited to, bluetooth identification information of the second repeater, IP address information of the second repeater, MAC address information of the second repeater, and device identification code information of the second repeater.
Optionally, the relay identifier information of the second relay may be acquired from a data table of the second relay, or the relay identifier information of the second relay may be acquired while acquiring the uplink data traffic of the second relay.
In a specific implementation, the repeater identification information of the second repeater may be IP address information of the second repeater, the IP address information of the second repeater may be sent to the first repeater, and a backup instruction may also be sent to the first repeater, after receiving the IP address information of the second repeater and the backup instruction, the first repeater establishes a connection relationship with the second repeater according to the IP address information of the second repeater, and backs up service data cached by the first repeater to the second repeater, and after receiving the service data cached by the first repeater, the second repeater transmits the service data according to a target address of the service data.
And S204, acquiring terminal identification information of the terminal of the Internet of things which establishes a connection relation with the first repeater at present.
The terminal identification information of the terminal of the internet of things includes but is not limited to bluetooth identification information of the terminal of the internet of things, MAC address information of the terminal of the internet of things, or device identification code information of the terminal of the internet of things.
S205, sending the terminal identification information to the third repeater and informing the third repeater of establishing a connection relationship with the terminal of the Internet of things so as to disconnect the connection relationship between the terminal of the Internet of things and the first repeater.
In specific implementation, the terminal identification information of the terminal of the internet of things may be sent to the third repeater while sending a connection instruction to the third repeater, and after receiving the terminal identification information of the terminal of the internet of things and the connection instruction, the third repeater establishes a connection relationship with the terminal of the internet of things according to the terminal identification information and notifies the terminal of the internet of things to disconnect the connection relationship with the first repeater.
And S206, performing abnormal cold processing on the first repeater.
The abnormal condition cold processing may include adding a preset flag to the information identifier of the first relay to indicate that the relay is currently in an abnormal state or hiding the state information identifier of the first relay.
Alternatively, the predetermined mark may be a "! "," x ","? "and the like.
Specifically, as shown in fig. 2, fig. 2 is a schematic diagram of the first repeater after performing abnormal cooling processing on the first repeater in the embodiment of the present invention. The repeater identifications searched by the terminal of the internet of things under the normal condition are respectively a repeater a, a repeater B and a repeater C, as shown in fig. 2-1 in fig. 2, and when the repeater a is in an abnormal condition, the repeater a, the repeater B and the repeater C searched by the terminal of the internet of things are shown in fig. 2-2.
According to the embodiment of the invention, when the first repeater is in an abnormal condition, the service data currently cached by the first repeater is backed up to the second repeater with larger uplink data flow according to the uplink data flow of the second repeater and the third repeater which are mutually backup repeaters with the first repeater, the Internet of things terminal connected to the first repeater is migrated to the third repeater with smaller uplink data flow, the two backup repeaters ensure that the data can be normally transmitted and the normal communication of the Internet of things terminal, the service data and the Internet of things terminal are respectively backed up to improve the fault resistance, and meanwhile, the first repeater with the abnormal condition is subjected to abnormal condition cold processing, so that the connection relation between other Internet of things terminals and the first repeater is avoided.
For better understanding and implementing the above-mentioned solution of the embodiment of the present invention, the following description is made with reference to a specific application scenario, assuming that the bluetooth connection technology is only used for the wireless network part in the current internet of things, the optical fiber connection is used for the wired network part, the network structure diagram of the internet of things is shown in fig. 4-a, the upper management device of the repeater is an AP, the wireless connection is used between the AP and the repeater, and between the repeater and the terminal of the internet of things, the wired connection is used between the AP and the external network, three repeaters A, B, C are provided below the AP, the three repeaters are backup repeaters each other, the terminal 1, 2, 3 of the internet of things is connected below the repeater a, the service data a is cached in the repeater a, the terminal 4, 5 of the internet of things is connected below the repeater B, the service data B is cached in the repeater B, and the terminal 6 is connected, the traffic data C is buffered in the repeater C.
Assuming that the repeater a is in an abnormal condition, and assuming that the uplink data traffic of the current repeater B is greater than the uplink data traffic of the repeater C, a flowchart of the interaction performed by the devices in the internet of things network by using the above scheme is shown in fig. 5, which specifically includes:
the AP acquires the uplink data flow of the repeater B;
the AP acquires the uplink data flow of the repeater C;
the AP compares the uplink data flow of the repeater B with the uplink data flow of the repeater C;
the AP sends the identification information of the repeater B and a service data backup instruction to the repeater A;
the repeater A backs up the service data to the repeater B;
the method comprises the steps that an AP obtains terminal identification information 1, 2 and 3 of terminals 1, 2 and 3 of the Internet of things connected with a repeater A;
the AP sends the terminal identification information of the terminals 1, 2 and 3 of the Internet of things to the repeater C and sends a disconnection instruction to the repeater A;
the repeater A is disconnected from the terminals 1, 2 and 3 of the Internet of things;
the repeater establishes a connection relation with the terminals 1, 2 and 3 of the internet of things according to the terminal identification information 1, 2 and 3.
After the above steps are executed, the network structure diagram of the internet of things is shown in fig. 4-B, the service data a cached in the repeater a is backed up in the repeater B, and the terminals 1, 2, 3 of the internet of things connected to the repeater a are connected to the repeater C.
Referring to fig. 6, fig. 6 is a schematic structural diagram of a data backup device based on the internet of things according to an embodiment of the present invention, where as shown in the figure, the data backup device at least includes:
the uplink data traffic obtaining module 310 is configured to obtain uplink data traffic of a second repeater and a third repeater that are backup repeaters with a first repeater in the internet of things when the first repeater is in an abnormal condition.
Optionally, the uplink data traffic obtaining module 310 may obtain the abnormal situation warning information uploaded by the first relay before obtaining the uplink data traffic of the second relay and the third relay which are backup relays with the first relay.
Optionally, the uplink data traffic obtaining module 310 may periodically obtain the transmission state information of the first repeater, the second repeater, and the third repeater before obtaining the uplink data traffic of the second repeater and the third repeater which are backup repeaters with the first repeater, and confirm that the first repeater is in an abnormal condition from the transmission state information of the first repeater.
Optionally, the uplink data traffic obtaining module 310 may obtain the backup relationship among the first repeater, the second repeater, and the third repeater from the first repeater, or obtain the backup relationship among the first repeater, the second repeater, and the third repeater from a data table of the uplink data traffic obtaining module.
A comparing module 320, configured to compare the uplink data traffic of the second repeater with the uplink data traffic of the third repeater.
A service data backup module 330, configured to, when the uplink data traffic of the second relay is greater than the uplink data traffic of the third relay, backup the service data currently cached by the first relay to the second relay so that the second relay uploads the service data, where the service data is uploaded by an internet of things terminal having a connection relationship with the first relay.
The service data comprises service data uploaded by the Internet of things terminal currently connected to the first repeater.
Optionally, the service data backup module 330 is specifically configured to, when the uplink data traffic of the second relay is greater than the uplink data traffic of the third relay, send the relay identification information of the second relay to the first relay and notify the first relay to backup the currently cached service data to the second relay, so that the second relay uploads the service data.
Optionally, the repeater identification information of the second repeater includes, but is not limited to, bluetooth identification information of the second repeater, IP address information of the second repeater, MAC address information of the second repeater, and device identification code information of the second repeater.
In a specific implementation, the repeater identification information of the second repeater may be IP address information of the second repeater, the service data backup module 330 may send the IP address information of the second repeater to the first repeater and also send a backup instruction to the first repeater, after receiving the IP address information of the second repeater and the backup instruction, the first repeater establishes a connection relationship with the second repeater according to the IP address information of the second repeater and backs up service data cached by the first repeater to the second repeater, and after receiving the service data cached by the first repeater, the second repeater transmits the service data according to a target address of the service data.
The internet of things terminal migration module 340 is configured to establish a connection relationship between the internet of things terminal currently having a connection relationship with the first repeater and the third repeater so as to disconnect the connection relationship between the internet of things terminal and the first repeater.
Optionally, the internet of things terminal migration module 340 is specifically configured to send the repeater identification information of the third repeater to the first repeater, so that the first repeater notifies the internet of things terminal, which currently has a connection relationship with the first repeater, to establish a connection relationship with the third repeater and disconnect the connection relationship with the first repeater.
Wherein the repeater identification information of the third repeater includes bluetooth identification information of the third repeater, IP address information of the third repeater, MAC address information of the third repeater, or device identification code information of the third repeater.
Optionally, the internet of things terminal establishes a connection relationship with the third repeater through internet of things connection technologies such as a bluetooth connection technology, an infrared connection technology, a Wifi connection technology, or a ZigBee connection technology.
In a specific implementation, the repeater identification information of the third repeater is MAC address information of the third repeater, the internet of things terminal migration module 340 may send the MAC address of the third repeater to the first repeater and send a terminal migration instruction to the first repeater, after receiving the MAC address of the third repeater and the terminal migration instruction, the first repeater sends the MAC address of the third repeater to the internet of things terminal that establishes a connection relationship with the first repeater and disconnects the connection with the internet of things terminal, and after receiving the MAC address of the third repeater, the internet of things terminal establishes a connection relationship with the third repeater to perform subsequent data transmission.
Optionally, as shown in fig. 7, the internet of things terminal migration module 340 may include:
a terminal identification information obtaining unit 341, configured to obtain terminal identification information of an internet of things terminal currently establishing a connection relationship with the first relay;
a terminal identification information transmitting unit 342, configured to transmit the terminal identification information to the third relay.
A notifying unit 343, configured to notify the third repeater of establishing a connection relationship with the internet of things terminal, so that the internet of things terminal disconnects the connection relationship with the first repeater.
The terminal identification information of the terminal of the internet of things comprises information such as Bluetooth identification information of the terminal of the internet of things, MAC address information of the terminal of the internet of things or equipment identification code information of the terminal of the internet of things.
In a specific implementation, the terminal identification information sending unit 342 may send the terminal identification information of the internet of things to the third repeater and send a connection instruction to the third repeater, and after receiving the terminal identification information of the internet of things and the connection instruction, the third repeater establishes a connection relationship with the terminal of the internet of things according to the terminal identification information and notifies the terminal of the internet of things to disconnect the connection relationship with the first repeater.
Optionally, the apparatus further comprises:
an abnormal condition cooling processing module 350, configured to perform abnormal condition cooling processing on the first repeater so as to prevent other internet of things terminals from establishing a connection relationship with the first repeater.
Optionally, the processing of the abnormal condition cold may include adding a preset flag to the status information identifier of the first relay to indicate that the relay is currently in an abnormal state or hide the status information identifier of the first relay.
Alternatively, the predetermined mark may be a "! "," x ","? "and the like.
Specifically, as shown in fig. 2, fig. 2 is a schematic diagram of the first repeater after performing abnormal cooling processing on the first repeater in the embodiment of the present invention. The repeater identifications searched by the terminal of the internet of things under the normal condition are respectively a repeater a, a repeater B and a repeater C, as shown in fig. 2-1 in fig. 2, and when the repeater a is in an abnormal condition, the repeater a, the repeater B and the repeater C searched by the terminal of the internet of things are shown in fig. 2-2.
According to the embodiment of the invention, when the first repeater is abnormal, the service data currently cached by the first repeater is backed up to the second repeater with larger uplink data flow according to the uplink data flow of the second repeater and the third repeater which are mutually backup repeaters with the first repeater, the Internet of things terminal connected to the first repeater is migrated to the third repeater with smaller uplink data flow, the two backup repeaters ensure that the data can be normally transmitted and the normal communication of the Internet of things terminal, and the service data and the Internet of things terminal are respectively backed up to improve the fault resistance.
It should be noted that the data backup device based on the internet of things at least includes a database for storing data and a processor for data processing, and may include a built-in storage medium or a storage medium provided separately.
As for the processor for data Processing, when executing Processing, the processor can be implemented by a microprocessor, a Central Processing Unit (CPU), a Digital Signal Processor (DSP), or a Programmable logic Array (FPGA); for the storage medium, the storage medium contains operation instructions, which may be computer executable codes, and the operation instructions implement the steps in the data backup process based on the internet of things described in the embodiment of the present invention in conjunction with fig. 1 or fig. 3.
An example of a data backup device based on the internet of things as a hardware entity is shown in fig. 8. The apparatus comprises a processor 401, a storage medium 402 and at least one external communication interface 403; the processor 401, storage medium 402, and communication interface 403 are all connected by a bus 404.
The processor 401 of the data backup device based on the internet of things can call the operating instructions in the storage medium 402 to execute the following procedures:
acquiring uplink data traffic of a second repeater and a third repeater which are backup repeaters with a first repeater when the first repeater in the Internet of things is abnormal;
comparing the uplink data traffic of the second repeater with the uplink data traffic of the third repeater;
when the uplink data flow of the second repeater is larger than the uplink data flow of the third repeater, backing up the currently cached service data of the first repeater to the second repeater so that the second repeater uploads the service data.
And establishing a connection relation between the terminal of the internet of things which currently has a connection relation with the first repeater and the third repeater so as to disconnect the connection relation between the terminal of the internet of things and the first repeater.
Here, it should be noted that: the above description related to the data backup device based on the internet of things is similar to the foregoing description of the data backup method based on the internet of things, and the description of the beneficial effects of the method is omitted for brevity. For technical details that are not disclosed in the embodiment of the data backup device based on the internet of things, please refer to the description of the embodiment of the method of the present invention.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by a computer program, which can be stored in a computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. The storage medium may be a magnetic disk, an optical disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), or the like.
The steps in the method of the embodiment of the invention can be sequentially adjusted, combined and deleted according to actual needs.
The modules in the device provided by the embodiment of the invention can be combined, divided and deleted according to actual needs.
The above disclosure is only for the purpose of illustrating the preferred embodiments of the present invention, and it is therefore to be understood that the invention is not limited by the scope of the appended claims.

Claims (8)

1. A data backup method based on the Internet of things is characterized by comprising the following steps:
the method comprises the steps that when a first repeater in the Internet of things is abnormal, upper management equipment acquires uplink data traffic of a second repeater and a third repeater, wherein the second repeater and the first repeater are backup repeaters;
the upper management equipment compares the uplink data traffic of the second repeater with the uplink data traffic of the third repeater;
when the uplink data flow of the second repeater is greater than the uplink data flow of the third repeater, the upper management device acquires the service data cached in the first repeater from the first repeater, and forwards the service data to the second repeater for backup so that the second repeater transmits the service data according to the target address of the service data after receiving the service data cached in the first repeater; the service data is uploaded by the Internet of things terminal which is currently connected to the first repeater;
and the upper management equipment establishes a connection relation between the terminal of the internet of things which currently has a connection relation with the first repeater and the third repeater so as to disconnect the connection relation between the terminal of the internet of things and the first repeater.
2. The method of claim 1, wherein the upper management device, after establishing a connection between the terminal of the internet of things currently in connection with the first relay and the third relay to disconnect the connection between the terminal of the internet of things and the first relay, comprises:
and the upper management equipment performs abnormal condition cold treatment on the first repeater so as to prevent other terminals of the internet of things from establishing a connection relation with the first repeater.
3. The method of claim 2, wherein the upper management device establishing a connection relationship between the internet of things terminal currently in a connection relationship with the first relay and the third relay to disconnect the connection relationship between the internet of things terminal and the first relay comprises:
and the upper management equipment sends the repeater identification information of the third repeater to the first repeater so that the first repeater informs the internet of things terminal which has a connection relation with the first repeater to establish a connection relation with the third repeater and disconnect the connection relation with the first repeater.
4. The method of claim 2, wherein the upper management device establishing a connection relationship between the internet of things terminal currently in a connection relationship with the first relay and the third relay to disconnect the connection relationship between the internet of things terminal and the first relay comprises:
the upper management equipment acquires terminal identification information of an Internet of things terminal which establishes a connection relation with the first repeater at present, wherein the terminal identification information comprises at least one of Bluetooth identification information, MAC address information or equipment identification code information;
the upper management equipment sends the terminal identification information to the third repeater;
and the upper management equipment informs the third repeater of establishing a connection relationship with the Internet of things terminal so as to disconnect the connection relationship between the Internet of things terminal and the first repeater.
5. A data backup device based on the Internet of things is characterized in that the device comprises:
the system comprises an uplink data traffic acquisition module, a first relay and a second relay, wherein the uplink data traffic acquisition module is used for acquiring uplink data traffic of a second relay and a third relay which are backup relays with a first relay when the first relay in the Internet of things is abnormal;
a comparing module, configured to compare the uplink data traffic of the second repeater with the uplink data traffic of the third repeater;
a service data backup module, configured to, when an uplink data traffic of the second relay is greater than an uplink data traffic of the third relay, obtain service data cached in the first relay from the first relay, and forward the service data to the second relay for backup, so that the second relay transmits the service data according to a target address of the service data after receiving the service data cached in the first relay; the service data is uploaded by the Internet of things terminal which is currently connected to the first repeater;
and the Internet of things terminal migration module is used for establishing a connection relationship between the Internet of things terminal which is currently connected with the first repeater and the third repeater so as to disconnect the connection relationship between the Internet of things terminal and the first repeater.
6. The apparatus of claim 5, wherein the apparatus further comprises:
and the abnormal condition cold processing module is used for performing abnormal condition cold processing on the first repeater so as to prevent other terminals of the internet of things from establishing a connection relation with the first repeater.
7. The apparatus of claim 6, wherein the internet of things terminal migration module is specifically configured to:
and sending the repeater identification information of the third repeater to the first repeater so that the first repeater informs the internet of things terminal which has a connection relation with the first repeater to establish a connection relation with the third repeater and disconnect the connection relation with the first repeater.
8. The apparatus of claim 6, wherein the internet of things terminal migration module comprises:
a terminal identification information obtaining unit, configured to obtain terminal identification information of an internet of things terminal currently establishing a connection relationship with the first repeater;
a terminal identification information transmitting unit for transmitting the terminal identification information to the third repeater;
and the notification unit is used for notifying the third repeater of establishing a connection relationship with the internet of things terminal so as to disconnect the connection relationship between the internet of things terminal and the first repeater.
CN201710627601.9A 2017-07-28 2017-07-28 Data backup method and device based on Internet of things Active CN107547264B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710627601.9A CN107547264B (en) 2017-07-28 2017-07-28 Data backup method and device based on Internet of things

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710627601.9A CN107547264B (en) 2017-07-28 2017-07-28 Data backup method and device based on Internet of things

Publications (2)

Publication Number Publication Date
CN107547264A CN107547264A (en) 2018-01-05
CN107547264B true CN107547264B (en) 2020-10-20

Family

ID=60970778

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710627601.9A Active CN107547264B (en) 2017-07-28 2017-07-28 Data backup method and device based on Internet of things

Country Status (1)

Country Link
CN (1) CN107547264B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111225335B (en) * 2020-01-16 2021-01-08 重庆医药高等专科学校 Method and system for transmitting child positioning data in real time based on Internet of things
CN114884805B (en) * 2022-05-25 2023-07-21 远景智能国际私人投资有限公司 Data transmission method, device, terminal and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101019375A (en) * 2004-09-22 2007-08-15 国际商业机器公司 Method and systems for copying data components between nodes of a network
CN104506576A (en) * 2014-12-03 2015-04-08 常州大学 Wireless sensor network and node task migration method thereof
CN105052205A (en) * 2013-03-15 2015-11-11 思科技术公司 Providing a backup network topology without serviece disruption
CN106686758A (en) * 2016-12-28 2017-05-17 上海海事大学 Method for recovering wireless sensor network connectivity

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101019375A (en) * 2004-09-22 2007-08-15 国际商业机器公司 Method and systems for copying data components between nodes of a network
CN105052205A (en) * 2013-03-15 2015-11-11 思科技术公司 Providing a backup network topology without serviece disruption
CN104506576A (en) * 2014-12-03 2015-04-08 常州大学 Wireless sensor network and node task migration method thereof
CN106686758A (en) * 2016-12-28 2017-05-17 上海海事大学 Method for recovering wireless sensor network connectivity

Also Published As

Publication number Publication date
CN107547264A (en) 2018-01-05

Similar Documents

Publication Publication Date Title
JP2016530766A5 (en)
CN109672708B (en) Communication method, device and system
US10560929B2 (en) Resource request method and system, device, and network side node
EP2934027A1 (en) Wireless communication system
CN104066129A (en) Network switching method and system
US10362549B2 (en) Method and apparatus for setting up interface between access points
JP6280658B2 (en) Autonomous expansion node B
US20180359644A1 (en) Slice information changing method, and communication system
WO2022017407A1 (en) Information processing method and apparatus, device, and readable storage medium
CN107465609B (en) Terminal routing method based on Internet of things and Internet of things terminal
EP4255103A3 (en) Device and method for service subscription via e2 interface in radio access network communication system
CN107547264B (en) Data backup method and device based on Internet of things
CN105072148B (en) Method and device for establishing connection with terminal
CN109802982B (en) Dual-connection implementation method, device and system
WO2016206302A1 (en) Load message forwarding method, device and system, and storage medium
CN105451367A (en) Wireless network connection method, device and system
CN113596792A (en) Binding method and device of electronic equipment, storage medium and electronic device
CN107404404B (en) Terminal routing method based on Internet of things and Internet of things terminal
RU2643163C2 (en) Method and device for implementation of call processing service, as well as method and device for transmission of indication data
CN108632355B (en) Routing method for household appliance network, control terminal, readable storage medium and equipment
CN105208679A (en) Equipment and method for realizing wireless network intercommunication
CN106413123B (en) Data transmission method and device
CN105101273A (en) Method and apparatus for role configuration of base station in wireless communication system
JP5957494B2 (en) WiFi connection system, WiFi connection terminal, WiFi connection method, and WiFi connection program
CN104320860A (en) Method, device and terminal for network connections

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