Movatterモバイル変換


[0]ホーム

URL:


CN114815641A - Monitoring method and device for smart device, storage medium and electronic device - Google Patents

Monitoring method and device for smart device, storage medium and electronic device
Download PDF

Info

Publication number
CN114815641A
CN114815641ACN202210319587.7ACN202210319587ACN114815641ACN 114815641 ACN114815641 ACN 114815641ACN 202210319587 ACN202210319587 ACN 202210319587ACN 114815641 ACN114815641 ACN 114815641A
Authority
CN
China
Prior art keywords
target
monitoring
monitoring process
running
memory
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.)
Pending
Application number
CN202210319587.7A
Other languages
Chinese (zh)
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.)
Qingdao Haier Technology Co Ltd
Haier Smart Home Co Ltd
Original Assignee
Qingdao Haier Technology Co Ltd
Haier Smart Home 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 Qingdao Haier Technology Co Ltd, Haier Smart Home Co LtdfiledCriticalQingdao Haier Technology Co Ltd
Priority to CN202210319587.7ApriorityCriticalpatent/CN114815641A/en
Publication of CN114815641ApublicationCriticalpatent/CN114815641A/en
Pendinglegal-statusCriticalCurrent

Links

Images

Classifications

Landscapes

Abstract

Translated fromChinese

本发明公开了一种智能设备的监控方法和装置、存储介质及电子设备。涉及智能家居技术领域,该智能设备的监控方法包括:在目标设备启动的情况下,运行目标监控进程,并通过目标监控进程监控目标设备的目标进程;在通过目标监控进程监测到目标进程运行异常的情况下,通过目标监控进程管理目标进程,以使目标进程恢复正常状态。本发明解决了设备进程未被监控导致设备运行异常无法及时解决的技术问题。

Figure 202210319587

The invention discloses a monitoring method and device for an intelligent device, a storage medium and an electronic device. It relates to the field of smart home technology, and the monitoring method of the smart device includes: when a target device is started, running a target monitoring process, and monitoring the target process of the target device through the target monitoring process; In the case of the target process, the target process is managed by the target monitoring process, so that the target process can be restored to the normal state. The invention solves the technical problem that the abnormal operation of the equipment cannot be solved in time because the equipment process is not monitored.

Figure 202210319587

Description

Translated fromChinese
智能设备的监控方法和装置、存储介质及电子设备Monitoring method and device for smart device, storage medium and electronic device

技术领域technical field

本发明涉及智能家居领域,具体而言,涉及一种智能设备的监控方法和装置、存储介质及电子设备。The present invention relates to the field of smart home, and in particular, to a monitoring method and device for a smart device, a storage medium and an electronic device.

背景技术Background technique

随着智能家电技术的不断成熟和相关产品的问世,在整个家居中出现了越来越多的智能设备,如智能音箱、智能洗衣机、智能冰箱等等。智能设备不仅使用人工智能技术来响应用户需求,还包含联网、播放器、蓝牙、屏幕显示、通话等功能。With the continuous maturity of smart home appliance technology and the advent of related products, more and more smart devices have appeared in the entire home, such as smart speakers, smart washing machines, smart refrigerators and so on. Smart devices not only use artificial intelligence technology to respond to user needs, but also include functions such as networking, players, Bluetooth, screen display, and calls.

而随着智能设备的功能增加,整个智能家电系统需要监控和管理更多的资源,如声音控制、内存资源和进程管理等。但是更多的资源监控和管理并不能保证智能设备中主要进程始终保持正常运行,使得智能设备的运行并没有被监控,如果主要进程出现问题也不能及时解决,影响设备的正常运行。As the functions of smart devices increase, the entire smart home appliance system needs to monitor and manage more resources, such as voice control, memory resources, and process management. However, more resource monitoring and management cannot ensure that the main processes in the smart device always run normally, so that the operation of the smart device is not monitored. If the main process has problems, it cannot be solved in time, which affects the normal operation of the device.

针对上述的问题,目前尚未提出有效的解决方案。For the above problems, no effective solution has been proposed yet.

发明内容SUMMARY OF THE INVENTION

本发明实施例提供了一种智能设备的监控方法和装置、存储介质及电子设备,以至少解决设备进程未被监控导致设备运行异常无法及时解决的技术问题。Embodiments of the present invention provide a monitoring method and device for an intelligent device, a storage medium, and an electronic device, so as to at least solve the technical problem that the abnormal operation of the device cannot be solved in time because the process of the device is not monitored.

根据本发明实施例的一个方面,提供了一种智能设备的监控方法,包括:在目标设备启动的情况下,运行目标监控进程,并通过上述目标监控进程监控上述目标设备的目标进程;在通过上述目标监控进程监测到上述目标进程运行异常的情况下,通过上述目标监控进程管理上述目标进程,以使上述目标进程恢复至运行正常。According to an aspect of the embodiments of the present invention, a method for monitoring a smart device is provided, including: when a target device is started, running a target monitoring process, and monitoring the target process of the target device through the target monitoring process; When the above-mentioned target monitoring process detects that the above-mentioned target process is running abnormally, the above-mentioned target process is managed by the above-mentioned target monitoring process, so that the above-mentioned target process can be restored to normal operation.

根据本发明实施例的另一方面,还提供了一种智能设备的监控装置,包括:运行单元,用于在目标设备启动的情况下,运行目标监控进程,并通过上述目标监控进程监控上述目标设备的目标进程;管理单元,用于在通过上述目标监控进程监测到上述目标进程运行异常的情况下,通过上述目标监控进程管理上述目标进程,以使上述目标进程恢复至运行正常。According to another aspect of the embodiments of the present invention, an apparatus for monitoring a smart device is also provided, including: a running unit, configured to run a target monitoring process when the target device is started, and monitor the above target through the above target monitoring process The target process of the device; a management unit, configured to manage the target process through the target monitoring process when the abnormal operation of the target process is detected by the target monitoring process, so as to restore the target process to normal operation.

根据本发明实施例的又一方面,还提供了一种计算机可读的存储介质,该计算机可读的存储介质中存储有计算机程序,其中,该计算机程序被设置为运行时执行上述智能设备的监控方法。According to another aspect of the embodiments of the present invention, a computer-readable storage medium is also provided, where a computer program is stored in the computer-readable storage medium, wherein the computer program is configured to execute the above-mentioned smart device when running. monitoring method.

根据本发明实施例的又一方面,还提供了一种电子设备,包括存储器和处理器,上述存储器中存储有计算机程序,上述处理器被设置为通过所述计算机程序执行上述的智能设备的监控方法。According to yet another aspect of the embodiments of the present invention, an electronic device is also provided, including a memory and a processor, the memory stores a computer program, and the processor is configured to perform the monitoring of the above-mentioned smart device through the computer program method.

在本发明实施例中,采用在目标设备启动的情况下,运行目标监控进程,并通过目标监控进程监控目标设备的目标进程,在通过目标监控进程监测到目标进程运行异常的情况下,通过目标监控进程管理目标进程,以使目标进程恢复至运行正常的方式,通过运行目标监控进程并通过运行的目标监控进程对目标进程进行监控,并在监测到目标进程异常时,通过目标监控进程管理目标进程以使目标进程恢复运行正常,达到了对目标设备中运行的进程进行监控,且在目标进程运行异常时,通过目标监控进程的管理实现目标进程的运行恢复正常的目的,从而实现了及时发现目标设备在运行时的进程异常,并及时解决目标设备的进程异常的技术效果,进而解决了设备进程未被监控导致设备运行异常无法及时解决的技术问题。In the embodiment of the present invention, when the target device is started, the target monitoring process is run, and the target process of the target device is monitored through the target monitoring process. The monitoring process manages the target process, so that the target process can be restored to the normal operation mode, by running the target monitoring process and monitoring the target process through the running target monitoring process, and when the abnormality of the target process is detected, the target process is managed by the target monitoring process. process to restore the target process to normal operation, to monitor the process running in the target device, and when the target process runs abnormally, the target process can be managed to restore the normal operation of the target process, thereby realizing timely detection. The process of the target device is abnormal during running, and the technical effect of solving the process abnormality of the target device in time is solved, thereby solving the technical problem that the abnormal operation of the device cannot be solved in time because the device process is not monitored.

附图说明Description of drawings

此处所说明的附图用来提供对本发明的进一步理解,构成本申请的一部分,本发明的示意性实施例及其说明用于解释本发明,并不构成对本发明的不当限定。在附图中:The accompanying drawings described herein are used to provide a further understanding of the present invention and constitute a part of the present application. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the attached image:

图1是根据本发明实施例的一种可选的智能设备的监控方法的应用环境的示意图;FIG. 1 is a schematic diagram of an application environment of an optional monitoring method for a smart device according to an embodiment of the present invention;

图2是根据本发明实施例的一种可选的智能设备的监控方法的流程示意图;2 is a schematic flowchart of an optional monitoring method for a smart device according to an embodiment of the present invention;

图3是根据本发明实施例的一种可选的智能设备的监控方法的流程示意图;3 is a schematic flowchart of an optional monitoring method for a smart device according to an embodiment of the present invention;

图4是根据本发明实施例的一种可选的智能设备的监控方法的流程示意图;4 is a schematic flowchart of an optional monitoring method for a smart device according to an embodiment of the present invention;

图5是根据本发明实施例的一种可选的智能设备的监控方法的流程示意图;5 is a schematic flowchart of an optional monitoring method for a smart device according to an embodiment of the present invention;

图6是根据本发明实施例的一种可选的智能设备的监控装置的结构示意图;6 is a schematic structural diagram of an optional monitoring apparatus for a smart device according to an embodiment of the present invention;

图7是根据本发明实施例的一种可选的电子设备的结构示意图。FIG. 7 is a schematic structural diagram of an optional electronic device according to an embodiment of the present invention.

具体实施方式Detailed ways

为了使本技术领域的人员更好地理解本发明方案,下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分的实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都应当属于本发明保护的范围。In order to make those skilled in the art better understand the solutions of the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only Embodiments are part of the present invention, but not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.

需要说明的是,本发明的说明书和权利要求书及上述附图中的术语“第一”、“第二”等是用于区别类似的对象,而不必用于描述特定的顺序或先后次序。应该理解这样使用的数据在适当情况下可以互换,以便这里描述的本发明的实施例能够以除了在这里图示或描述的那些以外的顺序实施。此外,术语“包括”和“具有”以及他们的任何变形,意图在于覆盖不排他的包含,例如,包含了一系列步骤或单元的过程、方法、系统、产品或设备不必限于清楚地列出的那些步骤或单元,而是可包括没有清楚地列出的或对于这些过程、方法、产品或设备固有的其它步骤或单元。It should be noted that the terms "first", "second" and the like in the description and claims of the present invention and the above drawings are used to distinguish similar objects, and are not necessarily used to describe a specific sequence or sequence. It is to be understood that the data so used may be interchanged under appropriate circumstances such that the embodiments of the invention described herein can be practiced in sequences other than those illustrated or described herein. Furthermore, the terms "comprising" and "having" and any variations thereof, are intended to cover non-exclusive inclusion, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those expressly listed Rather, those steps or units may include other steps or units not expressly listed or inherent to these processes, methods, products or devices.

根据本发明实施例的一个方面,提供了一种智能设备的监控方法,该智能设备的监控方法广泛应用于智慧家庭(Smart Home)、智能家居、智能家用设备生态、智慧住宅(Intelligence House)生态等全屋智能数字化控制应用场景。可选地,在本实施例中,上述智能设备的监控方法可以应用于如图1所示的由终端设备102和服务器104所构成的硬件环境中。如图1所示,服务器104通过网络与终端设备102进行连接,可用于为终端或终端上安装的客户端提供服务(如应用服务等),可在服务器上或独立于服务器设置数据库,用于为服务器104提供数据存储服务,可在服务器上或独立于服务器配置云计算和/或边缘计算服务,用于为服务器104提供数据运算服务。According to an aspect of the embodiments of the present invention, a monitoring method for a smart device is provided, and the monitoring method for a smart device is widely used in a smart home (Smart Home), a smart home, a smart home device ecology, and a smart house (Intelligence House) ecology and other application scenarios of whole-house intelligent digital control. Optionally, in this embodiment, the above-mentioned monitoring method for a smart device may be applied to a hardware environment composed of aterminal device 102 and aserver 104 as shown in FIG. 1 . As shown in FIG. 1 , theserver 104 is connected to theterminal device 102 through the network, and can be used to provide services (such as application services, etc.) for the terminal or the client installed on the terminal, and a database can be set on the server or independent of the server for To provide theserver 104 with data storage services, cloud computing and/or edge computing services may be configured on the server or independently of the server for providing theserver 104 with data computing services.

终端设备102通过网络上报进程异常给服务器104,服务器104在接收到进程异常后,不限于基于进程异常确定出对应的解决方案,从而将解决方案对应的执行指令通过网络反馈给终端设备102,以解决终端设备102的进程异常。终端设备102的进程异常不限于通过依次执行S102至S104以智能设备的监控方法实现。S102,运行目标监控进程。在目标设备启动的情况下,运行目标监控进程,并通过上述目标监控进程监控上述目标设备的目标进程。S104,管理目标进程。在通过上述目标监控进程监测到上述目标进程运行异常的情况下,通过上述目标监控进程管理上述目标进程,以使上述目标进程恢复至运行正常。Theterminal device 102 reports the process abnormality to theserver 104 through the network. After theserver 104 receives the process abnormality, it is not limited to determine the corresponding solution based on the process abnormality, so as to feed back the execution instruction corresponding to the solution to theterminal device 102 through the network, to Solve the process abnormality of theterminal device 102 . The abnormality of the process of theterminal device 102 is not limited to be realized by the monitoring method of the smart device by sequentially executing S102 to S104. S102, run the target monitoring process. When the target device is started, the target monitoring process is run, and the target process of the target device is monitored through the target monitoring process. S104, manage the target process. In the case that the above-mentioned target process is monitored abnormally by the above-mentioned target monitoring process, the above-mentioned target process is managed by the above-mentioned target monitoring process, so as to restore the above-mentioned target process to normal operation.

上述服务器可以是单一服务器,也可以是由多个服务器组成的服务器集群,或者是云服务器。上述网络可以包括但不限于以下至少之一:有线网络,无线网络。上述有线网络可以包括但不限于以下至少之一:广域网,城域网,局域网,上述无线网络可以包括但不限于以下至少之一:WIFI(Wireless Fidelity,无线保真),蓝牙。终端设备102可以并不限定于为PC、手机、平板电脑、智能空调、智能烟机、智能冰箱、智能烤箱、智能炉灶、智能洗衣机、智能热水器、智能洗涤设备、智能洗碗机、智能投影设备、智能电视、智能晾衣架、智能窗帘、智能影音、智能插座、智能音响、智能音箱、智能新风设备、智能厨卫设备、智能卫浴设备、智能扫地机器人、智能擦窗机器人、智能拖地机器人、智能空气净化设备、智能蒸箱、智能微波炉、智能厨宝、智能净化器、智能饮水机、智能门锁等上述仅是一种示例,本实施例中对此不作任何限定。The above server may be a single server, a server cluster composed of multiple servers, or a cloud server. The above-mentioned network may include, but is not limited to, at least one of the following: wired network, wireless network. The wired network may include but is not limited to at least one of the following: a wide area network, a metropolitan area network, and a local area network, and the wireless network may include but not limited to at least one of the following: WIFI (Wireless Fidelity, wireless fidelity), Bluetooth. Theterminal device 102 may not be limited to PCs, mobile phones, tablet computers, smart air conditioners, smart hoods, smart refrigerators, smart ovens, smart stoves, smart washing machines, smart water heaters, smart washing devices, smart dishwashers, and smart projection devices. , Smart TV, Smart Clothes Rack, Smart Curtain, Smart Video, Smart Socket, Smart Audio, Smart Speaker, Smart Fresh Air Equipment, Smart Kitchen and Bathroom Equipment, Smart Bathroom Equipment, Smart Sweeping Robot, Smart Window Cleaning Robot, Smart Mopping Robot, The above-mentioned intelligent air purification equipment, intelligent steamer, intelligent microwave oven, intelligent kitchen treasure, intelligent purifier, intelligent water dispenser, intelligent door lock, etc., are only examples, which are not limited in this embodiment.

作为一种可选的实施方式,如图2所示,上述智能设备的监控方法包括:As an optional implementation manner, as shown in FIG. 2 , the monitoring method for the above-mentioned smart device includes:

S202,在目标设备启动的情况下,运行目标监控进程,并通过上述目标监控进程监控上述目标设备的目标进程;S202, when the target device is started, run the target monitoring process, and monitor the target process of the above-mentioned target device through the above-mentioned target monitoring process;

S204,在通过上述目标监控进程监测到上述目标进程运行异常的情况下,通过上述目标监控进程管理上述目标进程,以使上述目标进程恢复至运行正常。S204, in the case that the target process is abnormally running through the target monitoring process, manage the target process through the target monitoring process, so that the target process can be restored to normal operation.

目标监控进程在目标设备启动时开始运行,不限于是在目标设备启动的同时启动目标监控进程。目标监控进程用于监控目标设备运行时所调用的进程,不限于为至少一个运行进程。目标监控进程不限于集成在目标设备的运行中心,通过启动目标设备自动启动目标监控进程。The target monitoring process starts to run when the target device is started, and is not limited to starting the target monitoring process when the target device is started. The target monitoring process is used to monitor the process called when the target device is running, and is not limited to at least one running process. The target monitoring process is not limited to being integrated in the operation center of the target device, and the target monitoring process is automatically started by starting the target device.

目标监控进程为目标设备中用于监控其余进程的监控进程,独立于目标设备中已有进程,已有进程包括目标设备运行中的进程以及未运行中的进程。目标监控进程同时监控的进程数量在此不做限定,可以同时监控目标设备中运行的全部进程,也可以监控部分进程,还可以是监控预设的某个进程。The target monitoring process is a monitoring process used to monitor other processes in the target device, and is independent of the existing processes in the target device. The existing processes include the running process and the non-running process of the target device. The number of processes monitored by the target monitoring process at the same time is not limited here. All processes running in the target device can be monitored at the same time, some processes can also be monitored, or a preset process can be monitored.

目标监控进程监测到目标进程运行异常时,通过目标监控进程管理目标进程不限于是通过目标监控进程消除目标进程的运行异常,例如,重启目标进程以使得目标进程恢复运行正常。When the target monitoring process detects that the target process is running abnormally, managing the target process through the target monitoring process is not limited to eliminating the abnormal running of the target process through the target monitoring process, for example, restarting the target process to restore the target process to normal operation.

作为一种可选的实施方式,通过目标监控进程监控目标设备的目标进程包括:通过目标监控进程与目标进程的进程间通信,建立目标进程与目标监控进程的监控关联关系;通过监控关联关系,目标监控进程监控目标进程。As an optional implementation manner, monitoring the target process of the target device through the target monitoring process includes: establishing a monitoring association relationship between the target process and the target monitoring process through inter-process communication between the target monitoring process and the target process; The target monitoring process monitors the target process.

与目标监控进程建立监控关联关系的不限于为至少一个目标进程,目标进程为目标设备运行时所调用的任意进程,例如目标设备的主进程。The monitoring association relationship established with the target monitoring process is not limited to at least one target process, and the target process is any process called when the target device runs, such as the main process of the target device.

通过目标监控进程与目标进程之间的进程间通信,建立目标进程与目标监控进程之间的监控关联关系,从而通过目标监控进程监控目标进程的运行。目标监控进程监控目标进程的运行不限于监控目标进程的运行状态以及目标进程的运行参数,通过运行状态和运行参数确定目标进程是否出现运行异常。Through the inter-process communication between the target monitoring process and the target process, a monitoring association relationship between the target process and the target monitoring process is established, thereby monitoring the running of the target process through the target monitoring process. The target monitoring process monitoring the running of the target process is not limited to monitoring the running status of the target process and the running parameters of the target process, and whether the target process is abnormally running is determined through the running status and running parameters.

在本申请实施例中,采用在目标设备启动的情况下,运行目标监控进程,并通过上述目标监控进程监控上述目标设备的目标进程,在通过上述目标监控进程监测到上述目标进程运行异常的情况下,通过上述目标监控进程管理上述目标进程,以使上述目标进程恢复至运行正常的方式,通过运行目标监控进程并通过运行的目标监控进程对目标进程进行监控,并在监测到目标进程异常时,通过目标监控进程管理目标进程以使目标进程恢复运行正常,达到了对目标设备中运行的进程进行监控,且在目标进程运行异常时,通过目标监控进程的管理实现目标进程的运行恢复正常的目的,从而实现了及时发现目标设备在运行时的进程异常,并及时解决目标设备的进程异常的技术效果,进而解决了设备进程未被监控导致设备运行异常无法及时解决的技术问题。In the embodiment of the present application, when the target device is started, the target monitoring process is run, and the target process of the target device is monitored by the target monitoring process, and the abnormal operation of the target process is monitored by the target monitoring process. Next, manage the above-mentioned target process through the above-mentioned target monitoring process, so as to restore the above-mentioned target process to a normal operation mode, and monitor the target process by running the target monitoring process and through the running target monitoring process, and when the abnormality of the target process is detected. , through the target monitoring process to manage the target process to restore the target process to normal operation, to monitor the process running in the target device, and when the target process runs abnormally, through the management of the target monitoring process, the operation of the target process can be restored to normal. The purpose is to realize the technical effect of timely discovering the process abnormality of the target device when it is running, and solving the process abnormality of the target device in time, thereby solving the technical problem that the abnormal operation of the device cannot be solved in time because the device process is not monitored.

作为一种可选的实施方式,如图3所示,在建立目标进程与目标监控进程的监控关联关系之后,还包括:As an optional implementation manner, as shown in Figure 3, after establishing the monitoring association relationship between the target process and the target monitoring process, it also includes:

S302,控制目标进程通过监控关联关系,按照目标频率持续发送状态数据包给目标监控进程,其中,目标监控进程根据状态数据包监测目标进程的运行情况。S302, the control target process continuously sends status data packets to the target monitoring process according to the target frequency by monitoring the association relationship, wherein the target monitoring process monitors the running status of the target process according to the status data packets.

S304,在目标监控进程按照目标频率持续接收到状态数据包的情况下,确定目标监控进程监测到目标进程运行正常。S304, in the case that the target monitoring process continues to receive the status data packets according to the target frequency, determine that the target monitoring process monitors that the target process is running normally.

在建立目标进程与目标监控进程的监控关联关系的情况下,控制目标进程主动按照目标频率给目标监控进程发送状态数据包,状态数据包用于指示目标进程是否运行正常,只有在目标进程运行正常的情况下,才能持续的发送状态数据包给目标监控进程,在目标进程运行异常的情况下,状态数据包的发送会出现发送异常,不限于是不发送状态数据包或者发送频率异常,从而状态数据包不能按照目标频率发送,目标监控进程自然也不能按照目标频率接收到状态数据包。In the case of establishing the monitoring relationship between the target process and the target monitoring process, the control target process actively sends status data packets to the target monitoring process according to the target frequency. The status data packets are used to indicate whether the target process is running normally. Only when the target process is running normally In this case, the status data packets can be continuously sent to the target monitoring process. In the case of abnormal operation of the target process, the sending of status data packets will be abnormal, not limited to not sending status data packets or abnormal sending frequency. Data packets cannot be sent at the target frequency, and the target monitoring process naturally cannot receive status packets at the target frequency.

在目标监控进程按照目标频率接收到状态数据包的情况下,确定目标进程运行正常,在目标监控进程未能接收到状态数据包或接收到状态数据包的频率不是目标频率的情况下,确定目标监控进程未能按照目标频率持续接收到状态数据包,此时确定监测到目标进程运行异常。In the case that the target monitoring process receives the status data packets according to the target frequency, it is determined that the target process is running normally, and when the target monitoring process fails to receive the status data packets or the frequency of receiving the status data packets is not the target frequency, determine the target If the monitoring process fails to continuously receive status packets according to the target frequency, it is determined that the target process is abnormally running.

目标频率为在预设单位时间内的发送次数,不限于以发送间隔表示,每隔预设间隔目标进程发送状态数据包给目标监控进程,从而目标监控进程通过是否按时收到状态数据包确定所监测的目标进程运行是否正常。The target frequency is the number of transmissions within a preset unit time, not limited to the sending interval. The target process sends status packets to the target monitoring process at preset intervals, so that the target monitoring process determines whether the status packets are received on time or not. Whether the monitored target process is running normally.

状态数据包中不限于包括目标进程的进程信息、当前的进程占用率、当前的内存参数等目标进程在当前的运行状态数据。The status data packet is not limited to include process information of the target process, current process occupancy rate, current memory parameters and other current running status data of the target process.

作为一种可选的实施方式,如图4所示,在控制目标进程通过监控关联关系,按照目标频率持续发送状态数据包给目标监控进程之后,还包括:As an optional implementation manner, as shown in FIG. 4 , after the control target process continuously sends status data packets to the target monitoring process according to the target frequency by monitoring the association relationship, it further includes:

S402,在目标监控进程未按照目标频率持续接收到状态数据包的情况下,确定目标监控进程监测到目标进程运行异常;S402, in the case that the target monitoring process does not continuously receive the status data packet according to the target frequency, determine that the target monitoring process has monitored that the target process is running abnormally;

S404,通过目标监控进程重新启动目标进程。S404, restart the target process through the target monitoring process.

在目标监控进程基于状态数据包确定目标进程运行异常时,则关闭目标进程并重新启动目标进程,通过重启目标进程以保证目标进程回归至运行正常状态。When the target monitoring process determines that the target process runs abnormally based on the status data packet, the target process is closed and the target process is restarted, and the target process is restarted to ensure that the target process returns to a normal running state.

以通过进程间通信建立目标进程与目标监控进程之间的心跳检测机制为例,目标进程主动发送心跳数据包给目标监控进程,目标监控进程通过心跳数据包的频率或间隔不正确,确定目标进程运行存在异常,则关闭目标进程被重启目标进程。Taking the establishment of the heartbeat detection mechanism between the target process and the target monitoring process through inter-process communication as an example, the target process actively sends heartbeat data packets to the target monitoring process, and the target monitoring process determines the target process through the incorrect frequency or interval of the heartbeat data packets. If there is an exception in the operation, the target process is closed and the target process is restarted.

作为一种可选的实施方式,在控制目标进程通过监控关联关系,按照目标频率持续发送状态数据包给目标监控进程之后,还包括:As an optional implementation manner, after controlling the target process to continuously send status data packets to the target monitoring process according to the target frequency by monitoring the association relationship, the method further includes:

S1,在目标监控进程接收到状态数据包的情况下,从状态数据包中获取目标进程的当前内存参数,其中,当前内存参数用于指示目标进程在当前时刻的可用内存空间;S1, when the target monitoring process receives the status data packet, obtain the current memory parameter of the target process from the status data packet, wherein the current memory parameter is used to indicate the available memory space of the target process at the current moment;

S2,根据可用内存空间确定目标进程的内存运行情况。S2: Determine the memory operation status of the target process according to the available memory space.

在目标监控进程基于接收到的状态数据包确定目标进程运行状态的情况下,从状态数据包中获取内存参数,以确定目标进程当前内存运行情况。每个状态数据包中所携带的为当前目标进程的内存参数,不同时刻目标进程的内存参数不限于相互独立。When the target monitoring process determines the running status of the target process based on the received status data packet, the memory parameters are obtained from the status data packet to determine the current memory running status of the target process. Each state data packet carries the memory parameters of the current target process, and the memory parameters of the target process at different times are not limited to being independent of each other.

以从状态数据包中获取的是目标进程当前可用内存空间为例,目标监控进程通过目标进程当前可用内存空间,确定目标进程的内存是否正常,以在内存异常的情况下,及时进行异常上报和处理。Taking the current available memory space of the target process obtained from the status data packet as an example, the target monitoring process determines whether the memory of the target process is normal through the current available memory space of the target process, so as to timely report the abnormality and report the abnormality in the case of abnormal memory. deal with.

作为一种可选的实施方式,上述根据可用内存空间确定目标进程的内存运行情况包括:As an optional implementation manner, the above-mentioned determination of the memory operation status of the target process according to the available memory space includes:

S1,在可用内存空间未处于预设内存范围的情况下,确定目标监控进程监测到目标进程当前内存运行异常;S1, when the available memory space is not within the preset memory range, determine that the target monitoring process detects that the current memory of the target process is running abnormally;

S2,将当前内存运行异常写入进程日志中,其中,进程日志用于记录目标设备中的进程异常S2, write the current memory running exception into the process log, where the process log is used to record the process exception in the target device

在可用内存空间处于预设内存范围的情况下,确定目标进程当前内存运行正常,在可用内存空间未处于预设内存范围的情况下,确定目标进程当前内存运行异常。在目标监控进程监测到目标进程当前内存运行异常的情况下,将内存运行异常写入进程日志,同时将内存运行异常相关数据写入进程日志,以便于通过进程日志进行目标进程运行异常的原因分析。If the available memory space is within the preset memory range, it is determined that the current memory of the target process is running normally, and if the available memory space is not within the preset memory range, it is determined that the current memory of the target process is running abnormally. When the target monitoring process detects that the current memory of the target process is abnormal, the abnormal memory operation is written into the process log, and the data related to the abnormal operation of the memory is written into the process log, so as to analyze the cause of the abnormal operation of the target process through the process log. .

作为一种可选的实施方式,在目标监控进程监测到目标进程当前内存异常的情况下,在目标时间重启目标设备,其中,目标时间为目标时间段中为目标设备分配的随机时刻。As an optional implementation manner, when the target monitoring process detects that the current memory of the target process is abnormal, the target device is restarted at the target time, where the target time is a random time allocated to the target device in the target time period.

在目标监测进程监测到目标进程当前内存运行异常的情况下,确定当前时刻的当前时间。通过判断当前时间是否位于目标时间段内,确定是否通过重启目标进程以释放目标进程的可用内存,从而将目标进程调整至内存运行正常状态。在当前时间未位于目标时间段的情况下,不限于通过重启目标进程以将目标进程调整至内存运行正常状态。在当前时间在目标时间段内时,通过在目标时刻重启目标设备以释放设备可用内存,从而将目标进程调整至内存运行正常状态。When the target monitoring process detects that the current memory of the target process runs abnormally, the current time at the current moment is determined. By judging whether the current time is within the target time period, it is determined whether to release the available memory of the target process by restarting the target process, so as to adjust the target process to a normal memory operation state. In the case that the current time is not within the target time period, it is not limited to restarting the target process to adjust the target process to a normal state of memory operation. When the current time is within the target time period, the target process is adjusted to a normal state of memory operation by restarting the target device at the target time to release the available memory of the device.

在目标时间重启目标设备,而目标时间为目标时间段中为目标设备分配的随机重启时刻。可选地,在当前时刻未位于目标时间段的情况下,在目标设备运行至目标时间段的情况下,不限于在目标时刻重启目标设备。Reboot the target device at the target time, and the target time is a random reboot time allocated for the target device in the target time period. Optionally, when the current moment is not within the target time period, and when the target device runs to the target time period, it is not limited to restart the target device at the target moment.

目标时间段不限于是为设备设定的重启时间段,每个设备在目标时间段内每个时刻重启的概率不限于相同,从而在设备数量较多时,避免多个设备同时重启给服务器造成的运行压力,通过目标时间段内随机的目标时刻,将多个设备的重启分散至目标时间段内的不同时刻,避免批量设备的重启给服务器造成的运行压力。The target time period is not limited to the restart time period set for the device, and the probability of each device restarting at each moment within the target time period is not limited to the same, so that when the number of devices is large, it can avoid the simultaneous restart of multiple devices to the server. Operating pressure, through the random target time in the target time period, the restart of multiple devices is distributed to different times in the target time period, so as to avoid the operating pressure caused by the restart of batch devices to the server.

以监控关联关系为心跳检测机制,目标时间段为夜间为例,上述智能设备的监控方法不限于如图5所示。Taking the monitoring association relationship as the heartbeat detection mechanism and the target time period as night as an example, the monitoring method of the above smart device is not limited to that shown in FIG. 5 .

S501,启动目标监控进程。在目标设备启动的情况下,启动并运行目标监控进程;S501, start a target monitoring process. When the target device is started, start and run the target monitoring process;

S502,拉起目标进程。目标监控进程拉起目标进程;S502, start the target process. The target monitoring process pulls up the target process;

S503,判断心跳是否正常。在判断为否的情况下,执行S502,继续拉起目标进程;在判断为是的情况下,执行S504。S503, determine whether the heartbeat is normal. If it is judged as NO, execute S502, and continue to pull up the target process; if judged as yes, execute S504.

S504,判断内存是否充足。在判断为否的情况下,执行S506;在判断为是的情况下,执行S505;S504, determine whether the memory is sufficient. If it is judged as NO, execute S506; if it is judged as yes, execute S505;

S505,判断是否为夜间。在判断为是的情况下,执行S506;在判断为否的情况下,执行S506并执行S503,持续判断目标进程的心跳是否正常。S505, it is determined whether it is night time. If it is determined to be yes, execute S506; if it is determined to be negative, execute S506 and execute S503 to continuously determine whether the heartbeat of the target process is normal.

S506,记录在运行日志中。将内存异常记录在运行日志中。S506, record in the operation log. Log memory exceptions in the run log.

S507,重启目标进程。在记录内存运行异常的情况下,重启目标进程以解决内存运行异常。S507, restart the target process. In the case of recording abnormal memory operation, restart the target process to resolve the abnormal memory operation.

需要说明的是,对于前述的各方法实施例,为了简单描述,故将其都表述为一系列的动作组合,但是本领域技术人员应该知悉,本发明并不受所描述的动作顺序的限制,因为依据本发明,某些步骤可以采用其他顺序或者同时进行。其次,本领域技术人员也应该知悉,说明书中所描述的实施例均属于优选实施例,所涉及的动作和模块并不一定是本发明所必须的。It should be noted that, for the sake of simple description, the foregoing method embodiments are all expressed as a series of action combinations, but those skilled in the art should know that the present invention is not limited by the described action sequence. As in accordance with the present invention, certain steps may be performed in other orders or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present invention.

根据本发明实施例的另一个方面,还提供了一种用于实施上述智能设备的监控方法的智能设备的监控装置。如图6所示,该装置包括:According to another aspect of the embodiments of the present invention, a monitoring apparatus for a smart device for implementing the above-mentioned monitoring method for a smart device is also provided. As shown in Figure 6, the device includes:

运行单元602,用于在目标设备启动的情况下,运行目标监控进程,并通过目标监控进程监控目标设备的目标进程;A running unit 602, configured to run the target monitoring process when the target device is started, and monitor the target process of the target device through the target monitoring process;

管理单元604,用于在通过目标监控进程监测到目标进程运行异常的情况下,通过目标监控进程管理目标进程,以使目标进程恢复至运行正常。The management unit 604 is configured to manage the target process through the target monitoring process under the condition that the abnormal running of the target process is detected by the target monitoring process, so as to restore the target process to normal operation.

可选地,上述运行单元602还用于通过目标监控进程与目标进程的进程间通信,建立目标进程与目标监控进程的监控关联关系;通过监控关联关系,目标监控进程监控目标进程。Optionally, the above-mentioned running unit 602 is further configured to establish a monitoring association relationship between the target process and the target monitoring process through inter-process communication between the target monitoring process and the target process; and through the monitoring association relationship, the target monitoring process monitors the target process.

可选地,上述智能设备的监控装置还包括控制单元,用于在建立目标进程与目标监控进程的监控关联关系之后,控制目标进程通过监控关联关系,按照目标频率持续发送状态数据包给目标监控进程,其中,目标监控进程根据状态数据包监测目标进程的运行情况;在目标监控进程按照目标频率持续接收到状态数据包的情况下,确定目标监控进程监测到目标进程运行正常。Optionally, the monitoring device of the above-mentioned smart device also includes a control unit, which is used to control the target process to continuously send status data packets to the target monitoring process according to the target frequency through the monitoring correlation relationship after establishing the monitoring correlation relationship between the target process and the target monitoring process. process, wherein the target monitoring process monitors the running status of the target process according to the status data packets; when the target monitoring process continuously receives the status data packets according to the target frequency, it is determined that the target monitoring process monitors that the target process is running normally.

可选地,上述智能设备的监控装置还包括第一重启单元,用于在控制目标进程通过监控关联关系,按照目标频率持续发送状态数据包给目标监控进程之后,在目标监控进程未按照目标频率持续接收到状态数据包的情况下,确定目标监控进程监测到目标进程运行异常;通过目标监控进程重新启动目标进程。Optionally, the monitoring device of the above-mentioned intelligent device further includes a first restarting unit, which is used to continuously send the status data packet to the target monitoring process according to the target frequency after the control target process passes the monitoring association relationship, and the target monitoring process does not follow the target frequency. In the case of continuously receiving status data packets, it is determined that the target monitoring process detects that the target process is running abnormally; the target process is restarted through the target monitoring process.

可选地,上述智能设备的监控装置还包括内存单元,用于在控制目标进程通过监控关联关系,按照目标频率持续发送状态数据包给目标监控进程之后,在目标监控进程接收到状态数据包的情况下,从状态数据包中获取目标进程的当前内存参数,其中,当前内存参数用于指示目标进程在当前时刻的可用内存空间;根据可用内存空间确定目标进程的内存运行情况。Optionally, the monitoring device of the above-mentioned intelligent device further includes a memory unit, which is used to continuously send the status data packet to the target monitoring process according to the target frequency by controlling the target process through the monitoring association relationship, and after the target monitoring process receives the status data packet. In this case, the current memory parameters of the target process are obtained from the status data packet, where the current memory parameters are used to indicate the available memory space of the target process at the current moment; the memory operation status of the target process is determined according to the available memory space.

可选地,上述内存单元还用于在可用内存空间未处于预设内存范围的情况下,确定目标监控进程监测到目标进程当前内存运行异常;将当前内存运行异常写入进程日志中,其中,进程日志用于记录目标设备中的进程异常Optionally, the above-mentioned memory unit is also used to determine that the target monitoring process has detected that the current memory operation of the target process is abnormal when the available memory space is not within the preset memory range; and write the current memory operation abnormality into the process log, wherein, The process log is used to record process exceptions in the target device

可选地,上述智能设备的监控装置还包括第二重启单元,用于在目标监控进程监测到目标进程当前内存异常的情况下,在目标时间重启目标设备,其中,目标时间为目标时间段中为目标设备分配的随机时刻。Optionally, the monitoring device of the above-mentioned smart device further includes a second restarting unit for restarting the target device at the target time when the target monitoring process detects that the current memory of the target process is abnormal, wherein the target time is in the target time period. A random moment assigned to the target device.

在本申请实施例中,采用在目标设备启动的情况下,运行目标监控进程,并通过上述目标监控进程监控上述目标设备的目标进程,在通过上述目标监控进程监测到上述目标进程运行异常的情况下,通过上述目标监控进程管理上述目标进程,以使上述目标进程恢复至运行正常的方式,通过运行目标监控进程并通过运行的目标监控进程对目标进程进行监控,并在监测到目标进程异常时,通过目标监控进程管理目标进程以使目标进程恢复运行正常,达到了对目标设备中运行的进程进行监控,且在目标进程运行异常时,通过目标监控进程的管理实现目标进程的运行恢复正常的目的,从而实现了及时发现目标设备在运行时的进程异常,并及时解决目标设备的进程异常的技术效果,进而解决了设备进程未被监控导致设备运行异常无法及时解决的技术问题。In the embodiment of the present application, when the target device is started, the target monitoring process is run, and the target process of the target device is monitored by the target monitoring process, and the abnormal operation of the target process is monitored by the target monitoring process. Next, manage the above-mentioned target process through the above-mentioned target monitoring process, so as to restore the above-mentioned target process to a normal operation mode, and monitor the target process by running the target monitoring process and through the running target monitoring process, and when the abnormality of the target process is detected. , through the target monitoring process to manage the target process to restore the target process to normal operation, to monitor the process running in the target device, and when the target process runs abnormally, through the management of the target monitoring process, the operation of the target process can be restored to normal. The purpose is to realize the technical effect of timely discovering the process abnormality of the target device when it is running, and solving the process abnormality of the target device in time, thereby solving the technical problem that the abnormal operation of the device cannot be solved in time because the device process is not monitored.

根据本发明实施例的又一个方面,还提供了一种用于实施上述智能设备的监控方法的电子设备,该电子设备可以是图1所示的终端设备或服务器。本实施例以该电子设备为终端设备为例来说明。如图7所示,该电子设备包括存储器702和处理器704,该存储器702中存储有计算机程序,该处理器704被设置为通过计算机程序执行上述任一项方法实施例中的步骤。According to another aspect of the embodiments of the present invention, there is also provided an electronic device for implementing the above-mentioned monitoring method for a smart device, where the electronic device may be the terminal device or the server shown in FIG. 1 . This embodiment is described by taking the electronic device as a terminal device as an example. As shown in FIG. 7 , the electronic device includes a memory 702 and aprocessor 704, where a computer program is stored in the memory 702, and theprocessor 704 is configured to execute the steps in any of the above method embodiments through the computer program.

可选地,在本实施例中,上述电子设备可以位于计算机网络的多个网络设备中的至少一个网络设备。Optionally, in this embodiment, the above-mentioned electronic device may be located in at least one network device among multiple network devices of a computer network.

可选地,在本实施例中,上述处理器可以被设置为通过计算机程序执行以下步骤:Optionally, in this embodiment, the above-mentioned processor may be configured to execute the following steps through a computer program:

S1,在目标设备启动的情况下,运行目标监控进程,并通过目标监控进程监控目标设备的目标进程;S1, when the target device is started, run the target monitoring process, and monitor the target process of the target device through the target monitoring process;

S2,在通过目标监控进程监测到目标进程运行异常的情况下,通过目标监控进程管理目标进程,以使目标进程恢复至运行正常。S2, in the case that the target process is abnormally running through the target monitoring process, manage the target process through the target monitoring process, so as to restore the target process to normal operation.

可选地,本领域普通技术人员可以理解,图7所示的结构仅为示意,电子设备也可以是任意终端设备。图7其并不对上述电子设备的结构造成限定。例如,电子设备还可包括比图7中所示更多或者更少的组件(如网络接口等),或者具有与图7所示不同的配置。Optionally, those skilled in the art can understand that the structure shown in FIG. 7 is only for illustration, and the electronic device may also be any terminal device. FIG. 7 does not limit the structure of the above electronic device. For example, the electronic device may also include more or fewer components than those shown in FIG. 7 (eg, network interfaces, etc.), or have a different configuration than that shown in FIG. 7 .

其中,存储器702可用于存储软件程序以及模块,如本发明实施例中的智能设备的监控方法和装置对应的程序指令/模块,处理器704通过运行存储在存储器702内的软件程序以及模块,从而执行各种功能应用以及数据处理,即实现上述的智能设备的监控方法。存储器702可包括高速随机存储器,还可以包括非易失性存储器,如一个或者多个磁性存储装置、闪存、或者其他非易失性固态存储器。在一些实例中,存储器702可进一步包括相对于处理器704远程设置的存储器,这些远程存储器可以通过网络连接至终端。上述网络的实例包括但不限于互联网、企业内部网、局域网、移动通信网及其组合。其中,存储器702具体可以但不限于用于存储目标监控进程、监控关联关系、运行监测数据等信息。作为一种示例,如图7所示,上述存储器702中可以但不限于包括上述智能设备的监控装置中的运行单元602和管理单元604。此外,还可以包括但不限于上述智能设备的监控装置中的其他模块单元,本示例中不再赘述。Wherein, the memory 702 can be used to store software programs and modules, such as program instructions/modules corresponding to the monitoring method and apparatus for a smart device in the embodiment of the present invention, and theprocessor 704 runs the software programs and modules stored in the memory 702, thereby Execute various functional applications and data processing, that is, to realize the above-mentioned monitoring method of the smart device. Memory 702 may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, memory 702 may further include memory located remotely fromprocessor 704, and these remote memories may be connected to the terminal through a network. Examples of such networks include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof. Wherein, the memory 702 can be specifically, but not limited to, used to store information such as target monitoring process, monitoring association relationship, and operation monitoring data. As an example, as shown in FIG. 7 , the above-mentioned memory 702 may include, but is not limited to, the running unit 602 and the management unit 604 in the monitoring apparatus of the above-mentioned smart device. In addition, it may also include but is not limited to other module units in the monitoring apparatus of the smart device, which will not be repeated in this example.

可选地,上述的传输装置706用于经由一个网络接收或者发送数据。上述的网络具体实例可包括有线网络及无线网络。在一个实例中,传输装置706包括一个网络适配器(Network Interface Controller,NIC),其可通过网线与其他网络设备与路由器相连从而可与互联网或局域网进行通讯。在一个实例中,传输装置706为射频(Radio Frequency,RF)模块,其用于通过无线方式与互联网进行通讯。Optionally, the above-mentionedtransmission device 706 is configured to receive or send data via a network. Specific examples of the above-mentioned networks may include wired networks and wireless networks. In one example, thetransmission device 706 includes a network adapter (Network Interface Controller, NIC), which can be connected to other network devices and routers through a network cable so as to communicate with the Internet or a local area network. In one example, thetransmission device 706 is a radio frequency (RF) module, which is used for wirelessly communicating with the Internet.

此外,上述电子设备还包括:显示器708,用于显示上述运行监测数据;和连接总线710,用于连接上述电子设备中的各个模块部件。In addition, the above-mentioned electronic equipment further includes: adisplay 708 for displaying the above-mentioned operation monitoring data; and aconnection bus 710 for connecting various module components in the above-mentioned electronic equipment.

在其他实施例中,上述终端设备或者服务器可以是一个分布式系统中的一个节点,其中,该分布式系统可以为区块链系统,该区块链系统可以是由该多个节点通过网络通信的形式连接形成的分布式系统。其中,节点之间可以组成点对点(P2P,Peer To Peer)网络,任意形式的计算设备,比如服务器、终端等电子设备都可以通过加入该点对点网络而成为该区块链系统中的一个节点。In other embodiments, the above-mentioned terminal device or server may be a node in a distributed system, wherein the distributed system may be a blockchain system, and the blockchain system may be communicated by the multiple nodes through a network A distributed system formed by connection in the form of. Among them, a peer-to-peer (P2P, Peer To Peer) network can be formed between nodes, and any form of computing devices, such as servers, terminals and other electronic devices can become a node in the blockchain system by joining the peer-to-peer network.

根据本申请的一个方面,提供了一种计算机程序产品或计算机程序,该计算机程序产品或计算机程序包括计算机指令,该计算机指令存储在计算机可读存储介质中。计算机设备的处理器从计算机可读存储介质读取该计算机指令,处理器执行该计算机指令,使得该计算机设备执行上述智能设备的监控方面的各种可选实现方式中提供的方法。其中,该计算机程序被设置为运行时执行上述任一项方法实施例中的步骤。According to one aspect of the present application, there is provided a computer program product or computer program comprising computer instructions stored in a computer readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the methods provided in the various optional implementations of the monitoring aspect of the smart device described above. Wherein, the computer program is configured to execute the steps in any one of the above method embodiments when running.

可选地,在本实施例中,上述计算机可读的存储介质可以被设置为存储用于执行以下步骤的计算机程序:Optionally, in this embodiment, the above-mentioned computer-readable storage medium may be configured to store a computer program for executing the following steps:

S1,在目标设备启动的情况下,运行目标监控进程,并通过目标监控进程监控目标设备的目标进程;S1, when the target device is started, run the target monitoring process, and monitor the target process of the target device through the target monitoring process;

S2,在通过目标监控进程监测到目标进程运行异常的情况下,通过目标监控进程管理目标进程,以使目标进程恢复至运行正常。S2, in the case that the target process is abnormally running through the target monitoring process, manage the target process through the target monitoring process, so as to restore the target process to normal operation.

可选地,在本实施例中,本领域普通技术人员可以理解上述实施例的各种方法中的全部或部分步骤是可以通过程序来指令终端设备相关的硬件来完成,该程序可以存储于一计算机可读存储介质中,存储介质可以包括:闪存盘、只读存储器(Read-Only Memory,ROM)、随机存取器(Random Access Memory,RAM)、磁盘或光盘等。Optionally, in this embodiment, those of ordinary skill in the art can understand that all or part of the steps in the various methods of the above-mentioned embodiments can be completed by instructing the hardware related to the terminal device through a program, and the program can be stored in a In the computer-readable storage medium, the storage medium may include: a flash disk, a read-only memory (Read-Only Memory, ROM), a random access memory (Random Access Memory, RAM), a magnetic disk or an optical disk, and the like.

上述本发明实施例序号仅仅为了描述,不代表实施例的优劣。The above-mentioned serial numbers of the embodiments of the present invention are only for description, and do not represent the advantages or disadvantages of the embodiments.

上述实施例中的集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在上述计算机可读取的存储介质中。基于这样的理解,本发明的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在存储介质中,包括若干指令用以使得一台或多台计算机设备(可为个人计算机、服务器或者网络设备等)执行本发明各个实施例所述方法的全部或部分步骤。If the integrated units in the above-mentioned embodiments are implemented in the form of software functional units and sold or used as independent products, they may be stored in the above-mentioned computer-readable storage medium. Based on this understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, Several instructions are included to cause one or more computer devices (which may be personal computers, servers, or network devices, etc.) to perform all or part of the steps of the methods described in the various embodiments of the present invention.

在本发明的上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述的部分,可以参见其他实施例的相关描述。In the above-mentioned embodiments of the present invention, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, reference may be made to related descriptions of other embodiments.

在本申请所提供的几个实施例中,应该理解到,所揭露的客户端,可通过其它的方式实现。其中,以上所描述的装置实施例仅仅是示意性的,例如所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,单元或模块的间接耦合或通信连接,可以是电性或其它的形式。In the several embodiments provided in this application, it should be understood that the disclosed client may be implemented in other manners. The apparatus embodiments described above are only illustrative, for example, the division of the units is only a logical function division, and there may be other division methods in actual implementation, for example, multiple units or components may be combined or Integration into another system, or some features can be ignored, or not implemented. On the other hand, the shown or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, indirect coupling or communication connection of units or modules, and may be in electrical or other forms.

所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution in this embodiment.

另外,在本发明各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically alone, or two or more units may be integrated into one unit. The above-mentioned integrated units may be implemented in the form of hardware, or may be implemented in the form of software functional units.

以上所述仅是本发明的优选实施方式,应当指出,对于本技术领域的普通技术人员来说,在不脱离本发明原理的前提下,还可以做出若干改进和润饰,这些改进和润饰也应视为本发明的保护范围。The above are only the preferred embodiments of the present invention. It should be pointed out that for those skilled in the art, without departing from the principles of the present invention, several improvements and modifications can be made. It should be regarded as the protection scope of the present invention.

Claims (10)

Translated fromChinese
1.一种智能设备的监控方法,其特征在于,包括:1. a monitoring method of intelligent equipment, is characterized in that, comprises:在目标设备启动的情况下,运行目标监控进程,并通过所述目标监控进程监控所述目标设备的目标进程;When the target device is started, run the target monitoring process, and monitor the target process of the target device through the target monitoring process;在通过所述目标监控进程监测到所述目标进程运行异常的情况下,通过所述目标监控进程管理所述目标进程,以使所述目标进程恢复至运行正常。In the case that the target process is monitored abnormally by the target monitoring process, the target process is managed by the target monitoring process, so as to restore the target process to normal operation.2.根据权利要求1所述的方法,其特征在于,所述通过所述目标监控进程监控所述目标设备的目标进程包括:2. The method according to claim 1, wherein the monitoring the target process of the target device through the target monitoring process comprises:通过所述目标监控进程与所述目标进程的进程间通信,建立所述目标进程与所述目标监控进程的监控关联关系;establishing a monitoring association relationship between the target process and the target monitoring process through inter-process communication between the target monitoring process and the target monitoring process;通过所述监控关联关系,所述目标监控进程监控所述目标进程。Through the monitoring association relationship, the target monitoring process monitors the target process.3.根据权利要求2所述的方法,其特征在于,在建立所述目标进程与所述目标监控进程的监控关联关系之后,还包括:3. The method according to claim 2, wherein after establishing the monitoring association relationship between the target process and the target monitoring process, the method further comprises:控制所述目标进程通过所述监控关联关系,按照目标频率持续发送状态数据包给所述目标监控进程,其中,所述目标监控进程根据所述状态数据包监测所述目标进程的运行情况;Controlling the target process to continuously send status data packets to the target monitoring process according to the target frequency through the monitoring association relationship, wherein the target monitoring process monitors the running status of the target process according to the status data packets;在所述目标监控进程按照所述目标频率持续接收到所述状态数据包的情况下,确定所述目标监控进程监测到所述目标进程运行正常。In the case that the target monitoring process continuously receives the status data packet according to the target frequency, it is determined that the target monitoring process monitors that the target process is running normally.4.根据权利要求3所述的方法,其特征在于,在控制所述目标进程通过所述监控关联关系,按照目标频率持续发送状态数据包给所述目标监控进程之后,还包括:4. The method according to claim 3, wherein after controlling the target process to continuously send status data packets to the target monitoring process according to the target frequency through the monitoring association relationship, the method further comprises:在所述目标监控进程未按照所述目标频率持续接收到所述状态数据包的情况下,确定所述目标监控进程监测到所述目标进程运行异常;通过所述目标监控进程重新启动所述目标进程。In the case that the target monitoring process does not continuously receive the status data packet according to the target frequency, determine that the target monitoring process detects that the target process is running abnormally; restart the target through the target monitoring process process.5.据权利要求3所述的方法,其特征在于,在控制所述目标进程通过所述监控关联关系,按照目标频率持续发送状态数据包给所述目标监控进程之后,还包括:5. The method according to claim 3, wherein after controlling the target process to continuously send status data packets to the target monitoring process according to the target frequency through the monitoring association relationship, the method further comprises:在所述目标监控进程接收到所述状态数据包的情况下,从所述状态数据包中获取所述目标进程的当前内存参数,其中,所述当前内存参数用于指示所述目标进程在当前时刻的可用内存空间;When the target monitoring process receives the status data packet, obtain the current memory parameter of the target process from the status data packet, where the current memory parameter is used to indicate that the target process is currently available memory space at the moment;根据所述可用内存空间确定所述目标进程的内存运行情况。The memory operation status of the target process is determined according to the available memory space.6.根据权利要求5所述的方法,其特征在于,所述根据所述可用内存空间确定所述目标进程的内存运行情况包括:6. The method according to claim 5, wherein the determining the memory running status of the target process according to the available memory space comprises:在所述可用内存空间未处于预设内存范围的情况下,确定所述目标监控进程监测到所述目标进程当前内存运行异常;In the case that the available memory space is not within the preset memory range, determine that the target monitoring process detects that the current memory of the target process is running abnormally;将所述当前内存运行异常写入进程日志中,其中,所述进程日志用于记录所述目标设备中的进程异常。The current memory running exception is written into a process log, where the process log is used to record the process exception in the target device.7.根据权利要求6所述的方法,其特征在于:7. The method according to claim 6, wherein:在所述目标监控进程监测到所述目标进程当前内存异常的情况下,在目标时间重启所述目标设备,其中,所述目标时间为目标时间段中为所述目标设备分配的随机时刻。When the target monitoring process detects that the current memory of the target process is abnormal, the target device is restarted at a target time, where the target time is a random time allocated to the target device in a target time period.8.一种智能设备的监控装置,其特征在于,包括:8. A monitoring device for intelligent equipment, comprising:运行单元,用于在目标设备启动的情况下,运行目标监控进程,并通过所述目标监控进程监控所述目标设备的目标进程;a running unit, configured to run a target monitoring process when the target device is started, and monitor the target process of the target device through the target monitoring process;管理单元,用于在通过所述目标监控进程监测到所述目标进程运行异常的情况下,通过所述目标监控进程管理所述目标进程,以使所述目标进程恢复至运行正常。A management unit, configured to manage the target process through the target monitoring process under the condition that the target process is abnormally running, so as to restore the target process to normal operation.9.一种计算机可读的存储介质,其特征在于,所述计算机可读的存储介质包括存储的程序,其中,所述程序运行时执行所述权利要求1至7任一项中所述的方法。9. A computer-readable storage medium, characterized in that the computer-readable storage medium comprises a stored program, wherein, when the program is run, the program described in any one of claims 1 to 7 is executed. method.10.一种电子设备,包括存储器和处理器,其特征在于,所述存储器中存储有计算机程序,所述处理器被设置为通过所述计算机程序执行所述权利要求1至7任一项中所述的方法。10. An electronic device comprising a memory and a processor, wherein a computer program is stored in the memory, and the processor is configured to execute any one of claims 1 to 7 through the computer program the method described.
CN202210319587.7A2022-03-292022-03-29 Monitoring method and device for smart device, storage medium and electronic devicePendingCN114815641A (en)

Priority Applications (1)

Application NumberPriority DateFiling DateTitle
CN202210319587.7ACN114815641A (en)2022-03-292022-03-29 Monitoring method and device for smart device, storage medium and electronic device

Applications Claiming Priority (1)

Application NumberPriority DateFiling DateTitle
CN202210319587.7ACN114815641A (en)2022-03-292022-03-29 Monitoring method and device for smart device, storage medium and electronic device

Publications (1)

Publication NumberPublication Date
CN114815641Atrue CN114815641A (en)2022-07-29

Family

ID=82531509

Family Applications (1)

Application NumberTitlePriority DateFiling Date
CN202210319587.7APendingCN114815641A (en)2022-03-292022-03-29 Monitoring method and device for smart device, storage medium and electronic device

Country Status (1)

CountryLink
CN (1)CN114815641A (en)

Citations (7)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN1904852A (en)*2006-08-012007-01-31西安西电捷通无线网络通信有限公司Method for monitoring and abnormal processing of computer application program
CN101268447A (en)*2005-05-262008-09-17美国联合包裹服务公司 Software Process Monitoring
CN108008800A (en)*2017-11-292018-05-08锐捷网络股份有限公司A kind of reset request processing method, device and equipment
CN109660426A (en)*2018-12-142019-04-19泰康保险集团股份有限公司Monitoring method and system, computer-readable medium and electronic equipment
CN111090562A (en)*2019-11-252020-05-01广东科徕尼智能科技有限公司Business process monitoring method, equipment and storage medium of edge intelligent gateway
CN111949490A (en)*2020-08-142020-11-17中国工商银行股份有限公司JVM process monitoring method and device
CN112350840A (en)*2019-08-082021-02-09中移物联网有限公司Fault monitoring and repairing method and related equipment

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN101268447A (en)*2005-05-262008-09-17美国联合包裹服务公司 Software Process Monitoring
CN1904852A (en)*2006-08-012007-01-31西安西电捷通无线网络通信有限公司Method for monitoring and abnormal processing of computer application program
CN108008800A (en)*2017-11-292018-05-08锐捷网络股份有限公司A kind of reset request processing method, device and equipment
CN109660426A (en)*2018-12-142019-04-19泰康保险集团股份有限公司Monitoring method and system, computer-readable medium and electronic equipment
CN112350840A (en)*2019-08-082021-02-09中移物联网有限公司Fault monitoring and repairing method and related equipment
CN111090562A (en)*2019-11-252020-05-01广东科徕尼智能科技有限公司Business process monitoring method, equipment and storage medium of edge intelligent gateway
CN111949490A (en)*2020-08-142020-11-17中国工商银行股份有限公司JVM process monitoring method and device

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
轧制技术及连轧自动化国家重点实验室: "新一代全连续热连轧带钢质量智能精准控制系统研究与应用", 30 April 2019, 冶金工业出版社, pages: 121 - 122*

Similar Documents

PublicationPublication DateTitle
CN115296948A (en)Scene information updating method and device, storage medium and electronic device
CN109245974A (en)Household electrical appliance distribution method, apparatus and computer readable storage medium
CN114866365B (en)Arbitration machine election method, device, intelligent equipment and computer readable storage medium
CN115175152B (en) Smart device binding method and device, storage medium and electronic device
CN114815641A (en) Monitoring method and device for smart device, storage medium and electronic device
CN115309062B (en)Control method and device of equipment, storage medium and electronic device
CN115174297B (en)Method and device for updating attribute information, storage medium and electronic device
CN115695586A (en)Login processing method, device and system
CN105847022A (en)Network configuration methods and system of local area network of power line communication (PLC)
CN115474225A (en)Online state determination method and device, storage medium and electronic device
CN115499333A (en)Method, system, storage medium and electronic device for determining association relationship
CN116133088B (en) Smart device pairing method and device, storage medium and electronic device
CN113126510A (en)Household appliance control system and control method thereof
CN115695182A (en)Network connection method, device, storage medium and electronic device
CN114697345B (en)Information updating method and device, storage medium and electronic device
CN115296947B (en)Control command response method and device, storage medium and electronic device
CN115174296B (en)Equipment function access method and device, storage medium and electronic device
CN115955386B (en)Determination method and device for disconnection reason, storage medium and electronic device
CN117176791A (en) Push information sending method and device, storage medium and electronic device
CN115312048B (en)Equipment awakening method and device, storage medium and electronic device
CN117240874A (en) Equipment linkage method and device, storage medium and electronic device
CN117527459A (en)Control method and device of intelligent equipment, storage medium and electronic device
CN117834493A (en) IoT module performance testing method, device and storage medium
CN120148499A (en) Method and device for executing voice commands, storage medium and electronic device
CN105933924B (en)Online state detection method and device for information interaction software and terminal

Legal Events

DateCodeTitleDescription
PB01Publication
PB01Publication
SE01Entry into force of request for substantive examination
SE01Entry into force of request for substantive examination

[8]ページ先頭

©2009-2025 Movatter.jp