Kernel log processing method and device of controlled equipment and electronic equipment
By responding to mode control instructions and kernel log reading commands in the controlled device, the method of obtaining kernel logs in the fault situation is realized, solving the problem of fault location and ensuring the integrity and obtainability of kernel logs.
Patent Information
- Application Number
- CN202411554503.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-01
- Publication Date
- 2025-03-11
AI Technical Summary
When a computing device fails, it is difficult to effectively obtain the kernel log for trouble location.
By implementing the kernel log processing method in the controlled device, enter firmware mode in response to the mode control command of the master device, and receive the kernel log reading command, read and send the kernel log to the master device.
It realizes the ability to obtain kernel logs when a device fails, provides effective reference information for trouble location, and avoids the problem of kernel logs being cleared in operating system mode.
Smart Images

Figure CN119597693A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and in particular to a kernel log processing method and device for a controlled device and electronic equipment. Background Art
[0002] With the continuous development of computer technology, computing devices have been applied in more and more scenarios. During use, computing devices may fail at any time, for example, the computing device system may freeze, thus affecting normal use. In actual application scenarios, it is often necessary to clearly locate the failure of the computing device.
[0003] Since kernel logs can provide effective reference information for locating faults, how to obtain kernel logs has become a technical problem that needs to be solved urgently. Summary of the invention
[0004] The embodiment of the present invention provides a kernel log processing method and device of a controlled device and an electronic device, which can realize the acquisition of kernel logs.
[0005] In order to solve the above problem, an embodiment of the present invention discloses a kernel log processing method of a controlled device, the method comprising:
[0006] Entering a firmware mode in response to a mode control instruction sent by a connected master control device; the mode control instruction is triggered when a device failure occurs in the controlled device;
[0007] Receive a kernel log reading command sent by the master control device; the kernel log reading command is a firmware command used to control the controlled device to read and send kernel logs;
[0008] In response to the kernel log reading command, the locally stored kernel log is read, and the kernel log is sent to the main control device based on the connection path for storage by the main control device.
[0009] Optionally, the kernel log reading command is generated in the following manner: the main control device receives a kernel log entry address, a kernel log file size, and a preset command name input by a user based on the firmware mode to generate the kernel log reading command;
[0010] Wherein, the kernel log reading command is sent based on the connection path.
[0011] Optionally, the controlled device is pre-configured with a firmware code for implementing the kernel log reading command; and the reading of the locally stored kernel log includes:
[0012] Running the firmware code to read the kernel log entry address and the kernel log file size from the kernel log read command;
[0013] Reading data from the kernel log entry address according to a preset size, and writing the read log data into a storage queue corresponding to the connection path until the target location is read;
[0014] The space size between the target location and the kernel log entry address is the same as the kernel log file size.
[0015] Optionally, writing the read log data into a storage queue corresponding to the connection path includes:
[0016] Writing the log data into a temporary variable;
[0017] When the log data meets a preset writing condition, writing the log data into the storage queue;
[0018] The step of sending the kernel log to the main control device based on the connection path includes:
[0019] When the data in the storage queue meets a preset sending condition, the log data in the storage queue is sent to the main control device through the connection path.
[0020] Optionally, the master control device is connected to the controlled device via a serial port line; the storage queue is a serial port first-in first-out queue;
[0021] The mode control instruction is sent by the master control device to the controlled device during the process of restarting the controlled device when the device failure occurs in the controlled device.
[0022] Optionally, the method further comprises:
[0023] In response to the parameter acquisition instruction, acquiring a parameter value of a specified parameter from a specified system file;
[0024] Determine the kernel log entry address based on the parameter value, and output the kernel log entry address;
[0025] In response to the size acquisition instruction, an option value of a specified option is acquired from a specified configuration file;
[0026] The kernel log file size is determined based on the option value, and the kernel log file size is output.
[0027] Optionally, the kernel log includes a plurality of log data, and the method further includes:
[0028] When the operating system kernel detects a specific event, generating a piece of log data;
[0029] The log data is stored in a preset kernel log storage space; the starting address of the kernel log storage space is the kernel log entry address, and the space size of the kernel log storage space is the kernel log file size;
[0030] The step of reading data from the kernel log entry address according to a preset size includes:
[0031] Starting from the kernel log entry address, the log data of the preset size is read cyclically in sequence.
[0032] On the other hand, an embodiment of the present invention discloses a kernel log processing device of a controlled device, the device comprising:
[0033] A first response module, configured to enter a firmware mode in response to a mode control instruction sent by a connected master control device; the mode control instruction is triggered when a device failure occurs in the controlled device;
[0034] A receiving module, used for receiving a kernel log reading command sent by the master control device; the kernel log reading command is a firmware command, used for controlling the controlled device to read and send kernel logs;
[0035] The second response module is used to respond to the kernel log reading command, read the kernel log stored locally, and send the kernel log to the main control device based on the connection path for the main control device to save.
[0036] Optionally, the kernel log reading command is generated in the following manner: the main control device receives a kernel log entry address, a kernel log file size, and a preset command name input by a user based on the firmware mode to generate the kernel log reading command;
[0037] Wherein, the kernel log reading command is sent based on the connection path.
[0038] Optionally, the controlled device is pre-configured with a firmware code for implementing the kernel log reading command; and the second response module is specifically configured to:
[0039] Running the firmware code to read the kernel log entry address and the kernel log file size from the kernel log read command;
[0040] Reading data from the kernel log entry address according to a preset size, and writing the read log data into a storage queue corresponding to the connection path until the target location is read;
[0041] The space size between the target location and the kernel log entry address is the same as the kernel log file size.
[0042] Optionally, the second response module is further configured to:
[0043] Writing the log data into a temporary variable;
[0044] When the log data meets a preset writing condition, writing the log data into the storage queue;
[0045] When the data in the storage queue meets a preset sending condition, the log data in the storage queue is sent to the main control device through the connection path.
[0046] Optionally, the master control device is connected to the controlled device via a serial port line; the storage queue is a serial port first-in first-out queue;
[0047] The mode control instruction is sent by the master control device to the controlled device during the process of restarting the controlled device when the device failure occurs in the controlled device.
[0048] Optionally, the device further comprises:
[0049] A third response module, configured to obtain a parameter value of a specified parameter from a specified system file in response to the parameter acquisition instruction;
[0050] A first output module, configured to determine the kernel log entry address based on the parameter value, and output the kernel log entry address;
[0051] A fourth response module, configured to obtain an option value of a specified option from a specified configuration file in response to the size acquisition instruction;
[0052] The second output module is used to determine the kernel log file size based on the option value and output the kernel log file size.
[0053] Optionally, the kernel log includes a plurality of log data, and the device further includes:
[0054] A generating module, used for generating a piece of the log data when the operating system kernel detects a specific event;
[0055] A storage module, used for storing the log data into a preset kernel log storage space; the starting address of the kernel log storage space is the kernel log entry address, and the space size of the kernel log storage space is the kernel log file size;
[0056] The second response module is further configured to:
[0057] Starting from the kernel log entry address, the log data of the preset size is read cyclically in sequence.
[0058] On the other hand, an embodiment of the present invention discloses an electronic device, comprising: a processor, a memory, a communication interface and a communication bus, wherein the processor, the memory and the communication interface communicate with each other through the communication bus; the memory is used to store at least one executable instruction, and the executable instruction enables the processor to execute the aforementioned method.
[0059] The embodiment of the present invention further discloses a machine-readable medium on which instructions are stored. When executed by one or more processors, the processors are enabled to execute the method described above.
[0060] The embodiment of the present invention has the following advantages: In the kernel log processing method of the controlled device provided by the embodiment of the present invention, in response to the mode control instruction sent by the connected master control device, the firmware mode is entered; the mode control instruction is triggered when the controlled device has a device failure. The kernel log reading command sent by the master control device is received; the kernel log reading command belongs to a firmware command and is used to control the controlled device to read and send the kernel log. In response to the kernel log reading command, the kernel log stored locally is read, and the kernel log is sent to the master control device based on the connection path for the master control device to save. In this way, the kernel log of the controlled device can be uploaded to the master control device, and the acquisition of the kernel log is realized. Since the kernel log includes the log generated when the controlled device has a device failure, by acquiring the kernel log, effective reference information can be provided for locating the fault, and the fault location is convenient. At the same time, since the kernel log in the memory will not be cleared in the firmware mode, by first triggering the controlled device to enter the firmware mode, and reading the kernel log by the kernel log reading command in the firmware mode, the problem of the kernel log being cleared and causing the kernel log acquisition failure can be avoided. BRIEF DESCRIPTION OF THE DRAWINGS
[0061] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments of the present invention will be briefly introduced below. Obviously, the accompanying drawings in the following description are only some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying creative labor.
[0062] Figure 1 It is a flowchart of a kernel log processing method of a controlled device provided by an embodiment of the present invention;
[0063] Figure 2is a schematic diagram of a sending process provided by an embodiment of the present invention;
[0064] Figure 3 It is a block diagram of a kernel log processing device of a controlled device provided by an embodiment of the present invention;
[0065] Figure 4 It is a structural schematic diagram of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0066] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0067] First, an application scenario of an embodiment of the present invention is described. The kernel log processing method of the controlled device provided in the embodiment of the present invention can adopt a master-controlled mode to obtain the kernel log in the controlled device. Specifically, the kernel log in the controlled device can be obtained to the master control device for the user to view. Among them, the controlled device can be any computing device, the master control device can be a computing device used by the user, and the master control device can have a display function and a data export function, so as to facilitate the user to view the obtained kernel log and export the obtained kernel log. Exemplarily, the computing device can be a computer, a server, or other device with processing capabilities.
[0068] Furthermore, the controlled device may be a device used in a special usage scenario, wherein the special usage scenario may be that the computing device is in an unattended environment during operation and is not connected to an external device (e.g., a mouse, a keyboard, and a display device), but is remotely operated through a network, and the computing device operates normally through the network and is managed through a serial port.
[0069] For example, with the rapid development of information technology and the differentiation of user needs, computing devices have been widely used in actual production scenarios such as financial settlement, industrial production, command and control, big data storage and computing. In these scenarios, computing devices are often in special usage scenarios, and it is often more difficult to troubleshoot problems in special usage scenarios. In addition, in special usage scenarios, if a problem occurs with a computing device, it is often not allowed to directly replace a new computing device, but it is necessary to troubleshoot the problem, locate the problem clearly, and determine the cause of the problem. However, for special usage scenarios, such as unattended, mouse-less and display-less computing devices, problems that are difficult to locate may occur during use, for example, the computing device system freezes during use. Among them, the freeze problem refers to the inability of the computing device's operating system to respond normally. The freezing of the computing device system is a serious computer failure. Once the computer has such a failure, it will directly affect the normal data processing / storage in scenarios such as financial settlement, industrial production, command and control, big data storage and computing, causing losses to the user. The longer the time to troubleshoot the problem, the greater the loss.
[0070] At present, once a computer freezes, the only way is to manually return the computing device to the device manufacturer and locate the problem manually. However, some freeze problems are related to the operating environment, and the method of returning to the device manufacturer for manual location cannot find clues related to the problem. The kernel log, as log information generated by the operating system kernel, records key events, errors, warnings and debugging information when the system is running, and is the key to solving the location problem, and can provide an effective reference for problem location. Since the kernel log is recorded in the memory, once the computing device is powered off, the kernel log will be lost. Therefore, in the method of returning to the device manufacturer, the kernel log of the computing device cannot be obtained, which will make it difficult to locate the cause of the problem. That is, in special scenarios, the hardware cannot be moved, and the operation of the computing device cannot be changed. Therefore, an embodiment of the present invention provides a kernel log processing method for a controlled device to ensure that the kernel log in the controlled device can also be obtained in special scenarios. The kernel log processing method provided by an embodiment of the present invention is described in detail below.
[0071] Reference Figure 1 , shows a flowchart of a kernel log processing method of a controlled device provided by an embodiment of the present invention. Figure 1 As shown, the kernel log processing method of the controlled device specifically includes the following steps:
[0072] Step 101: Entering a firmware mode in response to a mode control instruction sent by a connected master control device; the mode control instruction is triggered when a device failure occurs in the controlled device.
[0073] Step 102: Receive a kernel log read command sent by the master control device; the kernel log read command is a firmware command used to control the controlled device to read and send kernel logs.
[0074] Step 103: In response to the kernel log read command, read the locally stored kernel log, and send the kernel log to the main control device based on the connection path for the main control device to save.
[0075] In an embodiment of the present invention, the operating system of the controlled device can store the kernel log in the memory, and the memory does not lose power when the computing device is restarted, that is, the restart will not cause the kernel log in the memory to be lost. Further, when the operating system is booted into the operating system mode, the previously recorded kernel log will be cleared to facilitate the recording of new kernel logs. When the operating system is booted into the firmware mode, since in the firmware mode, the firmware has its own log system, which is independent of the kernel log of the operating system, therefore, the kernel log in the memory will not be cleared. Exemplarily, the operating system can be a Linux operating system.
[0076] Among them, the operating system mode refers to the working state of the controlled device after it is started and the operating system is loaded. In the operating system mode, the operating system is responsible for managing hardware resources, executing applications, and providing a user interface. Under normal circumstances, the computing device enters the operating system mode by default after startup. The firmware mode refers to the specific startup and operation mode provided by the system firmware. Specifically, the firmware is software embedded in the computing device, which is responsible for initializing and configuring the hardware and providing underlying services for the operating system. During the computer startup process, in the firmware mode, the specific startup and operation mode provided by the system firmware may include: executing a series of startup steps, such as hardware initialization, operating system loading, and underlying service operation. Exemplarily, the firmware can be a Basic Input / Output System (BIOS), a Unified Extensible Firmware Interface (UEFI), or a Processor Monitor (PMON) firmware.
[0077] Further, the controlled device can be connected to the main control device through a serial port. In order to ensure that the kernel log can be obtained normally, the main control device can first send a mode control instruction to the controlled device. Among them, the mode control instruction can be used to control the controlled device to enter the firmware mode. The mode control instruction can be triggered when a device failure occurs in the controlled device, so as to obtain the kernel log in time, thereby providing reference information for fault location. Since it is necessary to obtain the kernel log in the controlled device in the firmware mode, the controlled device can be controlled to obtain the log based on the firmware command. Specifically, the kernel log acquisition command can be configured for the controlled device in advance, so as to control the controlled device to read the kernel log and transmit it to the main control device through the kernel log acquisition command. Exemplarily, the kernel log acquisition command can be integrated for the controlled device to ensure that the controlled device can respond to the kernel log acquisition command normally. The kernel log generated by the controlled device to the main control device can be saved in the main control device for the user to view, so as to facilitate the user to troubleshoot the controlled device based on the kernel log. The mode control instruction can be sent during the restart process after the controlled device receives the restart instruction triggered by the external trigger. In view of the characteristics that the memory of the controlled device does not lose power when it restarts, and the kernel log is not affected in the firmware mode, in the embodiment of the present invention, when a device failure occurs in the controlled device, the controlled device is first controlled to restart, and then the controlled device is controlled to enter the firmware mode. While ensuring that the kernel log is not affected, the controlled device can be conveniently controlled by the main control device to read and send the kernel log.
[0078] In summary, in the kernel log processing method of the controlled device provided by the embodiment of the present invention, in response to the mode control instruction sent by the connected master device, the firmware mode is entered; the mode control instruction is triggered when the controlled device has a device failure. The kernel log reading command sent by the master device is received; the kernel log reading command belongs to a firmware command, which is used to control the controlled device to read and send the kernel log. In response to the kernel log reading command, the kernel log stored locally is read, and the kernel log is sent to the master device based on the connection path for the master device to save. In this way, the kernel log of the controlled device can be uploaded to the master device, and the acquisition of the kernel log is realized. Since the kernel log includes the log generated when the controlled device has a device failure, by acquiring the kernel log, effective reference information can be provided for locating the fault, which is convenient for fault locating. At the same time, since the kernel log in the memory will not be cleared in the firmware mode, by first triggering the controlled device to enter the firmware mode, and reading the kernel log through the kernel log reading command in the firmware mode, the problem of kernel log being cleared and causing kernel log acquisition failure can be avoided.
[0079] Optionally, in the embodiment of the present invention, the master control device and the controlled device are connected via a serial port line to form a connection path, and the storage queue is a serial port first-in first-out queue (First Input First Output, FIFO). Specifically, the serial port FIFO in the controlled device can be a sending FIFO. The kernel log of the controlled device is read out in a fixed size loop, written into the register of the serial port in the form of characters, and transmitted to the master control device through the FIFO mechanism. Accordingly, the transmission path between the master control device and the controlled device is the serial port line. Furthermore, the mode control instruction is sent by the master control device to the controlled device during the process of restarting the controlled device when a device failure occurs in the controlled device.
[0080] Specifically, the serial port line connected between the master device and the controlled device may be connected after the device failure occurs in the controlled device, or may be connected before the failure occurs, and the implementation of the present invention is not limited to this. Exemplarily, the staff may connect the two ends of the serial port line to the debugging serial port access ports of the master device and the controlled device respectively, and then connect the serial port line between the master device and the controlled device. Further, the specific type of device failure of the controlled device may be defined as needed. Exemplarily, the device failure of the controlled device may specifically refer to the operating system of the controlled device being stuck and unable to respond normally. Accordingly, in the case of a device failure of the controlled device, the controlled device may be physically restarted according to the externally triggered restart instruction, so that the controlled device starts to restart. Exemplarily, the staff may trigger the physical button of the controlled device for restarting in the case of a device failure in the controlled device. Alternatively, an automatic trigger device may be connected in advance to the physical button of the controlled device for restarting, and in the case of a device failure in the controlled device, the automatic trigger device may be controlled to perform a pressing operation to trigger the physical button of the controlled device for restarting. For example, the automatic trigger device may be a mechanical arm, a micro robot, and the like.
[0081] Further, during the restart of the controlled device, the controlled device can choose to enter the operating system mode or the firmware mode. In order to make the controlled device enter the firmware mode this time, the master device can send a mode control instruction to the controlled device after the controlled device restarts. Among them, the mode control instruction can be an instruction for instructing the controlled device to enter the firmware mode. Specifically, the master device and the controlled device are connected via a serial port line. Therefore, after the controlled device is triggered to restart, the output information of the controlled device is transmitted to the master device via the serial port line and displayed in the master device. Exemplarily, serial port terminal software can be installed in the master device, which can be displayed in the serial port terminal interface. Accordingly, the user can enter the mode control instruction in the display interface of the master device, or, by triggering the first designated physical button, control the master device to execute and generate the first button mode signal as the mode control instruction. Accordingly, the master device can send the mode control instruction to the controlled device via the serial port line.
[0082] In the embodiment of the present invention, when the master device is restarting after a device failure occurs in the controlled device, the master device sends a mode control instruction to the controlled device, which can ensure that the controlled device can enter the firmware mode, thereby avoiding the kernel log of the controlled device from being cleared, ensuring that the kernel log of the failed controlled device can be obtained, thereby providing a reference for subsequent troubleshooting and reducing the difficulty of troubleshooting. At the same time, by setting the master device and the controlled device to be connected via a serial port line, the storage queue is a serial port first-in-first-out queue. Since the firmware function of the controlled device is often relatively simple, a general serial port connection method is adopted to avoid the connection method being unsupported, thereby causing the read kernel log to be unable to be normally transmitted to the master device.
[0083] It should be noted that, in the case where there are other connection modes supported by the firmware mode of the controlled device, other connection modes may also be used for the master device and the controlled device, and the embodiment of the present invention does not limit this.
[0084] Optionally, in an embodiment of the present invention, the kernel log reading command may be generated by the following steps:
[0085] Step S21, the main control device receives the kernel log entry address, kernel log file size and preset command name input by the user based on the firmware mode to generate the kernel log reading command; wherein the kernel log reading command is sent based on the connection path.
[0086] In an embodiment of the present invention, the above step S21 can be performed by the main control device. Specifically, based on the remote command line interface corresponding to the firmware mode, the kernel log entry address, kernel log file size and preset command name input by the user can be received. Then, based on the received kernel log entry address, kernel log file size and preset command name, a kernel log reading command is generated. Among them, the remote command line interface can be a firmware shell interface, and the remote command line interface can be a serial terminal interface in the main control device. In the case where the main control device and the controlled device are connected via a serial port line, during the process of the controlled device restarting to enter the firmware mode, all output information (information available for display) can be transmitted to the main control device via the serial port line and displayed in the port terminal interface of the main control device.
[0087] Furthermore, the remote command line interface can be specifically an interface for inputting command lines after the controlled device enters the firmware mode. By displaying the remote command line interface on the master device, the user can conveniently send a kernel log reading command to the controlled device based on the master device.
[0088] Specifically, after the master control device sends a mode control instruction to the controlled device, the user can trigger the master control device to send a control instruction for controlling the controlled device to enter the firmware shell mode. The firmware shell mode refers to a mode that supports the input of a command line for firmware commands to control the controlled device. Exemplarily, the master control device can be controlled to execute a control instruction for generating a second key mode signal as the firmware shell mode by triggering a second designated physical button, and the control instruction can be sent to the controlled device through the serial port line. Furthermore, after the controlled device enters the firmware shell mode, the data of the command line interface corresponding to the firmware shell mode can be transmitted to the master control device for display. Accordingly, the master control device can display the remote command line interface based on these data.
[0089] Further, the kernel log entry address represents the starting address of the kernel log storage space in the controlled device, and the kernel log file size represents the space size of the kernel log storage space in the controlled device. The kernel log entry address and the kernel log file size are command parameters required to generate the kernel log read command, and can be passed in as command parameters. The preset command name refers to the instruction name defined for the kernel log read command, wherein the preset command name can be defined as needed, and illustratively, the preset command name can be read_klog, which is not limited in the embodiment of the present invention. The kernel log entry address and the kernel log file size can be obtained in advance from the controlled terminal and stored in a specified location of the master device for user viewing.
[0090] The kernel log storage space is a pre-set area for storing kernel logs. The kernel log storage space belongs to the memory, and the kernel log includes multiple log data. Accordingly, the kernel log can be generated and stored in the following manner: when the operating system kernel detects a specific event, a log data is generated; the log data is stored in the preset kernel log storage space; the starting address of the kernel log storage space is the kernel log entry address, and the space size of the kernel log storage space is the kernel log file size.
[0091] Among them, the specific event can be an event that the developer predetermines to be recorded. For example, the specific event can include: system call failure, hardware failure, driver error. Each time a specific event occurs, a log data can be generated and written to the kernel log storage space accordingly. In this way, the specific event that occurred can be recorded based on the recorded log data.
[0092] Specifically, the user can obtain the kernel log entry address and the kernel log file size from the specified location. For example, the main control device displays the kernel log entry address and the kernel log file size in response to the user's viewing instruction, so that the user can know the kernel log entry address and the kernel log file size. Then, the user enters the command line of the preset command name, kernel log entry address and kernel log file size in the remote command line interface. Correspondingly, the main control device can combine the kernel log entry address, kernel log file size and preset command name in the command line entered by the user according to the preset command format to obtain the kernel log reading command. Finally, the kernel log reading command is sent to the controlled device through the serial port line. Among them, the preset command format can be defined as needed. For example, the preset command format can be: firmware name> command name kernel log entry address kernel log file size, which is not limited in the embodiment of the present invention.
[0093] Exemplarily, taking PMON firmware as an example, assuming that the kernel log entry address is 0xffffffff81539760 and the kernel log file size is 0x20000. Accordingly, the generated kernel log reading command can be: PMON>read_klog0xffffffff81539760 0x20000. Among them, the specific values of the kernel log entry address and the kernel log file size can be input by the user to the main control device, and are set according to the actual situation of the controlled device. Accordingly, the user can pre-control the controlled device through the following steps S31 to S34, output the kernel log entry address and the kernel log file size, so as to obtain the specific values of the kernel log entry address and the kernel log file size.
[0094] In an embodiment of the present invention, the main control device receives the kernel log entry address, kernel log file size and preset command name input by the user based on the remote command line interface corresponding to the firmware mode. Based on the kernel log entry address, kernel log file size and preset command name, a kernel log reading command is generated. In this way, when the controlled device responds to the kernel log reading command, the kernel log entry address and kernel log file size can be easily known, thereby improving the response speed of the kernel log reading command. At the same time, by providing a remote command line interface, it is convenient for the user to use the main control device to send the kernel log reading command, thereby reducing the difficulty of obtaining the log.
[0095] Optionally, the embodiment of the present invention may further include the following steps:
[0096] Step S31, in response to the parameter acquisition instruction, acquiring the parameter value of the specified parameter from the specified system file.
[0097] Step S32: determine the kernel log entry address based on the parameter value, and output the kernel log entry address.
[0098] Step S33: In response to the size acquisition instruction, the option value of the specified option is acquired from the specified configuration file.
[0099] Step S34: Determine the kernel log file size based on the option value, and output the kernel log file size.
[0100] In the embodiment of the present invention, the kernel log entry address and the kernel log file size can be pre-acquired from the controlled device through the above steps S31 to S34. Specifically, the above steps S31 to S34 can be executed before the controlled device sends a device failure, that is, the user can obtain the kernel log entry address and the kernel log file size from the controlled device in advance, so as to generate a kernel log read command using the master device based on the kernel log entry address and the kernel log file size.
[0101] Specifically, the parameter acquisition instruction may be triggered when it is necessary to obtain the kernel log entry address from the controlled device, and the designated system file may be a file in the controlled device that stores designated parameters, and the designated parameters are parameters related to the kernel log entry address. Specifically, the designated system file may be the System.map file of the kernel in the operating system or files such as vmlinux. The designated parameters may be log buffer parameters. Accordingly, the parameter acquisition instruction may be a read operation on the designated parameters. In response to the parameter acquisition instruction, the controlled device may execute an operation of reading the parameter value of the log buffer parameter, and then determining and outputting the kernel log entry address based on the read parameter value. Specifically, the read parameter value may be determined as the kernel log entry address.
[0102] In an embodiment of the present invention, the kernel log entry address and the kernel log file size can be sent to the main control device to achieve output. So that the user of the main control device can know the specific values of the kernel log entry address and the kernel log file size. Accordingly, the main control device can store the received kernel log entry address and the kernel log file size to the specified location of the main control device for the convenience of the user to view. Alternatively, it can also be sent to the device of the operating system manufacturer to achieve output. Accordingly, the operating system manufacturer can inform the main control device user of the obtained kernel log entry address and the kernel log file size, and the main control device user will store the kernel log entry address and the kernel log file size to the specified location of the main control device, and the embodiment of the present invention does not limit this.
[0103] Furthermore, the specified configuration file may be a configuration file compiled by the kernel, and the instruction configuration file may be a file of the .config type. Specifically, the specified option may be an option related to the kernel log file size. Exemplarily, the specified option may be the CONFIG_LOG_BUF_SHIFT option, which determines the size of the kernel log stored in the memory. The larger the specific value of the CONFIG_LOG_BUF_SHIFT option, the larger the kernel log file size. Accordingly, the size acquisition instruction may be a read operation on the specified option. In response to the size acquisition instruction, the controlled device may execute a read of the specific value of the CONFIG_LOG_BUF_SHIFT option, which is the option value of the option. The kernel log file size is then determined and output based on the specific value read. Specifically, CONFIG_LOG_BUF_SHIFT is an option for defining the size of the kernel log memory area. The specific value of the CONFIG_LOG_BUF_SHIFT option is represented by x. 2 x Determines the size of the kernel log file.
[0104] In an embodiment of the present invention, the controlled device obtains the parameter value of the specified parameter from the specified system file in response to the parameter acquisition instruction. The kernel log entry address is determined based on the parameter value, and the kernel log entry address is output. In response to the size acquisition instruction, the option value of the specified option is obtained from the specified configuration file. The kernel log file size is determined based on the option value, and the kernel log file size is output. In this way, the kernel log entry address and the kernel log file size of the controlled device can be accurately obtained through the parameter acquisition instruction and the size acquisition instruction, thereby facilitating the user to obtain the parameters required to generate the kernel log reading command.
[0105] In an embodiment of the present invention, the kernel log reading command can be implemented based on firmware code, and the kernel log reading command can be a shell command provided by the firmware corresponding manufacturer. The command can be used to read the log and transmit the kernel log to the main control device through the serial port. Specifically, the firmware code for implementing the function implemented by the kernel log reading command can be added to the firmware layer of the controlled device, and the kernel log reading command is integrated into the controlled device. The kernel log reading command can be used to obtain the kernel log later, providing convenient conditions for the troubleshooter to obtain the kernel log. Optionally, the controlled device in the embodiment of the present invention is pre-configured with a command for implementing the kernel log reading command. Specifically, the firmware code of the kernel log reading command can be pre-added to the firmware source code. When an abnormality occurs in the device, after the restart instruction, the controlled device responds to the kernel log reading command and can execute the firmware code of the kernel log reading command. In this way, the corresponding firmware code is integrated on the firmware, and the kernel log reading command can be implemented on the firmware, ensuring that the kernel log reading command can be normally responded to in the firmware mode. At the same time, the firmware code of the kernel log reading command will only be executed in response to the kernel log reading command. When the computing device is started and operated normally, the configured firmware code of the kernel log reading command will not have an impact. In an embodiment of the present invention, the firmware code of the kernel log read command can be used to implement the function corresponding to the kernel log read command. Specifically, the function corresponding to the kernel log read command can be represented by the following steps 1031 to 1032:
[0106] The above-mentioned step of reading the kernel log stored locally may specifically include:
[0107] Step 1031: Run the firmware code to read the kernel log entry address and the kernel log file size from the kernel log read command.
[0108] Step 1032: read data from the kernel log entry address according to a preset size, and write the read log data into a storage queue corresponding to the connection path until the target position is read; wherein the space size between the target position and the kernel log entry address is the same as the kernel log file size.
[0109] Specifically, the controlled device can respond to the kernel log read command and run the firmware code of the kernel log read command to achieve: parsing the received kernel log read command, extracting the kernel log entry address and the kernel log file size passed in by the kernel log read command. Then, the target position can be determined based on the kernel log entry address and the kernel log file size. Among them, the target position can represent the kernel log end address. Exemplarily, the kernel log entry address can be added with the kernel log file size, and the obtained address can be used as the target position. In this way, it can be ensured that the space size between the target position and the kernel log entry address is the same as the kernel log file size.
[0110] Furthermore, the kernel log entry address indicates the location where the kernel log starts to be stored, and therefore, reading can be performed starting from the kernel log entry address. Specifically, starting from the kernel log entry address, the log data of the preset size can be read in sequence in a loop. The preset size can be a fixed size, and the preset size can be an integer multiple of the size of a single log data. That is, the log data of the preset size is read each time according to the preset size, and the read log data is written into the storage queue corresponding to the connection path, and then the log data of the preset size is read again from the position where the last reading ended, so as to realize cyclic reading. Among them, the storage queue can be established based on the serial port sending register, and the read log data is written into the storage queue corresponding to the connection path, and specifically, the read log data is written into the serial port sending register.
[0111] In an embodiment of the present invention, by continuously reading out the log data in a loop, when the target position is finally read, it can be considered that all kernel logs have been read, so the reading process can be terminated. Among them, the preset size can be set as needed, and illustratively, the preset size can be 1 byte. The read log data can be written into the serial port FIFO in the form of characters. The log data in the serial port FIFO can eventually be transmitted to the serial terminal software of the remote debugging computing device (i.e., the main control device) through the serial port line. Correspondingly, the main control device can monitor the serial port line, and when the log data arrives, the log data can be placed in the receiving buffer. Open the serial terminal software on the main control device, and the log data received in the receiving buffer can be displayed. Optionally, in an embodiment of the present invention, the main control device can save the received kernel log through the file saving function of the serial terminal software. Alternatively, the received kernel log can also be saved to a specified file through the copy printing function.
[0112] It should be noted that the kernel log actually recorded in the controlled device may be smaller than the kernel log file size, that is, the end address of the kernel log actually recorded may be smaller than the target location. Therefore, in the process of reading from the kernel log entry address, it is determined whether the read location is empty. If the data in the read location is empty, the read operation can be terminated to avoid performing unnecessary read operations. Among them, the data is empty means that no data is stored in the location. Of course, it is also possible to directly default to reading to the target location and then terminate the read operation to omit the judgment operation.
[0113] In the embodiment of the present invention, by running the firmware code of the kernel log read command, it is possible to read the kernel log entry address and the kernel log file size from the kernel log read command. Data is read from the kernel log entry address according to the preset size, and the read log data is written into the storage queue corresponding to the connection path until the target position is read. Wherein, the space size between the target position and the kernel log entry address is the same as the kernel log file size. In this way, the log data between the kernel log entry address and the target position can be read and written into the storage queue to ensure the integrity of the kernel log read.
[0114] Optionally, in the embodiment of the present invention, the step of writing the log data into the storage queue corresponding to the connection path may specifically include:
[0115] Step 1032a: write the log data into a temporary variable.
[0116] Step 1032c: When the log data meets a preset writing condition, write the log data into the storage queue.
[0117] Accordingly, the above step of sending the kernel log to the main control device based on the connection path may specifically include:
[0118] Step 1033: When the data in the storage queue meets a preset sending condition, the log data in the storage queue is sent to the main control device through the connection path.
[0119] The temporary variable refers to a variable used to store temporary data. In the embodiment of the present invention, the temporary variable can be used to save the log data of a preset size read each time. The data type defined for the temporary variable can be consistent with the data type of the log data, for example, it can be a character type. Before starting to read, a variable can be created as a temporary variable, and after finishing reading, the temporary variable can be released to avoid unnecessary resource occupation.
[0120] The preset write condition can be set as needed. For example, the preset write condition can be that the total size of the log data written in the temporary variable is not less than the first preset threshold value, and the embodiment of the present invention does not limit this. Accordingly, the total size of the log data written in the temporary variable can be detected. If it is detected that the total size is not less than the first preset threshold value, the operation of writing the log data in the temporary variable to the storage queue can be performed once. Among them, after the log data in the temporary variable is written to the storage queue, the log data in the temporary variable can be cleared to facilitate writing subsequent log data. Compared with the method of directly writing the read log data to the storage queue each time, in the embodiment of the present invention, the read log data is first written to the temporary variable. When the log data in the temporary variable meets the preset write condition, the log data in the temporary variable is written to the storage queue corresponding to the connection path, which can reduce the number of writes to the storage queue and thus improve the write efficiency.
[0121] For example, Figure 2 is a schematic diagram of a sending process provided by an embodiment of the present invention, such as Figure 2 As shown, the size area in the memory stores the kernel log of the controlled device. For this part of the log data, the data can be read and written into a temporary variable first, then written into the serial port FIFO, and finally transmitted to the remote computer.
[0122] Specifically, the preset sending condition can be set as needed. For example, the preset sending condition can be that the total size of the log data stored in the storage queue is not less than the second preset threshold, or the storage queue is full. The embodiment of the present invention does not limit this. Wherein, the second preset threshold can represent the minimum amount of data required for sending. Correspondingly, the log data in the storage queue is the kernel log read, and the log data stored in the storage queue can be detected. If it is detected that it meets the preset sending condition, an operation of sending the log data in the storage queue to the main control device through the connection path can be performed once. Specifically, the log data stored in the storage queue can be sent to the main control device through the serial port line. Wherein, the sent log data is cleared from the storage queue to facilitate writing subsequent log data. In the embodiment of the present invention, the storage queue in the register of the serial port is used to store the log data first, and when the preset sending condition is met, that is, the total size of the log data stored in the storage queue is not less than the second preset threshold, and when a large amount of log data has been stored in the storage queue, the log data in the storage queue is sent to the main control device. In this way, the access to the serial port line can be reduced to a certain extent, and the sending efficiency can be improved.
[0123] In one related technology, the kernel log is captured through the central processing unit (CPU) debugging tool. However, this method is only applicable to the CPU debugging stage of the computing device, that is, it is only applicable to the product development stage. It cannot be adapted to the finished computer actually running in the production environment, and this method cannot obtain the kernel log when the computer has a system jam problem. In another related technology, a kernel module is inserted into the operating system of the computing device in advance, and the kernel module is continuously run to store the kernel log in a storage medium that is not lost when the power is off, and then the kernel log is subsequently obtained based on the storage medium. In this method, when the computing device is operating normally, it is also necessary to run the kernel module to obtain the kernel log, which will cause additional system overhead, and because when the system jam problem occurs, the kernel log generated at the end is often unable to be written to the storage medium, so there is a problem of incomplete kernel log written to the storage medium.
[0124] In the embodiment of the present invention, it is only necessary to execute the kernel log reading command to obtain the kernel log in the event of a fault, so that the overall operation is simple and the system overhead is lower. In the embodiment of the present invention, the kernel log is read from the entry address of the kernel log. In this way, all kernel logs can be exported to the main control device to ensure the integrity of the kernel log. Further, since there is no need for professional and technical personnel to assist, and there is no need to dispatch kernel professionals to the site of the controlled device to obtain the kernel log, by adding the implementation code corresponding to the kernel log reading command in the firmware code of the controlled device in advance, the user can directly control the controlled device to send the kernel log to the remote main control device based on the main control device to read the kernel log command, thereby obtaining the kernel log, and will not cause changes to the hardware and operating environment of the computing device. Therefore, the difficulty of implementation is lower, the difficulty of the operator is reduced, and the convenience of operation is improved. At the same time, by obtaining the kernel log, the difficulty of problem investigation can be reduced, the problem can be located remotely, the progress of problem investigation can be accelerated, the labor cost of the investigator can be saved, and powerful help can be provided for the investigator.
[0125] Reference Figure 3 , shows a block diagram of a kernel log processing device of a controlled device provided by an embodiment of the present invention, such as Figure 3 As shown, the kernel log processing device of the controlled device specifically includes:
[0126] A first response module 201, configured to enter a firmware mode in response to a mode control instruction sent by a connected master device; the mode control instruction is triggered when a device failure occurs in the controlled device;
[0127] The receiving module 202 is used to receive a kernel log reading command sent by the master device; the kernel log reading command is a firmware command, which is used to control the controlled device to read and send kernel logs;
[0128] The second response module 203 is used to respond to the kernel log reading command, read the kernel log stored locally, and send the kernel log to the main control device based on the connection path for the main control device to save.
[0129] Optionally, the kernel log reading command is generated in the following manner: the main control device receives a kernel log entry address, a kernel log file size, and a preset command name input by a user based on the firmware mode to generate the kernel log reading command;
[0130] Wherein, the kernel log reading command is sent based on the connection path.
[0131] Optionally, the controlled device is pre-configured with a firmware code for implementing the kernel log reading command; the second response module 203 is specifically used to:
[0132] Running the firmware code to read the kernel log entry address and the kernel log file size from the kernel log read command;
[0133] Reading data from the kernel log entry address according to a preset size, and writing the read log data into a storage queue corresponding to the connection path until the target location is read;
[0134] The space size between the target location and the kernel log entry address is the same as the kernel log file size.
[0135] Optionally, the second response module 203 is further configured to:
[0136] Writing the log data into a temporary variable;
[0137] When the log data meets a preset writing condition, writing the log data into the storage queue;
[0138] When the data in the storage queue meets a preset sending condition, the log data in the storage queue is sent to the main control device through the connection path.
[0139] Optionally, the master control device is connected to the controlled device via a serial port line; the storage queue is a serial port first-in first-out queue;
[0140] The mode control instruction is sent by the master control device to the controlled device during the process of restarting the controlled device when the device failure occurs in the controlled device.
[0141] Optionally, the device further comprises:
[0142] A third response module, configured to obtain a parameter value of a specified parameter from a specified system file in response to the parameter acquisition instruction;
[0143] A first output module, configured to determine the kernel log entry address based on the parameter value, and output the kernel log entry address;
[0144] A fourth response module, configured to obtain an option value of a specified option from a specified configuration file in response to the size acquisition instruction;
[0145] The second output module is used to determine the kernel log file size based on the option value and output the kernel log file size.
[0146] Optionally, the kernel log includes a plurality of log data, and the device further includes:
[0147] A generating module, used for generating a piece of the log data when the operating system kernel detects a specific event;
[0148] A storage module, used for storing the log data into a preset kernel log storage space; the starting address of the kernel log storage space is the kernel log entry address, and the space size of the kernel log storage space is the kernel log file size;
[0149] The second response module 203 is further configured to:
[0150] Starting from the kernel log entry address, the log data of the preset size is read cyclically in sequence.
[0151] In summary, in the kernel log processing device of the controlled device provided by the embodiment of the present invention, in response to the mode control instruction sent by the connected master device, the firmware mode is entered; the mode control instruction is triggered when the controlled device has a device failure. The kernel log reading command sent by the master device is received; the kernel log reading command belongs to a firmware command, which is used to control the controlled device to read and send the kernel log. In response to the kernel log reading command, the kernel log stored locally is read, and the kernel log is sent to the master device based on the connection path for the master device to save. In this way, the kernel log of the controlled device can be uploaded to the master device, and the acquisition of the kernel log is realized. Since the kernel log includes the log generated when the controlled device has a device failure, by acquiring the kernel log, effective reference information can be provided for locating the fault, which is convenient for fault locating. At the same time, since the kernel log in the memory will not be cleared in the firmware mode, by first triggering the controlled device to enter the firmware mode, and reading the kernel log through the kernel log reading command in the firmware mode, the problem of the kernel log being cleared and causing the kernel log acquisition failure can be avoided.
[0152] Reference Figure 4 , is a schematic diagram of the structure of an electronic device provided by an embodiment of the present invention. Figure 4 As shown, the electronic device includes: a processor, a memory, a communication interface and a communication bus, wherein the processor, the memory and the communication interface communicate with each other through the communication bus; the memory is used to store at least one executable instruction, and the executable instruction enables the processor to execute the kernel log processing method of the controlled device of the above embodiment. The executable instructions can form a program.
[0153] An embodiment of the present invention provides a machine-readable medium having instructions stored thereon, which, when executed by one or more processors, enables the processors to execute the kernel log processing method of the controlled device in the above-mentioned embodiment. Each embodiment in this specification is described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same and similar parts between the embodiments can be referred to each other.
[0154] It will be appreciated by those skilled in the art that the embodiments of the present invention may be provided as methods, devices, or computer program products. Therefore, the embodiments of the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the embodiments of the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program codes.
[0155] It should be noted that all actions of acquiring signals, information or data in this application are carried out in compliance with the relevant data protection laws and policies of the country where they are located and with the authorization given by the owner of the corresponding device.
[0156] The embodiments of the present invention are described with reference to the flowcharts and / or block diagrams of the methods, terminal devices (systems), and computer program products according to the embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of the processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing terminal device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing terminal device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0157] These computer program instructions may also be stored in a computer readable memory capable of directing a computer or other programmable data processing terminal device to operate in a predictable manner, so that the instructions stored in the computer readable memory produce a manufactured product including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0158] These computer program instructions can also be loaded onto a computer or other programmable data processing terminal device so that a series of operating steps are executed on the computer or other programmable terminal device to produce a computer-implemented process, thereby providing instructions for executing on the computer or other programmable terminal device to implement the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0159] Although the preferred embodiments of the present invention have been described, those skilled in the art may make additional changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the embodiments of the present invention.
[0160] Finally, it should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or terminal device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or terminal device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or terminal device including the elements.
[0161] The above is a detailed introduction to a kernel log processing method for a controlled device, a kernel log processing device for a controlled device, an electronic device and one or more readable media provided by the present invention. Specific examples are used in this article to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea; at the same time, for a person skilled in the art, according to the idea of the present invention, there will be changes in the specific implementation method and application scope. In summary, the content of this specification should not be understood as a limitation on the present invention.
Claims
1. A kernel log processing method for a controlled device, characterized in that: The method comprises: Entering a firmware mode in response to a mode control instruction sent by a connected master control device; the mode control instruction is triggered when a device failure occurs in the controlled device; Receive a kernel log reading command sent by the master control device; the kernel log reading command is a firmware command used to control the controlled device to read and send kernel logs; In response to the kernel log reading command, the locally stored kernel log is read, and the kernel log is sent to the main control device based on the connection path for storage by the main control device.
2. The method according to claim 1, characterized in that The kernel log reading command is generated in the following way: The main control device receives the kernel log entry address, kernel log file size and preset command name input by the user based on the firmware mode to generate the kernel log reading command; Wherein, the kernel log reading command is sent based on the connection path.
3. The method according to claim 1, characterized in that The controlled device is pre-configured with a firmware code for implementing the kernel log reading command; The reading of the locally stored kernel log includes: Running the firmware code to read the kernel log entry address and the kernel log file size from the kernel log read command; Reading data from the kernel log entry address according to a preset size, and writing the read log data into a storage queue corresponding to the connection path until the target location is read; The space size between the target location and the kernel log entry address is the same as the kernel log file size.
4. The method according to claim 3, characterized in that The step of writing the read log data into a storage queue corresponding to the connection path includes: Writing the log data into a temporary variable; When the log data meets a preset writing condition, writing the log data into the storage queue; The step of sending the kernel log to the main control device based on the connection path includes: When the data in the storage queue meets a preset sending condition, the log data in the storage queue is sent to the main control device through the connection path.
5. The method according to claim 3 or 4, characterized in that: The master control device is connected to the controlled device via a serial port line; the storage queue is a serial port first-in first-out queue; The mode control instruction is sent by the master control device to the controlled device during the process of restarting the controlled device when the device failure occurs in the controlled device.
6. The method according to claims 2-4, characterized in that: The method further comprises: In response to the parameter acquisition instruction, acquiring a parameter value of a specified parameter from a specified system file; Determine the kernel log entry address based on the parameter value, and output the kernel log entry address; In response to the size acquisition instruction, an option value of a specified option is acquired from a specified configuration file; The kernel log file size is determined based on the option value, and the kernel log file size is output.
7. The method according to claim 3, characterized in that The kernel log includes a plurality of log data, and the method further includes: When the operating system kernel detects a specific event, generating a piece of log data; The log data is stored in a preset kernel log storage space; the starting address of the kernel log storage space is the kernel log entry address, and the space size of the kernel log storage space is the kernel log file size; The step of reading data from the kernel log entry address according to a preset size includes: Starting from the kernel log entry address, the log data of the preset size is read cyclically in sequence.
8. A kernel log processing device for a controlled device, characterized in that: The device comprises: A first response module, configured to enter a firmware mode in response to a mode control instruction sent by a connected master control device; the mode control instruction is triggered when a device failure occurs in the controlled device; A receiving module, used for receiving a kernel log reading command sent by the master control device; the kernel log reading command is a firmware command, used for controlling the controlled device to read and send kernel logs; The second response module is used to respond to the kernel log reading command, read the kernel log stored locally, and send the kernel log to the main control device based on the connection path for the main control device to save.
9. An electronic device, characterized in that: include: A processor, a memory, a communication interface and a communication bus, wherein the processor, the memory and the communication interface communicate with each other via the communication bus; The memory is used to store executable instructions, and the executable instructions enable the processor to execute the method according to any one of claims 1 to 7.
10. One or more machine-readable media, characterized in that Instructions are stored thereon, which, when executed by one or more processors, cause the processors to perform the method according to any one of claims 1 to 7.