Server startup control method and device, storage medium and electronic device

By recording and accessing bus devices that are allowed to be started in accordance with the network protocol in the server, and detecting and generating startup items, the problem of low server startup control efficiency is solved, and a fast and automatic startup process is realized, reducing maintenance difficulty and manpower and material consumption.

CN118642763BActive Publication Date: 2024-12-03INSPUR SUZHOU INTELLIGENT TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411116127.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-08-14
Publication Date
2024-12-03
Estimated Expiration
2044-08-14

AI Technical Summary

Technical Problem

The server startup control efficiency is low. In the prior art, PXE startup through hardware modification or customized BIOS versions, etc., there are problems such as wasting manpower and material resources and difficult maintenance.

Method used

Record the reference bus device that allows the operating system to be started in the server's startup system and access the device without starting it, detect and generate startup items that comply with the target network protocol, and use these startup items to start the operating system.

Benefits of technology

It improves the server startup control efficiency, reduces manpower and material investment, simplifies the use and maintenance of network card functions, and realizes rapid start-up and automatic adaptation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118642763B_ABST
    Figure CN118642763B_ABST
Patent Text Reader

Abstract

The embodiment of the present application provides a method and device for starting up a server, a storage medium and an electronic device, wherein the method comprises: when the server startup process is controlled to run to the startup stage of the operating system, accessing the target storage location to obtain a reference bus device; detecting the target bus device connected to the server from the reference bus device; when the target bus device is detected from the reference bus device, generating a startup item that complies with the target network protocol corresponding to the target bus device; and starting the operating system using the startup item. Through the present application, the problem of low startup control efficiency of the server is solved, thereby achieving the effect of improving the startup control efficiency of the server.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present application relate to the field of computers, and in particular, to a method and device for controlling startup of a server, a storage medium, and an electronic device. Background Art

[0002] PXE (Preboot Execution Environment) is a network boot technology that allows users to boot computers from the network without using local storage (such as hard disk). PXE uses a special network protocol called Preboot Execution Protocol (PXE), which allows client machines to obtain the required boot files from the network. PXE supports multiple operating systems. Its main application scenarios include automatic system installation, system maintenance, system disaster recovery, system remote update, virtualization deployment, network boot, etc. It has obvious advantages in various application scenarios, including reducing installation time, saving maintenance costs, security, reliability, timely updates to improve update efficiency, reducing deployment time, improving deployment efficiency, improving system startup efficiency, etc., and is widely used on servers.

[0003] In the related art, when a customer specifies to use a network card to perform PXE boot on the server's operating system, they can only do so by modifying the hardware, customizing the BIOS version, or disabling the PXE function of other network cards. It is understandable that this causes a serious waste of manpower and material resources, and increases the difficulty of subsequent maintenance or version upgrades. Summary of the invention

[0004] The embodiments of the present application provide a method and device for starting up a server, a storage medium, and an electronic device, so as to at least solve the problem of low efficiency of starting up a server in the related art.

[0005] According to an embodiment of the present application, a server startup control method is provided, which is applied to a startup system of the server, wherein a reference bus device that allows the operating system of the server to be started according to a target network protocol is recorded at a target storage location in the server, and the target storage location is set to allow the startup system to access it when the server is not started. The method comprises: when controlling the startup process of the server to run to the startup stage of the operating system, accessing the target storage location to obtain the reference bus device; detecting the target bus device connected to the server from the reference bus device; when the target bus device is detected from the reference bus device, generating a startup item that corresponds to the target bus device and complies with the target network protocol; and using the startup item to start the operating system.

[0006] In an exemplary embodiment, the target storage location is deployed on the baseboard management controller of the server, and the accessing the target storage location to obtain the reference bus device includes: generating and initiating a target access request to the baseboard management controller, wherein the target access request is used to request access to the target storage location to obtain the reference bus device, and the baseboard management controller is configured to respond to the received access request and read the data stored in the storage location on the baseboard management controller; and receiving the reference bus device returned by the baseboard management controller in response to the received target access request.

[0007] In an exemplary embodiment, the target storage location is deployed on a baseboard management controller of the server, and before accessing the target storage location to obtain the reference bus device, the method includes: receiving a target adjustment request, wherein the target adjustment request is used to request that the reference bus device recorded on the target storage location be adjusted to a first candidate bus device; in response to the target adjustment request, detecting an adjustment bus device between the reference bus device and the first candidate bus device; and adjusting the reference bus device recorded on the target storage location to the first candidate bus device according to the adjustment bus device.

[0008] In an exemplary embodiment, adjusting the reference bus device recorded at the target storage location to the first candidate bus device according to the adjustment bus device includes: deleting the adjustment bus device from the reference bus device recorded at the target storage location to obtain the first candidate bus device; and / or recording the adjustment bus device in the reference bus device stored at the target storage location to obtain the first candidate bus device.

[0009] In an exemplary embodiment, the target storage location records first bus device information corresponding to the reference bus device, and detecting the target bus device connected to the server from the reference bus device includes: searching for second bus device information of the target bus device from the first bus device information; and determining that the target bus device is detected from the reference bus device when the second bus device information is found from the first bus device information.

[0010] In an exemplary embodiment, searching for the second bus device information of the target bus device from the first bus device information includes: when the first bus device information includes N bus device information, searching for the second bus device information from the N bus device information by performing the following steps, wherein N is a positive integer greater than or equal to 1: extracting an i-th group of bus device attributes carried in an i-th bus device information among the N bus device information, and extracting the target bus device attributes of the target bus device carried in the second bus device information, wherein the i-th bus device information is the bus device information corresponding to the i-th bus device among the N bus devices, the reference bus device includes the N bus devices, and i is a positive integer less than or equal to N; comparing whether the i-th group of bus device attributes is consistent with the target bus device attributes to obtain a first comparison result.

[0011] In an exemplary embodiment, after the comparison of whether the i-th group of bus device attributes is consistent with the target bus device attributes to obtain a first comparison result, the method further includes: extracting the i+1-th group of bus device attributes carried in the i+1-th bus device information among the N bus device information, when the first comparison result is used to indicate that there are bus device attributes in the i-th group of bus device attributes that are inconsistent with the target bus device attributes, wherein the i+1-th bus device information is the bus device information corresponding to the i+1-th bus device among the N bus devices, and i+1 is a positive integer less than or equal to N; and comparing whether the i+1-th group of bus device attributes is consistent with the target bus device attributes to obtain a second comparison result.

[0012] In an exemplary embodiment, a generation component is deployed in the startup system, and when the target bus device is detected from the reference bus device, the startup item corresponding to the target bus device and conforming to the target network protocol is generated, including: when the reference bus device includes M bus devices and the target bus device includes P bus devices, the startup items corresponding to the P bus devices and conforming to the target network protocol are generated by executing the following steps, wherein the M bus devices include the P bus devices, M is a positive integer, and P is a positive integer less than or equal to M: controlling the generation component to generate startup items corresponding to the P bus devices and conforming to the target network protocol to obtain P startup items, and controlling the generation component to generate a startup item list; controlling the generation component to store the P startup items in the startup item list.

[0013] In an exemplary embodiment, the use of the startup item to start the operating system includes: when the target bus device includes P bus devices and the startup item includes P startup items corresponding to the P bus devices, using the P startup items to start the operating system by executing the following steps, wherein P is a positive integer less than or equal to M: detecting the startup sequence corresponding to the P startup items; using the first startup item in the startup sequence among the P startup items to start the operating system; and when starting the operating system using the first startup item fails, using the next startup item located after the first startup item in the startup sequence to start the operating system.

[0014] In an exemplary embodiment, after the operating system is started using the startup item, the method further includes: in a case where the reference bus device recorded at the target storage location is adjusted to a second candidate bus device, detecting a difference bus device between the second candidate bus device and the reference bus device, wherein the difference bus device is a bus device different from the second candidate bus device and the reference bus device; and deleting the startup item corresponding to the difference bus device from the startup item.

[0015] In an exemplary embodiment, an adjustment component is deployed in the startup system, and deleting the startup item corresponding to the difference bus device from the startup item includes: when the startup item includes P startup items and the difference bus device includes R bus devices, deleting the R startup items corresponding to the R bus devices from the P startup items by executing the following steps, wherein P is a positive integer less than or equal to M, and R is a positive integer: controlling the adjustment component to search for the R startup items corresponding to the R bus devices from the P startup items; and controlling the adjustment component to delete the R startup items.

[0016] According to another embodiment of the present application, a startup control device for a server is provided, comprising: a startup system applied to the server, a target storage location in the server recording a reference bus device that allows the operating system of the server to be started according to a target network protocol, the target storage location being set to allow the startup system to access it when the server is not started, the device comprising: an access module, for accessing the target storage location to obtain the reference bus device when controlling the startup process of the server to run to the startup stage of the operating system; a first detection module, for detecting the target bus device connected to the server from the reference bus device; a generation module, for generating a startup item corresponding to the target bus device and conforming to the target network protocol when the target bus device is detected from the reference bus device; and a startup module, for starting the operating system using the startup item.

[0017] According to another embodiment of the present application, a computer-readable storage medium is provided, in which a computer program is stored, wherein the computer program is configured to execute the steps of any of the above method embodiments when run.

[0018] According to another embodiment of the present application, an electronic device is provided, including a memory and a processor, wherein the memory stores a computer program, and the processor is configured to run the computer program to execute the steps in any one of the above method embodiments.

[0019] According to another embodiment of the present application, a computer program product is provided, including a computer program, and when the computer program is executed by a processor, the steps in any of the above method embodiments are implemented.

[0020] Through the present application, bus devices that allow the server's operating system to be started according to the network protocol are recorded in the server. These bus devices allow the startup system to be accessed when the server is not started. When the server's operating system is started, if the bus device connected to the server is found from the bus devices that allow the server's operating system to be started according to the network protocol recorded in the server, it can be indicated that the bus device currently connected to the server is allowed to start the server's operating system according to the network protocol. In this case, a startup item corresponding to the bus device is generated, and the server's operating system is started through the specified bus device according to customer needs. Therefore, the problem of low startup control efficiency of the server can be solved, thereby achieving the effect of improving the startup control efficiency of the server. BRIEF DESCRIPTION OF THE DRAWINGS

[0021] Figure 1It is a hardware structure block diagram of a server device of a server startup control method according to an embodiment of the present application;

[0022] Figure 2 is a flow chart of a method for starting up a server according to an embodiment of the present application;

[0023] Figure 3 is a schematic diagram of an optional query bus device according to an embodiment of the present application;

[0024] Figure 4 is a schematic diagram of an optional newly added bus device according to an embodiment of the present application;

[0025] Figure 5 is a schematic diagram of an optional deletion of a bus device according to an embodiment of the present application;

[0026] Figure 6 is a schematic diagram of an optional server startup control method according to an embodiment of the present application;

[0027] Figure 7 It is a structural block diagram of a startup control device of a server according to an embodiment of the present application. DETAILED DESCRIPTION

[0028] The embodiments of the present application will be described in detail below with reference to the accompanying drawings and in combination with the embodiments.

[0029] It should be noted that the terms "first", "second", etc. in the specification and claims of this application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence.

[0030] The method embodiments provided in the embodiments of the present application can be executed in a server device or a similar computing device. Taking running on a server device as an example, Figure 1 1 is a hardware structure block diagram of a server device of a server startup control method according to an embodiment of the present application. Figure 1 As shown, the server device may include one or more ( Figure 1 Only one is shown in the figure) a processor 102 (the processor 102 may include but is not limited to a processing device such as a microprocessor MCU or a programmable logic device FPGA) and a memory 104 for storing data, wherein the above-mentioned server device may also include a transmission device 106 and an input / output device 108 for communication functions. It can be understood by those skilled in the art that Figure 1 The structure shown is only for illustration and does not limit the structure of the above server device. Figure 1 More or fewer components as shown, or with Figure 1 Different configurations shown.

[0031] The memory 104 can be used to store computer programs, for example, software programs and modules of application software, such as the computer program corresponding to the startup control method of the server in the embodiment of the present application. The processor 102 executes various functional applications and data processing by running the computer program stored in the memory 104, that is, to implement the above method. The memory 104 may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 104 may further include a memory remotely arranged relative to the processor 102, and these remote memories can be connected to the server device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0032] The transmission device 106 is used to receive or send data via a network. The specific example of the above network may include a wireless network provided by a communication provider of the server device. In one example, the transmission device 106 includes a network adapter (Network Interface Controller, referred to as NIC), which can be connected to other network devices through a base station so as to communicate with the Internet. In one example, the transmission device 106 can be a radio frequency (RF) module, which is used to communicate with the Internet wirelessly.

[0033] First, the terms involved in the embodiments of the present application are explained as follows:

[0034] BIOS: Base Input / Output System, basic input / output system.

[0035] BMC: Baseboard Management Controller, baseboard management controller.

[0036] PXE: Preboot Execution Environment, pre-boot execution environment.

[0037] VID: Vendor ID, vendor ID (Identity document).

[0038] DID: Device ID, device ID.

[0039] SVID: Subsystem-Identification, a secondary code that authorizes the manufactured device.

[0040] SSID: Subsystem-Vendor Identification, system vendor identification code.

[0041] NVRAM: Non-Volatile Random Access Memory, non-volatile random access memory.

[0042] PXEID: Preboot EXecution Environment Identifier, pre-boot execution environment flag.

[0043] In this embodiment, a server startup control method is provided, which is applied to a startup system of the server, wherein a reference bus device that allows the operating system of the server to be started according to a target network protocol is recorded at a target storage location in the server, and the target storage location is set to allow the startup system to access when the server is not started. Figure 2 is a flow chart of a method for starting up a server according to an embodiment of the present application, such as Figure 2 As shown, the process includes the following steps:

[0044] Step S202, when controlling the startup process of the server to run to the startup phase of the operating system, accessing the target storage location to obtain the reference bus device;

[0045] Step S204, detecting a target bus device to which the server is connected from the reference bus device;

[0046] Step S206, when the target bus device is detected from the reference bus device, generating a startup item corresponding to the target bus device and conforming to the target network protocol;

[0047] Step S208: start the operating system using the startup item.

[0048] Through the embodiments of the present application, bus devices that allow the server's operating system to be started according to the network protocol are recorded in the server. These bus devices allow the startup system to be accessed when the server is not started. When the server's operating system is started, if the bus device connected to the server is found from the bus devices that allow the server's operating system to be started according to the network protocol recorded in the server, it can be indicated that the bus device currently connected to the server is allowed to start the server's operating system according to the network protocol. In this case, a startup item corresponding to the bus device is generated, and the server's operating system is started through the specified bus device according to customer needs. Therefore, the problem of low startup control efficiency of the server can be solved, thereby achieving the effect of improving the startup control efficiency of the server.

[0049] In the technical solution provided in the above step S202, the boot system may include but is not limited to a BIOS (Basic Input Output System) in a server, and the bus device may include but is not limited to a device that complies with a target bus device. As an optional example, the bus device may include but is not limited to a bus device that complies with a PCIE protocol, for example, a PCIE (peripheral component interconnect express) network card, etc.

[0050] Optionally, in this embodiment, the target network protocol may, but is not limited to, allow the server's operating system to be started through the network. As an optional example, the target network protocol may, but is not limited to, include a PXE protocol, etc. This application does not impose any restrictions on this.

[0051] Optionally, in this embodiment, the reference bus device may include but is not limited to one or more bus devices, and the reference bus device may include but is not limited to being set by the customer according to needs. It can be understood that the reference bus device recorded in the target storage location can be dynamically updated according to changes in customer needs.

[0052] In an exemplary embodiment, the target storage location can be deployed on the baseboard management controller of the server in the following manner, but is not limited to: generating and initiating a target access request to the baseboard management controller, wherein the target access request is used to request access to the target storage location to obtain the reference bus device, and the baseboard management controller is configured to respond to the received access request and read the data stored in the storage location on the baseboard management controller; and receiving the reference bus device returned by the baseboard management controller in response to the received target access request.

[0053] Optionally, in this embodiment, the target storage location may be but is not limited to being deployed on a BMC (Baseboard Management Controller) of a server, and the startup system may be but is not limited to obtaining the reference bus device by accessing data recorded on the target storage location in the BMC.

[0054] Optionally, in this embodiment, the target storage location may include but is not limited to one or more storage sub-locations, and the storage sub-location may include but is not limited to a starting offset address and an offset. For example, the storage sub-location may be used to store but is not limited to device information of a bus device in a reference bus device.

[0055] Figure 3 is a schematic diagram of an optional query bus device according to an embodiment of the present application, such as Figure 3 As shown, the bus device may include, but is not limited to, a network card as an example, and may include, but is not limited to, the following contents:

[0056] 1. Added an OEM (Original Equipment Manufacturer) IPMI (Intelligent Platform Management Interface) command to query the stored PXE boot network card information, which can include but is not limited to the flag bit _PXEID_ and the device attributes of the bus device, such as the actual DID, VID, SSID, SVID, etc. of the bus device.

[0057] 2. When BMC receives the IPMI command to query the PXE boot network card information, it parses and determines whether the information header is _PXEID_. If the information header is _PXEID_, it goes to step 3; otherwise, it returns 01, indicating that the query information is invalid, and ends.

[0058] 3. Add a new structure to store parsed information.

[0059] typedef struct { UINT16 Did;

[0060] UINT16 Vid;

[0061] UINT16 ssid;

[0062] UINT16 Svid;

[0063] } RESERVE_DEVICE_PXEID_LIST.

[0064] And set the variable ReserveDeviceList (reserved device list) to store the network card information (equivalent to bus device information) that has been reserved for PXE boot.

[0065] 4. Read the data from EEPROM (Electrically Erasable Programmable read only memory) as required. ) and obtain the network card information reserved for PXE boot and fill it into ReserveDeviceList.

[0066] 5. After the ReserveDeviceList information is escaped, it is successfully returned according to the specified rules.

[0067] 6. End.

[0068] In an exemplary embodiment, the target storage location may be deployed on the baseboard management controller of the server in the following manner, but is not limited to, before accessing the target storage location to obtain the reference bus device: receiving a target adjustment request, wherein the target adjustment request is used to request that the reference bus device recorded on the target storage location be adjusted to a first candidate bus device; in response to the target adjustment request, detecting an adjustment bus device between the reference bus device and the first candidate bus device; and adjusting the reference bus device recorded on the target storage location to the first candidate bus device according to the adjustment bus device.

[0069] Optionally, in this embodiment, the adjusted bus devices may include but are not limited to bus devices that the customer wants to add or reduce, and the adjusted bus devices may include but are not limited to bus devices that are different between the reference bus device and the first candidate bus device. For example, the adjusted bus devices may include but are not limited to bus devices that exist in the reference bus device and do not exist in the first candidate bus device, or the adjusted bus devices may include but are not limited to bus devices that do not exist in the reference bus device and exist in the first candidate bus device.

[0070] Optionally, in this embodiment, the adjustment bus device may also be carried directly in the target adjustment request but is not limited to it. It is understandable that the adjustment bus device may be deleted directly from the reference bus device but is not limited to it, or the adjustment bus device may be recorded in the reference bus device.

[0071] In an exemplary embodiment, the reference bus device recorded at the target storage location may be adjusted to the first candidate bus device according to the adjustment bus device in the following manner, but is not limited to: deleting the adjustment bus device from the reference bus device recorded at the target storage location to obtain the first candidate bus device; and / or recording the adjustment bus device in the reference bus device stored at the target storage location to obtain the first candidate bus device.

[0072] Optionally, in this embodiment, the reference bus device recorded in the target storage location may be, but is not limited to, allowed to be dynamically changed. For example, bus devices may be added or reduced according to user needs. Figure 4 is a schematic diagram of an optional newly added bus device according to an embodiment of the present application, such as Figure 4 As shown, the bus device may include, but is not limited to, a network card as an example, and may include, but is not limited to, the following contents:

[0073] 1. BMC adds a new OEM IPMI command, which is used to set the network card information for PXE startup of the specified network card, and set the interface specification and storage information standards, including the information identification bit _PXEID_ and the device attributes of the bus device, such as the DID, VID, SSID, and SVID of the bus device.

[0074] 2. When BMC receives the IPMI command for adding a specified network card PXE, it parses and determines whether the information header is _PXEID_. If the information header is _PXEID_, it goes to step 3; otherwise, it returns 01, indicating that the newly added PXE startup network card information is invalid, and executes the end step.

[0075] 3. Add a new structure to store parsed information.

[0076] typedef struct { UINT16 Did;

[0077] UINT16 Vid;

[0078] UINT16 ssid;

[0079] UINT16 Svid;

[0080] } RESERVE_DEVICE_PXEID;

[0081] And set the variable ReserveDevice (reserved device) to store the network card information reserved for PXE boot.

[0082] 4. Parse the information of the ipmi command in sequence. Each field is two BYTEs, namely DID, VID, SSID, and SVID, and store the information in ReserveDevice.

[0083] 5. Read the network card information of the specified network card PXE startup that has been stored in the EEPROM (equivalent to the target storage location), and determine the number N of valid information storage. If N<5 (or 10 or 15, etc., this application does not impose any restrictions on this), jump to step 6; if N>=5, return error message 02, indicating that the upper limit of the retained PXE startup network card information has been reached. If writing is required, please delete the invalid information first.

[0084] 6. Write the information in ReserveDevice to the next location of the currently written data in the EEPROM, for example, the N+1th location, and return the information 00, indicating that the reserved PXE boot network card information has been successfully stored in the EEPROM.

[0085] 7. End.

[0086] Figure 5 is a schematic diagram of an optional deletion of a bus device according to an embodiment of the present application, such as Figure 5 As shown, the bus device may include, but is not limited to, a network card as an example, and may include, but is not limited to, the following contents:

[0087] 1. Added a new OEM IPMI command to delete the network card information that does not require PXE boot, including the flag bit _PXEID_, the actual DID, VID, SSID, and SVID of the device.

[0088] 2. When BMC receives the IPMI command to delete the network card information that does not require PXE startup, it parses and determines whether the information header is _PXEID_. If the information header is _PXEID_, it goes to step 3; otherwise, it returns 01, marks the deletion of information as invalid, and ends.

[0089] 3. Add a new structure to store parsed information.

[0090] typedef struct { UINT16 Did;

[0091] UINT16 Vid;

[0092] UINT16 ssid;

[0093] UINT16 Svid;

[0094] } RESERVE_DEVICE_DELETE;

[0095] And set the variable ReserveDeviceDelete to store and delete the network card information for PXE boot.

[0096] 4. Parse the information of the IPMI command in sequence. Each field is two BYTEs, namely DID, VID, SSID, and SVID, and store the information in ReserveDeviceDelete.

[0097] 5. Add a new array to store parsed information.

[0098] typedef struct { UINT16 Did;

[0099] UINT16 Vid;

[0100] UINT16 ssid;

[0101] UINT16 Svid;

[0102] } RESERVE_DEVICE_PXEID_LIST;

[0103] And set the variable ReserveDeviceList to store the network card information that has been reserved for PXE boot.

[0104] 6. Use the newly added IPMI command to query the stored PXE boot network card information, obtain the filter device information from the specified location of the EEPROM, parse it in sequence, and fill the parsed information into the ReserveDeviceList according to the specification.

[0105] 7. Poll the information in ReserveDeviceList to check whether there is any information matching ReserveDeviceDelete. If the match is successful, jump to step 8; otherwise, return information 05, indicating that there is no information to be deleted.

[0106] 8. Delete the ReserveDeviceDelete information in ReserveDeviceList.

[0107] 9. Erase the area for filtering device information in EEPROM, rewrite the latest data in ReserveDeviceList into EEPROM and return 00, indicating that the network card information started by PXE has been successfully deleted.

[0108] 10. End.

[0109] In the technical solution provided in the above step S204, the target bus device may be, but is not limited to, the bus device currently connected to the server, and may be, but is not limited to, detecting the target bus device connected to the server from the reference bus device in the following manner: searching for the target bus device from the reference bus device in a polling manner.

[0110] In an exemplary embodiment, the target storage location records the first bus device information corresponding to the reference bus device, and the target bus device connected to the server can be detected from the reference bus device in the following manner, but is not limited to: searching for the second bus device information of the target bus device from the first bus device information; and determining that the target bus device is detected from the reference bus device when the second bus device information is found from the first bus device information.

[0111] Optionally, in this embodiment, the bus device information may be, but is not limited to, stored according to the target structure, and the target storage location may be, but is not limited to, recording the first bus device information corresponding to the reference bus device.

[0112] Optionally, in this embodiment, the second bus device information of the target bus device may be searched from the first bus device in a polling manner, but is not limited to the polling manner.

[0113] In an exemplary embodiment, the second bus device information of the target bus device can be searched from the first bus device information in the following manner, but is not limited to: when the first bus device information includes N bus device information, the second bus device information is searched from the N bus device information by performing the following steps, wherein N is a positive integer greater than or equal to 1: extracting an i-th group of bus device attributes carried in an i-th bus device information among the N bus device information, and extracting the target bus device attributes of the target bus device carried in the second bus device information, wherein the i-th bus device information is the bus device information corresponding to the i-th bus device among the N bus devices, the reference bus device includes the N bus devices, and i is a positive integer less than or equal to N; comparing whether the i-th group of bus device attributes is consistent with the target bus device attributes to obtain a first comparison result.

[0114] Optionally, in this embodiment, the i-th group of bus device attributes may include but is not limited to one or more bus device attributes. As an optional example, the bus device attributes may include but are not limited to the device identification of the bus device, the device type of the bus device, etc. As an optional example, the device identification of the bus device may include but is not limited to the DID, VID, SSID, SVID, etc. of the bus device.

[0115] Optionally, in this embodiment, it can be determined that the i-th group of bus device attributes is consistent with the target bus device attributes when, but not limited to, the third number of bus device attributes included in the i-th group of bus device attributes is the same as the fourth number of bus device attributes included in the target bus device attributes, and each bus device attribute included in the i-th group of bus device attributes is the same as the corresponding bus device attribute in the target bus device attributes.

[0116] Optionally, in this embodiment, it can be but not limited to that when a third number of bus device attributes included in the i-th group of bus device attributes is different from a fourth number of bus device attributes included in the target bus device attributes, and / or when there is at least one bus device attribute in the i-th group of bus device attributes that is different from the bus device attributes in the target bus device attributes, it is determined that the i-th group of bus device attributes is inconsistent with the target bus device attributes.

[0117] In an exemplary embodiment, the i-th group of bus device attributes and the target bus device attributes are compared to see if they are consistent, and after obtaining a first comparison result, but not limited to, in the following manner: when the first comparison result is used to indicate that there are bus device attributes in the i-th group of bus device attributes that are inconsistent with the target bus device attributes, extract the i+1-th group of bus device attributes carried in the i+1-th bus device information among the N bus device information, wherein the i+1-th bus device information is the bus device information corresponding to the i+1-th bus device among the N bus devices, and i+1 is a positive integer less than or equal to N; and compare the i+1-th group of bus device attributes and the target bus device attributes to see if they are consistent, and obtain a second comparison result.

[0118] Optionally, in this embodiment, it can be determined that the i+1th group of bus device attributes is consistent with the target bus device attributes when, but not limited to, the first number of bus device attributes included in the i+1th group of bus device attributes is the same as the second number of bus device attributes included in the target bus device attributes, and each bus device attribute included in the i+1th group of bus device attributes is the same as the corresponding bus device attribute in the target bus device attributes.

[0119] Optionally, in this embodiment, it can be but is not limited to that when a first number of bus device attributes included in the i+1th group of bus device attributes is different from a second number of bus device attributes included in the target bus device attributes, and / or when there is at least one bus device attribute in the i+1th group of bus device attributes that is different from the corresponding bus device attribute in the target bus device attributes, it is determined that the i+1th group of bus device attributes is consistent with the target bus device attributes.

[0120] In the technical solution provided in the above step S206, when the target bus device is detected from the reference bus device, it can be indicated that the target bus device is a bus device that allows the server's operating system to be started according to the target network protocol. In this case, it is possible but not limited to generating a startup item that complies with the target network protocol corresponding to the target bus device.

[0121] Optionally, in this embodiment, each bus device in the reference bus device may have, but is not limited to, a corresponding startup item.

[0122] In an exemplary embodiment, a generation component is deployed in a startup system in the following manner, but is not limited to the following manner: when the target bus device is detected from the reference bus device, a startup item corresponding to the target bus device and conforming to the target network protocol is generated: when the reference bus device includes M bus devices and the target bus device includes P bus devices, startup items corresponding to the P bus devices and conforming to the target network protocol are generated by executing the following steps, wherein the M bus devices include the P bus devices, M is a positive integer, and P is a positive integer less than or equal to M: controlling the generation component to generate startup items corresponding to the P bus devices and conforming to the target network protocol to obtain P startup items, and controlling the generation component to generate a startup item list; controlling the generation component to store the P startup items in the startup item list.

[0123] Optionally, in this embodiment, the startup items corresponding to the bus devices recorded in the startup item list may change dynamically. For example, when the connected bus device changes, or when the bus devices included in the reference bus device change, the startup items corresponding to the bus devices recorded in the startup item list may also change accordingly.

[0124] Optionally, in this embodiment, the startup item list may be but is not limited to being used to store startup items corresponding to reference bus devices recorded in the reference bus device list, may be but is not limited to first generating startup items corresponding to the reference bus device, and when the target bus device is detected from the reference bus device, may be but is not limited to directly searching for startup items corresponding to the target bus device from the startup items corresponding to the generated reference bus device.

[0125] In the technical solution provided in the above step S208, the startup item corresponding to the target bus device can be but is not limited to the startup item for starting the server's operating system. In this way, it is possible to obtain the startup item required for starting the server's operating system through the network, thereby improving the efficiency of starting the server's operating system.

[0126] Through the embodiments of the present application, the needs of customers to specify the network card PXE to start the server's operating system are met, thereby achieving the purpose of saving time and using the network card according to its functions. The problem in the related technology that a customized version and a customized motherboard are required to achieve the purpose of the customer specifying the network card to start the server is solved, which saves manpower and material resources and enables customers to use it quickly. In addition, through functional expansion, the embodiments of the present application can also solve the problem of automatic adaptation of specified startup of other classified devices.

[0127] In an exemplary embodiment, the operating system can be started using the startup item in the following manner, but is not limited to: when the target bus device includes P bus devices and the startup item includes P startup items corresponding to the P bus devices, the operating system is started using the P startup items by executing the following steps, wherein P is a positive integer less than or equal to M: detecting the startup sequence corresponding to the P startup items; starting the operating system using the first startup item in the startup sequence among the P startup items; and when starting the operating system using the first startup item fails, starting the operating system using the next startup item located after the first startup item in the startup sequence.

[0128] Optionally, in this embodiment, the startup sequence may include, but is not limited to, the sequence of using P startup items to start the server's operating system, and may include, but is not limited to, trying to use P startup items one by one to start the server's operating system according to the startup sequence. It should be noted that the user can set the startup sequence according to needs, and the startup sequence is allowed to change dynamically.

[0129] Optionally, in this embodiment, the operating system can be started using the startup item in the following manner but is not limited to: when a bus device connected to a server is detected from the reference bus device, a startup item corresponding to the bus device is generated, and the operating system is started using the startup item corresponding to the bus device, wherein the target bus device includes the bus device.

[0130] Through the embodiments of the present application, when it is detected that a server is connected to a bus device included in a reference bus device, the server's operating system is started directly using the startup item corresponding to the bus device. In this way, the number of startup items of the bus device that need to be generated is reduced, the time required to start the server's operating system is reduced, and the efficiency of starting the server's operating system is improved.

[0131] In an exemplary embodiment, after the operating system is started using the startup item, the following method may be used but is not limited to: when the reference bus device recorded at the target storage location is adjusted to a second candidate bus device, a difference bus device between the second candidate bus device and the reference bus device is detected, wherein the difference bus device is a bus device different from the second candidate bus device and the reference bus device; and the startup item corresponding to the difference bus device is deleted from the startup item.

[0132] Optionally, in this embodiment, the second candidate bus device may be but is not limited to being different from the reference bus device, and the difference bus device may be but is not limited to including bus devices that are not included in the second candidate bus device and included in the reference bus device; or the difference bus device may be but is not limited to including bus devices that are included in the second candidate bus device and not included in the reference bus device.

[0133] Optionally, in this embodiment, when the difference bus device may include but is not limited to a bus device not included in the second candidate bus device and included in the reference bus device, the startup item corresponding to the difference bus device may be deleted from the startup item corresponding to the reference bus device but is not limited to.

[0134] Optionally, in this embodiment, a generation component is deployed in the startup system. When the difference bus device may include but is not limited to a bus device included in the second candidate bus device and not included in the reference bus device, the generation component may be controlled but is not limited to generate a startup item corresponding to the difference bus device.

[0135] In an exemplary embodiment, an adjustment component is deployed in a startup system, and the startup item corresponding to the difference bus device is deleted from the startup item in the following manner, but is not limited to: when the startup item includes P startup items and the difference bus device includes R bus devices, R startup items corresponding to the R bus devices are deleted from the P startup items by performing the following steps, wherein P is a positive integer less than or equal to M, and R is a positive integer: controlling the adjustment component to search for the R startup items corresponding to the R bus devices from the P startup items; and controlling the adjustment component to delete the R startup items.

[0136] Optionally, in this embodiment, the adjustment component can be controlled to search for the R startup items corresponding to the R bus devices from the P startup items in the following manner, but is not limited to: the adjustment component is controlled to search for the R startup items corresponding to the bus device identifiers of the R startup items from the bus device identifiers and startup items having a corresponding relationship.

[0137] In order to better understand the startup control method of the server in the embodiment of the present application, the startup control method of the server in the embodiment of the present application is explained and illustrated in combination with optional embodiments below, which can be applicable to but not limited to the embodiment of the present application.

[0138] Add SETUP function to set PXE boot network card information on BIOS, which can include but is not limited to the following:

[0139] 1. Added a new PXE priority list module under SETUP.

[0140] 2. Added a new setting function. You can add the information of the PXE boot network card under setup. Enter the DID, VID, SSID, and SVID respectively, and press the Enter key to save them to NVRAM and send them to BMC through the information storage ipmi command.

[0141] 3. Added a delete function, which allows you to delete the information of the PXE boot network card under setup. Enter the DID, VID, SSID, and SVID respectively, press Enter to save the NVRAM and send it to the BMC through the information delete ipmi command.

[0142] 4. Added the function of displaying the set list, which reads the set PXE priority list from BIOS NVRAM and displays it.

[0143] Figure 6 is a schematic diagram of an optional server startup control method according to an embodiment of the present application, such as Figure 6 As shown, the bus device including the network card can be used as an example for explanation and description, but it is not limited to include the following contents:

[0144] 1. Turn on the server.

[0145] 2. During the POST process, query the ipmi command through the PXE startup network card information to obtain the list of network card information that the customer maintains on the BMC side and needs to be PXE started.

[0146] 3. If the information is returned successfully, jump to the next step; otherwise, retry times + 1. If retry = 3 (or 5 or 8, etc.) and it is still unsuccessful, jump to step 6.

[0147] 4. Parse the information returned by ipmi, determine whether the ASCII (American Standard Code for Information Interchange) parsing of the 1st to 7th bytes is valid, and determine whether it meets the header of _PXEID_. If so, proceed to the next step; otherwise, jump to step 6.

[0148] 5. Parse all PXE boot network card information, including DID, VID, SSID, SVID, and update to BIOS NVRAM.

[0149] 6. Generate BootDeviceList (boot device list) through FilterBootDeviceList (filter driver device list) module to store all generated boot items.

[0150] 7. Added PxeBootAdjust module, and added PxeBootAdjust (Pxe driver adjustment) module ELINK to the back of FilterBootDeviceList module for adjusting the network card PXE boot items.

[0151] 8. Add an array to store the network card device information that needs to generate PXE boot items.

[0152] typedef struct { UINT16 Did;

[0153] UINT16 Vid;

[0154] UINT16 ssid;

[0155] UINT16 Svid;

[0156] } RESERVE_DEVICE_PXEID_LIST; And set the array ReserveDeviceList[5] to store the network card information that needs to generate PXE boot items.

[0157] 9. Use the getVariable command to read the set PXE priority list from the BIOS NVRAM. If the read value is not NULL (invalid), proceed to the next step; if it is NULL, jump to step 14.

[0158] 10. Update the DID, VID, SSID, and SVID obtained from NVRAM to ReserveDeviceList in sequence.

[0159] 11. If ReserveDeviceList is NULL, jump to step 14, otherwise, go to the next step.

[0160] 12. Poll all PCIE devices in turn. If the network card is recognized to be in place, obtain the DID, VID, SSID, and SVID of the network card and proceed to the next step. If the polling is completed, jump to step 14.

[0161] 13. Check whether there is a complete match in the ReserveDeviceList based on the device DID, VID, SSID, and SVID. If so, jump to step 12; otherwise, obtain the corresponding device information in the BootDeviceList, delete the startup item of the corresponding device through the DeleteBootDevice function, and continue to step 12.

[0162] 14. Generate the startup items in the list in sequence according to the information in BootDeviceList.

[0163] 15. End.

[0164] Through the embodiments of the present application, an interface is reserved for customers, and customers can set the network card information that needs to be PXE started according to their own needs, which can not only speed up the PXE training time, but also meet the needs of customizing network cards for PXE startup, reduce the maintenance of customized versions and customized motherboards, save manpower and material resources, and improve customer experience and product competitiveness.

[0165] Through the description of the above implementation methods, those skilled in the art can clearly understand that the method according to the above embodiment can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk), and includes a number of instructions for a terminal device (which can be a mobile phone, computer, server, or network device, etc.) to execute the methods described in each embodiment of the present application.

[0166] In this embodiment, a startup control device for a server is also provided, which is used to implement the above-mentioned embodiments and preferred implementation modes, and the descriptions that have been made will not be repeated. As used below, the term "module" can implement a combination of software and / or hardware of a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceivable.

[0167] Figure 7 is a structural block diagram of a startup control device of a server according to an embodiment of the present application, such as Figure 7 As shown, the device includes a startup system applied to a server, a reference bus device that allows the operating system of the server to be started according to a target network protocol is recorded at a target storage location in the server, and the target storage location is set to allow the startup system to access when the server is not started, and the device includes:

[0168] An access module 702, configured to access the target storage location to obtain the reference bus device when controlling the startup process of the server to run to the startup phase of the operating system;

[0169] A first detection module 704, configured to detect a target bus device to which the server is connected from the reference bus device;

[0170] A generating module 706, configured to generate a startup item corresponding to the target bus device and conforming to the target network protocol when the target bus device is detected from the reference bus device;

[0171] The startup module 708 is used to start the operating system using the startup item.

[0172] Through the above-mentioned device, bus devices that allow the server's operating system to be started according to the network protocol are recorded in the server. These bus devices allow the startup system to be accessed when the server is not started. When the server's operating system is started, if the bus device connected to the server is found from the bus devices that allow the server's operating system to be started according to the network protocol recorded in the server, it can be indicated that the bus device currently connected to the server is allowed to start the server's operating system according to the network protocol. In this case, a startup item corresponding to the bus device is generated, and the server's operating system is started through the specified bus device according to customer needs. Therefore, the problem of low startup control efficiency of the server can be solved, thereby achieving the effect of improving the startup control efficiency of the server.

[0173] In an exemplary embodiment, the access module includes:

[0174] A generating unit, configured to generate and initiate a target access request to the baseboard management controller, wherein the target access request is used to request access to the target storage location to obtain the reference bus device, and the baseboard management controller is configured to respond to the received access request and read data stored in the storage location on the baseboard management controller;

[0175] The receiving unit is used to receive the reference bus device returned by the baseboard management controller in response to the received target access request.

[0176] In an exemplary embodiment, the target storage location is deployed on a baseboard management controller of the server, and the above-mentioned device includes:

[0177] A receiving module, configured to receive a target adjustment request before accessing the target storage location to obtain the reference bus device, wherein the target adjustment request is used to request that the reference bus device recorded in the target storage location be adjusted to a first candidate bus device;

[0178] a second detection module, configured to detect an adjustment bus device between the reference bus device and the first candidate bus device in response to the target adjustment request;

[0179] An adjustment module is used to adjust the reference bus device recorded in the target storage location to the first candidate bus device according to the adjustment bus device.

[0180] In an exemplary embodiment, the adjustment module includes:

[0181] a deleting unit, configured to delete the adjustment bus device from the reference bus devices recorded at the target storage location to obtain the first candidate bus device; and / or

[0182] A recording unit is used to record the adjusted bus device in the reference bus device stored in the target storage location to obtain the first candidate bus device.

[0183] In an exemplary embodiment, the first detection module includes:

[0184] a searching unit, configured to search the second bus device information of the target bus device from the first bus device information;

[0185] A determining unit is used to determine that the target bus device is detected from the reference bus device when the second bus device information is found from the first bus device information.

[0186] In an exemplary embodiment, the searching unit is used to:

[0187] In the case where the first bus device information includes N bus device information, the second bus device information is searched from the N bus device information by performing the following steps, where N is a positive integer greater than or equal to 1:

[0188] Extracting an i-th group of bus device attributes carried in an i-th bus device information among the N bus device information, and extracting a target bus device attribute of the target bus device carried in the second bus device information, wherein the i-th bus device information is bus device information corresponding to the i-th bus device among the N bus devices, the reference bus device includes the N bus devices, and i is a positive integer less than or equal to N;

[0189] The bus device attributes of the i-th group are compared with the target bus device attributes to determine whether they are consistent, and a first comparison result is obtained.

[0190] In an exemplary embodiment, the apparatus further comprises:

[0191] an extraction module, configured to extract, after obtaining a first comparison result by comparing whether the i-th group of bus device attributes is consistent with the target bus device attributes, an i+1-th group of bus device attributes carried in an i+1-th bus device information among the N bus device information, if the first comparison result indicates that there is a bus device attribute inconsistent with the target bus device attribute in the i-th group of bus device attributes, wherein the i+1-th bus device information is bus device information corresponding to an i+1-th bus device among the N bus devices, and i+1 is a positive integer less than or equal to N;

[0192] The comparison module is used to compare whether the attributes of the (i+1)th group of bus devices are consistent with the attributes of the target bus device to obtain a second comparison result.

[0193] In an exemplary embodiment, the generating module is used to:

[0194] In the case where the reference bus device includes M bus devices and the target bus device includes P bus devices, the startup items corresponding to the P bus devices and conforming to the target network protocol are generated by executing the following steps, wherein the M bus devices include the P bus devices, M is a positive integer, and P is a positive integer less than or equal to M:

[0195] Control the generating component to generate startup items corresponding to the P bus devices and conforming to the target network protocol, obtain P startup items, and control the generating component to generate a startup item list;

[0196] Control the generating component to store the P startup items into the startup item list.

[0197] In an exemplary embodiment, the startup module is used to:

[0198] In a case where the target bus device includes P bus devices and the startup items include P startup items corresponding to the P bus devices, the operating system is started using the P startup items by performing the following steps, wherein P is a positive integer less than or equal to M:

[0199] Detecting the startup order corresponding to the P startup items;

[0200] Start the operating system using the first startup item in the startup sequence among the P startup items;

[0201] In the case that starting the operating system by using the first startup item fails, starting the operating system by using the next startup item after the first startup item in the startup sequence.

[0202] In an exemplary embodiment, the apparatus further comprises:

[0203] a third detection module, configured to detect a different bus device between the second candidate bus device and the reference bus device after the operating system is started using the startup item, when the reference bus device recorded in the target storage location is adjusted to a second candidate bus device, wherein the different bus device is a bus device different from the second candidate bus device and the reference bus device;

[0204] The deleting module is used to delete the startup item corresponding to the difference bus device from the startup items.

[0205] In an exemplary embodiment, the deletion module is used to:

[0206] In the case where the startup items include P startup items and the difference bus devices include R bus devices, the R startup items corresponding to the R bus devices are deleted from the P startup items by performing the following steps, wherein P is a positive integer less than or equal to M, and R is a positive integer:

[0207] Control the adjustment component to search the R startup items corresponding to the R bus devices from the P startup items;

[0208] Control the adjustment component to delete the R startup items.

[0209] It should be noted that the above modules can be implemented by software or hardware. For the latter, it can be implemented in the following ways, but not limited to: the above modules are all located in the same processor; or the above modules are located in different processors in any combination.

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

[0211] In an exemplary embodiment, the computer-readable storage medium may include, but is not limited to, various media that can store computer programs, such as a USB flash drive, a read-only memory (ROM), a random access memory (RAM), a mobile hard disk, a magnetic disk, or an optical disk.

[0212] An embodiment of the present application further provides an electronic device, including a memory and a processor, wherein 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 method embodiments.

[0213] In an exemplary embodiment, the electronic device may further include a transmission device and an input / output device, wherein the transmission device is connected to the processor, and the input / output device is connected to the processor.

[0214] An embodiment of the present application further provides a computer program product, which includes a computer program. When the computer program is executed by a processor, the steps in any one of the above method embodiments are implemented.

[0215] An embodiment of the present application further provides another computer program product, including a non-volatile computer-readable storage medium, wherein the non-volatile computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps in any of the above method embodiments are implemented.

[0216] An embodiment of the present application also provides a computer program, which includes computer instructions stored in a computer-readable storage medium; a processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device performs the steps in any one of the above method embodiments.

[0217] For specific examples in this embodiment, reference may be made to the examples described in the above embodiments and exemplary implementation modes, and this embodiment will not be described in detail herein.

[0218] Obviously, those skilled in the art should understand that the above modules or steps of the present application can be implemented by a general computing device, they can be concentrated on a single computing device, or distributed on a network composed of multiple computing devices, they can be implemented by a program code executable by a computing device, so that they can be stored in a storage device and executed by the computing device, and in some cases, the steps shown or described can be executed in a different order from that herein, or they can be made into individual integrated circuit modules, or multiple modules or steps therein can be made into a single integrated circuit module for implementation. Thus, the present application is not limited to any specific combination of hardware and software.

[0219] The above description is only the preferred embodiment of the present application and is not intended to limit the present application. For those skilled in the art, the present application may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the principles of the present application shall be included in the protection scope of the present application.

Claims

1. A method for controlling the startup of a server, characterized in that: A boot system applied to a server, wherein a reference bus device that allows the operating system of the server to be booted according to a target network protocol is recorded at a target storage location in the server, and the target storage location is set to allow the boot system to access it when the server is not booted, and the method comprises: In a case where the startup process of the server is controlled to run to the startup phase of the operating system, accessing the target storage location to obtain the reference bus device; Detecting a target bus device to which the server is connected from the reference bus device; In the case where the target bus device is detected from the reference bus device, generating a startup item corresponding to the target bus device and conforming to the target network protocol; Using the startup item to start the operating system; The target storage location records the first bus device information corresponding to the reference bus device, and the step of detecting the target bus device connected to the server from the reference bus device includes: Searching the second bus device information of the target bus device from the first bus device information; In the case where the second bus device information is found from the first bus device information, determining that the target bus device is detected from the reference bus device; The searching for the second bus device information of the target bus device from the first bus device information comprises: when the first bus device information comprises N bus device information, searching for the second bus device information from the N bus device information by performing the following steps, wherein N is a positive integer greater than or equal to 1: Extracting an i-th group of bus device attributes carried in an i-th bus device information among the N bus device information, and extracting a target bus device attribute of the target bus device carried in the second bus device information, wherein the i-th bus device information is bus device information corresponding to the i-th bus device among the N bus devices, the reference bus device includes the N bus devices, and i is a positive integer less than or equal to N; Comparing the i-th group of bus device attributes with the target bus device attributes to see whether they are consistent, and obtaining a first comparison result; Wherein, after comparing whether the i-th group of bus device attributes is consistent with the target bus device attributes and obtaining a first comparison result, the method further includes: In a case where the first comparison result is used to indicate that there are bus device attributes in the i-th group of bus device attributes that are inconsistent with the target bus device attributes, extracting the i+1-th group of bus device attributes carried in the i+1-th bus device information among the N bus device information, wherein the i+1-th bus device information is the bus device information corresponding to the i+1-th bus device among the N bus devices, and i+1 is a positive integer less than or equal to N; The bus device attributes of the (i+1)th group are compared with the target bus device attributes to determine whether they are consistent, and a second comparison result is obtained.

2. The method according to claim 1, characterized in that The target storage location is deployed on a baseboard management controller of the server, and accessing the target storage location to obtain the reference bus device includes: Generate and initiate a target access request to the baseboard management controller, wherein the target access request is used to request access to the target storage location to obtain the reference bus device, and the baseboard management controller is configured to respond to the received access request and read data stored in the storage location on the baseboard management controller; The reference bus device is received, which is returned by the baseboard management controller in response to the received target access request.

3. The method according to claim 1, characterized in that: The target storage location is deployed on a baseboard management controller of the server. Before accessing the target storage location to obtain the reference bus device, the method includes: receiving a target adjustment request, wherein the target adjustment request is used to request that the reference bus device recorded at the target storage location be adjusted to a first candidate bus device; In response to the target adjustment request, detecting an adjustment bus device between the reference bus device and the first candidate bus device; According to the adjustment bus device, the reference bus device recorded at the target storage location is adjusted to the first candidate bus device.

4. The method according to claim 3, characterized in that The step of adjusting the reference bus device recorded at the target storage location to the first candidate bus device according to the adjusted bus device includes: Deleting the adjustment bus device from the reference bus devices recorded at the target storage location to obtain the first candidate bus device; and / or, The adjusted bus device is recorded in the reference bus device stored in the target storage location to obtain the first candidate bus device.

5. The method according to claim 1, characterized in that The startup system is deployed with a generation component, and when the target bus device is detected from the reference bus device, the startup item corresponding to the target bus device and conforming to the target network protocol is generated, including: In the case where the reference bus device includes M bus devices and the target bus device includes P bus devices, the startup items corresponding to the P bus devices and conforming to the target network protocol are generated by executing the following steps, wherein the M bus devices include the P bus devices, M is a positive integer, and P is a positive integer less than or equal to M: Control the generating component to generate startup items corresponding to the P bus devices and conforming to the target network protocol, obtain P startup items, and control the generating component to generate a startup item list; Control the generating component to store the P startup items into the startup item list.

6. The method according to claim 1, characterized in that The method of using the startup item to start the operating system includes: when the target bus device includes P bus devices and the startup item includes P startup items corresponding to the P bus devices, starting the operating system using the P startup items by executing the following steps, wherein P is a positive integer less than or equal to M, and M is the number of bus devices included in the reference bus device: Detecting the startup order corresponding to the P startup items; Start the operating system using the first startup item in the startup sequence among the P startup items; In the case that starting the operating system by using the first startup item fails, starting the operating system by using the next startup item after the first startup item in the startup sequence.

7. The method according to claim 1, characterized in that After starting the operating system using the startup item, the method further includes: In a case where the reference bus device recorded at the target storage location is adjusted to a second candidate bus device, detecting a difference bus device between the second candidate bus device and the reference bus device, wherein the difference bus device is a bus device different from the second candidate bus device and the reference bus device; The startup item corresponding to the difference bus device is deleted from the startup items.

8. The method according to claim 7, characterized in that The startup system is deployed with an adjustment component, and the deleting the startup item corresponding to the difference bus device from the startup item includes: when the startup item includes P startup items and the difference bus device includes R bus devices, deleting the R startup items corresponding to the R bus devices from the P startup items by performing the following steps, wherein P is a positive integer less than or equal to M, M is the number of bus devices included in the reference bus device, and R is a positive integer: Control the adjustment component to search the R startup items corresponding to the R bus devices from the P startup items; Control the adjustment component to delete the R startup items.

9. A server startup control device, characterized in that: A boot system applied to a server, wherein a reference bus device that allows the operating system of the server to be booted according to a target network protocol is recorded at a target storage location in the server, and the target storage location is set to allow the boot system to access it when the server is not booted, and the device comprises: An access module, configured to access the target storage location to obtain the reference bus device when controlling the startup process of the server to run to the startup phase of the operating system; A first detection module, used for detecting a target bus device connected to the server from the reference bus device; A generating module, configured to generate a startup item corresponding to the target bus device and conforming to the target network protocol when the target bus device is detected from the reference bus device; A startup module, used to start the operating system using the startup item; The target storage location records the first bus device information corresponding to the reference bus device, and the first detection module includes: a searching unit, configured to search the second bus device information of the target bus device from the first bus device information; a determining unit, configured to determine that the target bus device is detected from the reference bus device when the second bus device information is found from the first bus device information; Wherein, the searching unit is used for: In the case where the first bus device information includes N bus device information, the second bus device information is searched from the N bus device information by performing the following steps, where N is a positive integer greater than or equal to 1: Extracting an i-th group of bus device attributes carried in an i-th bus device information among the N bus device information, and extracting a target bus device attribute of the target bus device carried in the second bus device information, wherein the i-th bus device information is bus device information corresponding to the i-th bus device among the N bus devices, the reference bus device includes the N bus devices, and i is a positive integer less than or equal to N; Comparing the i-th group of bus device attributes with the target bus device attributes to see whether they are consistent, and obtaining a first comparison result; Wherein, the device further comprises: an extraction module, configured to extract, after obtaining a first comparison result by comparing whether the i-th group of bus device attributes is consistent with the target bus device attributes, an i+1-th group of bus device attributes carried in an i+1-th bus device information among the N bus device information, if the first comparison result indicates that there is a bus device attribute inconsistent with the target bus device attribute in the i-th group of bus device attributes, wherein the i+1-th bus device information is bus device information corresponding to an i+1-th bus device among the N bus devices, and i+1 is a positive integer less than or equal to N; The comparison module is used to compare whether the attributes of the (i+1)th group of bus devices are consistent with the attributes of the target bus device to obtain a second comparison result.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, wherein the computer program implements the steps of the method described in any one of claims 1 to 8 when executed by a processor.

11. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of the method described in any one of claims 1 to 8 are implemented.

12. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method described in any one of claims 1 to 8 are implemented.