A startup item disabling method, device, apparatus and storage medium

CN117608691BActive Publication Date: 2026-09-11INSPUR (SHANDONG) COMPUTER TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202311600895.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-11-28
Publication Date
2026-09-11
Estimated Expiration
2043-11-28

AI Technical Summary

Technical Problem

然而,每张网卡均能通过网线连接网络来引导不同的操作系统,若要禁用其中的某些网卡对应的启动项,可通过禁用网卡的方式,关闭网卡启动设备来实现,但这种方式存在一个缺陷,在目前的BIOS菜单下,仅针对SATA(Serial Advanced TechnologyAttachment,串行高级技术附件)硬盘设备、网卡启动设备设置了开关选项,可针对这两种类型的单一设备进行开关控制,并在启动列表中将其剔除,但对于NVME(Non VolatileMemory Host Controller Interface Specification,非易失性内存主机控制器接口规范)盘、光驱磁盘启动设备或者USB启动设备等其他启动设备,还没有对应的关闭选项,即无法控制NVME盘设备、光驱磁盘启动设备等其他启动设备的开启和关闭,虽然可以满足大多数场景,但对某些特定场景依旧存在缺陷

Benefits of technology

[0045] As can be seen, when this application receives a startup item disable request, it creates a disabled startup item list under the settings menu of the basic input/output system, and displays all initialized startup items from the pre-created target startup item list in the disabled startup item list. The target startup item list is a list created based on startup items corresponding to all devices capable of booting the server system. Then, based on the startup item disable request, all startup devices to be disabled are determined. Next, all initialized startup items corresponding to the devices to be disabled displayed in the disabled startup item list are marked to obtain marked disabled startup items. Then, the target startup item list is retrieved, and the initialized startup items corresponding to the marked disabled startup items in the target startup item list are deleted to obtain a deleted startup item list. Finally, the startup items under the current settings menu are updated to display the startup items in the deleted startup item list, and all startup items in the deleted startup item list are enabled to disable the startup items corresponding to the devices to be disabled. This application first creates a list of disabled startup items under the settings menu of the basic input/output system, and then removes the startup items corresponding to the devices to be disabled from the list of target startup items corresponding to all devices that can boot the server system. This enables the disabling of startup items for various types of startup devices, meets more diverse startup item disabling scenarios, avoids entering the wrong operating system, and saves manpower and time costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117608691B_ABST
    Figure CN117608691B_ABST
Patent Text Reader

Abstract

The application discloses a startup item disabling method and device, equipment and storage medium, and relates to the technical field of computers, and comprises the following steps: creating a disabled startup item list under a setting menu of a basic input / output system, and displaying all post-initialization startup items in a target startup item list in the disabled startup item list; marking all post-initialization startup items corresponding to a device to be disabled displayed in the disabled startup item list to obtain marked disabled startup items; pulling the target startup item list, and deleting the post-initialization startup items corresponding to the marked disabled startup items in the target startup item list to obtain a post-deletion startup item list; updating the startup items under the setting menu to display the startup items in the post-deletion startup item list, and starting all the startup items in the post-deletion startup item list. The application can realize the disabling of startup items of various types of startup devices, meet more diversified startup item disabling scenarios, and avoid entering an incorrect operating system.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and in particular to a method, apparatus, device and storage medium for disabling startup items. Background Technology

[0002] Currently, BIOS (Basic Input Output System) typically uses two boot modes to start servers: UEFI (Unified Extensible Firmware Interface) and LEGACY (a traditional computer boot mode). Under these two boot modes, all boot devices can be classified into four boot types: hard drive boot, network card boot, optical drive / disk boot, and other devices such as USB (Universal Serial Bus) boot. Different boot types enable the server to enter the operating system (OS) through different media.

[0003] However, in actual data center applications, multiple boot devices are often installed on a single machine. Depending on the actual application requirements, the target boot device is selected from these multiple boot devices to enter different operating systems. In order to prevent accidental entry into the wrong operating system, it is necessary to disable the boot entries of other boot devices that are not currently in use, in order to avoid the risk of entering the wrong operating system.

[0004] Disabling server startup items is currently achieved by modifying the startup order and then performing a loop startup. For example, when the target boot device is the network card, the startup order can be adjusted to set the network card as the first boot item. Then, the network card can be enabled and polled, thus achieving a loop startup of this single boot type. This avoids the possibility of booting the wrong hard drive or other boot devices into the wrong operating system due to network card startup failure. However, each network card can connect to the network via a network cable to boot different operating systems. To disable the boot entries corresponding to certain network cards, one can disable the network card itself, thus turning off the network card boot device. However, this method has a drawback: the current BIOS menu only provides on / off options for SATA (Serial Advanced Technology Attachment) hard drives and network card boot devices. This allows for the control of individual devices of these two types, removing them from the boot list. However, there are no corresponding disabling options for other boot devices such as NVMe (Non-Volatile Memory Host Controller Interface Specification) drives, optical drives, or USB boot devices. This means it's impossible to control the enabling and disabling of NVMe drives, optical drives, and other boot devices. While this satisfies most scenarios, it still has limitations in certain specific situations. Manually uninstalling these devices increases labor costs and poses certain security risks.

[0005] In summary, how to solve the problem of not being able to disable optical drives, disk devices, and other types of boot devices independently is a problem that still needs further research in this field. Summary of the Invention

[0006] In view of this, the purpose of this application is to provide a method, apparatus, device, and storage medium for disabling boot items, capable of disabling boot items on various types of boot devices, meeting more diverse boot item disabling scenarios, avoiding entry into incorrect operating systems, and saving manpower and time costs. The specific solution is as follows:

[0007] Firstly, this application discloses a method for disabling startup items, including:

[0008] When a startup item disable request is received, a disabled startup item list is created under the settings menu of the basic input / output system, and all initialized startup items in the pre-created target startup item list are displayed in the disabled startup item list; the target startup item list is a list created based on the startup items corresponding to all devices that can boot the server system.

[0009] Based on the startup item disable request, determine all startup devices to be disabled, and obtain the devices to be disabled;

[0010] Mark all the initialization startup items displayed in the list of disabled startup items that correspond to the device to be disabled, and then disable the startup items after obtaining the marks;

[0011] Retrieve the target startup item list and delete the initialized startup item corresponding to the disabled startup item marked in the target startup item list to obtain the deleted startup item list;

[0012] The startup items under the current settings menu are updated to display the startup items in the deleted startup item list, and all startup items in the deleted startup item list are enabled to disable the startup items corresponding to the device to be disabled.

[0013] Optionally, the startup item disabling method further includes:

[0014] Once the platform firmware initialization is detected, the boot manager component based on the unified extensible firmware interface specification detects all devices that can boot the server system and obtains multiple target boot devices.

[0015] The loading option structure of the startup item corresponding to each target startup device is initialized to obtain the initialized startup item, and all the initialized startup items are saved to the context menu structure.

[0016] Create a startup item list under the settings menu of the basic input / output system to obtain a target startup item list, and add all the initialized startup items in the context menu structure to the target startup item list.

[0017] Optionally, the initialization of the loading option structure for each boot item corresponding to the target boot device to obtain the initialized boot item includes:

[0018] Each target boot device is sequentially marked to obtain a marked boot item, and the feature information and hardware address of the target boot device corresponding to each marked boot item are recorded to obtain an initialized boot item.

[0019] Optionally, the step of sequentially marking the startup item corresponding to each target startup device to obtain the marked startup item includes:

[0020] Each target startup device is sequentially labeled with a serial number to obtain the serial number-labeled startup item;

[0021] The option type of each of the aforementioned numbered startup items is marked as a startup type to obtain the marked startup items.

[0022] Optionally, adding all the initialized launch items in the context menu structure to the target launch item list includes:

[0023] Add all the initialized startup items in the context menu structure to the device list located in the target startup item list;

[0024] Accordingly, displaying all initialized startup items from the pre-created target startup item list in the disabled startup item list includes:

[0025] The disabled startup list displays all initialized startup items in the device list located in the pre-created target startup list.

[0026] Optionally, saving all the initialized startup items to the context menu structure includes:

[0027] All the initialized startup items are stored in a context menu structure, and boolean variables are added to each of the initialized startup items in the context menu structure.

[0028] Accordingly, marking all the initialization-based startup items displayed in the disabled startup item list that correspond to the device to be disabled, and then disabling the marked startup items, includes:

[0029] Set the variable of all the initialized startup items corresponding to the device to be disabled in the list of disabled startup items to false, and then disable the startup items after obtaining the flag;

[0030] Accordingly, the step of retrieving the target startup item list and deleting the initialized startup item corresponding to the marked disabled startup item in the target startup item list to obtain the deleted startup item list includes:

[0031] The target boot item list is retrieved using a pre-created storage boot command function;

[0032] Identify the initialization-after-disabled startup item in the target startup item list based on the variable, and delete the initialization-after-disabled startup item corresponding to the marked startup item from the target startup item list.

[0033] Optionally, updating the startup items under the current settings menu to display the startup items in the deleted startup item list and enabling all startup items in the deleted startup item list to disable the startup items corresponding to the device to be disabled includes:

[0034] The startup items under the current settings menu are updated by updating the page function, so as to display the startup items in the list of deleted startup items;

[0035] During the startup process of the basic input / output system, the boot manager boot function based on the unified extensible firmware interface specification starts all the boot items in the deleted boot item list, so as to disable the boot item corresponding to the device to be disabled.

[0036] Secondly, this application discloses a startup item disabling device, comprising:

[0037] The list creation module is used to create a list of disabled startup items under the settings menu of the basic input / output system when a startup item disable request is received.

[0038] The startup item display module is used to display all initialized startup items from a pre-created target startup item list in the disabled startup item list; the target startup item list is a list created based on startup items corresponding to all devices capable of booting the server system.

[0039] The determination module is used to determine all startup devices to be disabled based on the startup item disable request, and obtain the devices to be disabled;

[0040] The startup item marking module is used to mark all the initialized startup items displayed in the disabled startup item list that correspond to the device to be disabled, and then disable the startup items after obtaining the markings;

[0041] The pull and delete module is used to pull the target startup item list and delete the initialized startup item corresponding to the disabled startup item marked after the target startup item list, so as to obtain the deleted startup item list;

[0042] The update and startup module is used to update the startup items under the current settings menu, so as to display the startup items in the deleted startup item list and start all startup items in the deleted startup item list, so as to disable the startup items corresponding to the device to be disabled.

[0043] Thirdly, this application discloses an electronic device, including a processor and a memory; wherein, when the processor executes a computer program stored in the memory, it implements the aforementioned startup item disabling method.

[0044] Fourthly, this application discloses a computer-readable storage medium for storing a computer program; wherein, when the computer program is executed by a processor, it implements the aforementioned startup item disabling method.

[0045] As can be seen, when this application receives a startup item disable request, it creates a disabled startup item list under the settings menu of the basic input / output system, and displays all initialized startup items from the pre-created target startup item list in the disabled startup item list. The target startup item list is a list created based on startup items corresponding to all devices capable of booting the server system. Then, based on the startup item disable request, all startup devices to be disabled are determined. Next, all initialized startup items corresponding to the devices to be disabled displayed in the disabled startup item list are marked to obtain marked disabled startup items. Then, the target startup item list is retrieved, and the initialized startup items corresponding to the marked disabled startup items in the target startup item list are deleted to obtain a deleted startup item list. Finally, the startup items under the current settings menu are updated to display the startup items in the deleted startup item list, and all startup items in the deleted startup item list are enabled to disable the startup items corresponding to the devices to be disabled. This application first creates a list of disabled startup items under the settings menu of the basic input / output system, and then removes the startup items corresponding to the devices to be disabled from the list of target startup items corresponding to all devices that can boot the server system. This enables the disabling of startup items for various types of startup devices, meets more diverse startup item disabling scenarios, avoids entering the wrong operating system, and saves manpower and time costs. Attached Figure Description

[0046] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of this application. For those skilled in the art, other drawings can be obtained based on the provided drawings without creative effort.

[0047] Figure 1 This is a flowchart of a startup item disabling method disclosed in this application;

[0048] Figure 2 This application discloses a specific method for disabling startup items.

[0049] Figure 3 This is a schematic diagram of a startup item disabling device disclosed in this application;

[0050] Figure 4 This is a structural diagram of an electronic device disclosed in this application. Detailed Implementation

[0051] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0052] This application discloses a method for disabling startup items. See also: Figure 1 As shown, the method includes:

[0053] Step S11: When a startup item disable request is received, a disabled startup item list is created under the settings menu of the basic input / output system, and all initialized startup items in the pre-created target startup item list are displayed in the disabled startup item list; the target startup item list is a list created based on the startup items corresponding to all devices that can boot the server system.

[0054] It should be noted that the boot item disabling scheme proposed in this application is applied to UEFI boot mode. When a boot item disabling request is obtained, a list is first created in the Setup menu of the Basic Input / Output System (i.e., BIOS) to record the boot items corresponding to the disabled devices, resulting in a list of disabled boot items (such as STR_DISABLE_BOOT_OPTIONS). Then, all initialized boot items in the target boot item list, which was created in advance based on the boot items corresponding to all devices capable of booting the server system, are displayed in the aforementioned list of disabled boot items.

[0055] It should be noted that, before creating the list of disabled boot items under the settings menu of the Basic Input / Output System, the process specifically includes: after detecting that the platform firmware initialization is complete, detecting all devices capable of booting the server system using a boot manager component based on the Unified Extensible Firmware Interface Specification to obtain multiple target boot devices; initializing the loading option structure of the boot item corresponding to each target boot device to obtain initialized boot items, and saving all initialized boot items to the context menu structure; creating a boot item list under the settings menu of the Basic Input / Output System to obtain a target boot item list, and adding all initialized boot items from the context menu structure to the target boot item list. In this embodiment, after the platform firmware initialization is detected, the boot manager component (UEFI BootManager) based on the Unified Extensible Firmware Interface (UEFI) specification first detects all devices capable of booting the server system, obtaining multiple target boot devices. These target boot devices include, but are not limited to, hard drive boot devices, network card boot devices, optical drive boot devices, and other types of devices, such as USB. Hard drive boot devices include, but are not limited to, SATA hard drives and NVMe drives. Network card boot devices include, but are not limited to, HBA (Host Bus Adapter) cards and RAID (Redundant Arrays of Independent Arrays) cards. Disks (disk arrays), cards, etc.; next, the boot entries corresponding to each of the above-mentioned target boot devices are traversed, and the load option structure (i.e., EFI_BOOT_MANAGER_LOAD_OPTION) of the boot entry corresponding to each of the above-mentioned target boot devices is initialized to obtain the corresponding initialized boot entries, and then all the above-mentioned initialized boot entries are saved to the context menu structure (i.e., BM_MENU_CTX); further, a list is created under the settings menu of the basic input / output system to record the boot entries corresponding to all boot devices on the current target server, to obtain the target boot entry list, and then all the above-mentioned initialized boot entries in the context menu structure (i.e., BM_MENU_CTX) are added to the target boot entry list.

[0056] Specifically, the initialization of the load option structure for each boot entry corresponding to the target boot device to obtain the initialized boot entry may include: sequentially marking each boot entry corresponding to the target boot device to obtain marked boot entries, and recording the characteristic information and hardware address of the target boot device corresponding to each marked boot entry to obtain the initialized boot entry. It should be noted that the load option structure (i.e., EFI_BOOT_MANAGER_LOAD_OPTION) contains multiple objects, such as OptionNumber, OptionType, FilePath, and Description. Initializing the load option structure involves performing corresponding initialization operations on each object within it. For example, sequentially marking each boot entry corresponding to the target boot device capable of booting the server system to obtain marked boot entries, such as filling the "OptionNumber" with a sequence number to mark each boot entry, and recording the characteristic information and hardware address of the target boot device corresponding to each marked boot entry to obtain the initialized boot entry.

[0057] In one specific implementation, the step of sequentially marking the startup items corresponding to each target boot device to obtain marked startup items may specifically include: sequentially marking the startup items corresponding to each target boot device by serial number to obtain serial number-marked startup items; and marking the option type of each serial number-marked startup item as a startup type to obtain marked startup items. For example, each startup item can be numbered and the serial number can be filled into "OptionNumber" to mark each startup item, and the path of the boot device can be filled into "FilePath" to record the startup items corresponding to the boot device. In addition, detailed description information of each startup item can be filled into "Description", such as model, manufacturer, etc.; furthermore, the type of each startup item can be filled into "OptionType" to distinguish whether the option is a startup item or a driver loading item, etc.

[0058] Specifically, adding all the initialized startup items in the context menu structure to the target startup item list may include: adding all the initialized startup items in the context menu structure to the device list located in the target startup item list. In this embodiment, all the initialized startup items in the context menu structure (BM_MENU_CTX) can be saved to the device list (i.e., BM_BOOT_DEV_ITEM) located in the target startup item list.

[0059] Accordingly, displaying all initialized boot items from the pre-created target boot item list in the disabled boot item list may specifically include: displaying all initialized boot items in the device list located in the pre-created target boot item list in the disabled boot item list. That is, the disabled boot item list displays all initialized boot items located in the device list (i.e., BM_BOOT_DEV_ITEM) of the aforementioned target boot item list.

[0060] In one specific embodiment, saving all the initialized startup items to the context menu structure may specifically include: storing all the initialized startup items to the context menu structure, and adding a Boolean variable to each initialized startup item in the context menu structure. In this embodiment, after storing all the initialized startup items to the context menu structure (BM_MENU_CTX), a Boolean (BOOL) variable A is added to each initialized startup item in the context menu structure (BM_MENU_CTX).

[0061] Step S12: Determine all startup devices to be disabled based on the startup item disable request, and obtain the devices to be disabled.

[0062] In this embodiment, after displaying all initialized startup items in the pre-created target startup item list in the disabled startup item list, further, all startup devices to be disabled are determined according to the startup item disabling request, and the corresponding devices to be disabled are obtained; wherein, the number of devices to be disabled can be one or more.

[0063] Step S13: Mark all the initialization startup items displayed in the list of disabled startup items that correspond to the device to be disabled, and then disable the startup items after obtaining the marks.

[0064] Furthermore, all the initialization startup items displayed in the list of disabled startup items that correspond to the aforementioned device to be disabled are searched, and then these found startup items are marked to obtain the marked disabled startup items.

[0065] In one specific embodiment, marking all the initialized startup items corresponding to the device to be disabled in the disabled startup item list, and then disabling the marked startup items, may specifically include: setting the variable of all the initialized startup items corresponding to the device to be disabled in the disabled startup item list to false, and then disabling the marked startup items. In this embodiment, the variable of all the initialized startup items corresponding to the device to be disabled in the disabled startup item list can be set to false (i.e., FALSE) to obtain the corresponding marked startup items, while other unmarked initialized startup items are defaulted to true (i.e., TRUE).

[0066] Step S14: Retrieve the target startup item list and delete the initialization startup item corresponding to the marked disabled startup item in the target startup item list to obtain the deleted startup item list.

[0067] In this embodiment, after marking all the initialization startup items corresponding to the device to be disabled displayed in the disabled startup item list to obtain marked disabled startup items, the target startup item list is first retrieved, and then the initialization startup items corresponding to the marked disabled startup items (i.e. startup items with the FALSE mark) in the target startup item list are deleted, thereby obtaining the deleted startup item list.

[0068] Specifically, retrieving the target boot item list and deleting the initialized boot items corresponding to the marked disabled boot items in the target boot item list to obtain a deleted boot item list may include: retrieving the target boot item list through a pre-created stored boot command function; identifying the initialized boot items corresponding to the marked disabled boot items in the target boot item list according to the variable, and deleting the initialized boot items corresponding to the marked disabled boot items from the target boot item list. In this embodiment, the target boot item list can be retrieved through a pre-created RestoreBootOrder function (stored boot function), then the initialized boot items corresponding to the marked disabled boot items in the target boot item list can be identified according to the above variable A, and then the initialized boot items corresponding to the marked disabled boot items can be deleted from the target boot item list.

[0069] Step S15: Update the startup items under the current settings menu to display the startup items in the deleted startup item list, and enable all startup items in the deleted startup item list to disable the startup items corresponding to the device to be disabled.

[0070] In this embodiment, after deleting the initialization boot item corresponding to the marked disabled boot item in the target boot item list, the boot list displayed under Setup settings can be updated to more intuitively reflect the change in boot items, thereby displaying the boot items in the deleted boot item list. Then, during the BIOS boot process, all boot items in the deleted boot item list are started to complete the operating system boot process, thereby disabling the boot item corresponding to the device to be disabled.

[0071] As can be seen, in this embodiment, when a startup item disable request is received, a disable startup item list is created under the settings menu of the basic input / output system, and all initialized startup items in the pre-created target startup item list are displayed in the disable startup item list. The target startup item list is a list created based on startup items corresponding to all devices capable of booting the server system. Then, based on the startup item disable request, all startup devices to be disabled are determined to obtain the devices to be disabled. Next, all initialized startup items corresponding to the devices to be disabled displayed in the disable startup item list are marked to obtain marked disable startup items. Then, the target startup item list is retrieved, and the initialized startup items corresponding to the marked disable startup items in the target startup item list are deleted to obtain a deleted startup item list. Finally, the startup items under the current settings menu are updated to display the startup items in the deleted startup item list, and all startup items in the deleted startup item list are enabled to disable the startup items corresponding to the devices to be disabled. In this embodiment, a list of disabled startup items is first created under the settings menu of the basic input / output system. Then, the startup items corresponding to the devices to be disabled in the list of disabled startup items are deleted from the target startup item list of all devices that can boot the server system. This enables the disabling of startup items for various types of startup devices, meets more diverse startup item disabling scenarios, avoids entering the wrong operating system, and saves manpower and time costs.

[0072] This application discloses a specific method for disabling startup items. See [link to relevant documentation]. Figure 2 As shown, the method includes:

[0073] Step S21: When a startup item disable request is received, a disabled startup item list is created under the settings menu of the basic input / output system, and all initialized startup items in the pre-created target startup item list are displayed in the disabled startup item list; the target startup item list is a list created based on the startup items corresponding to all devices that can boot the server system.

[0074] Step S22: Determine all startup devices to be disabled based on the startup item disable request, and obtain the devices to be disabled.

[0075] Step S23: Mark all the initialization startup items displayed in the list of disabled startup items that correspond to the device to be disabled, and then disable the startup items after obtaining the marks.

[0076] Step S24: Retrieve the target startup item list and delete the initialization startup item corresponding to the marked disabled startup item in the target startup item list to obtain the deleted startup item list.

[0077] Step S25: Update the startup items under the current settings menu using the update page function to display the startup items in the deleted startup item list.

[0078] In this embodiment, the startup items under the current settings menu (Setup) can be updated using the UpdatePages function, thereby displaying the startup items in the deleted startup item list.

[0079] Step S26: During the startup process of the basic input / output system, all startup items in the deleted startup item list are started through the boot manager boot function based on the unified extensible firmware interface specification, so as to disable the startup item corresponding to the device to be disabled.

[0080] In this embodiment, during the startup process of the basic input / output system, all startup items in the deleted startup item list can be started through the boot manager boot function (i.e., the EfiBootManagerBootFunc function) based on the unified extensible firmware interface specification, thereby disabling the startup items corresponding to the devices to be disabled.

[0081] For more detailed processing procedures of steps S21 to S24, please refer to the relevant content disclosed in the foregoing embodiments, which will not be repeated here.

[0082] As can be seen, this application embodiment creates a new menu window based on all detected startup items to set the startup items that need to be disabled, and disables them individually as needed. It does not need to target a single type of startup device. As long as the startup device is listed in the startup list, the startup items can be deleted through the newly added disable window, and the remaining startup items that need to be used are retained. This avoids potential risks during use, avoids large-scale physical manual changes to hardware status, can meet more diverse startup item disabling scenarios, and solves the current problem that it is not possible to disable optical drive disk devices and other startup device types individually.

[0083] Accordingly, this application also discloses a startup item disabling device, see [link to relevant documentation]. Figure 3As shown, the device includes:

[0084] The list creation module 11 is used to create a list of disabled startup items under the settings menu of the basic input / output system when a startup item disable request is received.

[0085] The startup item display module 12 is used to display all initialized startup items from a pre-created target startup item list in the disabled startup item list; the target startup item list is a list created based on startup items corresponding to all devices capable of booting the server system.

[0086] The determination module 13 is used to determine all startup devices to be disabled based on the startup item disable request, and obtain the devices to be disabled;

[0087] The startup item marking module 14 is used to mark all the initialized startup items displayed in the disabled startup item list that correspond to the device to be disabled, and then disable the startup items after obtaining the markings.

[0088] The pull and delete module 15 is used to pull the target startup item list and delete the initialized startup item corresponding to the disabled startup item marked after the target startup item list, so as to obtain the deleted startup item list;

[0089] The update and startup module 16 is used to update the startup items under the current settings menu, so as to display the startup items in the deleted startup item list and start all startup items in the deleted startup item list, so as to disable the startup items corresponding to the device to be disabled.

[0090] The specific workflow of each of the above modules can be found in the relevant content disclosed in the foregoing embodiments, and will not be repeated here.

[0091] As can be seen, in this embodiment, when a startup item disable request is received, a disable startup item list is created under the settings menu of the basic input / output system, and all initialized startup items in the pre-created target startup item list are displayed in the disable startup item list. The target startup item list is a list created based on startup items corresponding to all devices capable of booting the server system. Then, based on the startup item disable request, all startup devices to be disabled are determined to obtain the devices to be disabled. Next, all initialized startup items corresponding to the devices to be disabled displayed in the disable startup item list are marked to obtain marked disable startup items. Then, the target startup item list is retrieved, and the initialized startup items corresponding to the marked disable startup items in the target startup item list are deleted to obtain a deleted startup item list. Finally, the startup items under the current settings menu are updated to display the startup items in the deleted startup item list, and all startup items in the deleted startup item list are enabled to disable the startup items corresponding to the devices to be disabled. In this embodiment, a list of disabled startup items is first created under the settings menu of the basic input / output system. Then, the startup items corresponding to the devices to be disabled in the list of disabled startup items are deleted from the target startup item list of all devices that can boot the server system. This enables the disabling of startup items for various types of startup devices, meets more diverse startup item disabling scenarios, avoids entering the wrong operating system, and saves manpower and time costs.

[0092] In some specific embodiments, the startup item disabling device may further include:

[0093] The device detection unit is used to detect all devices that can boot the server system after the platform firmware initialization is completed, and obtain multiple target boot devices by using the boot manager component based on the unified extensible firmware interface specification.

[0094] An initialization unit is used to initialize the loading option structure of the startup item corresponding to each of the target startup devices to obtain the initialized startup item;

[0095] The startup item saving unit is used to save all the initialized startup items to the context menu structure;

[0096] The list creation unit is used to create a list of startup items under the settings menu of the basic input / output system, and obtain the target list of startup items;

[0097] The first adding unit is used to add all the initialized startup items in the context menu structure to the target startup item list.

[0098] In some specific embodiments, the initialization unit may specifically include:

[0099] The first startup item marking unit is used to mark the startup item corresponding to each target startup device in sequence to obtain the marked startup item;

[0100] An information recording unit is used to record the feature information and hardware address of the target startup device corresponding to each of the marked startup items, so as to obtain the initialized startup items.

[0101] In some specific embodiments, the first startup item marking unit may specifically include:

[0102] The second startup item marking unit is used to mark the startup item corresponding to each target startup device in sequence by serial number to obtain the serial number marked startup item;

[0103] The startup type marking unit is used to mark the option type of each of the numbered startup items as a startup type, thereby obtaining the marked startup items.

[0104] In some specific embodiments, the first adding unit may specifically include:

[0105] The second adding unit is used to add all the initialized startup items in the context menu structure to the device chain list located in the target startup item list;

[0106] Accordingly, the startup item display module 12 may specifically include:

[0107] A startup item display unit is used to display all initialized startup items in the device linked list of a pre-created target startup item list in the disabled startup item list.

[0108] In some specific embodiments, the startup item storage unit may specifically include:

[0109] A startup item storage unit is used to store all the initialized startup items into a context menu structure;

[0110] A variable addition unit is used to add boolean type variables to each of the initialized startup items in the context menu structure;

[0111] Accordingly, the startup item marking module 14 may specifically include:

[0112] The setting unit is used to set the variable of all the initialized startup items corresponding to the device to be disabled in the list of disabled startup items to false, and then disable the startup items after obtaining the mark;

[0113] Accordingly, the pull and delete module 15 may specifically include:

[0114] A pull unit is used to pull the target boot item list through a pre-created storage boot command function;

[0115] A startup item identification unit is configured to identify, based on the variable, the initialized startup item corresponding to the marked disabled startup item in the target startup item list;

[0116] The startup item deletion unit is used to delete the initialized startup item corresponding to the marked disabled startup item from the target startup item list.

[0117] In some specific embodiments, the update and startup module 16 may specifically include:

[0118] The startup item update unit is used to update the startup items under the current settings menu through the update page function, so as to display the startup items in the deleted startup item list;

[0119] The startup item startup unit is used to start all startup items in the deleted startup item list through the boot manager boot function based on the Unified Extensible Firmware Interface Specification during the startup process of the basic input / output system, so as to disable the startup item corresponding to the device to be disabled.

[0120] Furthermore, embodiments of this application also disclose an electronic device, Figure 4 This is a structural diagram of an electronic device 20 according to an exemplary embodiment. The content of the diagram should not be construed as limiting the scope of this application.

[0121] Figure 4 This is a schematic diagram of the structure of an electronic device 20 provided in an embodiment of this application. Specifically, the electronic device 20 may include: at least one processor 21, at least one memory 22, a power supply 23, a communication interface 24, an input / output interface 25, and a communication bus 26. The memory 22 stores a computer program, which is loaded and executed by the processor 21 to implement the relevant steps in the startup item disabling method disclosed in any of the foregoing embodiments. Furthermore, the electronic device 20 in this embodiment may specifically be an electronic computer.

[0122] In this embodiment, the power supply 23 is used to provide operating voltage for each hardware device on the electronic device 20; the communication interface 24 can create a data transmission channel between the electronic device 20 and external devices, and the communication protocol it follows can be any communication protocol applicable to the technical solution of this application, and is not specifically limited here; the input / output interface 25 is used to acquire external input data or output data to the outside world, and its specific interface type can be selected according to specific application needs, and is not specifically limited here.

[0123] In addition, the memory 22, as a carrier for resource storage, can be a read-only memory, random access memory, disk or optical disk, etc. The resources stored thereon can include operating system 221, computer program 222, etc., and the storage method can be temporary storage or permanent storage.

[0124] The operating system 221 is used to manage and control the various hardware devices on the electronic device 20 and the computer program 222, which may be Windows Server, Netware, Unix, Linux, etc. In addition to including a computer program capable of performing the startup item disabling method disclosed in any of the foregoing embodiments, the computer program 222 may further include a computer program capable of performing other specific tasks.

[0125] Furthermore, this application also discloses a computer-readable storage medium for storing a computer program; wherein, when the computer program is executed by a processor, it implements the aforementioned startup item disabling method. The specific steps of this method can be found in the corresponding content disclosed in the foregoing embodiments, and will not be repeated here.

[0126] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on its differences from other embodiments. Similar or identical parts between embodiments can be referred to interchangeably. For the apparatus disclosed in the embodiments, since it corresponds to the method disclosed in the embodiments, the description is relatively simple; relevant parts can be referred to in the method section.

[0127] Those skilled in the art will further recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0128] The steps of the methods or algorithms described in conjunction with the embodiments disclosed herein can be implemented directly by hardware, a software module executed by a processor, or a combination of both. The software module can be located in random access memory (RAM), main memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, removable disk, CD-ROM, or any other form of storage medium known in the art.

[0129] Finally, it should be noted that in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

[0130] The above provides a detailed description of a startup item disabling method, apparatus, device, and storage medium provided in this application. Specific examples have been used to illustrate the principles and implementation methods of this application. The descriptions of the above embodiments are only for the purpose of helping to understand the method and core ideas of this application. At the same time, for those skilled in the art, there will be changes in the specific implementation methods and application scope based on the ideas of this application. Therefore, the content of this specification should not be construed as a limitation of this application.

Claims

1. A method of disabling a startup item, characterized by, include: When a startup item disable request is received, a startup item disable list is created under the settings menu of the basic input / output system, and all initialized startup items in the pre-created target startup item list are displayed in the startup item disable list; The target boot item list is a list created based on the boot items corresponding to all devices that can boot the server system. Based on the startup item disable request, determine all startup devices to be disabled, and obtain the devices to be disabled; Mark all the initialization startup items displayed in the list of disabled startup items that correspond to the device to be disabled, and then disable the startup items after obtaining the marks; Retrieve the target startup item list and delete the initialized startup item corresponding to the disabled startup item marked in the target startup item list to obtain the deleted startup item list; The startup items under the current settings menu are updated to display the startup items in the deleted startup item list, and all startup items in the deleted startup item list are enabled to disable the startup items corresponding to the device to be disabled. The method further includes: when the platform firmware initialization is detected to be complete, detecting all devices capable of booting the server system through a boot manager component based on the Unified Extensible Firmware Interface Specification to obtain multiple target boot devices; initializing the loading option structure of the boot item corresponding to each target boot device to obtain an initialized boot item, and saving all the initialized boot items to a context menu structure; creating a boot item list under the settings menu of the basic input / output system to obtain a target boot item list, and adding all the initialized boot items in the context menu structure to the target boot item list; The step of initializing the loading option structure of the startup item corresponding to each target startup device to obtain the initialized startup item includes: sequentially marking the startup item corresponding to each target startup device to obtain the marked startup item, and recording the feature information and hardware address of the target startup device corresponding to each marked startup item to obtain the initialized startup item; The step of sequentially marking the startup item corresponding to each target startup device to obtain the marked startup item includes: sequentially marking the startup item corresponding to each target startup device by serial number to obtain serial number marked startup items; and marking the option type of each serial number marked startup item as a startup type to obtain the marked startup item.

2. The startup item disabling method according to Claim 1, wherein Adding all the initialized launch items in the context menu structure to the target launch item list includes: Add all the initialized startup items in the context menu structure to the device list located in the target startup item list; Accordingly, displaying all initialized startup items from the pre-created target startup item list in the disabled startup item list includes: The list of disabled startup items displays all initialized startup items in the device list located in the pre-created list of target startup items.

3. The startup item disabling method according to Claim 1, wherein The step of saving all the initialized startup items to the context menu structure includes: All the initialized startup items are stored in a context menu structure, and boolean variables are added to each of the initialized startup items in the context menu structure. Accordingly, marking all the initialization-based startup items displayed in the disabled startup item list that correspond to the device to be disabled, and then disabling the marked startup items, includes: Set the variable of all the initialized startup items corresponding to the device to be disabled in the list of disabled startup items to false, and then disable the startup items after obtaining the flag; Accordingly, the step of retrieving the target startup item list and deleting the initialized startup item corresponding to the marked disabled startup item in the target startup item list to obtain the deleted startup item list includes: The target boot item list is retrieved using a pre-created storage boot command function; Identify the initialization-after-disabled startup item in the target startup item list based on the variable, and delete the initialization-after-disabled startup item corresponding to the marked startup item from the target startup item list.

4. The startup item disabling method according to any one of claims 1 to 3, characterized by, The step of updating the startup items under the current settings menu to display the startup items in the deleted startup item list and enabling all startup items in the deleted startup item list to disable the startup items corresponding to the device to be disabled includes: The startup items under the current settings menu are updated by updating the page function, so as to display the startup items in the list of deleted startup items; During the startup process of the basic input / output system, the boot manager boot function based on the unified extensible firmware interface specification starts all the boot items in the deleted boot item list, so as to disable the boot item corresponding to the device to be disabled.

5. A boot item disabling apparatus characterized by comprising: include: The list creation module is used to create a list of disabled startup items under the settings menu of the basic input / output system when a startup item disable request is received. A startup item display module is used to display all initialized startup items from a pre-created target startup item list in the disabled startup item list; The target boot item list is a list created based on the boot items corresponding to all devices that can boot the server system. The determination module is used to determine all startup devices to be disabled based on the startup item disable request, and obtain the devices to be disabled; The startup item marking module is used to mark all the initialized startup items displayed in the disabled startup item list that correspond to the device to be disabled, and then disable the startup items after obtaining the markings; The pull and delete module is used to pull the target startup item list and delete the initialized startup item corresponding to the disabled startup item marked after the target startup item list, so as to obtain the deleted startup item list; The update and startup module is used to update the startup items under the current settings menu, so as to display the startup items in the deleted startup item list and start all startup items in the deleted startup item list, so as to disable the startup items corresponding to the device to be disabled. The device is further configured to, upon detecting that the platform firmware initialization is complete, detect all devices capable of booting the server system using a boot manager component based on the unified extensible firmware interface specification, and obtain multiple target boot devices; initialize the loading option structure of the boot item corresponding to each target boot device to obtain the initialized boot item, and save all the initialized boot items to the context menu structure; Create a startup item list under the settings menu of the basic input / output system to obtain a target startup item list, and add all the initialized startup items in the context menu structure to the target startup item list; The device is further configured to sequentially mark the startup item corresponding to each target startup device to obtain the marked startup item, and record the feature information and hardware address of the target startup device corresponding to each marked startup item to obtain the initialized startup item; The device is further configured to sequentially mark the startup item corresponding to each target startup device by serial number to obtain serial number-marked startup items; and to mark the option type of each serial number-marked startup item as a startup type to obtain marked startup items.

6. An electronic device, comprising: It includes a processor and a memory; wherein, when the processor executes a computer program stored in the memory, it implements the startup item disabling method as described in any one of claims 1 to 4.

7. A computer-readable storage medium, characterized in that, Used to store computer programs; wherein, when the computer programs are executed by a processor, they implement the startup item disabling method as described in any one of claims 1 to 4.

Citation Information

Patent Citations

  • Processing method and device for starting items

    CN104573497A

  • Server BIOS startup item sequence sorting method and medium

    CN112905252A