CN115714717B - Internet of things terminal communication link fault positioning method based on flow characteristics - Google Patents

Internet of things terminal communication link fault positioning method based on flow characteristics Download PDF

Info

Publication number
CN115714717B
CN115714717B CN202211400644.0A CN202211400644A CN115714717B CN 115714717 B CN115714717 B CN 115714717B CN 202211400644 A CN202211400644 A CN 202211400644A CN 115714717 B CN115714717 B CN 115714717B
Authority
CN
China
Prior art keywords
equipment
time sequence
flow
flow data
data
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
CN202211400644.0A
Other languages
Chinese (zh)
Other versions
CN115714717A (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.)
State Grid Corp of China SGCC
State Grid Hunan Electric Power Co Ltd
Information and Telecommunication Branch of State Grid Hunan Electric Power Co Ltd
Original Assignee
State Grid Corp of China SGCC
State Grid Hunan Electric Power Co Ltd
Information and Telecommunication Branch of State Grid Hunan Electric Power 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 State Grid Corp of China SGCC, State Grid Hunan Electric Power Co Ltd, Information and Telecommunication Branch of State Grid Hunan Electric Power Co Ltd filed Critical State Grid Corp of China SGCC
Priority to CN202211400644.0A priority Critical patent/CN115714717B/en
Publication of CN115714717A publication Critical patent/CN115714717A/en
Application granted granted Critical
Publication of CN115714717B publication Critical patent/CN115714717B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The application discloses a method for positioning communication link faults of an internet of things terminal based on flow characteristics, which comprises the following steps: s1, capturing a flow data packet uploaded by equipment on a server to obtain flow data packet information; s2, classifying the obtained flow data packet information to construct a flow data time sequence data set; s3, constructing a flow time sequence feature library of the terminal equipment; s4, calculating the shortest distance between the time sequence of the flow data transmitted by the terminal equipment and the time sequence characteristic; s5, judging whether the data transmission process of the current type of equipment is normal or not according to the shortest distance and the distance threshold value; s6, if the transmission process of the current equipment is abnormal, selecting a grabbing node on a transmission link between the equipment and the application to grab and analyze the equipment message; s7, obtaining the communication link fault point by analyzing the message content. The application can realize the automatic, rapid and accurate positioning of the communication link fault between the widely applicable and reliable Internet of things terminal and the client application.

Description

Internet of things terminal communication link fault positioning method based on flow characteristics
Technical Field
The application relates to the technical field of communication control, in particular to a method for positioning communication link faults of an internet of things terminal based on flow characteristics.
Background
At present, real-time sensing of data such as environmental information, important instrument and equipment state information and the like can be realized through various internet of things terminal acquisition equipment and edge internet of things agents, and the data is transmitted to an internet of things management platform through a mobile network, so that application such as intelligent control, equipment monitoring and security risk prediction of a client building are supported. However, part of the internet of things perceives that the terminal is far away, in order to ensure the data security, the equipment needs to pass through a firewall or a security gateway and other equipment in the transmission process, the reasons for the data transmission failure of the equipment are numerous, and once the failure occurs, the equipment needs to be cooperatively checked by multiple personnel, so that the operation and maintenance efficiency is low, the service use of clients is affected, and great economic loss and security risk can be caused when serious.
Disclosure of Invention
The application provides a method for positioning a communication link fault of an Internet of things terminal based on flow characteristics, which aims to solve the technical problems of high cost and low efficiency in the prior art for troubleshooting a data transmission fault of a communication link.
The technical scheme adopted by the application is as follows:
A method for positioning communication link faults of an Internet of things terminal based on flow characteristics comprises the following steps:
s1, capturing a flow data packet uploaded by equipment on a server to obtain flow data packet information, wherein the flow data packet information comprises a client and a server IP, a port, time and length;
S2, classifying the obtained flow data packet information according to the equipment positions and types, and constructing a flow data time sequence data set consisting of flow data time sequences of various equipment and characteristic labels corresponding to the various equipment;
S3, constructing a flow time sequence feature library of the terminal equipment according to the flow data time sequence data set;
S4, calculating the shortest distance between the time sequence of the flow data transmitted in the running process of the terminal equipment and the time sequence characteristic;
S5, comparing the calculated shortest distance with a set distance threshold value, and judging whether the data transmission process of the current equipment is normal or not;
S6, if the transmission process of the current equipment is abnormal, selecting a grabbing node on a transmission link between the equipment and the application to grab equipment messages, and analyzing the messages by using a message analysis program;
s7, analyzing and obtaining a communication link fault point between the equipment and the application by comparing the analysis message content of the grabbing node.
Further, the step S2 specifically includes the steps of:
S21, constructing a flow data time sequence of single-class equipment as S= { S 1,s2,…,sT }, wherein T represents the length of the time sequence, namely the frequency of uploading data by the equipment, and S 1,s2,…,sT is the flow data size arranged according to the time sequence;
s22, a flow data time sequence data set consisting of flow data time sequences of various devices and corresponding feature labels of the various devices:
W={(S1,c1),…,(Sn,cn),…,(SN,cN)}
wherein S n represents a traffic data time sequence of the nth class device, and c n represents a feature tag of the nth class device.
Further, the step S3 specifically includes the steps of:
S31, constructing a candidate time sequence feature set: for the nth class device, selecting a candidate feature set, denoted as p n={pn,1,…,pn,l,…,pn,L, in its traffic data time series S n, where The set of candidate timing features for all devices may be represented as p= { P 1,p2,…,pN }, where k represents the length of the candidate feature; l represents the first candidate feature of the nth class device;
S32, dividing the device flow time sequence into subsequences with equal length: dividing the flow data time sequence S n of the nth class device into subsequences with the length of k, wherein the subsequence set can be represented as S n.k={s1,k,s2,k,…,si,k,…,sT-k+1,k, and the subsequences S i,k={si,si+1,…si+k-1;
S33, calculating the residual square sum of the candidate time sequence feature set and the subsequence: calculating the sum of squares of residuals between all candidate feature sequences and sub-sequences of length k, and the set of sum squares of sub-sequence residuals of length k for the nth class of devices can be expressed as:
dn,k={d(pn,l,s1,k),…,d(pn,l,si,k),…,d(pn,l,sT-k+1,k)},
Wherein, Representing the i th residual square sum, the candidate feature sequence and subsequence residual square sum set of the n-th device is
S34, calculating a characteristic evaluation value of the candidate characteristic sequence to obtain a device flow time sequence characteristic library: calculating the feature evaluation capability of all candidate feature sequences of the nth class of equipment, selecting the candidate feature sequence with the largest evaluation value G n,l as the flow time sequence feature q n of the current equipment, wherein the specific calculation formula is as follows:
Wherein, Represents the average of all data within set D n,Representing the average of all data within set d n,k, the traffic timing feature library q= { Q 1,…,qn,…,qN } for all devices.
Further, the step S4 specifically includes the steps of:
S41, calculating Euclidean distance between the two points a i and q n,j, namely D i,j=|ai-qn,j I, and obtaining a distance matrix D with the size of (m, L), wherein the distance matrix D is specifically expressed as:
Wherein a i is the ith time point in the flow data time sequence A= { a 1,a2,…,am } to be judged, and q n,j is the jth time sequence feature in the time sequence feature sequence q n={qn,1,qn,2,…,qn,L };
S42, searching a path R from d 1,1 to d m,L in a distance matrix, wherein R=R 1,R2,…,Rk,…,RK, and R k=(i,j)k, max (m, L) is more than or equal to K and less than or equal to m+L-1;
s43, obtaining a shortest path in a dynamic iteration mode, wherein a specific recursion formula is as follows:
r(i,j)=di,j+min{r(i-1,j-i),r(i-1,j),r(i,j-1)};
S44, calculating the shortest distance between the flow data time sequence A and the time sequence characteristic sequence q n:
further, in step S6, the grabbing node includes a network firewall, an internet of things management platform, and a data forwarding server.
Further, the step S7 specifically includes the steps of:
S71, if a few of the equipment information is missing in three data messages and the other most of the equipment is normal, judging that the APN card flow of the current equipment is used up or the equipment fails;
s72, if all the equipment information in the three data messages is missing, judging that the base station of the network operator is faulty;
S73, if the data message information collected at the network firewall is normal, but the information at the Internet of things management platform is missing, judging that the network firewall policy is due;
And S74, if the data message information collected by the network firewall and the Internet of things management platform are normal, but the equipment message information collected by the northbound server is missing, judging that the data forwarding server fails.
The application also provides a device for positioning the communication link fault of the terminal of the internet of things based on the flow characteristics, which comprises:
The flow data packet information acquisition module is used for capturing flow data packets uploaded by the equipment on the server to acquire flow data packet information, wherein the flow data packet information comprises a client and a server IP, a port, time and a length;
the flow data time sequence data set construction module is used for classifying the obtained flow data packet information according to the equipment positions and types and constructing a flow data time sequence data set consisting of flow data time sequences of various equipment and characteristic labels corresponding to the various equipment;
the flow time sequence feature library construction module is used for constructing a flow time sequence feature library of the terminal equipment according to the flow data time sequence data set;
the shortest distance calculation module is used for calculating the shortest distance between the flow data time sequence and the time sequence characteristics transmitted in the operation process of the terminal equipment;
The judging module is used for comparing the calculated shortest distance with a set distance threshold value and judging whether the data transmission process of the current equipment is normal or not;
The device message grabbing and analyzing module is used for selecting grabbing nodes to grab device messages on a transmission link between the device and the application if the transmission process of the current device is abnormal, and analyzing the messages by using a message analyzing program;
and the fault point analysis module is used for analyzing and obtaining the fault point of the communication link between the equipment and the application by comparing the analysis message content of the grabbing node.
The application also provides electronic equipment, which comprises a memory, a processor and a computer program stored on the memory and capable of running on the processor, wherein the processor realizes the steps of the method for positioning the communication link fault of the terminal of the Internet of things based on the flow characteristic when executing the program.
The application also provides a storage medium, which comprises a stored program, and when the program runs, the equipment where the storage medium is located is controlled to execute the steps of the method for positioning the communication link fault of the terminal of the Internet of things based on the flow characteristics.
Compared with the prior art, the application has the following beneficial effects:
The application provides a method for positioning communication link faults of an Internet of things terminal based on flow characteristics, which classifies flow packet information uploaded by Internet of things equipment and constructs a flow data time sequence data set and a flow time sequence characteristic library, when the shortest distance between a flow data time sequence transmitted in the operation process of the terminal equipment and the time sequence characteristics obtained through calculation is used for judging that the transmission process of the current equipment is abnormal, the important nodes of the transmission link between the equipment and client applications are used for capturing and comparing and analyzing the message content of the equipment to obtain the communication link fault points between the equipment and the client applications, thereby realizing the communication link fault positioning between the widely applicable and reliable Internet of things terminal and the client applications.
In addition to the objects, features and advantages described above, the present application has other objects, features and advantages. The application will be described in further detail with reference to the accompanying drawings.
Drawings
The accompanying drawings, which are included to provide a further understanding of the application and are incorporated in and constitute a part of this specification, illustrate embodiments of the application and together with the description serve to explain the application. In the drawings:
fig. 1 is a flow chart of a method for positioning a communication link fault of an internet of things terminal according to a preferred embodiment of the present application.
Fig. 2 is a schematic diagram of the flow packet information fields of a preferred embodiment of the present application.
Fig. 3 is a schematic flow chart of the substeps of step S3 of the preferred embodiment of the application.
Fig. 4 is a schematic flow chart of the substeps of step S4 of the preferred embodiment of the application.
Fig. 5 is a schematic diagram of the location of a node of a grabbed message on a data transmission link according to a preferred embodiment of the present application.
Fig. 6 is a schematic flow chart of the substeps of step S7 of the preferred embodiment of the application.
Fig. 7 is a schematic diagram of an internet of things terminal communication link fault locating device based on a flow characteristic according to a preferred embodiment of the present application.
Fig. 8 is a schematic block diagram of an electronic device entity of a preferred embodiment of the present application.
Fig. 9 is an internal structural view of the computer device of the preferred embodiment of the present application.
Detailed Description
It should be noted that, without conflict, the embodiments of the present application and features of the embodiments may be combined with each other. The application will be described in detail below with reference to the drawings in connection with embodiments.
Referring to fig. 1, a preferred embodiment of the present application provides a method for locating a communication link failure of an internet of things terminal based on a traffic characteristic, comprising the steps of:
S1, capturing a flow data packet uploaded by equipment on a server through WIRESHARK software to obtain flow data packet information, wherein the flow data packet information comprises a client and a server IP, a port, time and flow data length (see figure 2);
S2, classifying the obtained flow data packet information according to the equipment positions and types, and constructing a flow data time sequence data set consisting of flow data time sequences of various equipment and characteristic labels corresponding to the various equipment;
S3, constructing a flow time sequence feature library of the terminal equipment according to the flow data time sequence data set;
S4, calculating the shortest distance between the time sequence of the flow data transmitted in the running process of the terminal equipment and the time sequence characteristic;
S5, comparing the calculated shortest distance with a set distance threshold L 0 to judge whether the data transmission process of the current equipment is normal or not;
S6, if the transmission process of the current equipment is abnormal (namely, the calculated shortest distance is larger than a set distance threshold L 0), selecting a grabbing node to grab equipment messages on a transmission link between the equipment and an application (see figure 5), and analyzing the messages by using a message analysis program, wherein the grabbing node comprises a network firewall, an Internet of things management platform and a data forwarding server;
s7, analyzing and obtaining a communication link fault point between the equipment and the application by comparing the analysis message content of the grabbing node.
The embodiment provides a method for positioning a communication link fault of an Internet of things terminal based on flow characteristics, which classifies flow packet information uploaded by Internet of things equipment and constructs a flow data time sequence data set and a flow time sequence characteristic library, when the shortest distance between a flow data time sequence transmitted in the operation process of the terminal equipment and the time sequence characteristics obtained through calculation is judged to be abnormal in the transmission process of the current equipment, the communication link fault point between the equipment and a client application is obtained by grabbing and comparing and analyzing the equipment message content on important nodes of the transmission link between the equipment and the client application, the communication link fault positioning between the widely applicable and reliable Internet of things terminal and the client application is realized, the whole positioning process can automatically and quickly find the communication link fault point according to the flow packet information, the equipment message content and the like without manual participation, the positioning efficiency is high, the time is short, the cost is low, the normal operation of the communication link can be quickly and accurately found out by adopting corresponding measures in time, the maintenance efficiency is improved, and economic loss and safety risk caused by the influence of the service use of the client due to the long-time searching of the fault point is avoided.
Specifically, the step S2 specifically includes the steps of:
S21, constructing a flow data time sequence of single-class equipment as S= { S 1,s2,…,sT }, wherein T represents the length of the time sequence, namely the frequency of uploading data by the equipment, and S 1,s2,…,sT is the flow data size arranged according to the time sequence;
s22, a flow data time sequence data set consisting of flow data time sequences of various devices and corresponding feature labels of the various devices:
W={(S1,c1),…,(Sn,cn),…,(SN,cN)}
wherein S n represents a traffic data time sequence of the nth class device, and c n represents a feature tag of the nth class device.
In this embodiment, by constructing the flow data time sequence S of a single device, the flow data time sequences of various devices, and the flow data time sequence data set W formed by the feature tags corresponding to the various devices, the purpose and advantage are that the flow sequences of the various devices can be individually analyzed so as to extract the flow characteristics. The device data may also be pruned in the dataset based on the feature tags if devices are subsequently added or deleted.
Specifically, as shown in fig. 3, the step S3 specifically includes the steps of:
S31, constructing a candidate time sequence feature set: for the nth class device, selecting a candidate feature set, denoted as p n={pn,1,…,pn,l,…,pn,L, in its traffic data time series S n, where The set of candidate timing features for all devices may be represented as p= { P 1,p2,…,pN }, where k represents the length of the candidate feature; l represents the first candidate feature of the nth class device;
S32, dividing the device flow time sequence into subsequences with equal length: dividing the flow data time sequence S n of the nth class device into subsequences with the length of k, wherein the subsequence set can be represented as S n.k={s1,k,s2,k,…,si,k,…,sT-k+1,k, and the subsequences S i,k={si,si+1,…si+k-1;
S33, calculating the residual square sum of the candidate time sequence feature set and the subsequence: calculating the sum of squares of residuals between all candidate feature sequences and sub-sequences of length k, and the set of sum squares of sub-sequence residuals of length k for the nth class of devices can be expressed as:
dn,k={d(pn,l,s1,k),…,d(pn,l,si,k),…,d(pn,l,sT-k+1,k)},
Wherein, Representing the i th residual square sum, the candidate feature sequence and subsequence residual square sum set of the n-th device is
S34, calculating a characteristic evaluation value of the candidate characteristic sequence to obtain a device flow time sequence characteristic library: calculating the feature evaluation capability of all candidate feature sequences of the nth class of equipment, selecting the candidate feature sequence with the largest evaluation value G n,l as the flow time sequence feature q n of the current equipment, wherein the specific calculation formula is as follows:
Wherein, Represents the average of all data within set D n,Representing the average of all data within set d n,k, the traffic timing feature library q= { Q 1,…,qn,…,qN } for all devices.
In this embodiment, when a traffic timing characteristic library of a terminal device is constructed, a candidate timing characteristic set and equal-length subsequences are constructed first, then a residual square sum of the candidate timing characteristic set and the subsequences is calculated, and meanwhile, the traffic timing characteristic library Q of all devices is obtained according to the largest candidate characteristic sequence in the calculated characteristic evaluation value of the candidate characteristic sequence as the traffic timing characteristic of the current device, and the purpose and benefit of the method for obtaining the traffic timing characteristic library Q by adopting the above measures are as follows: the feature sequence which can most represent the flow characteristics of the equipment can be selected from the candidate time sequence feature set of the equipment so as to carry out comparison and judgment when a new equipment flow sequence is received.
Specifically, as shown in fig. 4, the step S4 specifically includes the steps of:
S41, calculating Euclidean distance between the two points a i and q n,j, namely D i,j=|ai-qn,j I, and obtaining a distance matrix D with the size of (m, L), wherein the distance matrix D is specifically expressed as:
Wherein a i is the ith time point in the flow data time sequence A= { a 1,a2,…,am } to be judged, and q n,j is the jth time sequence feature in the time sequence feature sequence q n={qn,1,qn,2,…,qn,L };
S42, searching a path R from d 1,1 to d m,L in a distance matrix, wherein R=R 1,R2,…,Rk,…,RK, and R k=(i,j)k, max (m, L) is more than or equal to K and less than or equal to m+L-1;
s43, obtaining a shortest path in a dynamic iteration mode, wherein a specific recursion formula is as follows:
r(i,j)=di,j+min{r(i-1,j-i),r(i-1,j),r(i,j-1)};
S44, calculating the shortest distance between the flow data time sequence A and the time sequence characteristic sequence q n:
In the embodiment, firstly, euclidean distance between two points a i and q j is calculated to obtain a distance matrix D with the size of (m, L); then find a path R from d 1,1 to d m,L in the distance matrix; then obtaining the shortest path in a dynamic iteration mode; finally, the shortest distance between the flow data time sequence A and the time sequence characteristic sequence q n is calculated. The embodiment adopts the measures to obtain the shortest distance and has the following purposes and benefits: and evaluating the similarity between the flow data time sequence to be judged and the equipment characteristic sequence according to the obtained shortest distance so as to judge whether the equipment flow transmission is normal.
As shown in fig. 6, the step S7 specifically includes the steps of:
S71, if a few of the equipment information is missing in three data messages and the other most of the equipment is normal, judging that the APN card flow of the current equipment is used up or the equipment fails;
s72, if all the equipment information in the three data messages is missing, judging that the base station of the network operator is faulty;
S73, if the data message information collected at the network firewall is normal, but the information at the Internet of things management platform is missing, judging that the network firewall policy is due;
And S74, if the data message information collected by the network firewall and the Internet of things management platform are normal, but the equipment message information collected by the northbound server is missing, judging that the data forwarding server fails.
According to the embodiment, the node where the fault occurs is judged in multiple aspects according to the equipment information missing condition in the corresponding data message, the data message information acquired at the network firewall, the information condition at the Internet of things management platform and the equipment message information missing condition acquired at the northbound server, so that the fault point of the communication link can be found accurately and efficiently.
As shown in fig. 7, another aspect of the present application further provides a device for locating a communication link failure of an internet of things terminal based on a traffic characteristic, including:
The flow data packet information acquisition module is used for capturing flow data packets uploaded by the equipment on the server to acquire flow data packet information, wherein the flow data packet information comprises a client and a server IP, a port, time and a length;
the flow data time sequence data set construction module is used for classifying the obtained flow data packet information according to the equipment positions and types and constructing a flow data time sequence data set consisting of flow data time sequences of various equipment and characteristic labels corresponding to the various equipment;
the flow time sequence feature library construction module is used for constructing a flow time sequence feature library of the terminal equipment according to the flow data time sequence data set;
the shortest distance calculation module is used for calculating the shortest distance between the flow data time sequence and the time sequence characteristics transmitted in the operation process of the terminal equipment;
The judging module is used for comparing the calculated shortest distance with a set distance threshold value and judging whether the data transmission process of the current equipment is normal or not;
The device message grabbing and analyzing module is used for selecting grabbing nodes to grab device messages on a transmission link between the device and the application if the transmission process of the current device is abnormal, and analyzing the messages by using a message analyzing program;
and the fault point analysis module is used for analyzing and obtaining the fault point of the communication link between the equipment and the application by comparing the analysis message content of the grabbing node.
As shown in fig. 8, the preferred embodiment of the present application further provides an electronic device, including a memory, a processor, and a computer program stored in the memory and capable of running on the processor, where the processor implements the steps of the method for positioning a communication link failure of an internet of things terminal based on a traffic characteristic in the foregoing embodiment when executing the program.
As shown in fig. 9, the preferred embodiment of the present application also provides a computer device, which may be a terminal or a living body detection server, the internal structure of which may be as shown in fig. 9. The computer device includes a processor, a memory, and a network interface connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The network interface of the computer device is used for communicating with other external computer devices through network connection. The computer program is executed by the processor to realize the steps of the method for positioning the communication link fault of the terminal of the internet of things based on the flow characteristic.
It will be appreciated by persons skilled in the art that the architecture shown in fig. 9 is merely a block diagram of some of the architecture relevant to the present inventive arrangements and is not limiting as to the computer device to which the present inventive arrangements are applicable, and that a particular computer device may include more or fewer components than shown, or may combine some of the components, or have a different arrangement of components.
The preferred embodiment of the application also provides a storage medium, which comprises a stored program, and when the program runs, the device where the storage medium is controlled to execute the steps of the method for positioning the communication link fault of the terminal of the internet of things based on the flow characteristic in the embodiment.
It should be noted that the steps illustrated in the flowcharts of the figures may be performed in a computer system such as a set of computer executable instructions, and that although a logical order is illustrated in the flowcharts, in some cases the steps illustrated or described may be performed in an order other than that illustrated herein.
The functions described in the method of this embodiment, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in one or more computing device readable storage media. Based on such understanding, a part of the present application that contributes to the prior art or a part of the technical solution may be embodied in the form of a software product stored in a storage medium, comprising several instructions for causing a computing device (which may be a personal computer, a server, a mobile computing device or a network device, etc.) to execute all or part of the steps of the method described in the embodiments of the present application. And the aforementioned storage medium includes: a usb disk, a removable hard disk, a Read-Only Memory (ROM), a random-access Memory (RAM, random Access Memory), a magnetic disk or an optical disk, or other various media capable of storing program codes.
It will be appreciated by those skilled in the art that embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein. The scheme in the embodiment of the application can be realized by adopting various computer languages, such as object-oriented programming language Java, an transliteration script language JavaScript and the like.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While preferred embodiments of the present application have been described, additional variations and modifications in those embodiments may occur to those skilled in the art once they learn of the basic inventive concepts. It is therefore intended that the following claims be interpreted as including the preferred embodiments and all such alterations and modifications as fall within the scope of the application.
It will be apparent to those skilled in the art that various modifications and variations can be made to the present application without departing from the spirit or scope of the application. Thus, it is intended that the present application also include such modifications and alterations insofar as they come within the scope of the appended claims or the equivalents thereof.

Claims (9)

1. The method for positioning the communication link fault of the terminal of the Internet of things based on the flow characteristics is characterized by comprising the following steps:
s1, capturing a flow data packet uploaded by equipment on a server to obtain flow data packet information, wherein the flow data packet information comprises a client and a server IP, a port, time and length;
S2, classifying the obtained flow data packet information according to the equipment positions and types, and constructing a flow data time sequence data set consisting of flow data time sequences of various equipment and characteristic labels corresponding to the various equipment;
S3, constructing a flow time sequence feature library of the terminal equipment according to the flow data time sequence data set;
S4, calculating the shortest distance between the time sequence of the flow data transmitted in the running process of the terminal equipment and the time sequence characteristic;
S5, comparing the calculated shortest distance with a set distance threshold value, and judging whether the data transmission process of the current equipment is normal or not;
S6, if the transmission process of the current equipment is abnormal, selecting a grabbing node on a transmission link between the equipment and the application to grab equipment messages, and analyzing the messages by using a message analysis program;
s7, analyzing and obtaining a communication link fault point between the equipment and the application by comparing the analysis message content of the grabbing node.
2. The method for locating the communication link failure of the terminal of the internet of things based on the flow characteristics according to claim 1, wherein the step S2 specifically comprises the steps of:
S21, constructing a flow data time sequence of single-class equipment as S= { S 1,s2,…,sT }, wherein T represents the length of the time sequence, namely the frequency of uploading data by the equipment, and S 1,s2,…,sT is the flow data size arranged according to the time sequence;
s22, a flow data time sequence data set consisting of flow data time sequences of various devices and corresponding feature labels of the various devices:
W={(S1,c1),…,(Sn,cn),…,(SN,cN)}
wherein S n represents a traffic data time sequence of the nth class device, and c n represents a feature tag of the nth class device.
3. The method for locating the communication link failure of the terminal of the internet of things based on the flow characteristics according to claim 2, wherein the step S3 specifically includes the steps of:
S31, constructing a candidate time sequence feature set: for the nth class device, selecting a candidate feature set, denoted as p n={pn,1,…,pn,l,…,pn,L, in its traffic data time series S n, where K min≤k≤kmax, the set of candidate timing features for all devices can be represented as p= { P 1,p2,…,pN }, where k represents the length of the candidate feature; l represents the first candidate feature of the nth class device;
S32, dividing the device flow time sequence into subsequences with equal length: dividing the flow data time sequence S n of the nth class device into subsequences with the length of k, wherein the subsequence set can be represented as S n.k={s1,k,s2,k,…,si,k,…,sT-k+1,k, and the subsequences S i,k={si,si+1,…si+k-1;
S33, calculating the residual square sum of the candidate time sequence feature set and the subsequence: calculating the sum of squares of residuals between all candidate feature sequences and sub-sequences of length k, and the set of sum squares of sub-sequence residuals of length k for the nth class of devices can be expressed as:
dn,k={d(pn,l,s1,k),…,d(pn,l,si,k),…,d(pn,l,sT-k+1,k)},
Wherein, Representing the i th residual square sum, the candidate feature sequence and subsequence residual square sum set of the n-th device is
S34, calculating a characteristic evaluation value of the candidate characteristic sequence to obtain a device flow time sequence characteristic library: calculating the feature evaluation capability of all candidate feature sequences of the nth class of equipment, selecting the candidate feature sequence with the largest evaluation value G n,l as the flow time sequence feature q n of the current equipment, wherein the specific calculation formula is as follows:
Wherein, Represents the average of all data within set D n,Representing the average of all data within set d n,k, the traffic timing feature library q= { Q 1,…,qn,…,qN } for all devices.
4. The method for locating a communication link failure of an internet of things terminal based on a traffic characteristic according to claim 3, wherein the step S4 specifically includes the steps of:
S41, calculating Euclidean distance between the two points a i and q n,j, namely D i,j=|ai-qn,j I, and obtaining a distance matrix D with the size of (m, L), wherein the distance matrix D is specifically expressed as:
Wherein a i is the ith time point in the flow data time sequence A= { a 1,a2,…,am } to be judged, and q n,j is the jth time sequence feature in the time sequence feature sequence q n={qn,1,qn,2,…,qn,L };
S42, searching a path R from d 1,1 to d m,L in a distance matrix, wherein R=R 1,R2,…,Rk,…,RK, and R k=(i,j)k, max (m, L) is more than or equal to K and less than or equal to m+L-1;
s43, obtaining a shortest path in a dynamic iteration mode, wherein a specific recursion formula is as follows:
r(i,j)=di,j+min{r(i-1,j-i),r(i-1,j),r(i,j-1)};
S44, calculating the shortest distance between the flow data time sequence A and the time sequence characteristic sequence q n:
5. the method for locating a communication link fault of an internet of things terminal based on a traffic characteristic according to claim 1, wherein in step S6, the grabbing node comprises a network firewall, an internet of things management platform and a data forwarding server.
6. The method for locating the communication link failure of the terminal of the internet of things based on the traffic characteristics according to claim 5, wherein the step S7 specifically includes the steps of:
S71, if a few of the equipment information is missing in three data messages and the other most of the equipment is normal, judging that the APN card flow of the current equipment is used up or the equipment fails;
s72, if all the equipment information in the three data messages is missing, judging that the base station of the network operator is faulty;
S73, if the data message information collected at the network firewall is normal, but the information at the Internet of things management platform is missing, judging that the network firewall policy is due;
And S74, if the data message information collected by the network firewall and the Internet of things management platform are normal, but the equipment message information collected by the northbound server is missing, judging that the data forwarding server fails.
7. The utility model provides a thing networking terminal communication link fault location device based on flow characteristic which characterized in that includes:
The flow data packet information acquisition module is used for capturing flow data packets uploaded by the equipment on the server to acquire flow data packet information, wherein the flow data packet information comprises a client and a server IP, a port, time and a length;
the flow data time sequence data set construction module is used for classifying the obtained flow data packet information according to the equipment positions and types and constructing a flow data time sequence data set consisting of flow data time sequences of various equipment and characteristic labels corresponding to the various equipment;
the flow time sequence feature library construction module is used for constructing a flow time sequence feature library of the terminal equipment according to the flow data time sequence data set;
the shortest distance calculation module is used for calculating the shortest distance between the flow data time sequence and the time sequence characteristics transmitted in the operation process of the terminal equipment;
The judging module is used for comparing the calculated shortest distance with a set distance threshold value and judging whether the data transmission process of the current equipment is normal or not;
The device message grabbing and analyzing module is used for selecting grabbing nodes to grab device messages on a transmission link between the device and the application if the transmission process of the current device is abnormal, and analyzing the messages by using a message analyzing program;
and the fault point analysis module is used for analyzing and obtaining the fault point of the communication link between the equipment and the application by comparing the analysis message content of the grabbing node.
8. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that,
The steps of the method for positioning the communication link fault of the terminal of the internet of things based on the flow characteristics according to any one of claims 1 to 6 are realized when the processor executes the program.
9. A storage medium comprising a stored program which, when run, controls a device in which the storage medium is located to perform the steps of the method for locating a communication link failure of an internet of things terminal based on traffic characteristics according to any one of claims 1 to 6.
CN202211400644.0A 2022-11-09 2022-11-09 Internet of things terminal communication link fault positioning method based on flow characteristics Active CN115714717B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211400644.0A CN115714717B (en) 2022-11-09 2022-11-09 Internet of things terminal communication link fault positioning method based on flow characteristics

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211400644.0A CN115714717B (en) 2022-11-09 2022-11-09 Internet of things terminal communication link fault positioning method based on flow characteristics

Publications (2)

Publication Number Publication Date
CN115714717A CN115714717A (en) 2023-02-24
CN115714717B true CN115714717B (en) 2024-08-09

Family

ID=85232706

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211400644.0A Active CN115714717B (en) 2022-11-09 2022-11-09 Internet of things terminal communication link fault positioning method based on flow characteristics

Country Status (1)

Country Link
CN (1) CN115714717B (en)

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112564964A (en) * 2020-12-04 2021-03-26 中国石油大学(华东) Fault link detection and recovery method based on software defined network

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9203740B2 (en) * 2013-07-18 2015-12-01 Globalfoundries Inc. Automated network fault location
US10348554B2 (en) * 2016-04-25 2019-07-09 Cisco Technology, Inc. Hybrid fibre coaxial fault locationing in cable network environments

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112564964A (en) * 2020-12-04 2021-03-26 中国石油大学(华东) Fault link detection and recovery method based on software defined network

Also Published As

Publication number Publication date
CN115714717A (en) 2023-02-24

Similar Documents

Publication Publication Date Title
CN109587008B (en) Method, device and storage medium for detecting abnormal flow data
CN111541661A (en) Power information network attack scene reconstruction method and system based on causal knowledge
CN113489619B (en) Network topology inference method and device based on time series analysis
CN112615888B (en) Threat assessment method and device for network attack behavior
CN111181923A (en) Flow detection method and device, electronic equipment and storage medium
CN112463422A (en) Internet of things fault operation and maintenance method and device, computer equipment and storage medium
CN112165484A (en) Network encryption traffic identification method and device based on deep learning and side channel analysis
CN113935426A (en) Method and device for detecting abnormal data traffic of power internet of things
CN115396204A (en) Industrial control network flow abnormity detection method and device based on sequence prediction
CN116032602A (en) Method, device, equipment and storage medium for automatically identifying threat data
Ramírez et al. Explainable machine learning for performance anomaly detection and classification in mobile networks
CN115714717B (en) Internet of things terminal communication link fault positioning method based on flow characteristics
CN117729027A (en) Abnormal behavior detection method, device, electronic equipment and storage medium
CN117389779A (en) Micro-service fault root cause positioning method
CN117319258A (en) Method, device, equipment and storage medium for detecting node abnormality of edge X
CN116405261A (en) Malicious flow detection method, system and storage medium based on deep learning
Whalen et al. Hidden markov models for automated protocol learning
CN113285977B (en) Network maintenance method and system based on block chain and big data
CN108055149A (en) End-to-end Traffic Anomaly feature extracting method in a kind of Time and Frequency Synchronization application
CN116401604B (en) Method for classifying and detecting cold head state and predicting service life
CN112954689A (en) Lightweight network intrusion detection system and method for Bluetooth wireless transmission
CN118199911A (en) Method and system for detecting abnormal service of 5G core network control plane network element
CN118632275A (en) Method and device for detecting abnormality of signaling link, electronic equipment and storage medium
CN117376205A (en) Power communication network abnormality detection method, device, electronic equipment and storage medium
CN118764292A (en) Electric power vulnerability positioning method, device, equipment and medium based on vulnerability fingerprint

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