Device control method and related device

The computer equipment receives and processes the operation messages broadcast by the control equipment, and solves the problem of complex and high cost of remote control of equipment in the prior art, and realizes the low-cost remote operation function.

CN115834645BActive Publication Date: 2025-04-15XFUSION DIGITAL TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211233994.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-10-10
Publication Date
2025-04-15
Estimated Expiration
2042-10-10

AI Technical Summary

Technical Problem

In the prior art, remote control of equipment requires the installation of basic control systems, and the system needs to be online at all times, which is complex and costly.

Method used

The computer device receives the operation message broadcast by the control device. The operation message includes the target physical address and the target verification information. When the message meets the preset conditions, the computer device performs the target operation and sends the operation result.

Benefits of technology

Remotely control the computer equipment to perform target operations and reduce implementation costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115834645B_ABST
    Figure CN115834645B_ABST
Patent Text Reader

Abstract

The embodiment of the present application provides a device control method and related devices, which relate to the field of devices. In the method, a computer device receives an operation message broadcast by a control device. The operation message includes an operation message header, a target physical address of a target computer device, and target verification information of a 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 performs 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. 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.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present invention relate to the field of equipment, and in particular to an equipment control method and related equipment. Background Art

[0002] In the prior art, the equipment is mainly managed by remotely logging into the Basic Control System (BMC) to achieve remote power-off of the equipment. Figure 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 basic control system is built on server 1, and the basic control system can be accessed through the Internet Protocol (IP), thereby achieving 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 server 1) needs to install the basic control system, and the basic control system needs to be online at all times. The implementation of the solution is complex and the implementation cost is high. Summary of the invention

[0003] The present application provides a device control method and related devices, which can remotely control computer devices to perform target operations with low implementation cost.

[0004] In a first aspect, a device control method is provided, which is applied to a computer device.

[0005] The device control method comprises the following steps:

[0006] 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 performs 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. Among them, the preset conditions include 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 operation message header is greater than or equal to the preset length. The computer device sends the operation result of the operation message to the control device.

[0007] 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 meets the preset conditions, the computer device can determine that the operation message is used to control the target computer device to perform the target operation. In addition, when 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 will perform 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. Finally, the computer device sends the operation result of the operation message to the control device.

[0008] In combination with the first aspect, in one implementation, the above-mentioned operation message also includes operation instruction information, and the operation instruction information is used to instruct the target computer device to perform the target operation; in this case, the preset condition is that the operation message includes the operation instruction information.

[0009] In this solution, when the operation message includes the above-mentioned operation instruction information, it can be determined that the operation message is used to control the target computer device to perform the target operation.

[0010] In combination with the first aspect, in one implementation, 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, and the computer device discards the operation message.

[0011] In combination with the first aspect, in one implementation, the device control method further includes:

[0012] 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. The feedback message is used to indicate that the target verification information is inconsistent with the local verification information, so that the control device knows that the target verification information is incorrect. The control device can modify the target verification information and rebroadcast the operation message.

[0013] In combination with the first aspect, in one implementation, before the computer device receives the operation message broadcast by the control device, the device control method further includes:

[0014] The computer device receives the physical address request broadcasted by the control device, and responds to the physical address request by sending a local physical address to the control device.

[0015] 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.

[0016] In combination with the first aspect, in one implementation, the target operation includes powering off, restarting, or waiting for a first period of time after powering off and then powering on.

[0017] In a second aspect, the present application also provides a device control method, which is applied to control a device.

[0018] The device control method comprises the following steps:

[0019] The control device broadcasts an operation message. The operation message includes an operation message header, a target physical address of a target computer device, and target verification information of the target computer device. The control device receives an operation result of the operation message from the computer device, wherein the computer device performs the target operation when the operation message meets a 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, and after the target operation is completed, the operation result of the operation message is determined to be a successful operation. The preset conditions include 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 that the length of the operation message header is greater than or equal to the preset length.

[0020] 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.

[0021] In combination with the second aspect, in one implementation, the above-mentioned operation message also includes operation instruction information, and the operation instruction information is used to instruct the target computer device to perform the target operation; in this case, the preset condition is that the operation message includes the operation instruction information.

[0022] In conjunction with the second aspect, in one implementation, the device control method further includes:

[0023] The control device receives a feedback message sent by the computer device when it determines 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. The feedback message is used to indicate that the target verification information is inconsistent with the local verification information.

[0024] In conjunction with the second aspect, in one implementation, the device control method further includes:

[0025] The control device broadcasts a physical address request and receives a local physical address sent by the computer device in response to the physical address request.

[0026] In combination with the second aspect, in one implementation, the target operation includes powering off, restarting, or waiting for a first period of time after powering off and then powering on.

[0027] In a third aspect, the present application further provides a computer device, comprising a module for executing the method described in the first aspect.

[0028] In a fourth aspect, the present application also provides a control device, comprising a module for executing the method described in the second aspect.

[0029] In a fifth aspect, the present application also provides an electronic device, comprising one or more processors; wherein the one or more processors are used to execute computer programs stored in one or more memories, so that the computer device implements the method described in the first aspect or the second aspect.

[0030] In a sixth aspect, the present application further provides a computer-readable storage medium, wherein 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 implemented.

[0031] In a seventh aspect, the present application further provides a computer program product comprising instructions, which, when executed on a computer, enables the computer to execute the method described in the first aspect or the second aspect.

[0032] In an eighth aspect, the present application further provides a chip, comprising a processor and a data interface, wherein the processor reads instructions stored in a memory through the data interface to execute the method described in the first aspect or the second aspect.

[0033] Optionally, as an implementation method, the chip may also include a memory, in which instructions are stored, and the processor is used to execute the instructions stored in the memory. When the instructions are executed, the processor is used to execute the method described in the first aspect or the second aspect. BRIEF DESCRIPTION OF THE DRAWINGS

[0034] The following is an introduction to the drawings used in the embodiments of the present application.

[0035] Figure 1 It is a structural diagram of a BMC system management technology provided by an embodiment of the present application;

[0036] Figure 2 It is a flow chart of a device control method provided in an embodiment of the present application;

[0037] Figure 3 It is a structural diagram of an operation message provided in an embodiment of the present application;

[0038] Figure 4 It is a schematic diagram of the structure of a result message provided in an embodiment of the present application;

[0039] Figure 5 is a structural schematic diagram of a computer device provided in an embodiment of the present application;

[0040] Figure 6 is a structural schematic diagram of a control device provided in an embodiment of the present application;

[0041] Figure 7 It is a structural schematic diagram of a control system provided in an embodiment of the present application;

[0042] Figure 8 is a structural schematic diagram of another control system provided in an embodiment of the present application;

[0043] Fig. 9 It is a structural schematic diagram of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0044] The technical solution in this application will be described below in conjunction with the accompanying drawings.

[0045] Due to the applications involved in the embodiments of the present application, in order to facilitate understanding, the relevant terms and other related concepts involved in the embodiments of the present application are first introduced below.

[0046] In the embodiments of the present application, the words "exemplary" or "for example" are used to indicate examples, illustrations or descriptions. Any embodiment or design described as "exemplary" or "for example" in the present application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplary" or "for example" is intended to present related concepts in a specific way.

[0047] The "at least one" mentioned in the embodiments of the present application refers to one or more, and "multiple" refers to two or more. "At least one of the following" or its similar expression refers to any combination of these items, including any combination of single items or plural items. For example, at least one of a, b, or c can be represented by: 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 the associated objects, indicating that three relationships can exist. For example, A and / or B can be represented by: A exists alone, A and B exist at the same time, and B exists alone, where A and B can be singular or plural. The character " / " generally indicates that the associated objects before and after are an "or" relationship. The serial numbers of the steps of the embodiments of the present application (such as step S1, step S21, etc.) are only for distinguishing different steps, and do not limit the order of execution between the steps.

[0048] Furthermore, unless otherwise specified, the ordinal numbers such as "first" and "second" used in the embodiments of the present application are used to distinguish multiple objects, and are not used to limit the order, timing, priority or importance of multiple objects. For example, the first device and the second device are only for the convenience of description, and do not represent the difference in structure, importance, etc. between the first device and the second device. In some embodiments, the first device and the second device can also be the same device.

[0049] In the above embodiments, the term "when..." can be interpreted as meaning "if..." or "after..." or "in response to determining..." or "in response to detecting...", depending on the context. The above description is only an optional embodiment of the present application and is not intended to limit the present application. Any modification, equivalent substitution, improvement, etc. made within the concept and principle of the present application shall be included in the protection scope of the present application.

[0050] To facilitate understanding, the relevant terms and concepts involved in the embodiments of the present application are first introduced below.

[0051] (1) Physical address

[0052] The Media Access Control (MAC) address is used to identify a LAN node. The MAC address is also called a physical address. For example, the size of a physical address is 48 bits, the first 24 bits are the manufacturer number, and the last 24 bits are the network card number.

[0053] (2) Network card

[0054] A network card is a piece of computer hardware designed to allow computers to communicate on a computer network. Because it has a MAC address, it belongs between Layer 1 and Layer 2 of the Open System Interconnection Reference Model (OSI). It allows users to connect to each other via cables or wirelessly.

[0055] (3) Motherboard

[0056] The motherboard, also called the mainboard, systemboard, or motherboard, is one of the most basic and important components of a computer. The motherboard plays a vital role in the entire computer system. The quality of the motherboard determines the stability of the hardware system. The motherboard is the core of the computer hardware system and the largest printed circuit board in the main chassis. The main function of the motherboard is to transmit various electronic signals, and some chips are also responsible for the preliminary processing of some peripheral data. All components in the computer host are connected through the motherboard. When the computer is running normally, the control of the system memory, storage devices and other input / output (I / O) devices must be completed through the motherboard. Whether the computer performance can be fully utilized, whether the hardware functions are sufficient, and how the hardware compatibility is, all depend on the design of the motherboard.

[0057] (4) Computer equipment

[0058] The computer device in this article refers to a device including a network card and a motherboard, such as a server, a computer (desktop computer, laptop computer, etc.), a single-chip microcomputer, and other devices with network access. Among them, the MAC address of the computer device is the MAC address of the network card.

[0059] The above description of technical terms can be applied hereinafter.

[0060] The embodiment of the present application provides a device control method, which can remotely control a computer device to perform a target operation with low implementation cost.

[0061] The device control method provided by this application is described in detail below:

[0062] The device control method in the embodiment of the present application is applied to a control system. The control system includes a control device and at least one computer device. Hereinafter, the device control method is specifically described by taking one of the at least one computer device as an example.

[0063] refer to Figure 2 , Figure 2 : is a flow chart of a device control method provided in an embodiment of the present application. The device control method comprises the following steps:

[0064] 201. A computer device receives an operation message broadcast by a control device. The operation message includes an operation message header, a target physical address of a target computer device, and target verification information of the target computer device.

[0065] For example, the control device is connected to a plurality of computer devices, and the control device broadcasts operation messages to the plurality of computer devices.

[0066] Specifically, the operation message is a local area network message, that is, a layer 2 network protocol message, and there is no limit on the length of the local area network message. The target verification information is the use permission authorization information of the target computer device, for example, the target verification information includes the target password.

[0067] 202. When the operation message satisfies a 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 computer device performs 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. The preset condition includes that the number of repetitions of the target physical address in the operation message is greater than or equal to a preset number, and / or the length of the operation message header is greater than or equal to a preset length.

[0068] Among them, whether the operation message meets the preset conditions, whether the target physical address and the local physical address of the computer device are the same, and whether the target verification information and the local verification information of the computer device are consistent, there is no special limitation on the judgment order of the above three.

[0069] Specifically, the target physical address is distinguished from other messages by setting the number of repetitions and / or the length of the operation message header. When the number of repetitions of the physical address contained in the operation message received by the computer device is greater than or equal to a preset number and / or the length of the operation message header is greater than or equal to a preset length, the operation message is confirmed to be a message for controlling the target computer device to perform the target operation.

[0070] The specific value of the preset number of times can be set according to actual conditions, so that the operation message can be distinguished from other messages. For example, the preset number of times is 5, 10 or 16. Further illustratively, the number of repetitions of the target physical address in the operation message is less than the number of repetitions of the physical address in the service message.

[0071] Similarly, the specific value of the preset length can be set according to actual conditions, 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. Further illustratively, the length of the message header of the operation message is less than the length of the message header of the service message.

[0072] Exemplarily, the local authentication information of a computer device includes a local password, which may be a usage password set by a user of the computer device (when the usage password verification is passed, the user can use the computer device), or the local password may be a universal password, that is, a usage password applicable to at least one computer device in the control system.

[0073] 203. The computer device sends the operation result of the operation message to the control device.

[0074] Correspondingly, the control device receives the operation result of the operation message from the computer device.

[0075] Specifically, the computer device may send the operation result of the operation message to the control device by sending 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 a successful operation, and "0" indicates a failed operation. Exemplarily, the information contained in the result message also includes at least one of the following: local physical address information of the computer device, or result message indication information, etc. For example, the result message indication information is 2 bytes of "AAAA" or 4 bytes of "BBBBBBBB". Wherein A and B are hexadecimal numbers.

[0076] In an 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 implementation cost is low.

[0077] As a possible implementation, the above-mentioned operation message also includes operation instruction information, and the operation instruction information is used to instruct the target computer device to perform the target operation; in this case, the preset condition is that the operation message includes the operation instruction information.

[0078] Exemplarily, when the target operation is a power-off operation, the operation instruction information is a 2-byte "DDDD". Another exemplary embodiment, when the target operation is a restart operation, the operation instruction information is a 2-byte "CCCC". C and D are hexadecimal numbers.

[0079] In the embodiment of the present application, when the operation message includes the above-mentioned operation instruction 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, the target physical address, the target verification information and the 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 the length of the operation message header is greater than or equal to the preset length.

[0080] As a possible implementation, the target operation includes powering off, restarting, or waiting for a first time after powering off and then powering on.

[0081] Among them, power off refers to safe power off, which can be understood as the computer device controlling the internal parts of the device to stop working in a certain power off sequence to achieve shutdown, or the computer device performs data synchronization before power off to avoid damage to the system data of the computer device and cause failure when it is powered on again. The above power off sequence can be determined according to the actual situation of the computer device.

[0082] Restart means powering on immediately after powering off. The target operation can also be to wait for a period of time after powering off before powering 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.

[0083] As a possible implementation, the target authentication information further includes at least one of the following: a target user name of the target computer device, a physical address of the control device. Correspondingly, the local authentication information further includes at least one of the following: a local user name of the computer device, a physical address of the control device.

[0084] Specifically, verifying the user name can assist in verifying the credibility of the control device. When the target user name and the local user name of the computer device are the same, it indicates that the control device broadcasting the operation message is a trusted device. Similarly, 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 own physical address to the computer device in advance or the user stores 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 can determine that the operation message is broadcast by the control device.

[0085] As a possible implementation, the device control method further includes:

[0086] 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 does not process the message.

[0087] For example, in order to save the data processing capacity of the computer device, it is possible to 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 meets the preset conditions. In this way, when the target physical address or the target verification information fails to pass the verification, the subsequent judgment process can be stopped to save data processing capacity.

[0088] As a possible implementation, the device control method further includes:

[0089] 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. The feedback message is used to indicate that the target verification information is inconsistent with the local verification information, so that the control device knows that the target verification information is incorrect. The control device can modify the target verification information and rebroadcast the operation message.

[0090] There is no particular limitation on the specific structure of the feedback message, as long as the control device can be informed that the target verification information is incorrect. For example, the feedback message may be 8 bytes of "EEEEEEEEEEEEEEEE".

[0091] As a possible implementation manner, before the computer device receives the operation message broadcast by the control device, the device control method further includes:

[0092] The computer device receives the physical address request broadcast by the control device.

[0093] In response, the control device broadcasts a physical address request.

[0094] Specifically, the physical address request may be a request based on various network protocols, such as Address Resolution Protocol (ARP), Simple Network Management Protocol (SNMP), and the like.

[0095] ARP is a transmission control protocol (TCP / IP) that obtains a physical address based on an IP address. When a host sends information, it broadcasts an ARP request containing the target IP address to all hosts on the local area network and receives a return message to determine the physical address corresponding to the target IP address.

[0096] SNMP is a set of network management protocols defined by the Internet Engineering Task Force (IETF). Using SNMP, a management workstation (i.e., the control device in the embodiment of the present application) can remotely manage all network devices (i.e., the computer devices in the embodiment of the present application) that support this protocol.

[0097] The computer device responds to the physical address request and sends the local physical address to the control device.

[0098] Accordingly, the control device receives the local physical address sent by the computer device in response to the physical address request.

[0099] 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.

[0100] As a possible implementation, local verification information (such as local passwords and local user names) can be collected and entered into the control device in advance. In this way, the control device can remotely operate the computer device as needed based on the collected local verification information and the local physical address of the computer device. Specifically, when the computer device needs to be operated, the local verification information of the computer device is used as the target verification information.

[0101] As a possible implementation method, refer to Figure 3 , Figure 3 : It is a schematic diagram of the structure of an operation message provided by an embodiment of the present application. In this embodiment, the length of the operation message is 108 bytes, and the target operation is a power-off operation, the target verification information is a 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 is a 6-byte operation message header (such as FF FF FF FF FF FF FE), followed by a 48-bit (6-byte) MAC address of the target computer device repeated 16 times, and finally a 6-byte password, a total of 108 bytes.

[0102] As a possible implementation method, refer to Figure 4 , Figure 4 It is a schematic diagram of the structure of a result message provided in an embodiment of the present application. In this embodiment, the length of the result message is 108 bytes, 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, illustratively, 1 can be used to indicate a successful power-off and 0 to indicate a power-off failure; the last 5 bytes are reserved bytes for subsequent other purposes. Among them, the structure of the result message is consistent with that of the operation message, in order to facilitate software development and operation and maintenance. The MAC address in the result message does not need to be repeated 16 times, and 1 MAC address can be used as the identifier of the computer device.

[0103] The method embodiment of the embodiment of the present application is introduced above, and the device in the embodiment of the present application is introduced below.

[0104] An embodiment of the present application provides a computer device, which includes a module for executing the above-mentioned device control method.

[0105] refer to Figure 5 , Figure 5 5 is a schematic diagram of a computer device provided in an embodiment of the present application. The computer device includes a receiving module 501, a processing module 502 and a sending module 503, wherein:

[0106] The receiving module 501 is used to receive the operation message broadcast by the control device. The operation message includes the operation message header, the target physical address of the target computer device and the target verification information of the target computer device.

[0107] The processing module 502 is used to perform the target operation 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, and after the target operation is completed, determine that the operation result of the operation message is successful. The preset conditions include that the number of repetitions of the target physical address in the operation message is a preset number of times, and / or that the length of the operation message header is a preset length.

[0108] The sending module 503 is used to send the operation result of the operation message to the control device.

[0109] An embodiment of the present application also provides a control device, which includes a module for executing the above-mentioned device control method.

[0110] refer to Figure 6 , Figure 6 60 is a schematic diagram of a control device provided in an embodiment of the present application. The control device includes a broadcast module 601 and a receiving module 602, wherein:

[0111] The broadcast module 601 is used to broadcast the operation message. The operation message includes the operation message header, the target physical address of the target computer device and the target verification information of the target computer device.

[0112] The receiving module 602 is used to receive the operation result of the operation message from the computer device, wherein the computer device performs the target operation 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, and after the target operation is completed, the operation result of the operation message is determined to be a successful operation. The preset conditions include that the number of repetitions of the target physical address in the operation message is a preset number of times, and / or that the length of the operation message header is a preset length.

[0113] use Figure 6 The control device shown can realize remote operation of computer equipment at the hardware level, and is easy to implement batch management within the local area network.

[0114] In one possible embodiment, reference Figure 7 , Figure 7 70 is a schematic diagram of a control system provided by an embodiment of the present application. The computer device includes a network card 702 and a mainboard 703 , and the network card 702 is connected to the mainboard 703 .

[0115] The network card 702 is used to receive the operation message broadcast by the control device, wherein the operation message includes an operation message header, a target physical address of a target computer device and target verification information of the target computer device;

[0116] When the operation message satisfies a 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 main board 703 is used to execute the target operation, and after the target operation is completed, determine that the operation result of the operation message is a successful operation; the preset condition includes that 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 message header is a preset length;

[0117] The network card 702 is used to send the operation result of the operation message to the control device.

[0118] Furthermore, the network card 702 includes a transceiver unit 704 and a first processing unit 705, and the mainboard 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.

[0119] The transceiver unit 704 is used to receive the operation message broadcast by the control device.

[0120] The first processing unit 705 is used to send indication information to the second processing unit 706 when confirming that the operation message meets the preset conditions and the target verification information carried by the operation message is consistent with the local verification information, and the indication information is used to instruct the second processing unit to perform the target operation.

[0121] The second processing unit 706 is used to execute the target operation, and after the target operation is completed, determine that the operation result of the operation message is a successful operation.

[0122] The transceiver unit 704 is used to send the operation result of the operation message to the control device.

[0123] The transceiver unit 704 has the function of controlling the transceiver 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 the operation message is identified to contain the MAC address of the network card, the operation message is handed over to the first processing unit 705 for processing.

[0124] The first processing unit 705 can process information carried in the operation message, such as the target MAC address and the target authentication information.

[0125] 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 meets the preset conditions and the target verification information carried by the operation message is consistent with the local verification information, it sends an indication message to the second processing unit 706 to instruct the second processing unit 706 to perform the target operation. The second processing unit 706 obtains the execution status of the target operation, and after the execution is completed, it feeds back the execution status to the first processing unit 705, so that the first processing unit 705 sends a result message to the control device 701 through the transceiver unit 704.

[0126] When the transceiver unit 704 determines that the target MAC address in the operation message is inconsistent with the local MAC address, the operation message 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, a feedback message is sent to the control device 701 through the transceiver unit 704 to let the control device 701 know that the target verification information in the operation message is incorrect.

[0127] In one possible embodiment, reference Figure 8 , Figure 8 1 is a schematic diagram of the structure of another control system provided in an embodiment of the present application. In a server laboratory scenario, the control system includes a control device, a switch and a server, and the switch serves as a communication medium between the control device and the server. In this embodiment, the number of servers is 9 as an example. Taking server 3 as an example, server 3 includes network card 801.

[0128] Furthermore, taking the target operation of power-off as an example, first, the control device broadcasts ARP messages to obtain the MAC addresses of all servers in the LAN, and stores the passwords of each server in the control device in advance. Then, when the server needs to be powered off remotely, the operation message is broadcast again, and the operation message carries the MAC address of the server that needs to be powered off. It is also possible to control the power-off of all servers in the laboratory in batches by broadcasting the operation message multiple times.

[0129] Taking the control of powering off server 3 as an example, the control device assembles a message containing the MAC address and password information of server 3 and sends it to the local area network. When server 3 receives an operation message containing the local MAC address, the operation message meets the preset conditions, and the password verification is passed, the power-off process is performed. Server 3 waits for the power-off process to be completed and sends the power-off operation result containing the local MAC address to the control device. The control device receives and records the power-off operation result, and the control process ends.

[0130] See also Fig. 9 , Fig. 9 It is a structural schematic diagram of an electronic device provided in an embodiment of the present application.

[0131] The present application also provides an electronic device, Fig. 9 The electronic device 900 shown (the device 900 may be a computer device) includes a memory 905, a processor 901, a user interface 903, a network interface 904, and a bus 902. The memory 905, the processor 901, the user interface 903, and the network interface 904 are connected to each other through the bus 902.

[0132] In addition, the user interface 903 may include a display screen (Display), a keyboard (Keyboard), and optionally the user interface 903 may also include a standard wired interface, a wireless interface. The network interface 904 may optionally include a standard wired interface, a wireless interface (such as a WI-FI interface).

[0133] The memory 905 may be a read-only memory (ROM), a static storage device, a dynamic storage device or a random access memory (RAM). The memory 905 may store a program. When the program stored in the memory 905 is executed by the processor 901, the processor 901 and the network interface 904 are used to execute each step of the device control method of the embodiment of the present application.

[0134] The processor 901 can adopt a general central processing unit (CPU), a microprocessor, an application specific integrated circuit (ASIC), a graphics processing unit (GPU) or one or more integrated circuits to execute relevant programs to implement the functions required to be performed by the units in the electronic device described in the above embodiments, or to execute the device control method described in the embodiments of the present application.

[0135] The processor 901 may also be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the device control method of the embodiment of the present application may be completed by an integrated logic circuit of hardware or software instructions in the processor 901. The above-mentioned processor 901 may also be a general-purpose processor, a digital signal processor (DigitalSignal Processing, DSP), an application-specific integrated circuit (ASIC), a field programmable gate array (Field ProgrammableGate Array, FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The disclosed methods, steps and logic block diagrams in the embodiments of the present application may be implemented or executed. The general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc. The steps of the device control method disclosed in the embodiment of the present application may be directly embodied as being executed by a hardware decoding processor, or executed by a combination of hardware and software modules in a decoding processor. The software module may be located in a mature storage medium in the art such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory or an electrically erasable programmable memory, a register, etc. The storage medium is located in the memory 905, and the processor 901 reads the information in the memory 905, and combines its hardware to complete the functions required to be performed by the units included in the electronic device described in the above embodiment, or executes the device control method of the method embodiment of the present application.

[0136] The network interface 904 uses a transceiver such as but not limited to a transceiver to implement communication between the electronic device 900 and other devices or a communication network. For example, when the electronic device 900 is a control device, the physical address information of the computer device can be obtained through the network interface 904.

[0137] The bus 902 may include a path for transmitting information between various components of the electronic device 900 (eg, the memory 905 , the processor 901 , the user interface 903 , and the network interface 904 ).

[0138] It should be noted that although Fig. 9 The electronic device 900 shown only shows a memory, a processor, a user interface, and a communication interface, but in the specific implementation process, those skilled in the art should understand that the electronic device 900 also includes other devices necessary for normal operation. At the same time, according to specific needs, those skilled in the art should understand that the electronic device 900 may also include hardware devices for implementing other additional functions. In addition, those skilled in the art should understand that the electronic device 900 may also only include the devices necessary to implement the embodiments of the present application, and does not necessarily include Fig. 9 All devices shown in .

[0139] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application can be essentially or partly embodied in the form of a computer program product that contributes to the prior art, and the computer program product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods described in each embodiment of the present application. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0140] An embodiment of the present invention further provides a chip, which includes a processor and a data interface. The processor reads instructions stored in a memory through the data interface to execute the device control method described in the embodiment of the present application.

[0141] Optionally, as an implementation method, the chip may also include a memory, in which instructions are stored, and the processor is used to execute the instructions stored in the memory. When the instructions are executed, the processor is used to execute the device control method described in the embodiment of the present application.

[0142] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.

[0143] In the several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0144] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0145] In addition, each functional unit in each embodiment of the present patent application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.

[0146] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

Claims

1. A device control method, characterized in that: Applied to a computer device, the computer device comprises a network card and a motherboard, the network card is connected to the motherboard, and the method comprises the following steps: The network card receives an operation message broadcast by a control device, wherein the operation message includes an operation message header, a target physical address of a target computer device, and target verification information of the target computer device; The network card sends instruction information to the mainboard 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, wherein the instruction information is used to instruct to perform the target operation; The mainboard executes the target operation, and after the target operation is completed, determines that the operation result of the operation message is a successful operation; the preset condition includes that the number of repetitions of the target physical address in the operation message is greater than or equal to a preset number, and / or the length of the operation message header is greater than or equal to a preset length; The network card sends the operation result of the operation message to the control device.

2. The method according to claim 1, characterized in that The operation message also includes operation instruction information, and the operation instruction information is used to instruct the target computer device to perform the target operation; The preset condition is that the operation message includes the operation instruction information.

3. The method according to claim 1, characterized in that The method further comprises: When the target physical address and the local physical address are different, the operation message is discarded.

4. The method according to any one of claims 1 to 3, characterized in that: The method further comprises: When the target physical address is the same as the local physical address and the target verification information is inconsistent with the local verification information, a feedback message is sent to the control device, where the feedback message is used to indicate that the target verification information is inconsistent with the local verification information.

5. The method according to any one of claims 1 to 3, characterized in that: Before receiving the operation message broadcast by the control device, the method further includes: receiving a physical address request broadcasted by the control device; In response to the physical address request, the local physical address is sent to the control device.

6. The method according to any one of claims 1 to 3, characterized in that: The target operation includes powering off, restarting, or waiting for a first time after powering off and then powering on.

7. A device control method, characterized in that: Applied to a control device, the method comprises the following steps: Broadcasting an operation message, wherein the operation message includes an operation message header, a target physical address of a target computer device, and target verification information of the target computer device, wherein the target physical address in the operation message is repeated a number of times greater than or equal to a preset number of times, and / or the length of the operation message header is greater than or equal to a preset length; Receiving an operation result of the operation message from the computer device, wherein the operation result is used to indicate that the computer device successfully performs the target operation; Among them, the computer device includes a network card and a mainboard, the network card is connected to the mainboard, the network card is used to receive the operation message, and send indication information to the mainboard 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, and the indication information is used to instruct the execution of the target operation; the mainboard is used to execute the target operation; the network card is also used to send the operation result of the operation message; the preset conditions include 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 operation message header is greater than or equal to the preset length.

8. The method according to claim 7, characterized in that The operation message also includes operation instruction information, and the operation instruction information is used to instruct the target computer device to perform the target operation; The preset condition is that the operation message includes the operation instruction information.

9. The method according to claim 7, characterized in that: The method further comprises: A feedback message is received when the computer device determines 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, wherein the feedback message is used to indicate that the target verification information is inconsistent with the local verification information.

10. The method according to any one of claims 7 to 9, characterized in that: The method further comprises: Broadcast physical address request; The local physical address sent by the computer device in response to the physical address request is received.

11. The method according to any one of claims 7 to 9, characterized in that: The target operation includes powering off, restarting, or waiting for a first time after powering off and then powering on.

12. A computer device, characterized in that: It includes a network card and a mainboard, wherein the network card is connected to the mainboard, wherein: The network card is used to receive an operation message broadcast by a control device, wherein the operation message includes an operation message header, a target physical address of a target computer device, and target verification information of the target computer device; The network card sends instruction information to the mainboard 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, wherein the instruction information is used to instruct to perform the target operation; The mainboard is used to execute the target operation, and after the target operation is completed, determine that the operation result of the operation message is a successful operation; the preset condition includes that the number of repetitions of the target physical address in the operation message is greater than or equal to a preset number, and / or the length of the operation message header is greater than or equal to a preset length; The network card is used to send the operation result of the operation message to the control device.

13. The computer device according to claim 12, characterized in that The network card includes a transceiver unit and a first processing unit, the mainboard includes a second processing unit, the transceiver unit is connected to the first processing unit, and the first processing unit is connected to the second processing unit, wherein: The transceiver unit is used to receive the operation message broadcast by the control device; The first processing unit is used to send instruction information to the second processing unit when confirming that the operation message meets the preset condition and the target verification information carried by the operation message is consistent with the local verification information, wherein the instruction information is used to instruct the second processing unit to perform the target operation; The second processing unit is used to execute the target operation, and after the target operation is completed, determine that the operation result of the operation message is a successful operation; The transceiver unit is used to send the operation result of the operation message to the control device.

14. A control device, characterized in that: The method comprises a module for executing the method as claimed in any one of claims 7 to 11.

Citation Information

Patent Citations

  • Network access authentication method, network access authentication device, network access device and router

    CN106454828A

  • Multicast group management method and device, readable storage medium and computer

    CN110958124A