Protocol switching method and device and electronic equipment

Through dynamic switching management protocols, the substrate management controller and server operating system select the best protocol based on task requirements and resource status, solving the lack of functions and reliability of IPMI and Redfish protocols, and achieving efficient and flexible management of server operating systems and hardware to meet the needs of modern complex application scenarios.

CN120390040APending Publication Date: 2025-07-29INSPUR SUZHOU INTELLIGENT TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510577789.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-05-06
Publication Date
2025-07-29

AI Technical Summary

Technical Problem

The existing IPMI and Redfish protocols have functional limitations, performance and reliability problems in server management, making it difficult to achieve efficient, flexible and reliable management of server operating systems and hardware, especially in modern complex application scenarios.

Method used

Based on task requirements, network status and hardware resources, the current scenario is dynamically determined and switched to the best management protocol, including MCTP over PCIe, IPMI over KCS, MCTP over LAN with RMCP+, etc., to ensure the efficiency and reliability of data processing.

Benefits of technology

It realizes efficient, flexible and reliable management of substrate management controllers and server operating systems in modern complex application scenarios, improves the performance and stability of data processing, and meets the needs of modern complex application scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120390040A_ABST
    Figure CN120390040A_ABST
Patent Text Reader

Abstract

The invention discloses a protocol switching method and device and electronic equipment, and relates to the technical field of data processing, and the method comprises the steps that a substrate management controller and a server operating system can determine whether protocol switching is carried out or not based on one or more of task requirements, network states and hardware resources, and the protocol switching efficiency is improved. Therefore, it can be guaranteed that the IPMI protocol and the Redfish protocol always use the optimal protocol for data processing, efficient, flexible and reliable management of a server operating system and hardware is achieved, the requirements of modern complex application scenes are met, and therefore the problem how to overcome the defects of the IPMI protocol and the Redfish protocol in the aspects of functions, performance and reliability can be solved, and the service life of the IPMI protocol and the Redfish protocol is prolonged. According to the technical scheme, efficient, flexible and reliable management of the server operating system and the hardware is achieved, the requirements of modern complex application scenes are met, and the technical effects that efficient, flexible and reliable management of the server operating system and the hardware can be achieved, and the requirements of the modern complex application scenes are met are achieved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of data processing technologies, and in particular, to a protocol switching method, apparatus, and electronic device. Background Art

[0002] Currently, in server management, the Intelligent Platform Management Interface (IPMI) protocol or the Redfish protocol is often used to implement the interaction between the Baseboard Management Controller (BMC) and the server operating system (OS). For example, some patents propose using these protocols for hardware health status monitoring, system crash repair, and dynamic power consumption optimization. However, these traditional hardware management protocols have obvious deficiencies. On the one hand, their functions are limited to basic hardware operations, lacking the management ability for applications and containers within the OS, and it is also difficult to achieve fine-grained control and function expansion. On the other hand, there are performance and reliability issues. Network dependence leads to high latency, and BMC failures are likely to cause management failures, and they occupy system resources and affect business performance.

[0003] How to overcome the defects of the IPMI and Redfish protocols in terms of function, performance, and reliability, and achieve efficient, flexible, and reliable management of the server operating system and hardware, meeting the requirements of modern complex application scenarios has become an urgent problem to be solved. Summary of the Invention

[0004] This application provides a protocol switching method, apparatus, and electronic device to at least solve the problem in the related art that how to overcome the defects of the IPMI and Redfish protocols in terms of function, performance, and reliability, and achieve efficient, flexible, and reliable management of the server operating system and hardware, meeting the requirements of modern complex application scenarios has become an urgent problem to be solved.

[0005] This application provides a protocol switching method, including: determining the current scenario based on one or more of task requirements, network status, and hardware resources; determining the target management protocol based on the current scenario; sending a switching request including the target management protocol to the peer end; where when the execution entity is the baseboard management controller, the peer end is the server operating system; when the execution entity is the server operating system, the peer end is the baseboard management controller; when receiving the response information sent by the peer end, switching from the current management protocol to the target management protocol; where the response information is used to indicate that the peer end supports the target management protocol and the peer end has switched to the target management protocol.

[0006] The present application also provides a protocol switching device, including: a processing module, configured to determine a current scenario based on one or more of task requirements, network status, and hardware resources; the processing module is further configured to determine a target management protocol based on the current scenario; the processing module is further configured to control a transceiver module to send a switching request including the target management protocol to the peer end; wherein, when the execution entity is a baseboard management controller, the peer end is a server operating system; when the execution entity is a server operating system, the peer end is a baseboard management controller; the processing module is further configured to switch from the current management protocol to the target management protocol when the transceiver module receives response information sent by the peer end; wherein, the response information is used to indicate that the peer end supports the target management protocol and the peer end has switched to the target management protocol.

[0007] The present application also provides an electronic device, including: a memory, configured to store a computer program; a processor, configured to implement the steps of any one of the above protocol switching methods when executing the computer program.

[0008] The present application also provides a computer-readable storage medium, in which a computer program is stored, wherein the computer program implements the steps of any one of the above protocol switching methods when executed by a processor.

[0009] The present application also provides a computer program product, including a computer program, which implements the steps of any one of the above protocol switching methods when executed by a processor.

[0010] With this application, by obtaining one or more of the task requirements, network status, and hardware resources, the current scenario can be determined based on one or more of the task requirements, network status, and hardware resources. Based on the current scenario, the target management protocol is determined. When the execution entity is the baseboard management controller, the peer end is the server operating system; when the execution entity is the server operating system, the peer end is the baseboard management controller. At this time, the execution entity can send a switching request containing the target management protocol to the peer end. When receiving the response information sent by the peer end, switch from the current management protocol to the target management protocol. Among them, the response information is used to indicate that the peer end supports the target management protocol and the peer end has switched to the target management protocol. In this way, both the baseboard management controller and the server operating system can determine whether to perform protocol switching based on one or more of the task requirements, network status, and hardware resources, so as to ensure that both always use the best protocol for data processing, realize the efficient, flexible, and reliable management of the server operating system and hardware, meet the requirements of modern complex application scenarios. Therefore, it can solve the technical problem of how to overcome the defects of the IPMI and Redfish protocols in terms of function, performance, and reliability, realize the efficient, flexible, and reliable management of the server operating system and hardware, and meet the requirements of modern complex application scenarios, and achieve the technical effect of being able to efficiently, flexibly, and reliably manage the server operating system and hardware and meet the requirements of modern complex application scenarios. BRIEF DESCRIPTION OF THE DRAWINGS

[0011] To more clearly illustrate the embodiments of the present application, the accompanying drawings required for use in the embodiments will be briefly introduced below. Obviously, the accompanying drawings in the following description are only some embodiments of the present application. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.

[0012] Figure 1 It is a network architecture diagram to which a protocol switching method provided by an embodiment of the present application is applied;

[0013] Figure 2 It is a flowchart of a protocol switching method provided by an embodiment of the present application;

[0014] Figure 3 It is another flowchart of a protocol switching method provided by an embodiment of the present application;

[0015] Figure 4 It is another flowchart of a protocol switching method provided by an embodiment of the present application;

[0016] Figure 5 It is another flowchart of a protocol switching method provided by an embodiment of the present application;

[0017] Figure 6Another flowchart of a protocol switching method provided by an embodiment of the present application;

[0018] Figure 7 Another flowchart of a protocol switching method provided by an embodiment of the present application;

[0019] Figure 8 Another flowchart of a protocol switching method provided by an embodiment of the present application;

[0020] Figure 9 Another flowchart of a protocol switching method provided by an embodiment of the present application;

[0021] Figure 10 A structural diagram of a protocol switching device provided by an embodiment of the present application. Detailed implementation manners

[0022] Next, the technical solutions in the embodiments of the present application will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present application.

[0023] It should be noted that in the description of the present application, the terms "include", "comprise" or any other variant thereof are intended to cover a non-exclusive inclusion, so that a process, method, article or device including a series of elements not only includes those elements but also includes other elements not explicitly listed, or further includes elements inherent to such process, method, article or device. The terms "first", "second", etc. in the present application are used to distinguish similar objects and are not used to describe a specific order or sequence.

[0024] MCTP over PCIe in the embodiments of the present disclosure is a technology that transports the Management Component Transport Protocol (MCTP) over the PCI Express bus.

[0025] IPMI over KCS in the embodiments of the present disclosure is a way to implement Intelligent Platform Management Interface (IPMI) communication through a Keyboard Controller Style (KCS) interface.

[0026] MCTP over LAN in the embodiments of the present disclosure is a technology that transports the Management Component Transport Protocol (MCTP) over a Local Area Network (LAN).

[0027] IPMI over I2C in the embodiments of the present disclosure is a method that passes through I 2The method of implementing Intelligent Platform Management Interface (IPMI) communication via the C bus.

[0028] MCTP over I2C in the embodiments of the present disclosure is a technology that implements the Management Component Transport Protocol (MCTP) on the I2C bus.

[0029] IPMI over LAN with RMCP+ in the embodiments of the present disclosure is a technology that implements Intelligent Platform Management Interface (IPMI) communication via a Local Area Network (LAN) using the Remote Management Control Protocol Plus (RMCP+).

[0030] MCTP over LAN with RMCP+ in the embodiments of the present disclosure is a technical solution that combines the Management Component Transport Protocol (MCTP), Local Area Network (LAN), and Remote Management Control Protocol Plus (RMCP+).

[0031] To enable those skilled in the art of this technology to better understand the solutions of this application, the following further elaborates on this application in conjunction with the accompanying drawings and specific implementation manners.

[0032] In combination with the specific application environment architecture or specific hardware architecture on which the execution of the protocol switching method depends, the specific application environment architecture or specific hardware architecture is described herein.

[0033] The protocol switching method provided by the embodiments of this application is applied to the network architecture as Figure 1 shown, including a Baseboard Management Controller 1 and a server 2 installed with a server operating system. The Baseboard Management Controller 1 includes a protocol stack management module 1-1, a task distribution module 1-2, a judgment module 1-3, and a processing result module 1-4. The server 2 includes a protocol stack management module 2-1, a task receiving module 2-2, and a task execution module 2-3.

[0034] When the execution entity of the protocol switching method of the present invention is the baseboard management controller 1, the protocol stack management module 1-1 obtains the task requirements, network status, hardware resources, and the current management protocol (such as the current management protocol 1); the protocol stack management module 1-1 sends the processing information including the task requirements, network status, hardware resources, and the current management protocol to the task distribution module 1-2; the judgment module 1-3 determines the current scenario based on one or more of the task requirements, network status, and hardware resources; the judgment module 1-3 determines the target management protocol based on the current scenario. At the same time, the protocol stack management module 1-1 sends a switching request including the target management protocol to the server 2 based on the target management protocol determined by the judgment module 1-3. After the protocol stack management module 2-1 of the server 2 receives the switching request sent by the baseboard management controller 1 and determines that it supports the target management protocol, it obtains the current management protocol of the server 2 (such as the current management protocol 2), switches the current management protocol 2 to the target management protocol, and sends a response message to the baseboard management controller 1 indicating that the server 2 supports the target management protocol and the peer has switched to the target management protocol. When the protocol stack management module 1-1 of the baseboard management controller 1 receives the response message sent by the server 2, it switches from the current management protocol to the target management protocol. At the same time, the protocol stack management module 1-1 controls the judgment module 1-3 to perform data interaction with the task receiving module 2-2 of the server 2 using the target management protocol. After that, the task receiving module 2-2 sends the interaction result of the data interaction to the baseboard management controller 1. The processing result module 1-4 of the baseboard management controller 1 generates corresponding processing result information based on the interaction result sent by the server 2.

[0035] When the execution entity of the protocol switching method of the present invention is Server 2, the protocol stack management module 2-1 obtains the task requirements, network status, hardware resources, and the current management protocol (such as the current management protocol 3); the protocol stack management module 2-1 determines the current scenario based on one or more of the task requirements, network status, and hardware resources; the protocol stack management module 2-1 determines the target management protocol based on the current scenario; the protocol stack management module 2-1 sends a switching request including the target management protocol to the peer end. After receiving the switching request sent by Server 2, when the protocol stack management module 1-1 of the baseboard management controller 1 determines that it supports the target management protocol, it obtains the current management protocol of the baseboard management controller 1 (such as the current management protocol 4), and switches the current management protocol 4 to the target management protocol, and sends a response message to Server 2 indicating that the baseboard management controller 1 supports the target management protocol and the peer end has switched to the target management protocol. After receiving the response message sent by the baseboard management controller 1, the protocol stack management module 2-1 of Server 2 controls the task receiving module to switch the current management protocol 3 to the target management protocol, and uses this target management protocol to interact with the judgment module 1-3 of the baseboard management controller 1. After that, the task receiving module 2-2 sends the interaction result of the data interaction to the baseboard management controller 1. The processing result module 1-4 of the baseboard management controller 1 generates corresponding processing result information based on the interaction result sent by Server 2.

[0036] In some examples, the protocol stack management modules in the OS and BMC are responsible for managing the loading, unloading, and switching of protocols.

[0037] In some examples, the protocol stack management module is a software component that runs in the OS and BMC and is responsible for managing the loading, unloading, and switching of multiple management protocols. The following are the key functions of the protocol stack management module:

[0038] (1) Protocol stack registration

[0039] · Function: Support the registration and initialization of multiple management protocols (such as MCTP, IPMI).

[0040] · Implementation:

[0041] · Implement a protocol stack registration table in the OS and BMC respectively to store the supported protocols and their statuses.

[0042] · Each protocol needs to provide an initialization function, an unloading function, and a communication interface.

[0043] (2) Protocol loading and unloading

[0044] · Function: Dynamically load or unload the protocol stack according to requirements.

[0045] · Implementation:

[0046] · Provide load_protocol() and unload_protocol() functions for loading and unloading specific protocols.

[0047] · When loading a protocol, call the protocol's initialization function; when unloading a protocol, call the protocol's unloading function.

[0048] (3) Protocol switching

[0049] · Function: Switch to the most suitable protocol according to the scenario requirements.

[0050] · Implementation:

[0051] · Provide a switch_protocol() function to switch to the target protocol.

[0052] · When switching protocols, unload the current protocol and load the target protocol.

[0053] (4) Protocol status management

[0054] · Function: Monitor the status of each protocol (such as whether it is loaded, whether it is available).

[0055] · Implementation:

[0056] · Maintain the status information of each protocol (such as LOADED, UNLOADED, ACTIVE) in the protocol stack registry.

[0057] An embodiment of the present application provides a protocol switching method, which is described in detail in combination with the execution process of the protocol switching method.

[0058] Embodiment 1

[0059] Figure 2 A flowchart of the protocol switching method is exemplarily shown. The execution subject of this example can be an electronic device, such as a baseboard management controller or a server operating system, as Figure 2 shown, the method includes:

[0060] S11. Determine the current scenario based on one or more of the task requirements, network status, and hardware resources.

[0061] In some examples, when the execution subject is a baseboard management controller, when the baseboard management controller receives a task requirement that needs to be executed by the server operating system, at this time, the baseboard management controller determines the current scenario based on this task requirement.

[0062] Alternatively, when the baseboard management controller determines that the network state has changed by obtaining the network state between the baseboard management controller and the server operating system, the baseboard management controller determines the current scenario based on the network state at this time.

[0063] Alternatively, when the baseboard management controller determines that the hardware resources have changed by obtaining the hardware resources of the baseboard management controller, the baseboard management controller determines the current scenario based on the hardware resources at this time.

[0064] In some examples, when it is the server operating system, when the server operating system receives a task requirement initiated by a non-baseboard management controller, it determines the current scenario based on the task requirement at this time.

[0065] Alternatively, when the server operating system determines that the network state has changed by obtaining the current network state of the server on which the server operating system is installed, the server operating system determines the current scenario based on the network state at this time.

[0066] Alternatively, when the server operating system determines that the hardware resources have changed by obtaining the hardware resources of the server on which the server operating system is installed, the baseboard management controller determines the current scenario based on the hardware resources at this time.

[0067] In some examples, when determining the current scenario based on one or more of the task requirement, network state, and hardware resources, one or more of the task requirement, network state, and hardware resources can be obtained first. Then, one or more of the task requirement, network state, and hardware resources are input into a scenario model for scenario recognition to determine the current scenario. Among them, the training process of the scenario model includes:

[0068] Obtain training sample data and the labeled results of the training sample data. Among them, the training sample data includes one or more of historical task requirements, network states, and hardware resources, and the labeled results include the historical scenarios corresponding to one or more of the historical task requirements, network states, and hardware resources.

[0069] Input the training sample data into a neural network model for learning to obtain the prediction results of the neural network model for the training sample data.

[0070] Based on the prediction results and the labeled results, adjust the network parameters of the neural network model until the neural network model converges to obtain the scenario model.

[0071] In some examples, the network state includes at least one network parameter, the hardware resources include the operating parameters of at least one hardware, the network parameters include any one of network bandwidth, latency, and network stability, and the operating parameters include any one of the central processor usage rate, memory usage rate, and overall machine power consumption.

[0072] In some examples, when determining the current scenario based on one or more of the task requirements, network status, and hardware resources, when a new task requirement is received, the current scenario is determined as a task scenario;

[0073] Alternatively, when it is determined that the network parameters in the current cycle are different from those in the previous cycle, the current scenario is determined as a network scenario;

[0074] Alternatively, when it is determined that the operating parameters in the current cycle are different from those in the previous cycle, the current scenario is determined as a hardware scenario;

[0075] In this way, the current scenario can be determined based on one or more of the task requirements, network status, and hardware resources.

[0076] S12. Determine the target management protocol based on the current scenario.

[0077] In some examples, for the protocol switching method provided by the embodiments of the present disclosure, the corresponding relationship between the current scenario and the target management protocol is predefined. In this way, after obtaining the current scenario, the corresponding relationship can be queried based on the current scenario stored in the memory to obtain the target management protocol.

[0078] In some examples, when the current scenario is a task scenario, obtain the task type of the new task requirement; wherein, the task type includes any one of high-bandwidth tasks (such as firmware update tasks), low-latency tasks (such as fault diagnosis tasks), high-security tasks (such as remote field management tasks), and resource-constrained tasks; determine the target management protocol based on the task type; wherein, the target management protocol includes: a standardized communication protocol based on the peripheral component interconnect express bus (MCTP over PCIe) and an out-of-band management communication method based on the intelligent platform management interface protocol (IPMI over KCS), a management component transport protocol based on the local area network and the remote management control protocol upgraded version (MCTP over LAN with RMCP+), and an intelligent platform management interface based on the local area network and the remote management control protocol upgraded version (IPMI over LAN with RMCP+) any one of them;

[0079] For example, when the required bandwidth in the newly added task requirement is greater than the preset bandwidth, it is determined that the task type of the newly added task requirement is a high-bandwidth task. At this time, it is necessary to switch the current management protocol to MCTP over PCIe. Thus, for high-bandwidth tasks such as firmware updates and bulk log transmissions, it automatically switches to MCTP over PCIe, and the theoretical bandwidth is increased from 100 Mbps of IPMI to more than 5 Gbps, and the transmission time is reduced by 5 to 10 times. For example, the 10 GB firmware update is shortened from 15 minutes to 2 minutes, improving the user experience. At the same time, due to the streamlined message structure of the MCTP protocol, the protocol parsing overhead can be reduced. In high-load scenarios such as firmware updates, the CPU utilization rate is reduced from 75% of IPMI to 45% - 55%.

[0080] Alternatively, when the required latency in the newly added task requirement is less than the preset latency, it is determined that the task type of the newly added task requirement is a low-latency task. At this time, it is necessary to switch the current management protocol to IPMI over KCS. Thus, in low-latency tasks with high real-time requirements such as fault diagnosis and sensor polling, the 1 ms-level low-latency feature of IPMI over KCS is retained, and high-bandwidth tasks are prevented from preempting the channel through priority scheduling, improving the user experience.

[0081] Alternatively, when the security level in the newly added task requirement is greater than the preset level, it is determined that the task type of the newly added task requirement is a high-security task. At this time, it is necessary to switch the current management protocol to MCTP over LAN with RMCP+ or IPMI over LAN with RMCP+ that supports encryption.

[0082] Alternatively, when the required resources in the newly added task requirement are greater than the current resources, it is determined that the task type of the newly added task requirement is a resource-constrained task. At this time, it is necessary to switch the current management protocol to the low-power protocol MCTP over I2C. In this way, it automatically degrades to MCTP over I2C (power consumption < 100 mW) in resource-constrained devices, and enables MCTP over PCIe in high-performance servers, achieving intelligent matching of hardware interfaces.

[0083] In some examples, when the current scenario is a network scenario, obtain the change parameters that are different between the current cycle and the previous cycle; where the change parameters include any network parameter; based on the size relationship between the pre-configured parameter threshold and the change parameters, determine the first comparison result; based on the first comparison result, determine the target management protocol; where the target management protocol includes: any one of the Management Component Transport Protocol over LAN (MCTP over LAN) and the Out-of-Band Management Communication Method based on the Intelligent Platform Management Interface Protocol (IPMI over KCS); for example, when the network parameter is network bandwidth, if the network bandwidth occupied in the current cycle is greater than the bandwidth threshold, at this time, it is necessary to switch the current management protocol to MCTP over LAN. Or, if the network bandwidth occupied in the current cycle is less than or equal to the bandwidth threshold, at this time, it is necessary to switch the current management protocol to IPMI over KCS.

[0084] In some examples, when the current scenario is a hardware scenario, obtain the target parameters that are different between the current cycle and the previous cycle; where the target parameters include any operating parameter; based on the size relationship between the pre-configured operating threshold and the target parameters, determine the second comparison result; based on the second comparison result, determine the target management protocol; where the target management protocol includes: the Standardized Communication Protocol based on the Peripheral Component Interconnect Express Bus (MCTP over PCIe) and the Intelligent Platform Management Interface based on the Inter-Integrated Circuit Bus (IPMI over I2C); for example, when the operating parameter is the usage rate of the central processing unit, if the usage rate is less than or equal to the usage threshold, it means that the resources are sufficient, and at this time, it is necessary to switch the current management protocol to MCTP over PCIe; if the usage rate is greater than the usage threshold, it means that the resources are limited, and at this time, it is necessary to switch the current management protocol to IPMI over I2C; or, when the operating parameters include the usage rate of the central processing unit and the occupancy rate of the memory, if the usage rate is less than or equal to the usage threshold and the occupancy rate is less than or equal to the occupancy threshold, it means that the resources are sufficient, and at this time, it is necessary to switch the current management protocol to MCTP over PCIe; when the usage rate is greater than the usage threshold, and / or the occupancy rate is greater than the occupancy threshold, it means that the resources are limited, and at this time, it is necessary to switch the current management protocol to IPMI over I2C.

[0085] In addition, when there are multiple scenarios in the current scenario, such as multiple of the task scenario, the network scenario, and the hardware scenario, obtain the switching priorities corresponding to the task scenario, the network scenario, and the hardware scenario respectively; based on the scenario corresponding to the highest switching priority, determine the target management protocol.

[0086] S13. Send a switching request containing the target management protocol to the peer end. Where, when the execution entity is the Baseboard Management Controller, the peer end is the server operating system; when the execution entity is the server operating system, the peer end is the Baseboard Management Controller.

[0087] S14. When receiving the response information sent by the peer, switch from the current management protocol to the target management protocol. The response information is used to indicate that the peer supports the target management protocol and the peer has switched to the target management protocol.

[0088] As can be seen from the above, the protocol switching method provided by the embodiments of the present disclosure obtains one or more of the task requirements, network status, and hardware resources, and thus can determine the current scenario based on one or more of the task requirements, network status, and hardware resources; based on the current scenario, determine the target management protocol; when the execution entity is the baseboard management controller, the peer is the server operating system; when the execution entity is the server operating system, the peer is the baseboard management controller; at this time, the execution entity can send a switching request including the target management protocol to the peer; when receiving the response information sent by the peer, switch from the current management protocol to the target management protocol; the response information is used to indicate that the peer supports the target management protocol and the peer has switched to the target management protocol. In this way, both the baseboard management controller and the server operating system can determine whether to perform protocol switching based on one or more of the task requirements, network status, and hardware resources, so as to ensure that both always use the best protocol for data processing, realize efficient, flexible, and reliable management of the server operating system and hardware, and meet the requirements of modern complex application scenarios.

[0089] In some implementable examples, in combination with Figure 2 , such as Figure 3 shown, the above S11 can be specifically implemented by the following S110.

[0090] S110. When receiving the newly added task requirements, determine that the current scenario is a task scenario.

[0091] As described above, the protocol switching method provided by the embodiments of the present disclosure obtains one or more of task requirements, network status, and hardware resources, and thus can determine the current scenario based on one or more of task requirements, network status, and hardware resources. For example, when a new task requirement is received, the current scenario is determined to be a task scenario. Based on the current scenario, the target management protocol is determined. When the execution entity is the baseboard management controller, the peer end is the server operating system. When the execution entity is the server operating system, the peer end is the baseboard management controller. At this time, the execution entity can send a switching request including the target management protocol to the peer end. When the response information sent by the peer end is received, switch from the current management protocol to the target management protocol. The response information is used to indicate that the peer end supports the target management protocol and the peer end has switched to the target management protocol. In this way, both the baseboard management controller and the server operating system can determine whether to perform protocol switching based on one or more of task requirements, network status, and hardware resources, so as to ensure that both always use the best protocol for data processing, realize efficient, flexible, and reliable management of the server operating system and hardware, and meet the requirements of modern complex application scenarios.

[0092] In some implementable examples, the network status includes at least one network parameter; combined with Figure 2 , such as Figure 4 shown, the above S11 can be specifically implemented by the following S111.

[0093] S111. When it is determined that the network parameters in the current cycle are different from those in the previous cycle, determine that the current scenario is a network scenario.

[0094] As described above, the protocol switching method provided by the embodiments of the present disclosure obtains one or more of task requirements, network status, and hardware resources, and thus can determine the current scenario based on one or more of task requirements, network status, and hardware resources. For example, when it is determined that the network parameters in the current cycle are different from those in the previous cycle, determine that the current scenario is a network scenario. Based on the current scenario, the target management protocol is determined. When the execution entity is the baseboard management controller, the peer end is the server operating system. When the execution entity is the server operating system, the peer end is the baseboard management controller. At this time, the execution entity can send a switching request including the target management protocol to the peer end. When the response information sent by the peer end is received, switch from the current management protocol to the target management protocol. The response information is used to indicate that the peer end supports the target management protocol and the peer end has switched to the target management protocol. In this way, both the baseboard management controller and the server operating system can determine whether to perform protocol switching based on one or more of task requirements, network status, and hardware resources, so as to ensure that both always use the best protocol for data processing, realize efficient, flexible, and reliable management of the server operating system and hardware, and meet the requirements of modern complex application scenarios.

[0095] In some feasible examples, the hardware resources include the operating parameters of at least one piece of hardware; in combination with Figure 2 , such as Figure 5 shown, the above S11 can be specifically implemented by the following S112.

[0096] S112. When it is determined that the operating parameters in the current cycle are different from those in the previous cycle, determine that the current scenario is a hardware scenario.

[0097] As can be seen from the above, the protocol switching method provided by the embodiments of the present disclosure obtains one or more of the task requirements, network status, and hardware resources, and thus can determine the current scenario based on one or more of the task requirements, network status, and hardware resources; for example: when it is determined that the operating parameters in the current cycle are different from those in the previous cycle, determine that the current scenario is a hardware scenario; based on the current scenario, determine the target management protocol; when the execution entity is the baseboard management controller, the peer end is the server operating system; when the execution entity is the server operating system, the peer end is the baseboard management controller; at this time, the execution entity can send a switching request including the target management protocol to the peer end; when receiving the response information sent by the peer end, switch from the current management protocol to the target management protocol; where the response information is used to indicate that the peer end supports the target management protocol and the peer end has switched to the target management protocol. In this way, both the baseboard management controller and the server operating system can determine whether to perform protocol switching based on one or more of the task requirements, network status, and hardware resources, so as to ensure that both always use the best protocol for data processing, realize the efficient, flexible, and reliable management of the server operating system and hardware, and meet the requirements of modern complex application scenarios.

[0098] In some feasible examples, in combination with Figure 2 , such as Figure 6 shown, the above S12 can be specifically implemented by the following S120 and S121.

[0099] S120. When the current scenario is a task scenario, obtain the task type of the newly added task requirement; where the task type includes any one of high-bandwidth tasks, low-latency tasks, high-security tasks, and resource-constrained tasks;

[0100] S121. Based on the task type, determine the target management protocol; where the target management protocol includes: any one of the standardized communication protocol based on the peripheral component interconnect express bus, the out-of-band management communication method based on the intelligent platform management interface protocol, the management component transfer protocol based on the local area network and the upgraded remote management control protocol, and the intelligent platform management interface based on the local area network and the upgraded remote management control protocol.

[0101] As can be seen from the above, the protocol switching method provided by the embodiments of the present disclosure obtains one or more of task requirements, network status, and hardware resources, and thus can determine the current scenario based on one or more of task requirements, network status, and hardware resources; when the current scenario is a task scenario, obtain the task type of the newly added task requirement; based on the task type, determine the target management protocol; when the execution entity is the baseboard management controller, the peer end is the server operating system; when the execution entity is the server operating system, the peer end is the baseboard management controller; at this time, the execution entity can send a switching request including the target management protocol to the peer end; when receiving the response information sent by the peer end, switch from the current management protocol to the target management protocol; wherein, the response information is used to indicate that the peer end supports the target management protocol and the peer end has switched to the target management protocol. In this way, both the baseboard management controller and the server operating system can determine whether to perform protocol switching based on one or more of task requirements, network status, and hardware resources, so as to ensure that both always use the best protocol for data processing, realizing efficient, flexible, and reliable management of the server operating system and hardware, and meeting the requirements of modern complex application scenarios.

[0102] In some feasible examples, the network status includes at least one network parameter; combined with Figure 2 , such as Figure 7 shown, the above S12 can be specifically implemented through the following S122 - S124.

[0103] S122. When the current scenario is a network scenario, obtain the change parameter that is different between the current period and the previous period; wherein, the change parameter includes any network parameter;

[0104] S123. Based on the size relationship between the pre - configured parameter threshold and the change parameter, determine the first comparison result;

[0105] S124. Based on the first comparison result, determine the target management protocol; wherein, the target management protocol includes any one of the management component transfer protocol based on the local area network and the out - of - band management communication method based on the intelligent platform management interface protocol.

[0106] As can be seen from the above, the protocol switching method provided by the embodiments of the present disclosure obtains one or more of task requirements, network status, and hardware resources, and thus can determine the current scenario based on one or more of task requirements, network status, and hardware resources; when the current scenario is a network scenario, obtain the change parameters that are different between the current cycle and the previous cycle; determine the first comparison result based on the size relationship between the pre-configured parameter threshold and the change parameters; determine the target management protocol based on the first comparison result; determine the target management protocol based on the task type; when the execution entity is the baseboard management controller, the peer end is the server operating system; when the execution entity is the server operating system, the peer end is the baseboard management controller; at this time, the execution entity can send a switching request including the target management protocol to the peer end; when receiving the response information sent by the peer end, switch from the current management protocol to the target management protocol; wherein, the response information is used to indicate that the peer end supports the target management protocol and the peer end has switched to the target management protocol. In this way, both the baseboard management controller and the server operating system can determine whether to perform protocol switching based on one or more of task requirements, network status, and hardware resources, so as to ensure that both always use the best protocol for data processing, realizing efficient, flexible, and reliable management of the server operating system and hardware, and meeting the requirements of modern complex application scenarios.

[0107] In some feasible examples, the hardware resources include the operating parameters of at least one hardware; combined Figure 2 , such as Figure 8 shown, the above S12 can be specifically implemented through the following S125-S127.

[0108] S125. When the current scenario is a hardware scenario, obtain the target parameters that are different between the current cycle and the previous cycle; wherein, the target parameters include any one of the operating parameters;

[0109] S126. Determine the second comparison result based on the size relationship between the pre-configured operating threshold and the target parameters.

[0110] S127. Determine the target management protocol based on the second comparison result; wherein, the target management protocol includes: the standardized communication protocol based on the peripheral component interconnect express bus and the intelligent platform management interface based on the inter-integrated circuit bus.

[0111] As described above, the protocol switching method provided by the embodiments of the present disclosure obtains one or more of task requirements, network status, and hardware resources, and thus can determine the current scenario based on one or more of task requirements, network status, and hardware resources; when the current scenario is a hardware scenario, obtain target parameters that are different between the current cycle and the previous cycle; determine a second comparison result based on the size relationship between a pre-configured operation threshold and the target parameters; determine a target management protocol based on the second comparison result; determine a target management protocol based on the task type; when the execution entity is a baseboard management controller, the peer end is the server operating system; when the execution entity is the server operating system, the peer end is the baseboard management controller; at this time, the execution entity can send a switching request including the target management protocol to the peer end; when receiving the response information sent by the peer end, switch from the current management protocol to the target management protocol; where the response information is used to indicate that the peer end supports the target management protocol and the peer end has switched to the target management protocol. In this way, both the baseboard management controller and the server operating system can determine whether to perform protocol switching based on one or more of task requirements, network status, and hardware resources, so as to ensure that both always use the best protocol for data processing, realizing efficient, flexible, and reliable management of the server operating system and hardware, and meeting the requirements of modern complex application scenarios.

[0112] In some feasible examples, in combination with Figure 2 , such as Figure 9 shown, the above S12 can be specifically implemented by the following S128 and S129.

[0113] S128. When the current scenario includes multiple of a task scenario, a network scenario, and a hardware scenario, obtain the switching priorities corresponding to the task scenario, the network scenario, and the hardware scenario respectively;

[0114] S129. Determine the target management protocol based on the scenario corresponding to the highest switching priority.

[0115] In some examples, when the current scenario includes multiple of a task scenario, a network scenario, and a hardware scenario, the first network status and the first hardware resources of the server on which the server operating system is installed, as well as the second network status and the second hardware resources of the baseboard management controller, can be obtained. Then, the first network status, the first hardware resources, the second network status, the second hardware resources, and the current scenario are input into a protocol model for protocol selection to obtain a theoretical management protocol. Then, the theoretical management protocol is used as the target associated protocol. The training process of the protocol model includes:

[0116] Obtain training data and validation data; wherein, both the training data and the validation data include the historical network status and historical hardware resources of both the baseboard management controller and the server installed with the server operating system, and the theoretical management protocol corresponding to both the historical network status and historical hardware resources.

[0117] Input the training data into the neural network model for learning to obtain a pre-trained network model.

[0118] Input the validation data into the pre-trained network model for validation to obtain the distribution probabilities of the historical network status and historical hardware resources in the validation data for each predicted management protocol.

[0119] In the case where the predicted management protocol corresponding to the maximum separation probability is different from the theoretical management protocol, adjust the network parameters of the pre-trained network model, and return to input the training data into the pre-trained network model until the predicted management protocol corresponding to the maximum separation probability is the same as the theoretical management protocol for N consecutive times. At this time, it is considered that the pre-trained network model converges to obtain a protocol model. Here, N is an integer greater than or equal to 1.

[0120] As can be seen from the above, the protocol switching method provided by the embodiments of the present disclosure obtains one or more of the task requirements, network status, and hardware resources, and thus can determine the current scenario based on one or more of the task requirements, network status, and hardware resources; when the current scenario includes multiple of the task scenario, network scenario, and hardware scenario, obtain the switching priorities corresponding to the task scenario, network scenario, and hardware scenario respectively; determine the target management protocol based on the scenario corresponding to the highest switching priority; determine the target management protocol based on the task type; when the execution entity is the baseboard management controller, the peer end is the server operating system; when the execution entity is the server operating system, the peer end is the baseboard management controller; at this time, the execution entity can send a switching request including the target management protocol to the peer end; when receiving the response information sent by the peer end, switch from the current management protocol to the target management protocol; wherein, the response information is used to indicate that the peer end supports the target management protocol and the peer end has switched to the target management protocol. In this way, both the baseboard management controller and the server operating system can determine whether to perform protocol switching based on one or more of the task requirements, network status, and hardware resources, so as to ensure that both always use the best protocol for data processing, realizing efficient, flexible, and reliable management of the server operating system and hardware, and meeting the requirements of modern complex application scenarios.

[0121] Through the description of the above embodiments, those skilled in the art can clearly understand that the method according to the above embodiments can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware, but in many cases, the former is a better implementation method.

[0122] An embodiment of the present application further provides a protocol switching device, as Figure 10 shown, including a processing module 101 and a transceiver module 102. Among them,

[0123] The processing module 101 is used to determine the current scenario based on one or more of task requirements, network status, and hardware resources;

[0124] The processing module 101 is further used to determine the target management protocol based on the current scenario;

[0125] The processing module 101 is further used to control the transceiver module 102 to send a switching request including the target management protocol to the peer end; among them, when the execution entity is the baseboard management controller, the peer end is the server operating system; when the execution entity is the server operating system, the peer end is the baseboard management controller;

[0126] The processing module 101 is further used to switch from the current management protocol to the target management protocol when the transceiver module 102 receives the response information sent by the peer end; among them, the response information is used to indicate that the peer end supports the target management protocol and the peer end has switched to the target management protocol.

[0127] In some implementable examples, the processing module 101 is specifically used to determine that the current scenario is a task scenario when the transceiver module 102 receives a new task requirement.

[0128] In some implementable examples, the network status includes at least one network parameter; the processing module 101 is specifically used to determine that the current scenario is a network scenario when it is determined that the network parameters in the current period are different from those in the previous period.

[0129] In some implementable examples, the hardware resources include the operating parameters of at least one hardware; the processing module 101 is specifically used to determine that the current scenario is a hardware scenario when it is determined that the operating parameters in the current period are different from those in the previous period.

[0130] In some implementable examples, the processing module 101 is specifically used to obtain the task type of the new task requirement when the current scenario is a task scenario; among them, the task type includes any one of high-bandwidth tasks, low-latency tasks, high-security tasks, and resource-constrained tasks; the processing module 101 is specifically used to determine the target management protocol based on the task type; among them, the target management protocol includes: any one of a standardized communication protocol based on the peripheral component interconnect express bus, an out-of-band management communication method based on the intelligent platform management interface protocol, a management component transport protocol based on the local area network and the remote management control protocol upgraded version, and an intelligent platform management interface based on the local area network and the remote management control protocol upgraded version.

[0131] In some implementable examples, the network status includes at least one network parameter; the processing module 101 is specifically configured to obtain a change parameter that is different between the current cycle and the previous cycle when the current scenario is a network scenario; wherein, the change parameter includes any network parameter; the processing module 101 is specifically configured to determine a first comparison result based on the size relationship between a pre-configured parameter threshold and the change parameter; the processing module 101 is specifically configured to determine a target management protocol based on the first comparison result; wherein, the target management protocol includes any one of a management component transfer protocol based on a local area network and an out-of-band management communication method based on an intelligent platform management interface protocol.

[0132] In some implementable examples, the hardware resources include operating parameters of at least one hardware; the processing module 101 is specifically configured to obtain a target parameter that is different between the current cycle and the previous cycle when the current scenario is a hardware scenario; wherein, the target parameter includes any operating parameter; the processing module 101 is specifically configured to determine a second comparison result based on the size relationship between a pre-configured operating threshold and the target parameter; the processing module 101 is specifically configured to determine a target management protocol based on the second comparison result; wherein, the target management protocol includes a standardized communication protocol based on a peripheral component interconnect high-speed expansion bus and an intelligent platform management interface based on an inter-integrated circuit bus.

[0133] In some implementable examples, the processing module 101 is specifically configured to obtain switching priorities corresponding to a task scenario, a network scenario, and a hardware scenario respectively when the current scenario includes multiple ones of a task scenario, a network scenario, and a hardware scenario; the processing module 101 is specifically configured to determine a target management protocol based on the scenario corresponding to the highest switching priority; for the description of the features in the corresponding embodiments of the protocol switching device, reference may be made to the relevant description of the corresponding embodiments of the protocol switching method, which will not be elaborated here one by one.

[0134] An embodiment of the present application further provides an electronic device, including a memory and a processor. A computer program is stored in the memory, and the processor is configured to run the computer program to execute the steps in any one of the above embodiments of the protocol switching method.

[0135] An embodiment of the present application further provides a computer-readable storage medium, in which a computer program is stored. The computer program is configured to execute the steps in any one of the above embodiments of the protocol switching method when running.

[0136] In an exemplary embodiment, the computer-readable storage medium may include, but is not limited to, various media capable of storing computer programs, such as USB flash drives, read-only memory (ROM), random access memory (RAM), mobile hard disks, magnetic disks, or optical discs.

[0137] The embodiments of the present application also provide a computer program product. The computer program product includes a computer program, and when the computer program is executed by a processor, it implements the steps in any of the above-described protocol switching method embodiments.

[0138] The embodiments of the present application also provide another computer program product, including a non-volatile computer-readable storage medium. The non-volatile computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, it implements the steps in any of the above-described protocol switching method embodiments.

[0139] Those skilled in the art can further realize that the units and algorithm steps of each example described in combination with the embodiments disclosed herein can be implemented by electronic hardware, computer software, or a combination of the two. To clearly illustrate the interchangeability of hardware and software, the components and steps of each example have been generally described according to their functions in the above description. Whether these functions are executed in a hardware or software manner depends on the specific application and design constraints of the technical solution. Skilled professionals can use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of the present application.

[0140] The above provides a detailed introduction to a protocol switching method provided by the present application. Specific examples are used herein to elaborate on the principle and implementation manner of the present application. The description of the above embodiments is only used to help understand the method and its core idea of the present application. It should be noted that for those of ordinary skill in the art in the technical field, without departing from the principle of the present application, several improvements and modifications can be made to the present application, and these improvements and modifications also fall within the protection scope of the claims of the present application.

Claims

1. A protocol switching method, characterized in that Including: Determine the current scenario based on one or more of task requirements, network status, and hardware resources; Determine the target management protocol based on the current scenario; Send a handover request including the target management protocol to the peer; when the execution entity is the baseboard management controller, the peer is the server operating system; when the execution entity is the server operating system, the peer is the baseboard management controller; When receiving the response information sent by the peer, switch from the current management protocol to the target management protocol; where the response information is used to indicate that the peer supports the target management protocol and the peer has switched to the target management protocol.

2. The protocol switching method according to claim 1, wherein The determining based on one or more of task requirements, network status, and hardware resources includes: When receiving a newly added task requirement, determine that the current scenario is a task scenario.

3. The protocol switching method according to claim 1, characterized in that The network status includes at least one network parameter; The determining based on one or more of task requirements, network status, and hardware resources includes: When determining that the network parameter in the current cycle is different from the network parameter in the previous cycle, determine that the current scenario is a network scenario.

4. The protocol switching method according to claim 1, wherein The hardware resources include the operating parameters of at least one hardware; The determining based on one or more of task requirements, network status, and hardware resources includes: When determining that the operating parameter in the current cycle is different from the operating parameter in the previous cycle, determine that the current scenario is a hardware scenario.

5. The protocol switching method according to claim 1, characterized in that, The determining the target management protocol based on the current scenario includes: When the current scenario is a task scenario, obtain the task type of the newly added task requirement; where the task type includes any one of high-bandwidth tasks, low-latency tasks, high-security tasks, and resource-constrained tasks; Determine the target management protocol based on the task type; where the target management protocol includes any one of a standardized communication protocol based on the Peripheral Component Interconnect Express bus, an out-of-band management communication method based on the Intelligent Platform Management Interface protocol, a management component transport protocol based on the Local Area Network and Remote Management Control Protocol Enhanced Edition, and an Intelligent Platform Management Interface based on the Local Area Network and Remote Management Control Protocol Enhanced Edition.

6. The protocol switching method according to claim 1, characterized in that The network status includes at least one network parameter; The determining the target management protocol based on the current scenario includes: When the current scenario is a network scenario, obtain the change parameter that is different between the current cycle and the previous cycle; where the change parameter includes any one of the network parameters; Determine the first comparison result based on the pre-configured parameter threshold and the magnitude relationship of the change parameter; Determine the target management protocol based on the first comparison result; where the target management protocol includes any one of a management component transport protocol based on the Local Area Network and an out-of-band management communication method based on the Intelligent Platform Management Interface protocol.

7. The protocol switching method according to claim 1, characterized in that The hardware resources include the operating parameters of at least one hardware; The determining the target management protocol based on the current scenario includes: When the current scenario is a hardware scenario, obtain the target parameter that is different between the current cycle and the previous cycle; where the target parameter includes any one of the operating parameters; Determine a second comparison result based on a pre-configured operating threshold and the magnitude relationship of the target parameter; Determine a target management protocol based on the second comparison result; wherein, the target management protocol includes: a standardized communication protocol based on the Peripheral Component Interconnect Express (PCIe) bus and an Intelligent Platform Management Interface (IPMI) based on the Inter-Integrated Circuit (I2C) bus.

8. The protocol switching method according to claim 1, characterized in that The determining of the target management protocol based on the current scenario includes: When the current scenario includes multiple of a task scenario, a network scenario, and a hardware scenario, obtain the switching priorities corresponding to the task scenario, the network scenario, and the hardware scenario respectively; Determine the target management protocol based on the scenario corresponding to the highest switching priority.

9. A protocol switching device, characterized in that, Include: A processing module, configured to determine the current scenario based on one or more of task requirements, network status, and hardware resources; The processing module is further configured to determine the target management protocol based on the current scenario; The processing module is further configured to control a transceiver module to send a switching request including the target management protocol to the peer end; wherein, when the execution entity is a Baseboard Management Controller (BMC), the peer end is a server operating system; when the execution entity is a server operating system, the peer end is a Baseboard Management Controller (BMC); The processing module is further configured to, when the transceiver module receives response information sent by the peer end, switch from the current management protocol to the target management protocol; wherein, the response information is used to indicate that the peer end supports the target management protocol and the peer end has switched to the target management protocol.

10. An electronic device, characterized in that, Include: A memory, configured to store a computer program; A processor, configured to implement the steps of the protocol switching method according to any one of claims 1 to 8 when executing the computer program.