CN115834645A - Equipment control method and related equipment - Google Patents
Equipment control method and related equipment Download PDFInfo
- Publication number
- CN115834645A CN115834645A CN202211233994.2A CN202211233994A CN115834645A CN 115834645 A CN115834645 A CN 115834645A CN 202211233994 A CN202211233994 A CN 202211233994A CN 115834645 A CN115834645 A CN 115834645A
- Authority
- CN
- China
- Prior art keywords
- target
- physical address
- message
- verification information
- operation message
- 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.)
- Granted
Links
Images
Landscapes
- Computer And Data Communications (AREA)
- Selective Calling Equipment (AREA)
Abstract
本申请实施例提供一种设备控制方法及相关设备,涉及设备领域。该方法中,计算机设备接收控制设备广播的操作报文。该操作报文包括操作报文头、目标计算机设备的目标物理地址和目标计算机设备的目标验证信息。操作报文满足预设条件,目标物理地址和计算机设备的本地物理地址相同,且目标验证信息和计算机设备的本地验证信息一致时,计算机设备执行目标操作,且在目标操作执行完成后,计算机设备确定操作报文的操作结果为操作成功。计算机设备向控制设备发送操作报文的操作结果。本方案中,控制设备通过操作报文可以远程控制计算机设备执行目标操作,且实现成本低。
Embodiments of the present application provide a device control method and related devices, which relate to the field of devices. In the method, the computer device receives the operation message broadcast by the control device. The operation message includes an operation message header, a target physical address of the target computer device, and target verification information of the target computer device. When the operation message meets the preset conditions, the target physical address is the same as the local physical address of the computer device, and the target verification information is consistent with the local verification information of the computer device, the computer device executes the target operation, and after the target operation is completed, the computer device It is determined that the operation result of the operation message is the operation success. The computer device sends the operation result of the operation message to the control device. In this solution, the control device can remotely control the computer device to perform the target operation through the operation message, and the implementation cost is low.
Description
技术领域technical field
本发明实施例涉及设备领域,尤其涉及一种设备控制方法及相关设备。Embodiments of the present invention relate to the field of equipment, and in particular, to a method for controlling equipment and related equipment.
背景技术Background technique
现有技术中,主要通过远程登录基本控制系统(Basic Control System,BMC)来管理设备,实现设备远程下电。参见图1,控制端101可以管理K个服务器(K为正整数),例如如服务器1、服务器2、……、服务器K。以服务器1为例,在服务器1上额外搭建一套基本控制系统,可以通过网际互连协议(Internet Protocol,IP)访问该基本控制系统,从而达到控制服务器1的目的。具体地,用户在控制端101上通过浏览器访问基本控制系统。在该技术方案中,被控制设备(如服务器1)需要安装基本控制系统,且基本控制系统需要时刻在线,方案的实现复杂且实现成本较高。In the prior art, the device is managed mainly through remote login to a basic control system (Basic Control System, BMC), so as to realize remote power-off of the device. Referring to FIG. 1 , the control terminal 101 can manage K servers (K is a positive integer), such as server 1, server 2, . . . , server K. Taking server 1 as an example, an additional set of basic control system is built on server 1, and the basic control system can be accessed through Internet Protocol (IP), so as to achieve the purpose of controlling server 1. Specifically, the user accesses the basic control system through a browser on the control terminal 101 . In this technical solution, the controlled device (such as the server 1) needs to be equipped with a basic control system, and the basic control system needs to be online at all times, so the implementation of the solution is complicated and costly.
发明内容Contents of the invention
本申请提供一种设备控制方法及相关设备,可以远程控制计算机设备执行目标操作,且实现成本低。The present application provides a device control method and related devices, which can remotely control computer devices to perform target operations, and the implementation cost is low.
第一方面,提供一种设备控制方法,应用于计算机设备。In a first aspect, a device control method is provided, which is applied to a computer device.
上述设备控制方法包括以下步骤:The above-mentioned device control method includes the following steps:
计算机设备接收控制设备广播的操作报文。该操作报文包括操作报文头、目标计算机设备的目标物理地址和目标计算机设备的目标验证信息。操作报文满足预设条件,目标物理地址和计算机设备的本地物理地址相同,且目标验证信息和计算机设备的本地验证信息一致的情况下,计算机设备执行目标操作,且在目标操作执行完成后,计算机设备确定操作报文的操作结果为操作成功。其中,预设条件包括操作报文中目标物理地址的重复次数大于或等于预设次数,和/或,操作报文头的长度大于或等于预设长度。计算机设备向控制设备发送操作报文的操作结果。The computer device receives the operation message broadcast by the control device. The operation message includes an operation message header, a target physical address of the target computer device, and target verification information of the target computer device. When the operation message meets the preset conditions, the target physical address is the same as the local physical address of the computer device, and the target verification information is consistent with the local verification information of the computer device, the computer device executes the target operation, and after the target operation is completed, The computer device determines that the operation result of the operation message is a successful operation. Wherein, the preset condition includes that the number of repetitions of the target physical address in the operation message is greater than or equal to the preset number, and/or, the length of the header of the operation message is greater than or equal to the preset length. The computer device sends the operation result of the operation message to the control device.
本方案中,控制设备通过广播操作报文可以远程控制计算机设备执行目标操作,且实现成本低。具体地,计算机设备在操作报文满足预设条件时,可以确定操作报文是用于控制目标计算机设备执行目标操作的,另外,目标物理地址和计算机设备的本地物理地址相同,且目标验证信息和计算机设备的本地验证信息一致的情况下,计算机设备将执行目标操作,且在目标操作执行完成后,计算机设备确定操作报文的操作结果为操作成功。最后,计算机设备向控制设备发送操作报文的操作结果。In this solution, the control device can remotely control the computer device to perform the target operation by broadcasting the operation message, and the implementation cost is low. Specifically, when the operation message satisfies the preset condition, the computer device can determine that the operation message is used to control the target computer device to perform the target operation. In addition, the target physical address is the same as the local physical address of the computer device, and the target verification information If it is consistent with the local verification information of the computer device, the computer device will execute the target operation, and after the target operation is executed, the computer device determines that the operation result of the operation message is the operation success. Finally, the computer device sends the operation result of the operation message to the control device.
结合第一方面,在一种实施方式中,上述操作报文还包括操作指示信息,操作指示信息用于指示目标计算机设备执行目标操作;此时,预设条件为操作报文包括操作指示信息。With reference to the first aspect, in an implementation manner, the above operation message further includes operation instruction information, and the operation instruction information is used to instruct the target computer device to perform the target operation; at this time, the preset condition is that the operation message includes the operation instruction information.
本方案中,当操作报文包括上述操作指示信息时,可以确定该操作报文是用于控制目标计算机设备执行目标操作的。In this solution, when the operation message includes the above operation instruction information, it can be determined that the operation message is used to control the target computer device to perform the target operation.
结合第一方面,在一种实施方式中,设备控制方法还包括:操作报文中的目标物理地址和计算机设备的本地物理地址不相同时,可以确定该操作报文不是用于控制本计算机设备的,计算机设备丢弃该操作报文。With reference to the first aspect, in one embodiment, the device control method further includes: when the target physical address in the operation message is different from the local physical address of the computer device, it can be determined that the operation message is not used to control the computer device , the computer device discards the operation packet.
结合第一方面,在一种实施方式中,设备控制方法还包括:With reference to the first aspect, in an implementation manner, the device control method further includes:
操作报文中的目标物理地址和计算机设备的本地物理地址相同,且目标验证信息和本地验证信息不一致时,计算机设备向控制设备发送反馈报文,反馈报文用于指示目标验证信息和本地验证信息不一致,以使控制设备知晓目标验证信息不正确,控制设备可以修改目标验证信息并重新广播操作报文。When the target physical address in the operation message is the same as the local physical address of the computer device, and the target verification information is inconsistent with the local verification information, the computer device sends a feedback message to the control device, and the feedback message is used to indicate the target verification information and the local verification information. The information is inconsistent, so that the control device knows that the target verification information is incorrect, and the control device can modify the target verification information and re-broadcast the operation message.
结合第一方面,在一种实施方式中,计算机设备接收控制设备广播的操作报文之前,设备控制方法还包括:With reference to the first aspect, in an implementation manner, before the computer device receives the operation message broadcast by the control device, the device control method further includes:
计算机设备接收控制设备广播的物理地址请求。计算机设备响应物理地址请求,向控制设备发送本地物理地址。The computer device receives the physical address request broadcast by the control device. The computer device sends the local physical address to the control device in response to the physical address request.
本方案中,控制设备在远程操作计算机设备之前,需要先通过物理地址请求获得计算机设备的本地物理地址。在需要对计算机设备进行操作时,将计算机设备的本地物理地址作为目标物理地址。In this solution, before the control device remotely operates the computer device, it needs to obtain the local physical address of the computer device through a physical address request. When the computer device needs to be operated, the local physical address of the computer device is used as the target physical address.
结合第一方面,在一种实施方式中,上述目标操作包括下电,重启,或者,下电后等待第一时间后上电。With reference to the first aspect, in an implementation manner, the foregoing target operation includes powering off, restarting, or powering on after waiting for a first time after powering off.
第二方面,本申请还提供了一种设备控制方法,应用于控制设备。In a second aspect, the present application also provides a device control method, which is applied to control devices.
设备控制方法包括以下步骤:The device control method includes the following steps:
控制设备广播操作报文。操作报文包括操作报文头、目标计算机设备的目标物理地址和目标计算机设备的目标验证信息。控制设备接收来自计算机设备的操作报文的操作结果,其中,计算机设备在操作报文满足预设条件,目标物理地址和计算机设备的本地物理地址相同,且目标验证信息和计算机设备的本地验证信息一致时,执行目标操作,且在目标操作执行完成后,确定操作报文的操作结果为操作成功。预设条件包括操作报文中目标物理地址的重复次数大于或等于预设次数,和/或,操作报文头的长度大于或等于预设长度。The control device broadcasts an operation message. The operation message includes an operation message header, a target physical address of the target computer device, and target verification information of the target computer device. The control device receives the operation result of the operation message from the computer device, wherein the computer device meets the preset conditions in the operation message, the target physical address is the same as the local physical address of the computer device, and the target verification information is the same as the local verification information of the computer device When they are consistent, the target operation is executed, and after the target operation is executed, it is determined that the operation result of the operation message is the operation success. The preset condition includes that the number of repetitions of the target physical address in the operation message is greater than or equal to the preset number, and/or, the length of the header of the operation message is greater than or equal to the preset length.
本方案中,控制设备通过控制指令可以远程控制计算机设备执行目标操作,且实现成本低。In this solution, the control device can remotely control the computer device to perform the target operation through the control instruction, and the implementation cost is low.
结合第二方面,在一种实施方式中,上述操作报文还包括操作指示信息,操作指示信息用于指示目标计算机设备执行目标操作;此时,预设条件为操作报文包括操作指示信息。With reference to the second aspect, in an implementation manner, the above-mentioned operation message further includes operation instruction information, and the operation instruction information is used to instruct the target computer device to perform the target operation; at this time, the preset condition is that the operation message includes the operation instruction information.
结合第二方面,在一种实施方式中,设备控制方法还包括:With reference to the second aspect, in an implementation manner, the device control method further includes:
控制设备接收计算机设备在确定目标物理地址和本地物理地址相同,且目标验证信息和本地验证信息不一致时发送的反馈报文,反馈报文用于指示目标验证信息和本地验证信息不一致。The control device receives a feedback message sent by the computer device when it is determined that the target physical address is the same as the local physical address, and the target verification information is inconsistent with the local verification information, and the feedback message is used to indicate that the target verification information is inconsistent with the local verification information.
结合第二方面,在一种实施方式中,设备控制方法还包括:With reference to the second aspect, in an implementation manner, the device control method further includes:
控制设备广播物理地址请求。控制设备接收计算机设备响应物理地址请求发送的本地物理地址。The control device broadcasts a physical address request. The control device receives the local physical address sent by the computer device in response to the physical address request.
结合第二方面,在一种实施方式中,上述目标操作包括下电,重启,或者,下电后等待第一时间后上电。With reference to the second aspect, in an implementation manner, the foregoing target operation includes powering off, restarting, or powering on after waiting for a first time after powering off.
第三方面,本申请还提供了一种计算机设备,包括用于执行如第一方面所述方法的模块。In a third aspect, the present application also provides a computer device, including a module for executing the method described in the first aspect.
第四方面,本申请还提供了一种控制设备,包括用于执行如第二方面所述方法的模块。In a fourth aspect, the present application further provides a control device, including a module for executing the method as described in the second aspect.
第五方面,本申请还提供了一种电子设备,包括一个或多个处理器;其中,所述一个或多个处理器用于执行一个或多个存储器存储的计算机程序,使得所述计算机设备实现如第一方面或第二方面所述的方法。In a fifth aspect, the present application also provides an electronic device, including one or more processors; wherein, the one or more processors are configured to execute one or more computer programs stored in memories, so that the computer device realizes The method as described in the first aspect or the second aspect.
第六方面,本申请还提供了一种计算机可读存储介质,所述计算机可读存储介质存储有指令,当所述指令被处理器执行时,实现如第一方面或第二方面所述的方法。In a sixth aspect, the present application also provides a computer-readable storage medium, the computer-readable storage medium stores instructions, and when the instructions are executed by a processor, the method described in the first aspect or the second aspect is realized. method.
第七方面,本申请还提供一种包含指令的计算机程序产品,当所述计算机程序产品在计算机上运行时,使得计算机执行第一方面或第二方面所述的方法。In a seventh aspect, the present application further provides a computer program product containing instructions, which, when the computer program product is run on a computer, cause the computer to execute the method described in the first aspect or the second aspect.
第八方面,本申请还提供一种芯片,所述芯片包括处理器与数据接口,所述处理器通过所述数据接口读取存储器上存储的指令,执行第一方面或第二方面所述的方法。In the eighth aspect, the present application also provides a chip, the chip includes a processor and a data interface, and the processor reads the instructions stored in the memory through the data interface, and executes the instructions described in the first aspect or the second aspect. method.
可选地,作为一种实现方式,所述芯片还可以包括存储器,所述存储器中存储有指令,所述处理器用于执行所述存储器上存储的指令,当所述指令被执行时,所述处理器用于执行第一方面或第二方面所述的方法。Optionally, as an implementation manner, the chip may further include a memory, the memory stores instructions, the processor is configured to execute the instructions stored in the memory, and when the instructions are executed, the The processor is configured to execute the method described in the first aspect or the second aspect.
附图说明Description of drawings
下面对本申请实施例用到的附图进行介绍。The accompanying drawings used in the embodiments of the present application are introduced below.
图1是本申请实施例提供的一种BMC系统管理技术的结构示意图;Fig. 1 is the structural representation of a kind of BMC system management technology provided by the embodiment of the present application;
图2是本申请实施例提供的一种设备控制方法的流程示意图;FIG. 2 is a schematic flowchart of a device control method provided in an embodiment of the present application;
图3是本申请实施例提供的一种操作报文的结构示意图;FIG. 3 is a schematic structural diagram of an operation message provided by an embodiment of the present application;
图4是本申请实施例提供的一种结果报文的结构示意图;FIG. 4 is a schematic structural diagram of a result message provided by an embodiment of the present application;
图5是本申请实施例提供的一种计算机设备的结构示意图;FIG. 5 is a schematic structural diagram of a computer device provided by an embodiment of the present application;
图6是本申请实施例提供的一种控制设备的结构示意图;FIG. 6 is a schematic structural diagram of a control device provided by an embodiment of the present application;
图7是本申请实施例提供的一种控制系统的结构示意图;FIG. 7 is a schematic structural diagram of a control system provided by an embodiment of the present application;
图8是本申请实施例提供的另一种控制系统的结构示意图;Fig. 8 is a schematic structural diagram of another control system provided by an embodiment of the present application;
图9是本申请实施例提供的一种电子设备的结构示意图。FIG. 9 is a schematic structural diagram of an electronic device provided by an embodiment of the present application.
具体实施方式Detailed ways
下面将结合附图,对本申请中的技术方案进行描述。The technical solution in this application will be described below with reference to the accompanying drawings.
由于本申请实施例涉及的应用,为了便于理解,下面先对本申请实施例涉及的相关术语等相关概念进行介绍。Due to the applications involved in the embodiments of the present application, for ease of understanding, the following first introduces related terms and other related concepts involved in the embodiments of the present application.
本申请实施例中,“示例性的”或者“例如”等词用于表示作例子、例证或说明。本申请中被描述为“示例性的”或者“例如”的任何实施例或设计方案不应被解释为比其他实施例或设计方案更优选或更具优势。确切而言,使用“示例性的”或者“例如”等词旨在以具体方式呈现相关概念。In the embodiments of the present application, words such as "exemplary" or "for example" are used as examples, illustrations or descriptions. Any embodiment or design described herein as "exemplary" or "for example" is not to be construed as preferred or advantageous over other embodiments or designs. Rather, the use of words such as "exemplary" or "such as" is intended to present related concepts in a concrete manner.
本申请中实施例提到的“至少一个”是指一个或者多个,“多个”是指两个或两个以上。“以下至少一项(个)”或其类似表达,是指的这些项中的任意组合,包括单项(个)或复数项(个)的任意组合。例如,a、b、或c中的至少一项(个),可以表示:a、b、c、(a和b)、(a和c)、(b和c)、或(a和b和c),其中a、b、c可以是单个,也可以是多个。“和/或”,描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A、同时存在A和B、单独存在B这三种情况,其中A、B可以是单数或者复数。字符“/”一般表示前后关联对象是一种“或”的关系。而本申请中实施例的步骤的序号(如步骤S1、步骤S21等)只为了区分不同的步骤,不对步骤之间的先后执行顺序造成限定。The "at least one" mentioned in the embodiments of the present application refers to one or more, and the "multiple" refers to two or more. "At least one of the following" or similar expressions refer to any combination of these items, including any combination of single or plural items. For example, at least one item (piece) of a, b, or c may represent: a, b, c, (a and b), (a and c), (b and c), or (a and b and c), where a, b, c can be single or multiple. "And/or" describes the association relationship of associated objects, indicating that there may be three types of relationships, for example, A and/or B, which may indicate: A exists alone, A and B exist simultaneously, and B exists alone, among which A and B may be singular or plural. The character "/" generally indicates that the contextual objects are an "or" relationship. However, the sequence numbers of the steps in the embodiments of the present application (such as step S1, step S21, etc.) are only for distinguishing different steps, and do not limit the execution order of the steps.
以及,除非有相反的说明,本申请实施例使用“第一”、“第二”等序数词是用于对多个对象进行区分,不用于限定多个对象的顺序、时序、优先级或者重要程度。例如,第一设备和第二设备,只是为了便于描述,而并不是表示这第一设备和第二设备的结构、重要程度等的不同,在某些实施例中,第一设备和第二设备还可以是同样的设备。And, unless otherwise stated, the embodiments of the present application use ordinal numerals such as "first" and "second" to distinguish multiple objects, and are not used to limit the order, timing, priority or importance of multiple objects degree. For example, the first device and the second device are only for the convenience of description, and do not represent the differences in the structure and importance of the first device and the second device. In some embodiments, the first device and the second device It can also be the same device.
上述实施例中所用,根据上下文,术语“当……时”可以被解释为意思是“如果……”或“在……后”或“响应于确定……”或“响应于检测到……”。以上所述仅为本申请的可选实施例,并不用以限制本申请,凡在本申请的构思和原则之内,所作的任何修改、等同替换、改进等,均应包含在本申请的保护范围之内。As used in the above embodiments, depending on the context, the term "when" may be interpreted to mean "if..." or "after" or "in response to determining..." or "in response to detecting... ". The above are only optional embodiments of the application, and are not intended to limit the application. Any modifications, equivalent replacements, improvements, etc. made within the concept and principles of the application shall be included in the protection of the application. within range.
为了便于理解,下面先对本申请实施例涉及的相关术语及概念进行介绍。For ease of understanding, the following first introduces relevant terms and concepts involved in the embodiments of the present application.
(1)、物理地址(1), physical address
介质访问控制(Media Access Control,MAC)地址是识别局域网(Local AreaNetwork,LAN)节点的标识。MAC地址也称为物理地址。例如,物理地址大小是48比特位(bit),前24位是厂商编号,后24位为网卡编号。A Media Access Control (Media Access Control, MAC) address is an identifier for identifying a local area network (Local Area Network, LAN) node. MAC address is also known as physical address. For example, the size of the physical address is 48 bits, the first 24 bits are the serial number of the manufacturer, and the last 24 bits are the serial number of the network card.
(2)、网卡(2), network card
网卡是一块被设计用来允许计算机在计算机网络上进行通讯的计算机硬件。由于其拥有MAC地址,因此属于开放式系统互联通信参考模型(英语:Open SystemInterconnection Reference Model,缩写为OSI)的第1层和2层之间。它使得用户可以通过电缆或无线相互连接。A network card is a piece of computer hardware designed to allow a computer to communicate over a computer network. Because it has a MAC address, it belongs between the first and second layers of the Open System Interconnection Reference Model (English: Open System Interconnection Reference Model, abbreviated as OSI). It allows users to connect to each other via cable or wirelessly.
(3)、主板(3), main board
主板,又叫主机板(Mainboard)、系统板(Systemboard)、或母板(motherboard),是计算机最基本的同时也是最重要的部件之一。主板在整个计算机系统中扮演着举足轻重的角色。主板制造质量的高低,决定了硬件系统的稳定性。主板是计算机硬件系统的核心,也是主机箱内面积最大的一块印刷电路板。主板的主要功能是传输各种电子信号,部分芯片也负责初步处理一些外围数据。计算机主机中的各个部件都是通过主板来连接的,计算机在正常运行时对系统内存、存储设备和其他输入/输出(I/O)设备的操控都必须通过主板来完成。计算机性能是否能够充分发挥,硬件功能是否足够,以及硬件兼容性如何等,都取决于主板的设计。Motherboard, also known as Mainboard, System Board, or Motherboard, is one of the most basic and important components of a computer. The motherboard plays a pivotal role in the entire computer system. The quality of motherboard manufacturing determines the stability of the hardware system. The motherboard is the core of the computer hardware system, and it is also the largest printed circuit board in the main box. The main function of the motherboard is to transmit various electronic signals, and some chips are also responsible for preliminary processing of some peripheral data. All components in the host computer are connected through the motherboard, and the control of system memory, storage devices and other input/output (I/O) devices must be completed through the motherboard during normal operation of the computer. Whether the performance of the computer can be fully utilized, whether the hardware functions are sufficient, and how compatible the hardware is, all depend on the design of the motherboard.
(4)、计算机设备(4), computer equipment
本文中的计算机设备是指包括网卡和主板的设备,例如服务器、计算机(台式计算机、笔记本电脑等)、单片机等其他带网络入口的设备。其中,计算机设备的MAC地址为网卡的MAC地址。Computer equipment in this article refers to equipment including network cards and motherboards, such as servers, computers (desktop computers, notebook computers, etc.), single-chip microcomputers, and other equipment with network access. Wherein, the MAC address of the computer device is the MAC address of the network card.
以上对于技术术语的说明可以应用在下文中。The above description of technical terms can be applied in the following.
本申请实施例提供一种设备控制方法,可以远程控制计算机设备执行目标操作,且实现成本低。The embodiment of the present application provides a device control method, which can remotely control a computer device to execute a target operation, and the implementation cost is low.
下面对本申请提供的设备控制方法做具体说明:The equipment control method provided by this application is described in detail below:
本申请实施例中的设备控制方法应用于控制系统。上述控制系统包括控制设备和至少一个计算机设备,下文中,以至少一个计算机设备中的一个计算机设备为例对设备控制方法进行具体说明。The device control method in the embodiment of the present application is applied to a control system. The above control system includes a control device and at least one computer device. Hereinafter, the device control method will be described in detail by taking one of the at least one computer device as an example.
参考图2,图2是本申请实施例提供的一种设备控制方法的流程示意图。上述设备控制方法包括以下步骤:Referring to FIG. 2 , FIG. 2 is a schematic flowchart of a device control method provided in an embodiment of the present application. The above-mentioned device control method includes the following steps:
201、计算机设备接收控制设备广播的操作报文。操作报文包括操作报文头、目标计算机设备的目标物理地址和目标计算机设备的目标验证信息。201. The computer device receives the operation message broadcast by the control device. The operation message includes an operation message header, a target physical address of the target computer device, and target verification information of the target computer device.
举例地,控制设备与多个计算机设备连接,控制设备向多个计算机设备广播操作报文。For example, the control device is connected to multiple computer devices, and the control device broadcasts operation messages to the multiple computer devices.
具体地,操作报文为局域网报文,即二层网络协议报文,对局域网报文的长度不作限制。其中,目标验证信息是目标计算机设备的使用许可授权信息,例如,目标验证信息包括目标密码。Specifically, the operation message is a LAN message, that is, a Layer 2 network protocol message, and the length of the LAN message is not limited. Wherein, the target verification information is the use license authorization information of the target computer device, for example, the target verification information includes the target password.
202、在操作报文满足预设条件,目标物理地址和计算机设备的本地物理地址相同,且目标验证信息和计算机设备的本地验证信息一致的情况下,计算机设备执行目标操作,且在目标操作执行完成后,计算机设备确定操作报文的操作结果为操作成功。其中,预设条件包括操作报文中目标物理地址的重复次数大于或等于预设次数,和/或,操作报文头的长度大于或等于预设长度。202. When the operation message meets the preset conditions, the target physical address is the same as the local physical address of the computer device, and the target verification information is consistent with the local verification information of the computer device, the computer device executes the target operation, and the target operation is performed After completion, the computer device determines that the operation result of the operation message is a successful operation. Wherein, the preset condition includes that the number of repetitions of the target physical address in the operation message is greater than or equal to the preset number, and/or, the length of the header of the operation message is greater than or equal to the preset length.
其中,操作报文是否满足预设条件,目标物理地址和计算机设备的本地物理地址是否相同,以及,目标验证信息和计算机设备的本地验证信息是否一致,对上述三者的判断顺序不做特别限定。Among them, whether the operation message satisfies the preset conditions, whether the target physical address is the same as the local physical address of the computer device, and whether the target verification information is consistent with the local verification information of the computer device, and there is no special limitation on the judgment order of the above three .
具体地,通过设定目标物理地址的重复次数和/或操作报文头的长度来与其他报文进行区分,当计算机设备解析接收到的操作报文中包含的物理地址的重复次数大于或等于预设次数和/或操作报文头的长度大于或等于预设长度时,则确认该操作报文为控制目标计算机设备执行目标操作的报文。Specifically, by setting the number of repetitions of the target physical address and/or the length of the operation message header to distinguish it from other messages, when the computer device parses the number of repetitions of the physical address contained in the received operation message is greater than or equal to When the preset number of times and/or the length of the operation message header is greater than or equal to the preset length, it is confirmed that the operation message is a message for controlling the target computer device to perform the target operation.
其中,预设次数的具体数值可以根据实际情况进行设置,可以使得操作报文区别于其他报文即可。例如,预设次数为5、10或16等。进一步示例性地,操作报文中目标物理地址的重复次数小于业务报文中物理地址的重复次数。Wherein, the specific value of the preset number of times can be set according to the actual situation, so that the operation message can be distinguished from other messages. For example, the preset times are 5, 10 or 16 and so on. As a further example, the number of repetitions of the target physical address in the operation message is smaller than the number of repetitions of the physical address in the service message.
同样地,预设长度的具体数值可以根据实际情况进行设置,可以使得操作报文区别于其他报文即可。例如,预设长度为5字节、6字节或10字节等。进一步示例性地,操作报文的报文头的长度小于业务报文的报文头的长度。Similarly, the specific value of the preset length can be set according to the actual situation, so that the operation message can be distinguished from other messages. For example, the preset length is 5 bytes, 6 bytes or 10 bytes, etc. In a further example, the length of the header of the operation message is smaller than the length of the header of the service message.
示例性地,计算机设备的本地验证信息包括本地密码,本地密码可以为计算机设备的用户设置的使用密码(当使用密码验证通过时,则用户可以使用计算机设备),或者,本地密码为全能密码,即对控制系统中至少一个计算机设备均适用的使用密码。Exemplarily, the local verification information of the computer device includes a local password, and the local password may be a password set by the user of the computer device (when the password verification is passed, the user can use the computer device), or the local password is an omnipotent password, That is, the use password applicable to at least one computer device in the control system.
203、计算机设备向控制设备发送操作报文的操作结果。203. The computer device sends the operation result of the operation message to the control device.
相应地,控制设备接收来自计算机设备的操作报文的操作结果。Correspondingly, the control device receives the operation result of the operation message from the computer device.
具体地,计算机设备向控制设备发送操作报文的操作结果的方式可以为向控制设备发送结果报文,对结果报文的具体结构和报文长度不做特别限定。示例性地,结果报文包含的信息包括操作报文的操作结果,例如,用“1”表示操作成功,用“0”表示操作失败。示例性地,结果报文包含的信息还包括以下至少一项:计算机设备的本地物理地址信息、或结果报文指示信息等。例如,结果报文指示信息为2字节的“AAAA”或4字节的“BBBBBBBB”。其中,A和B为十六进制数。Specifically, the manner in which the computer device sends the operation result of the operation message to the control device may be to send a result message to the control device, and the specific structure and message length of the result message are not particularly limited. Exemplarily, the information contained in the result message includes the operation result of the operation message, for example, "1" indicates that the operation is successful, and "0" indicates that the operation fails. Exemplarily, the information included in the result message further includes at least one of the following: local physical address information of the computer device, or result message indication information, and the like. For example, the indication information of the result message is "AAAA" of 2 bytes or "BBBBBBBB" of 4 bytes. Among them, A and B are hexadecimal numbers.
本申请实施例中,控制设备通过操作报文(理解为局域网络数据包)可以远程控制计算机设备执行目标操作,且不依赖于计算机设备是否安装有远程访问控制系统(如BMC系统),实现成本低。In the embodiment of the present application, the control device can remotely control the computer device to perform the target operation through the operation message (understood as a local area network data packet), and does not depend on whether the computer device is installed with a remote access control system (such as a BMC system), and the realization cost Low.
作为一种可能的实施方式中,上述操作报文还包括操作指示信息,操作指示信息用于指示目标计算机设备执行目标操作;此时,预设条件为操作报文包括操作指示信息。As a possible implementation manner, the above operation message further includes operation instruction information, and the operation instruction information is used to instruct the target computer device to perform the target operation; at this time, the preset condition is that the operation message includes the operation instruction information.
示例性地,目标操作为下电操作时,操作指示信息为2字节的“DDDD”。又示例性地,目标操作为重启操作时,操作指示信息为2字节的“CCCC”。其中,C和D为十六进制数。Exemplarily, when the target operation is a power-off operation, the operation indication information is "DDDD" of 2 bytes. In another example, when the target operation is a restart operation, the operation indication information is "CCCC" of 2 bytes. Among them, C and D are hexadecimal numbers.
本申请实施例中,当操作报文包括上述操作指示信息时,可以确定该操作报文是用于控制目标计算机设备执行目标操作的。当然,当操作报文包括操作报文头、目标物理地址、目标验证信息和操作指示信息时,预设条件仍然可以为操作报文中目标物理地址的重复次数大于或等于预设次数,和/或,操作报文头的长度大于或等于预设长度。In the embodiment of the present application, when the operation message includes the above operation indication information, it can be determined that the operation message is used to control the target computer device to perform the target operation. Of course, when the operation message includes the operation message header, target physical address, target verification information and operation instruction information, the preset condition can still be that the number of repetitions of the target physical address in the operation message is greater than or equal to the preset number of times, and/or Or, the length of the operation header is greater than or equal to the preset length.
作为一种可能的实施方式中,上述目标操作包括下电,重启,或者,下电后等待第一时间后上电。As a possible implementation manner, the foregoing target operation includes powering off, restarting, or powering on after waiting for a first time after powering off.
其中,下电是指安全下电,安全下电可以理解为计算机设备按照一定的下电顺序控制设备内部各部分停止工作以实现关机,或者,计算机设备在下电前进行数据同步,避免计算机设备的系统数据被损坏导致再次上电时出现故障。上述的下电顺序可以根据计算机设备的实际情况进行确定。Wherein, power off refers to safe power off, and safe power off can be understood as computer equipment controlling the internal parts of the equipment to stop working according to a certain power off order to realize shutdown, or computer equipment performs data synchronization before power off to avoid computer equipment failure. The system data is corrupted, resulting in a failure when the power is turned on again. The above-mentioned power-off sequence can be determined according to the actual situation of the computer equipment.
重启是指下电后立即上电。而目标操作也可以是下电后等待一段时间后再上电,如等待第一时间之后再上电,第一时间的具体数值可以根据实际情况进行设置。Reboot means power on immediately after power off. The target operation can also be to wait for a period of time after power off and then power on, such as waiting for the first time before powering on, the specific value of the first time can be set according to the actual situation.
作为一种可能的实施方式中,目标验证信息还包括以下至少一项:目标计算机设备的目标用户名、控制设备的物理地址。对应地,本地验证信息还包括以下至少一项:计算机设备的本地用户名、控制设备的物理地址。As a possible implementation manner, the target verification information further includes at least one of the following: a target user name of the target computer device, and a physical address of the control device. Correspondingly, the local verification information further includes at least one of the following: a local user name of the computer device, and a physical address of the control device.
具体地,验证用户名可以辅助验证控制设备的可信度。当目标用户名和计算机设备的本地用户名相同时,表明广播操作报文的控制设备为可信设备。同样地,验证控制设备的物理地址可以确认操作报文是否为控制设备广播的。计算机设备可以提前获得控制设备的物理地址,例如控制设备提前广播自己的物理地址给计算机设备或者用户提前存入等方式。计算机设备在确定操作报文中携带的控制设备的物理地址与本地存储的控制设备的物理地址一致时,可以确定操作报文为控制设备广播的。Specifically, verifying the user name can assist in verifying the authenticity of the controlling device. When the target user name is the same as the local user name of the computer device, it indicates that the control device broadcasting the operation message is a trusted device. Likewise, verifying the physical address of the control device can confirm whether the operation message is broadcast by the control device. The computer device can obtain the physical address of the control device in advance, for example, the control device broadcasts its physical address to the computer device in advance or the user deposits it in advance. When the computer device determines that the physical address of the control device carried in the operation message is consistent with the physical address of the control device stored locally, it may determine that the operation message is broadcast by the control device.
作为一种可能的实施方式中,上述设备控制方法还包括:As a possible implementation manner, the above device control method further includes:
操作报文中的目标物理地址和计算机设备的本地物理地址不相同时,可以确定该操作报文不是用于控制本计算机设备的,计算机设备可以丢弃该操作报文,不对该报文进行处理。When the target physical address in the operation message is different from the local physical address of the computer device, it can be determined that the operation message is not used to control the computer device, and the computer device can discard the operation message and not process the message.
示例性地,为了节约计算机设备的数据处理量,可以先判断目标物理地址是否和本地物理地址相同,再判断目标验证信息是否和本地验证信息相同,最后,再判断操作报文是否满足预设条件。这样,当目标物理地址或目标验证信息未通过验证时,可以停止后续判断流程,节省数据处理量。Exemplarily, in order to save the data processing capacity of the computer equipment, it may first determine whether the target physical address is the same as the local physical address, then determine whether the target verification information is the same as the local verification information, and finally, determine whether the operation message satisfies the preset condition . In this way, when the physical address of the target or the verification information of the target fails to pass the verification, the subsequent judgment process can be stopped, saving the amount of data processing.
作为一种可能的实施方式中,上述设备控制方法还包括:As a possible implementation manner, the above device control method further includes:
操作报文中的目标物理地址和计算机设备的本地物理地址相同,且目标验证信息和本地验证信息不一致时,计算机设备向控制设备发送反馈报文,反馈报文用于指示目标验证信息和本地验证信息不一致,以使控制设备知晓目标验证信息不正确,控制设备可以修改目标验证信息并重新广播操作报文。When the target physical address in the operation message is the same as the local physical address of the computer device, and the target verification information is inconsistent with the local verification information, the computer device sends a feedback message to the control device, and the feedback message is used to indicate the target verification information and the local verification information. The information is inconsistent, so that the control device knows that the target verification information is incorrect, and the control device can modify the target verification information and re-broadcast the operation message.
对反馈报文的具体结构不做特别限定,只要能够使控制设备知晓目标验证信息不正确即可。示例性地,反馈报文可以为8字节的“EEEEEEEEEEEEEEEE”。The specific structure of the feedback message is not particularly limited, as long as the control device can know that the target verification information is incorrect. Exemplarily, the feedback message may be "EEEEEEEEEEEEEEEE" of 8 bytes.
作为一种可能的实施方式中,计算机设备接收控制设备广播的操作报文之前,设备控制方法还包括:As a possible implementation manner, before the computer device receives the operation message broadcast by the control device, the device control method further includes:
计算机设备接收控制设备广播的物理地址请求。The computer device receives the physical address request broadcast by the control device.
相应地,控制设备广播物理地址请求。Accordingly, the control device broadcasts a physical address request.
具体地,上述物理地址请求可以为基于各种网络协议的请求,例如地址解析协议(Address Resolution Protocol,ARP)、简单网络管理协议(Simple Network ManagementProtocol,SNMP)等。Specifically, the foregoing physical address request may be a request based on various network protocols, such as Address Resolution Protocol (Address Resolution Protocol, ARP), Simple Network Management Protocol (Simple Network Management Protocol, SNMP), and the like.
ARP是根据IP地址获取物理地址的一个传输控制协议(Transmission ControlProtocol/Internet Protocol,TCP/IP)。其中,主机发送信息时将包含目标IP地址的ARP请求广播到局域网络上的所有主机,并接收返回消息,以此确定目标IP地址对应的物理地址。ARP is a transmission control protocol (Transmission Control Protocol/Internet Protocol, TCP/IP) that obtains a physical address based on an IP address. Wherein, when the host sends information, it broadcasts the ARP request containing the target IP address to all hosts on the local area network, and receives the return message, so as to determine the physical address corresponding to the target IP address.
SNMP是由互联网工程任务组(Internet Engineering Task Force,IETF)定义的一套网络管理协议。利用SNMP,一个管理工作站(即本申请实施例中的控制设备)可以远程管理所有支持这种协议的网络设备(即本申请实施例中的计算机设备)。SNMP is a set of network management protocols defined by the Internet Engineering Task Force (IETF). Using SNMP, a management workstation (ie, the control device in this embodiment of the application) can remotely manage all network devices that support this protocol (ie, the computer equipment in this embodiment of the application).
计算机设备响应物理地址请求,向控制设备发送本地物理地址。The computer device sends the local physical address to the control device in response to the physical address request.
相应地,控制设备接收计算机设备响应物理地址请求发送的本地物理地址。Correspondingly, the control device receives the local physical address sent by the computer device in response to the physical address request.
本申请实施例中,控制设备在远程操作计算机设备之前,需要先通过物理地址请求获得计算机设备的本地物理地址。在需要对计算机设备进行操作时,将计算机设备的本地物理地址作为目标物理地址。In the embodiment of the present application, before the control device remotely operates the computer device, it needs to obtain the local physical address of the computer device through a physical address request. When the computer device needs to be operated, the local physical address of the computer device is used as the target physical address.
作为一种可能的实施方式中,对于本地验证信息(如本地密码和本地用户名),可以提前收集录入控制设备中,这样,控制设备根据收集的本地验证信息、以及计算机设备的本地物理地址,可以根据需要对计算机设备进行远程操作,具体地,在需要对计算机设备进行操作时,将计算机设备的本地验证信息作为目标验证信息。As a possible implementation, for local verification information (such as local password and local user name), it can be collected and entered into the control device in advance, so that the control device according to the collected local verification information and the local physical address of the computer device, The computer device can be remotely operated as required, specifically, when the computer device needs to be operated, the local verification information of the computer device is used as the target verification information.
作为一种可能的实施方式中,参考图3,图3是本申请实施例提供的一种操作报文的结构示意图。本实施例中,操作报文的长度以108字节为例,而目标操作为下电操作,目标验证信息为用户设置的密码,预设次数为16,预设长度为6字节。具体地,操作报文的结构为6字节的操作报文头(如FF FF FF FF FF FF FE)开头,接着为重复16次的目标计算机设备的48位(6字节)的MAC地址,最后为6字节的密码,共108字节。As a possible implementation manner, refer to FIG. 3 , which is a schematic structural diagram of an operation message provided in an embodiment of the present application. In this embodiment, the length of the operation message is 108 bytes as an example, and the target operation is power-off operation, the target verification information is the password set by the user, the preset number of times is 16, and the preset length is 6 bytes. Specifically, the structure of the operation message starts with a 6-byte operation message header (such as FF FF FF FF FF FF FE), followed by the 48-bit (6-byte) MAC address of the target computer device repeated 16 times, The last is a 6-byte password, a total of 108 bytes.
作为一种可能的实施方式中,参考图4,图4是本申请实施例提供的一种结果报文的结构示意图。本实施例中,结果报文的长度以108字节为例,而目标操作为下电操作。该报文结构为6字节的结果报文头(如FF FF FF FF FF FF FD)开头;接着为重复16次的48位的MAC地址;接着为1字节的操作结果,示例性地,可以用1表示下电成功、0表示下电失败;最后5个字节作为保留字节,以供后续其他用途使用。其中,结果报文与操作报文的结构一致,是为了便于软件开发和运维。结果报文中MAC地址可以不用重复16次,有1个MAC地址作为计算机设备的标识即可。As a possible implementation manner, refer to FIG. 4 , which is a schematic structural diagram of a result message provided in an embodiment of the present application. In this embodiment, the length of the result message is 108 bytes as an example, and the target operation is a power-off operation. The message structure starts with a 6-byte result message header (such as FF FF FF FF FF FF FD); followed by a 48-bit MAC address repeated 16 times; followed by a 1-byte operation result, for example, You can use 1 to indicate power-off success, and 0 to indicate power-off failure; the last 5 bytes are reserved bytes for subsequent use for other purposes. Among them, the structure of the result message is consistent with that of the operation message, which is for the convenience of software development and operation and maintenance. As a result, the MAC address in the message does not need to be repeated 16 times, and only one MAC address is used as the identification of the computer device.
上面介绍了本申请实施例的方法实施例,下面介绍本申请实施例中的装置。The method embodiments of the embodiments of the present application are described above, and the apparatuses in the embodiments of the present application are described below.
本申请实施例提供一种计算机设备,该计算机设备包括用于执行上述设备控制方法的模块。An embodiment of the present application provides a computer device, and the computer device includes a module for executing the above device control method.
参考图5,图5是本申请实施例提供的一种计算机设备的结构示意图。计算机设备包括接收模块501,处理模块502和发送模块503,其中:Referring to FIG. 5 , FIG. 5 is a schematic structural diagram of a computer device provided by an embodiment of the present application. The computer equipment includes a receiving
接收模块501,用于接收控制设备广播的操作报文。该操作报文包括操作报文头、目标计算机设备的目标物理地址和目标计算机设备的目标验证信息。The receiving
处理模块502,用于在操作报文满足预设条件,目标物理地址和计算机设备的本地物理地址相同,且目标验证信息和计算机设备的本地验证信息一致的情况下,执行目标操作,且在目标操作执行完成后,确定操作报文的操作结果为操作成功。其中,预设条件包括操作报文中目标物理地址的重复次数为预设次数,和/或,操作报文头的长度为预设长度。The
发送模块503,用于向控制设备发送操作报文的操作结果。The sending
本申请实施例还提供一种控制设备,该控制设备包括用于执行上述设备控制方法的模块。An embodiment of the present application further provides a control device, and the control device includes a module configured to execute the above-mentioned device control method.
参考图6,图6是本申请实施例提供的一种控制设备的结构示意图。控制设备包括广播模块601和接收模块602,其中:Referring to FIG. 6 , FIG. 6 is a schematic structural diagram of a control device provided by an embodiment of the present application. The control device includes a
广播模块601,用于广播操作报文。操作报文包括操作报文头、目标计算机设备的目标物理地址和目标计算机设备的目标验证信息。The
接收模块602,用于接收来自计算机设备的操作报文的操作结果,其中,计算机设备在操作报文满足预设条件,目标物理地址和计算机设备的本地物理地址相同,且目标验证信息和计算机设备的本地验证信息一致时,执行目标操作,且在目标操作执行完成后,确定操作报文的操作结果为操作成功。预设条件包括操作报文中目标物理地址的重复次数为预设次数,和/或,操作报文头的长度为预设长度。The receiving
利用图6所示的控制设备,可以在硬件层面实现远程操作计算机设备,易于在局域网范围内实现批量管理。Using the control device shown in Figure 6, remote operation of computer equipment can be realized at the hardware level, and batch management can be easily realized within the scope of the local area network.
在一个可能的实施例中,参考图7,图7是本申请实施例提供的一种控制系统的结构示意图。其中,计算机设备包括网卡702和主板703,所述网卡702与所述主板703连接。In a possible embodiment, refer to FIG. 7 , which is a schematic structural diagram of a control system provided in an embodiment of the present application. Wherein, the computer equipment includes a network card 702 and a mainboard 703, and the network card 702 is connected to the mainboard 703.
所述网卡702用于接收控制设备广播的操作报文,所述操作报文包括操作报文头、目标计算机设备的目标物理地址和所述目标计算机设备的目标验证信息;The network card 702 is used to receive an operation message broadcast by the control device, the operation message includes an operation message header, a target physical address of the target computer device, and target verification information of the target computer device;
在所述操作报文满足预设条件,所述目标物理地址和所述计算机设备的本地物理地址相同,且所述目标验证信息和所述计算机设备的本地验证信息一致的情况下,所述主板703用于执行目标操作,且在所述目标操作执行完成后,确定所述操作报文的操作结果为操作成功;所述预设条件包括所述操作报文中所述目标物理地址的重复次数为预设次数,和/或,所述操作报文头的长度为预设长度;When the operation message satisfies the preset condition, the target physical address is the same as the local physical address of the computer device, and the target verification information is consistent with the local verification information of the computer device, the motherboard 703 is used to execute the target operation, and after the execution of the target operation is completed, determine that the operation result of the operation message is a successful operation; the preset condition includes the number of repetitions of the target physical address in the operation message is a preset number of times, and/or, the length of the operation header is a preset length;
所述网卡702用于向所述控制设备发送所述操作报文的操作结果。The network card 702 is configured to send the operation result of the operation packet to the control device.
进一步地,网卡702包括收发单元704和第一处理单元705,而主板703包括第二处理单元706。所述收发单元704与所述第一处理单元705连接,所述第一处理单元705与所述第二处理单元706连接。Further, the network card 702 includes a transceiver unit 704 and a first processing unit 705 , and the motherboard 703 includes a second processing unit 706 . The transceiver unit 704 is connected to the first processing unit 705 , and the first processing unit 705 is connected to the second processing unit 706 .
所述收发单元704用于接收控制设备广播的操作报文。The transceiving unit 704 is configured to receive operation messages broadcast by the control device.
所述第一处理单元705用于在确认所述操作报文满足预设条件,且所述操作报文携带的目标验证信息与所述本地验证信息一致时,向所述第二处理单元706发送指示信息,所述指示信息用于指示所述第二处理单元执行目标操作。The first processing unit 705 is configured to send the operation message to the second processing unit 706 when it is confirmed that the operation message satisfies the preset condition, and the target verification information carried in the operation message is consistent with the local verification information. instruction information, where the instruction information is used to instruct the second processing unit to execute a target operation.
所述第二处理单元706用于执行所述目标操作,且在所述目标操作执行完成后,确定所述操作报文的操作结果为操作成功。The second processing unit 706 is configured to execute the target operation, and after the target operation is executed, determine that the operation result of the operation message is that the operation is successful.
所述收发单元704用于向所述控制设备发送所述操作报文的操作结果。The transceiving unit 704 is configured to send the operation result of the operation message to the control device.
收发单元704具有控制网络数据包收发功能,这也是网卡所具备的基本功能。控制设备701广播操作报文,计算机设备的收发单元704可以接收操作报文。识别到操作报文包含自身网卡的MAC地址时,将操作报文交由第一处理单元705进行处理。The transceiver unit 704 has the function of controlling the sending and receiving of network data packets, which is also the basic function of the network card. The control device 701 broadcasts the operation message, and the transceiver unit 704 of the computer device can receive the operation message. When it is recognized that the operation packet contains the MAC address of its own network card, the operation packet is handed over to the first processing unit 705 for processing.
第一处理单元705可处理目标MAC地址、目标验证信息等操作报文携带的信息。The first processing unit 705 may process information carried in operation packets such as target MAC address and target verification information.
第二处理单元706与网卡702可相互通信,即第一处理单元705在确认操作报文满足预设条件,且操作报文携带的目标验证信息与本地验证信息一致时,向第二处理单元706发送指示信息以指示第二处理单元706执行目标操作,第二处理单元706获取目标操作的执行状态,在执行结束后,向第一处理单元705反馈该执行状态,以使第一处理单元705通过收发单元704向控制设备701发送结果报文。The second processing unit 706 and the network card 702 can communicate with each other, that is, when the first processing unit 705 confirms that the operation message satisfies the preset condition, and the target verification information carried in the operation message is consistent with the local verification information, it sends a message to the second processing unit 706. Send instruction information to instruct the second processing unit 706 to execute the target operation, the second processing unit 706 obtains the execution status of the target operation, and feeds back the execution status to the first processing unit 705 after the execution is completed, so that the first processing unit 705 passes The transceiver unit 704 sends the result message to the control device 701 .
而当收发单元704确定操作报文中的目标MAC地址和本地MAC地址不一致时,丢弃该操作报文。当第一处理单元705确定操作报文携带的目标验证信息与本地验证信息不一致时,通过收发单元704向控制设备701发送反馈报文,以使控制设备701知晓操作报文中的目标验证信息不正确。However, when the transceiver unit 704 determines that the target MAC address in the operation packet is inconsistent with the local MAC address, the operation packet is discarded. When the first processing unit 705 determines that the target verification information carried in the operation message is inconsistent with the local verification information, it sends a feedback message to the control device 701 through the transceiver unit 704, so that the control device 701 knows that the target verification information in the operation message is inconsistent. correct.
在一个可能的实施例中,参考图8,图8是本申请实施例提供的另一种控制系统的结构示意图。在服务器实验室场景中,控制系统包括控制设备、交换器和服务器,交换器作为控制设备和服务器之间的通信中介。本实施例中,服务器的个数以9个为例。以服务器3为例,服务器3包括网卡801。In a possible embodiment, refer to FIG. 8 , which is a schematic structural diagram of another control system provided in an embodiment of the present application. In the server lab scenario, the control system includes control devices, switches, and servers, and the switch acts as a communication intermediary between control devices and servers. In this embodiment, the number of servers is 9 as an example. Taking the server 3 as an example, the server 3 includes a
进一步地,目标操作以下电操作为例,首先,控制设备通过广播ARP报文以获取局域网内所有服务器的MAC地址,并提前把各个服务器的密码存储于控制设备中。接着,在需要对服务器进行远程下电时,则再次广播操作报文,该操作报文中携带有想要其控制下电的服务器的MAC地址,也可以通过多次广播操作报文,实现批量控制实验室中所有服务器下电。Furthermore, the target operation takes the power-down operation as an example. First, the control device obtains the MAC addresses of all servers in the LAN by broadcasting ARP packets, and stores the passwords of each server in the control device in advance. Then, when it is necessary to remotely power off the server, the operation message is broadcast again, and the operation message carries the MAC address of the server that you want to control the power off. You can also broadcast the operation message multiple times to realize batch Power off all servers in the control lab.
以控制服务器3下电为例,控制设备组装包含服务器3的MAC地址和密码信息的报文进行局域网发送。当服务器3收到包含本机MAC地址的操作报文,操作报文满足预设条件,且密码验证通过,则进行下电处理。服务器3在等待下电处理完成,向控制设备发送包含本机MAC地址的下电操作结果。控制设备接收到下电操作结果并记录,控制流程结束。Taking the power off of the control server 3 as an example, the control device assembles a message containing the MAC address and password information of the server 3 and sends it over the LAN. When the server 3 receives the operation packet containing the local MAC address, the operation packet satisfies the preset conditions, and the password verification passes, the power-off process is performed. The server 3 is waiting for the completion of the power-off process, and sends the power-off operation result including the local MAC address to the control device. The control device receives and records the result of the power-off operation, and the control process ends.
参见图9,图9是本申请实施例提供的一种电子设备的结构示意图。Referring to FIG. 9 , FIG. 9 is a schematic structural diagram of an electronic device provided by an embodiment of the present application.
本申请实施例还提供一种电子设备,图9所示的电子设备900(该设备900具体可以是一种计算机设备)包括存储器905、处理器901、用户接口903、网络接口904以及总线902。其中,存储器905、处理器901、用户接口903、网络接口904通过总线902实现彼此之间的通信连接。The embodiment of the present application also provides an electronic device. The
此外,用户接口903可以包括显示屏(Display)、键盘(Keyboard),可选用户接口903还可以包括标准的有线接口、无线接口。网络接口904可选的可以包括标准的有线接口、无线接口(如WI-FI接口)。In addition, the
存储器905可以是只读存储器(Read Only Memory,ROM),静态存储设备,动态存储设备或者随机存取存储器(Random Access Memory,RAM)。存储器905可以存储程序,当存储器905中存储的程序被处理器901执行时,处理器901和网络接口904用于执行本申请实施例的设备控制方法的各个步骤。The
处理器901可以采用通用的中央处理器(Central Processing Unit,CPU),微处理器,应用专用集成电路(Application Specific Integrated Circuit,ASIC),图形处理器(graphics processing unit,GPU)或者一个或多个集成电路,用于执行相关程序,以实现上述实施例所述的电子设备中的单元所需执行的功能,或者执行本申请实施例所述的设备控制方法。The
处理器901还可以是一种集成电路芯片,具有信号的处理能力。在实现过程中,本申请实施例的设备控制方法的各个步骤可以通过处理器901中的硬件的集成逻辑电路或者软件形式的指令完成。上述的处理器901还可以是通用处理器、数字信号处理器(DigitalSignal Processing,DSP)、专用集成电路(ASIC)、现成可编程门阵列(Field ProgrammableGate Array,FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件。可以实现或者执行本申请实施例中的公开的各方法、步骤及逻辑框图。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。结合本申请实施例所公开的设备控制方法的步骤可以直接体现为硬件译码处理器执行完成,或者用译码处理器中的硬件及软件模块组合执行完成。软件模块可以位于随机存储器,闪存、只读存储器,可编程只读存储器或者电可擦写可编程存储器、寄存器等本领域成熟的存储介质中。该存储介质位于存储器905,处理器901读取存储器905中的信息,结合其硬件完成上述实施例所述的电子设备中包括的单元所需执行的功能,或者执行本申请方法实施例的设备控制方法。The
网络接口904使用例如但不限于收发器一类的收发装置,来实现电子设备900与其他设备或通信网络之间的通信。例如,电子设备900为控制设备时,可以通过网络接口904获取计算机设备的物理地址信息。The
总线902可包括在电子设备900各个部件(例如,存储器905、处理器901、用户接口903、网络接口904)之间传送信息的通路。
应注意,尽管图9所示的电子设备900仅仅示出了存储器、处理器、用户接口、通信接口,但是在具体实现过程中,本领域的技术人员应当理解,电子设备900还包括实现正常运行所必须的其他器件。同时,根据具体需要,本领域的技术人员应当理解,电子设备900还可包括实现其他附加功能的硬件器件。此外,本领域的技术人员应当理解,电子设备900也可仅仅包括实现本申请实施例所必须的器件,而不必包括图9中所示的全部器件。It should be noted that although the
所述功能如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的部分可以以计算机程序产品的形式体现出来,该计算机程序产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本申请各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(Read-Only Memory,ROM)、随机存取存储器(Random Access Memory,RAM)、磁碟或者光盘等各种可以存储程序代码的介质。If the functions described above are realized in the form of software function units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the essence of the technical solution of the present application or the part that contributes to the prior art or the part of the technical solution can be embodied in the form of a computer program product, and the computer program product is stored in a storage medium. Several instructions are included to make a computer device (which may be a personal computer, a server, or a network device, etc.) execute all or part of the steps of the methods described in the various embodiments of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), magnetic disk or optical disk and other various media that can store program codes. .
本发明实施例还提供一种芯片,所述芯片包括处理器与数据接口,所述处理器通过所述数据接口读取存储器上存储的指令,执行本申请实施例所述的设备控制方法。The embodiment of the present invention also provides a chip, the chip includes a processor and a data interface, and the processor reads instructions stored in the memory through the data interface, and executes the device control method described in the embodiment of the present application.
可选地,作为一种实现方式,所述芯片还可以包括存储器,所述存储器中存储有指令,所述处理器用于执行所述存储器上存储的指令,当所述指令被执行时,所述处理器用于执行本申请实施例所述的设备控制方法。Optionally, as an implementation manner, the chip may further include a memory, the memory stores instructions, the processor is configured to execute the instructions stored in the memory, and when the instructions are executed, the The processor is configured to execute the device control method described in the embodiment of the present application.
本领域普通技术人员可以意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,能够以电子硬件、或者计算机软件和电子硬件的结合来实现。这些功能究竟以硬件还是软件方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。Those skilled in the art can appreciate that the units and algorithm steps of the examples described in conjunction with the embodiments disclosed herein can be implemented by electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are executed by hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art may use different methods to implement the described functions for each specific application, but such implementation should not be regarded as exceeding the scope of the present application.
在本申请所提供的几个实施例中,应该理解到,所揭露的装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。In the several embodiments provided in this application, it should be understood that the disclosed devices and methods may be implemented in other ways. For example, the device embodiments described above are only illustrative. For example, the division of units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components can be combined or integrated. to another system, or some features may be ignored, or not implemented. In another point, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces, and the indirect coupling or communication connection of devices or units may be in electrical, mechanical or other forms.
作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。A unit described as a separate component may or may not be physically separated, and a component displayed as a unit may or may not be a physical unit, that is, it may be located in one place, or may be distributed to multiple network units. Part or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
另外,在本专利申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。In addition, each functional unit in each embodiment of the present patent application may be integrated into one processing unit, each unit may exist separately physically, or two or more units may be integrated into one unit.
以上所述,仅为本申请的具体实施方式,但本申请的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本申请揭露的技术范围内,可轻易想到变化或替换,都应涵盖在本申请的保护范围之内。因此,本申请的保护范围应以所述权利要求的保护范围为准。The above is only a specific implementation of the application, but the scope of protection of the application is not limited thereto. Anyone familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the application. Should be covered within the protection scope of this application. Therefore, the protection scope of the present application should be determined by the protection scope of the claims.
Claims (14)
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202211233994.2A CN115834645B (en) | 2022-10-10 | 2022-10-10 | Device control method and related device |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202211233994.2A CN115834645B (en) | 2022-10-10 | 2022-10-10 | Device control method and related device |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| CN115834645A true CN115834645A (en) | 2023-03-21 |
| CN115834645B CN115834645B (en) | 2025-04-15 |
Family
ID=85524542
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN202211233994.2A Active CN115834645B (en) | 2022-10-10 | 2022-10-10 | Device control method and related device |
Country Status (1)
| Country | Link |
|---|---|
| CN (1) | CN115834645B (en) |
Citations (9)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20160156964A1 (en) * | 2014-12-02 | 2016-06-02 | Panasonic Intellectual Property Management Co., Ltd. | Information terminal, information processing method, and control program |
| CN106454828A (en) * | 2016-09-30 | 2017-02-22 | 广东美的制冷设备有限公司 | Network access authentication method, network access authentication device, network access device and router |
| CN109672742A (en) * | 2018-12-25 | 2019-04-23 | 华南智能机器人创新研究院 | A kind of intelligent cooperative control method and system based between different die casting machine systems |
| CN109709915A (en) * | 2018-12-25 | 2019-05-03 | 华南智能机器人创新研究院 | A method and system for intelligent collaborative production between multiple production lines |
| CN109981681A (en) * | 2019-04-10 | 2019-07-05 | 广东虹勤通讯技术有限公司 | Wireless network access method and wireless network connection system |
| CN110958124A (en) * | 2019-12-12 | 2020-04-03 | 北京爱奇艺科技有限公司 | Multicast group management method, device, readable storage medium and computer |
| CN113517951A (en) * | 2021-05-16 | 2021-10-19 | 武汉领普科技有限公司 | Self-generating switch and processing method thereof, receiver and processing method thereof |
| CN113973102A (en) * | 2021-11-01 | 2022-01-25 | 新华三大数据技术有限公司 | Network address acquisition method, system and network equipment |
| WO2022016670A1 (en) * | 2020-07-24 | 2022-01-27 | 深圳创维数字技术有限公司 | Network configuration method and apparatus for device, and computer readable storage medium |
-
2022
- 2022-10-10 CN CN202211233994.2A patent/CN115834645B/en active Active
Patent Citations (9)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20160156964A1 (en) * | 2014-12-02 | 2016-06-02 | Panasonic Intellectual Property Management Co., Ltd. | Information terminal, information processing method, and control program |
| CN106454828A (en) * | 2016-09-30 | 2017-02-22 | 广东美的制冷设备有限公司 | Network access authentication method, network access authentication device, network access device and router |
| CN109672742A (en) * | 2018-12-25 | 2019-04-23 | 华南智能机器人创新研究院 | A kind of intelligent cooperative control method and system based between different die casting machine systems |
| CN109709915A (en) * | 2018-12-25 | 2019-05-03 | 华南智能机器人创新研究院 | A method and system for intelligent collaborative production between multiple production lines |
| CN109981681A (en) * | 2019-04-10 | 2019-07-05 | 广东虹勤通讯技术有限公司 | Wireless network access method and wireless network connection system |
| CN110958124A (en) * | 2019-12-12 | 2020-04-03 | 北京爱奇艺科技有限公司 | Multicast group management method, device, readable storage medium and computer |
| WO2022016670A1 (en) * | 2020-07-24 | 2022-01-27 | 深圳创维数字技术有限公司 | Network configuration method and apparatus for device, and computer readable storage medium |
| CN113517951A (en) * | 2021-05-16 | 2021-10-19 | 武汉领普科技有限公司 | Self-generating switch and processing method thereof, receiver and processing method thereof |
| CN113973102A (en) * | 2021-11-01 | 2022-01-25 | 新华三大数据技术有限公司 | Network address acquisition method, system and network equipment |
Non-Patent Citations (2)
| Title |
|---|
| GUPTA, SANDEEP;ET ALL: "STEP & TURN -A novel bimodal behavioral biometric-based user verification scheme for physical access control", COMPUTERS & SECURITY, 15 June 2022 (2022-06-15) * |
| 何小玉;: "宽带PON系统测试、设备进展和应用展望", 电信科学, no. 10, 15 October 2006 (2006-10-15) * |
Also Published As
| Publication number | Publication date |
|---|---|
| CN115834645B (en) | 2025-04-15 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US12487960B2 (en) | Communication method and system for distributed heterogeneous acceleration platform, device and medium | |
| EP3828709B1 (en) | Communication method and network card | |
| US8127015B2 (en) | Alerting system, architecture and circuitry | |
| JP2005006303A (en) | Virtual network address | |
| JP3629513B2 (en) | Data processing system and method | |
| US20050166213A1 (en) | Remote deployment of executable code in a pre-boot environment | |
| CN101252583B (en) | Method to enable Infiniband network bootstrap and Infiniband host computer equipment | |
| US6275851B1 (en) | Data processing system and method for remotely controlling modification of a client's initialization settings | |
| CN115632900B (en) | Computing equipment | |
| KR100345990B1 (en) | Data processing system and method for remotely disabling a client computer system | |
| JP2000172639A (en) | Remote control method and data processing system | |
| CN101088070B (en) | Method and system for remote recording mechanism | |
| WO2026016562A1 (en) | Data transmission method and computing device | |
| CN115834645A (en) | Equipment control method and related equipment | |
| CN118921397A (en) | Communication connection method, device, storage device and program product | |
| CN115454896B (en) | SMBUS-based SSD MCTP control message verification method, device, computer equipment and storage medium | |
| TWI799179B (en) | Computing systems and methods for management of a network device | |
| TWI220612B (en) | Network physical layer apparatus with smart cable analyzing function and application device thereof | |
| JP3667265B2 (en) | Communication protocol test equipment | |
| CN116909769A (en) | Control method and device of baseboard management controller | |
| CN115599721A (en) | Port switching method, system, computing device and chip | |
| KR20000035025A (en) | Data processing system and method for remotely accessing a client computer system's indivisual initialization settings while the client is powered off | |
| CN114489818A (en) | BMC configuration method and device based on BIOS | |
| CN114760193A (en) | Main/standby negotiation method and device | |
| CN119052097A (en) | Message transmission method and computing device |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| PB01 | Publication | ||
| PB01 | Publication | ||
| SE01 | Entry into force of request for substantive examination | ||
| SE01 | Entry into force of request for substantive examination | ||
| GR01 | Patent grant | ||
| GR01 | Patent grant | ||
| CP03 | Change of name, title or address |
Address after: 450000 Henan Province, Zhengzhou City, Free Trade Zone Zhengzhou Area (Zhengdong), Inner Ring North Road of Longhu, No. 99 Patentee after: Super Fusion Digital Technology Co.,Ltd. Country or region after: China Address before: 450000 Floor 9, building 1, Zhengshang Boya Plaza, Longzihu smart Island, Zhengdong New District, Zhengzhou City, Henan Province Patentee before: xFusion Digital Technologies Co., Ltd. Country or region before: China |
