Monitoring variable frequency sampling method, device, system and storage medium
By monitoring the mutation detection and dynamic threshold adjustment at the agent end, the problems of resource waste and untimely monitoring in frequency conversion sampling of the monitoring system are solved, and efficient mutation analysis and resource saving are achieved.
Patent Information
- Application Number
- CN202111578516.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-12-22
- Publication Date
- 2026-01-13
- Estimated Expiration
- 2041-12-22
AI Technical Summary
Existing monitoring systems lack optimization solutions for frequency conversion sampling technology, resulting in the inability to monitor changes in the status of target objects in a timely manner or excessive consumption of resources.
By acquiring sampling data of the monitored objects through the monitoring agent, mutation detection is performed, and sampling data before and after the mutation is sent in real time. The data is then combined with differential values and dynamically updated thresholds for monitoring, and the sampling frequency is flexibly adjusted to reduce resource waste.
It improves the real-time performance and accuracy of mutation analysis, reduces resource consumption, and optimizes the efficiency and accuracy of frequency conversion sampling.
Smart Images

Figure CN114443416B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of monitoring technology, specifically to a monitoring frequency conversion sampling method, device, system, and storage medium. Background Technology
[0002] Monitoring systems typically deploy monitoring agents on the monitored servers or terminals to collect status information of specified monitored items, such as performance metrics of the Central Processing Unit (CPU), memory, hard disk, and network, to monitor the operational status of the target object. When the operational status changes abruptly, i.e., a significant increase or decrease occurs within a short period of time, it may indicate that the target object is malfunctioning.
[0003] Currently, monitoring systems typically collect data at preset fixed time intervals. If the set time interval is too long, it is impossible to monitor changes in the status of the target object in a timely manner; if the set time interval is too short, a large amount of similar data will be collected when the operating status is stable, excessively consuming terminal network resources and server storage resources.
[0004] Therefore, the monitoring system can use frequency conversion sampling technology to monitor the operating status of the target object, but there is currently no better optimization solution for the monitoring system using frequency conversion sampling. Summary of the Invention
[0005] In view of this, embodiments of the present invention provide a method, device, system and storage medium for monitoring frequency conversion sampling, in order to solve the problem that there is currently no better optimization solution for monitoring systems for frequency conversion sampling.
[0006] According to a first aspect, embodiments of the present invention provide a method for monitoring frequency conversion sampling, the method being used for monitoring an agent, comprising:
[0007] The first sampled data to be detected is obtained. The first sampled data is the first-level sampled data obtained by the monitoring agent after sampling the monitored object according to the set first-level sampling time interval.
[0008] Based on the first sampled data, a sudden change detection is performed on the operating status of the monitored object to obtain the sudden change detection result;
[0009] If the mutation detection result is determined to be a mutation, then the second sampling data before the mutation occurred is obtained, and the second sampling data and the first sampling data are sent to the monitoring server.
[0010] The second sampled data is the first-level sampled data obtained by the monitoring agent after sampling within a first set time period before the sudden change in the running state of the monitored object, according to the set first-level sampling time interval. The first set time is determined according to the set first-level sampled data queue length.
[0011] In this embodiment of the application, when a mutation is detected in real time, the second sampling data before the mutation occurs and the first sampling data of the mutation can be sent to the monitoring server. In this way, the monitoring server can perform mutation analysis based on the second sampling data before the mutation occurs and the first sampling data of the mutation, thereby improving the real-time performance and accuracy of mutation analysis.
[0012] In conjunction with the first aspect, in the first embodiment of the first aspect, after sending the second sampling data and the first sampling data to the monitoring server, the method further includes:
[0013] Obtain the third sampling data after the mutation occurs, and send the third sampling data to the monitoring server;
[0014] The third sampling data is the first-level sampling data obtained by the monitoring agent after sampling within a second set time period following a sudden change in the operating state of the monitored object, according to the set first-level sampling time interval. The second set time is determined according to the set number of times the first-level sampling is sent after the sudden change occurs.
[0015] In this embodiment, after a mutation is detected in real time, the third sampling data after the mutation is detected needs to be sent to the monitoring server. This helps the monitoring server to perform mutation analysis and further improves the accuracy of mutation analysis.
[0016] In conjunction with the first aspect, the second embodiment of the first aspect further includes:
[0017] If it is determined that the mutation detection result is that no mutation has occurred, and the first sampling data does not belong to the first-level sampling data to be sent according to the set number of times after the mutation occurs, then the second-level sampling data is obtained and sent to the monitoring server.
[0018] The secondary sampling data is the average value of the primary sampling data within a set interval obtained by the monitoring agent after performing secondary sampling on the primary sampling data according to the set secondary sampling window width. The secondary sampling window width is greater than the primary sampling time interval.
[0019] In this embodiment of the application, when no mutation is detected in real time and it does not fall within the number of times the first-level sampling is sent after a mutation occurs, second-level sampling can be performed and the second-level sampling data can be sent to the monitoring server. This can avoid the waste of resources caused by collecting a large amount of similar data.
[0020] In conjunction with the first aspect, in the third embodiment of the first aspect, the step of performing abrupt change detection on the operating state of the monitored object based on the first sampling data includes:
[0021] Calculate the one-step difference between the first sampled data and the previous level sampled data of the first sampled data;
[0022] If the step difference value is greater than or equal to the mutation detection threshold, then the mutation detection result is determined to be a mutation.
[0023] If the step difference value is less than the mutation detection threshold, then the mutation detection result is determined to be no mutation.
[0024] In this embodiment, whether a mutation has occurred can be determined by a one-step difference value and a mutation detection threshold, thereby improving the accuracy of mutation detection.
[0025] In conjunction with the first aspect or the third embodiment of the first aspect, the fourth embodiment of the first aspect further includes:
[0026] If it is determined that no mutation has occurred, another mutation detection threshold is calculated based on the first sampling data, and the mutation detection threshold used for mutation detection is updated using the other mutation detection threshold.
[0027] In this embodiment, if no mutation is detected in real time, the mutation detection threshold can be dynamically updated. This allows the mutation detection threshold to be adjusted accordingly based on the sampled data, thereby avoiding the possibility of mutations occurring even if the threshold is not exceeded, and improving the accuracy of mutation detection.
[0028] In conjunction with the first aspect or the third embodiment of the first aspect, the fifth embodiment of the first aspect further includes:
[0029] Obtain fourth sampling data for mutation detection initialization, wherein the fourth sampling data is first-level sampling data obtained by the monitoring agent after sampling the monitored object according to the set first-level sampling time interval;
[0030] The initial value of the mutation detection threshold for mutation detection is calculated based on the fourth sampled data.
[0031] In this embodiment of the application, during the initialization of mutation detection, the initial value of the mutation detection threshold can be determined by sampling first-level sampling data according to the set first-level sampling time interval, thereby improving the reliability of the mutation detection threshold.
[0032] In conjunction with the first aspect or the third embodiment of the first aspect, the sixth embodiment of the first aspect further includes:
[0033] Receive monitoring parameters sent by the monitoring server, wherein the monitoring parameters include one or more of the following:
[0034] First-level sampling time interval;
[0035] Secondary sampling window width;
[0036] Length of the primary sampling data queue;
[0037] The number of times a primary sampling is sent after a mutation occurs.
[0038] In this embodiment, the monitoring agent can receive monitoring parameters sent by the monitoring server and perform mutation detection initialization, first-level sampling, second-level sampling, mutation detection, etc. through these parameters, thereby improving the efficiency of frequency conversion sampling in monitoring.
[0039] According to a second aspect, embodiments of the present invention provide a monitoring agent device, including: a memory and a processor, wherein the memory and the processor are communicatively connected to each other, the memory stores computer instructions, and the processor executes the computer instructions to perform the monitoring frequency conversion sampling method described in the first aspect or any embodiment of the first aspect.
[0040] According to a second aspect, embodiments of the present invention provide a monitoring frequency conversion sampling system, characterized in that the system includes: a monitoring agent and a monitoring server; wherein the monitoring agent is used to execute the monitoring frequency conversion sampling method described in the first aspect or any embodiment of the first aspect.
[0041] According to a fourth aspect, embodiments of the present invention provide a computer-readable storage medium storing computer instructions for causing the computer to perform the monitoring frequency conversion sampling method described in the first aspect or any embodiment of the first aspect. Attached Figure Description
[0042] The features and advantages of the invention will be more clearly understood by referring to the accompanying drawings, which are schematic and should not be construed as limiting the invention in any way. In the drawings:
[0043] Figure 1 A flowchart of a method for monitoring frequency conversion sampling is shown.
[0044] Figure 2 A schematic diagram of the architecture of a frequency conversion sampling monitoring system is shown.
[0045] Figure 3 A flowchart of another method for monitoring frequency conversion sampling is shown.
[0046] Figure 4 A flowchart of another method for monitoring frequency conversion sampling is shown.
[0047] Figure 5 A flowchart of another method for monitoring frequency conversion sampling is shown.
[0048] Figure 6 A schematic diagram of a monitoring agent terminal device is shown. Detailed Implementation
[0049] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0050] Figure 1 A flowchart of a frequency conversion sampling monitoring method is shown. This frequency conversion sampling method can be used on a monitoring agent. For example, a frequency conversion sampling monitoring system typically deploys a monitoring agent on the monitored server or terminal to collect status information of specified monitoring items, such as performance indicators of CPU, memory, hard disk, and network, to monitor the operating status of the target object. Figure 1 As shown, the frequency conversion sampling method for monitoring includes:
[0051] Step 101: Obtain the first sampled data to be detected. This first sampled data is the first-level sampled data obtained by the monitoring agent after sampling the monitored object according to the set first-level sampling time interval.
[0052] Specifically, the monitored objects can be performance indicators such as CPU, memory, hard drive, and network.
[0053] The first-level sampling time interval (i.e., T) can be preset; or it can be set by the monitoring server in the frequency conversion sampling system and sent to the monitoring agent.
[0054] Step 102: Perform a mutation detection on the operating status of the monitored object based on the first sampling data to obtain the mutation detection result.
[0055] Specifically, the operational status of the monitored object may undergo a sudden change or it may not undergo a sudden change.
[0056] Step 103: If the mutation detection result is determined to be a mutation, then obtain the second sampling data before the mutation occurred, and send the second sampling data and the first sampling data to the monitoring server.
[0057] The second sampling data is the first-level sampling data obtained by the monitoring agent after sampling within a first set time period before the running status of the monitored object changes abruptly, according to the set first-level sampling time interval. The first set time period is determined according to the set first-level sampling data queue length.
[0058] Specifically, the length of the primary sampling data queue (i.e., q) can be preset or set by the monitoring server in the frequency conversion sampling system and sent to the monitoring agent.
[0059] In this embodiment of the application, when a mutation is detected in real time, the second sampling data before the mutation occurs and the first sampling data of the mutation can be sent to the monitoring server. In this way, the monitoring server can perform mutation analysis based on the second sampling data before the mutation occurs and the first sampling data of the mutation, thereby improving the real-time performance and accuracy of mutation analysis.
[0060] In an optional embodiment, after performing step 103, the following may also be included:
[0061] Obtain the third sampling data after the mutation occurs, and send the third sampling data to the monitoring server;
[0062] The third sampling data is the first-level sampling data obtained by the monitoring agent after sampling within a second set time period following a sudden change in the running status of the monitored object, according to a set first-level sampling time interval. The second set time is determined according to the set number of times the first-level sampling is sent after the sudden change occurs.
[0063] Specifically, the number of times (M) a primary sampling is sent after the mutation occurs can be pre-set; or it can be set by the monitoring server and sent to the monitoring agent.
[0064] In this embodiment of the application, after a mutation is detected in real time, the third sampling data after the mutation is detected also needs to be sent to the monitoring server. This helps the monitoring server to perform mutation analysis and further improves the accuracy of mutation analysis.
[0065] In an optional embodiment, after performing step 102, the following may also be included:
[0066] If the mutation detection result is determined to be no mutation, and the first sampling data does not belong to the number of times the first-level sampling is sent after the mutation occurs, and the first-level sampling data is determined to be sent, then the second-level sampling data is obtained and sent to the monitoring server.
[0067] The secondary sampling data is the average value of the primary sampling data within a set interval obtained by the monitoring agent after performing secondary sampling on the primary sampling data according to the set secondary sampling window width. The secondary sampling window width is greater than the primary sampling time interval.
[0068] Specifically, the width of the secondary sampling window (i.e., w) can be preset; or it can be set by the monitoring server and sent to the monitoring agent.
[0069] The width of the secondary sampling window (w) can be n times the primary sampling time interval (T). For example, n is a positive integer greater than or equal to 3.
[0070] It is worth noting that if the width of the secondary sampling window is greater than the time interval of the primary sampling, the primary sampling is a high-frequency sampling and the secondary sampling is a low-frequency sampling compared to the primary sampling.
[0071] In this embodiment of the application, when no mutation is detected in real time and it does not fall within the number of times the first-level sampling continues after the mutation occurs, second-level sampling can be performed and the second-level sampling data can be sent to the monitoring server. This can avoid the waste of resources caused by collecting a large amount of similar data.
[0072] In an optional embodiment, step 102 can be implemented in ways not limited to the following:
[0073] 1-1. Calculate the first sampled data (i.e., x) i ), and the previous level of sampling data of the first sampling data (i.e., x) i-1 The one-step difference value (i.e., d) between ).
[0074] 1-2. If the one-step difference value (i.e., d) is greater than or equal to the mutation detection threshold (i.e., h), then the mutation detection result is determined to be a mutation.
[0075] 1-3. If the one-step difference value (i.e., d) is less than the mutation detection threshold (i.e., h), then the mutation detection result is determined to be that no mutation has occurred.
[0076] Specifically, the calculation process for the one-step difference value is as follows: d=|x i -x i-1 |
[0077] In this embodiment, whether a mutation has occurred can be determined by using a one-step difference value and a mutation detection threshold, thereby improving the accuracy of mutation detection.
[0078] In an optional embodiment, the monitoring frequency conversion sampling method may further include:
[0079] If the mutation detection result is determined to be no mutation, then another mutation detection threshold is calculated based on the first sampling data, and the mutation detection threshold used for mutation detection is updated using the other mutation detection threshold.
[0080] Specifically, the specific implementation process of calculating another mutation detection threshold based on the first sampling data is similar to that described in 2-1 to 2-4 below, and will not be repeated here.
[0081] In this embodiment, if no mutation is detected in real time, the mutation detection threshold can be dynamically updated. In this way, the mutation detection threshold can be adjusted accordingly based on the sampled data, thereby avoiding the situation where mutations may occur even if the threshold is not exceeded, and improving the accuracy of mutation detection.
[0082] In an optional embodiment, the monitoring frequency conversion sampling method may further include:
[0083] Obtain the fourth sampling data used for mutation detection initialization. The fourth sampling data is the first-level sampling data obtained by the monitoring agent after sampling the monitored object according to the set first-level sampling time interval.
[0084] The initial value of the mutation detection threshold is calculated based on the fourth sampling data.
[0085] Specifically, if the fourth sampled data is [x1, x2, ..., x...] n The specific implementation process for calculating the initial value of the mutation detection threshold includes:
[0086] 2-1. Calculate [x1, x2, ..., x] n Given the first quartile Q1 of [x1, x2, ..., x], calculate [x1, x2, ..., x]. n The third quartile Q3 of the [].
[0087] 2-2. Calculate the difference Q3 between the third quartile Q1 and the first quartile to obtain the interquartile range (IQR).
[0088] 2-3. Obtain [x1, x2, ..., x n The maximum value x in ] max and minimum value x min Calculate the difference between the two to obtain the range (RG).
[0089] 2-4. Determine the initial value of the mutation detection threshold h based on the interquartile range (IQR) and range (RG). That is:
[0090]
[0091] In this embodiment of the application, during the initialization of mutation detection, the initial value of the mutation detection threshold can be determined by sampling first-level sampling data according to the set first-level sampling time interval, thereby improving the reliability of the mutation detection threshold.
[0092] In an optional embodiment, the monitoring frequency conversion sampling method may further include:
[0093] Receive monitoring parameters sent by the monitoring server, which include one or more of the following:
[0094] The first-level sampling time interval (i.e., T);
[0095] The width of the secondary sampling window (i.e., w);
[0096] The length of the first-level sampling data queue (i.e., q);
[0097] The number of times (M) a first-level sample is sent after a mutation occurs.
[0098] In this embodiment, the monitoring agent can receive monitoring parameters sent by the monitoring server and perform mutation detection initialization, first-level sampling, second-level sampling, mutation detection, etc. through these parameters, thereby improving the efficiency of frequency conversion sampling in monitoring.
[0099] The following two specific examples illustrate the detailed implementation process of the above-mentioned frequency conversion sampling monitoring.
[0100] Example 1: Monitoring a frequency converter sampling system, such as Figure 2 As shown.
[0101] like Figure 2 As shown, the frequency conversion sampling monitoring system includes a frequency conversion sampling server (i.e., Server) and a frequency conversion sampling agent (i.e., Agent). The frequency conversion sampling server is referred to as the monitoring server, and the frequency conversion sampling agent is referred to as the monitoring agent.
[0102] The monitoring server includes a data transmission module, a data storage module, a parameter configuration module, and an interactive interface module.
[0103] The first data transmission module is used for network communication and data transmission between the monitoring server and the monitoring agent, including sending configuration parameters to the monitoring agent and receiving sampled data from the monitoring agent.
[0104] The data storage module is used to store configuration parameters, primary sampling data, and secondary sampling data;
[0105] The interactive interface module is used to input configuration parameters and display sampled data;
[0106] The parameter configuration module is used to manage and configure the monitoring items of the monitoring agent, the first-level sampling time interval, the second-level sampling window width, the sampling data queue length, and the number of times the first-level sampling is sent after a mutation occurs.
[0107] The monitoring agent includes a primary sampling module, a data caching module, a secondary sampling module, a mutation analysis module, and a secondary data transmission module.
[0108] The primary sampling module samples the specified monitoring items according to the set primary sampling time interval.
[0109] The data caching module establishes a sampled data cache based on the set sampled data queue length;
[0110] The mutation analysis module is used to initialize and dynamically update mutation detection thresholds;
[0111] The secondary sampling module resamples the primary sampling data (i.e., secondary sampling) according to the set secondary sampling window width to obtain the mean of the primary sampling data (i.e., secondary sampling data) within the specified interval;
[0112] The second data transmission module is used for network communication and data transmission between the monitoring agent and the monitoring server, receiving configuration parameters from the monitoring server and sending sampling data to the monitoring server.
[0113] Example 2: Interaction between the monitoring server and the monitoring agent, such as... Figure 3 As shown.
[0114] Step 1: Select the monitoring item on the monitoring server and set the parameters.
[0115] Specifically, the parameters that need to be configured on the monitoring server include:
[0116] The first-level sampling time interval (i.e., T);
[0117] The width of the secondary sampling window w = n × T, where n is a positive integer and n ≥ 3, representing the number of primary sampling points within the secondary sampling window;
[0118] The length of the primary sampling data queue (i.e., q) is used to temporarily store primary sampling data, and can store a maximum of q primary sampling data, where q≥n;
[0119] After a mutation occurs, high-frequency sampling (i.e., single sampling) is sent for a duration of m = M, where M ≥ n. Here, single sampling is considered high-frequency compared to double sampling, while double sampling is low-frequency.
[0120] Step 2: Monitor the agent's sampling initialization, perform first-level sampling, and complete the initialization of mutation detection. The main initialization process is as follows: Figure 4 As shown, it includes the following sub-steps:
[0121] Step 2.1: Initialize the first-level sampling counter C = 0, and initialize the first-level sampling data queue Q (maximum value = q) of length q and the data queue X of length n;
[0122] Step 2.2: Sample the monitored object at time intervals T. For each additional sampling point, increment the first-level sampling counter C by 1 and add the sampled data to queues Q and X.
[0123] Step 2.3: Determine if the counter C is n. If it is not n, repeat steps 2.2 to 2.3. When the counter C is n, reset C to 0. At this time, the data queue X is X = [x1, x2, ..., x...]. n ];
[0124] Step 2.4: Calculate the mutation detection threshold h using queue X. The calculation method is as follows:
[0125] Calculate [x1, x2, ..., x n The first quartile Q1;
[0126] Calculate [x1, x2, ..., x n The third quartile Q3;
[0127] Calculate the difference Q3 between the third quartile Q1 and the first quartile to obtain the interquartile range (IQR), which is:
[0128] IQR = Q3 - Q1
[0129] Get [x1, x2, ..., x n The maximum value x in ] max and minimum value x min Calculate the difference between the two to obtain the range (RG), which is:
[0130] RG = x max -x min
[0131] The initial value h of the mutation detection threshold is determined based on the interquartile range (IQR) and the range (RG). That is:
[0132]
[0133] Step 3: After the monitoring agent completes sampling and mutation detection initialization, it performs primary sampling, secondary sampling, and mutation detection. Based on the mutation detection results, it sends sampling data at different sampling frequencies to the monitoring server. The process is as follows: Figure 4 As shown, it includes the following sub-steps:
[0134] Step 3.1: Sample the specified monitoring item (i.e., the monitoring object) according to the first-level sampling time interval T to obtain the latest sampling data x. i and x i Add data to queues Q and X;
[0135] Step 3.2: Increment the first-level sampling counter C by 1, and check if the first-level sampling counter C is n. If C equals n, reset C to 0.
[0136] Step 3.3, calculate the current first-level sampled data x i And the previous level of sampling data x i-1 One-step difference: d=|x i -x i-1 | If d ≥ h, it indicates a mutation has occurred, proceed to step 3.4; otherwise, proceed to step 3.5;
[0137] Step 3.4: Set the duration m of high-frequency sampling (i.e., one sampling) to M, send all first-level sampling data in data queue Q to the monitoring server, and clear queue Q at the same time; repeat steps 3.1 to 3.3.
[0138] Step 3.5: Determine if m is 0. If not, m = m - 1, send the sampled data in data queue Q to the monitoring server, and clear queue Q. If m is 0, check if C is 0. If C is 0, calculate the mean of the n primary sampling points in queue X and send it as secondary sampling data to the monitoring server. The mean is:
[0139]
[0140] Step 3.6: Calculate the new mutation detection threshold using queue X according to the method described in step 2, and update the value of h; repeat steps 3.1 to 3.3.
[0141] As can be seen from the above embodiments:
[0142] (1) When the operating status of a monitored object undergoes a short-term abrupt change, the amplitude of the relevant monitoring indicators may not exceed the set alarm threshold, but the sudden change in operating status usually contains key event information. Compared with the method of changing the sampling frequency according to the amplitude, the present invention can change the sampling frequency for sudden rise or fall scenarios;
[0143] (2) Compared with the method of changing the sampling frequency after the event occurs, the present invention performs high-frequency primary sampling and low-frequency secondary sampling at the monitoring agent end. When the running status does not meet the triggering condition (i.e. less than the mutation detection threshold), secondary sampling data is sent; when the condition is met (i.e. greater than or equal to the mutation detection threshold), primary sampling data is sent, and high-frequency primary sampling data cached in the queue is resent. This can reduce bandwidth consumption and data redundancy at the monitoring server, and can also obtain high-frequency sampling data before the mutation occurs.
[0144] (3) By setting the length of the cached data queue and the number of high-frequency samplings (i.e., one sampling) in the sampling process, the duration of high-frequency sampling before and after the mutation can be flexibly adjusted.
[0145] (4) This invention makes up for the lack of frequency conversion sampling methods in sudden change scenarios. When combined with frequency conversion sampling methods based on fixed threshold detection amplitude, it can more comprehensively cover frequency conversion sampling scenarios in the monitoring field.
[0146] Figure 6 A schematic diagram of a monitoring agent device is shown. Figure 6 As shown, the electronic device may include: a processor 610, a communication interface 620, a memory 630, and a communication bus 640, wherein the processor 610, the communication interface 620, and the memory 630 communicate with each other through the communication bus 640. The processor 610 can call logical instructions in the memory 630 to execute a monitoring frequency conversion sampling method, which includes:
[0147] The first sampled data to be detected is obtained. The first sampled data is the first-level sampled data obtained by the monitoring agent after sampling the monitored object according to the set first-level sampling time interval.
[0148] Based on the first sampled data, a sudden change detection is performed on the operating status of the monitored object to obtain the sudden change detection result;
[0149] If the mutation detection result is determined to be a mutation, then the second sampling data before the mutation occurred is obtained, and the second sampling data and the first sampling data are sent to the monitoring server.
[0150] The second sampled data is the first-level sampled data obtained by the monitoring agent after sampling within a first set time period before the sudden change in the running state of the monitored object, according to the set first-level sampling time interval. The first set time is determined according to the set first-level sampled data queue length.
[0151] Furthermore, the logical instructions in the aforementioned memory 630 can be implemented as software functional units and, when sold or used as independent products, can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, essentially, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0152] It should be noted that the monitoring agent device provided in this application embodiment can implement all the method steps implemented in the above method embodiment and can achieve the same technical effect. Here, the parts that are the same as those in the method embodiment and the beneficial effects will not be described in detail.
[0153] On the other hand, the present invention also provides a computer program product, the computer program product comprising a computer program stored on a non-transitory computer-readable storage medium, the computer program comprising program instructions, wherein when the program instructions are executed by a computer, the computer is able to execute the monitoring frequency conversion sampling method provided by the above methods, the method comprising:
[0154] The first sampled data to be detected is obtained. The first sampled data is the first-level sampled data obtained by the monitoring agent after sampling the monitored object according to the set first-level sampling time interval.
[0155] Based on the first sampled data, a sudden change detection is performed on the operating status of the monitored object to obtain the sudden change detection result;
[0156] If the mutation detection result is determined to be a mutation, then the second sampling data before the mutation occurred is obtained, and the second sampling data and the first sampling data are sent to the monitoring server.
[0157] The second sampled data is the first-level sampled data obtained by the monitoring agent after sampling within a first set time period before the sudden change in the running state of the monitored object, according to the set first-level sampling time interval. The first set time is determined according to the set first-level sampled data queue length.
[0158] In another aspect, the present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, is implemented to perform the aforementioned monitoring frequency conversion sampling methods, the method comprising:
[0159] The first sampled data to be detected is obtained. The first sampled data is the first-level sampled data obtained by the monitoring agent after sampling the monitored object according to the set first-level sampling time interval.
[0160] Based on the first sampled data, a sudden change detection is performed on the operating status of the monitored object to obtain the sudden change detection result;
[0161] If the mutation detection result is determined to be a mutation, then the second sampling data before the mutation occurred is obtained, and the second sampling data and the first sampling data are sent to the monitoring server.
[0162] The second sampled data is the first-level sampled data obtained by the monitoring agent after sampling within a first set time period before the sudden change in the running state of the monitored object, according to the set first-level sampling time interval. The first set time is determined according to the set first-level sampled data queue length.
[0163] Furthermore, the present invention also provides a monitoring frequency conversion sampling system, the system comprising: a monitoring agent (such as...) Figure 2 The monitoring agent and monitoring server (such as the monitoring agent) and the monitoring server (such as the monitoring agent) Figure 2 The monitoring agent is used to execute the frequency conversion sampling method in the above embodiments.
[0164] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.
[0165] Through the above description of the embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in the various embodiments or some parts of the embodiments.
[0166] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method for monitoring frequency conversion sampling, characterized in that, The method is used to monitor the proxy end, including: The first sampled data to be detected is obtained. The first sampled data is the first-level sampled data obtained by the monitoring agent after sampling the monitored object according to the set first-level sampling time interval. Based on the first sampled data, a sudden change detection is performed on the operating status of the monitored object to obtain the sudden change detection result; If the mutation detection result is determined to be a mutation, then the second sampling data before the mutation occurred is obtained, and the second sampling data and the first sampling data are sent to the monitoring server. The second sampling data is first-level sampling data obtained by the monitoring agent after sampling at the set first-level sampling time interval within a first set time period before the running state of the monitored object changes abruptly. The first set time period is determined according to the set first-level sampling data queue length. After sending the second sampling data and the first sampling data to the monitoring server, the third sampling data after the mutation occurs is obtained, and the third sampling data is sent to the monitoring server. The third sampling data is the first-level sampling data obtained by the monitoring agent after sampling within a second set time period following a sudden change in the running state of the monitored object, according to the set first-level sampling time interval. The second set time is determined according to the set number of times the first-level sampling is sent after the sudden change occurs. If it is determined that the mutation detection result is that no mutation has occurred, and the first sampling data does not belong to the first-level sampling data to be sent according to the set number of times after the mutation occurs, then the second-level sampling data is obtained and sent to the monitoring server. The secondary sampling data is the average value of the primary sampling data within a set interval obtained by the monitoring agent after performing secondary sampling on the primary sampling data according to the set secondary sampling window width. The secondary sampling window width is greater than the primary sampling time interval.
2. The method according to claim 1, characterized in that, The step of detecting sudden changes in the operating status of the monitored object based on the first sampled data includes: Calculate the one-step difference between the first sampled data and the previous level sampled data of the first sampled data; If the step difference value is greater than or equal to the mutation detection threshold, then the mutation detection result is determined to be a mutation. If the step difference value is less than the mutation detection threshold, then the mutation detection result is determined to be no mutation.
3. The method according to claim 1 or 2, characterized in that, Also includes: If it is determined that no mutation has occurred, another mutation detection threshold is calculated based on the first sampling data, and the mutation detection threshold used for mutation detection is updated using the other mutation detection threshold.
4. The method according to claim 1 or 2, characterized in that, Also includes: Obtain fourth sampling data for mutation detection initialization, wherein the fourth sampling data is first-level sampling data obtained by the monitoring agent after sampling the monitored object according to the set first-level sampling time interval; The initial value of the mutation detection threshold for mutation detection is calculated based on the fourth sampled data.
5. The method according to claim 1 or 2, characterized in that, Also includes: Receive monitoring parameters sent by the monitoring server, wherein the monitoring parameters include one or more of the following: First-level sampling time interval; Secondary sampling window width; Length of the primary sampling data queue; The number of times a primary sampling is sent after a mutation occurs.
6. A monitoring agent terminal device, characterized in that, include: A memory and a processor are communicatively connected, the memory stores computer instructions, and the processor executes the monitoring frequency conversion sampling method according to any one of claims 1 to 5 by executing the computer instructions.
7. A frequency conversion sampling monitoring system, characterized in that, The system includes: a monitoring agent and a monitoring server; wherein the monitoring agent is used to execute the monitoring frequency conversion sampling method according to any one of claims 1 to 5.
8. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions for causing the computer to perform the monitoring frequency conversion sampling method according to any one of claims 1 to 5.
Citation Information
Patent Citations
Microcomputer relay protection method utilizing HHT transient characteristic quantity detection
CN111413641A
Self-adaptive data acquisition method and monitoring system
CN112418505A