A method and apparatus for setting a page identification picture of a baseboard management controller
Patent Information
- Application Number
- CN202410361546.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-03-27
- Publication Date
- 2026-08-18
- Estimated Expiration
- 2044-03-27
AI Technical Summary
[0003]现有技术方案在通过IPMI(智能平台管理接口命令)命令和Web页面设置BMC的web首页logo时存在明显的限制,无论是通过IPMI命令还是通过Web页面上传logo,都要求重启BMC才能生效,这是由于BMC在显示页面logo时采用的显示方式为软链接方式,软链接方式直接指向需要显示的图片所存储的文件中,这导致了每次更改logo图片,需要重新启动BMC才能显示替换后的图片,在需要频繁更换logo的场景下,每次更换都涉及到重启过程,可能会对服务器的正常运营造成影响,从IPMI命令设置logo模式切换到Web上传logo模式也需要重启BMC才能生效,产生极大的不便,影响服务器的运行和BMC管理人员的操作
[0030] This invention can retain the user-set identifier image when restoring the board management controller to factory settings. Whether the image is uploaded through the intelligent platform management interface command or obtained from a preset location, the target identifier image in the second image file storage unit corresponding to the second preset directory is copied to a temporary directory, and then copied back to the original second preset directory after restoring factory settings. This ensures that the user-set image is not lost and avoids the user having to reset the identifier image after restoring the board management controller to factory settings, thus improving the convenience of image setting.
Smart Images

Figure CN118445505B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of BMC (Baseboard Management Controller) technology, and specifically to a method and apparatus for setting page identifier images in a baseboard management controller. Background Technology
[0002] With the increasing number of servers owned by businesses, government departments, and individuals, and used for various purposes including scientific research, military, and commercial applications, web pages are essential for all servers. The logo on the BMC (Baseboard Management Controller) web homepage will vary depending on the user and the company.
[0003] Existing technical solutions have significant limitations when setting the BMC web homepage logo via IPMI (Intelligent Platform Management Interface) commands and web pages. Whether uploading the logo via IPMI commands or web pages, a BMC restart is required for the changes to take effect. This is because BMC uses symbolic links to display the logo, directly pointing to the file where the image to be displayed is stored. This means that every time the logo image is changed, a BMC restart is necessary to display the new image. In scenarios where logo changes are frequent, each change involves a restart, potentially impacting normal server operation. Switching from setting the logo via IPMI commands to uploading it via web also requires a BMC restart, causing significant inconvenience and affecting server performance and BMC administrator operations. Summary of the Invention
[0004] In view of this, the present invention provides a method, apparatus, device, medium and program product for setting the page logo image of a Baseboard Management Controller (BMC) to solve the problem of how to efficiently set the homepage logo image.
[0005] In a first aspect, the present invention provides a method for setting an identifier image on a substrate management controller page, the method comprising: obtaining an identifier image upload instruction triggered on the substrate management controller page, and determining the type of the identifier image upload instruction;
[0006] If the image upload command is a smart platform management interface command, then extract the target identifier information from the smart platform management interface command;
[0007] Based on the target identification information, check whether the first image file storage unit corresponding to the first preset directory stores a target identification image that corresponds to the target identification information;
[0008] When it is determined that the target identifier image is not stored in the first image file storage unit, the image information in the electrically erasable programmable read-only memory is searched to obtain the target identifier image. The image information includes: multiple different identifier images, and identifier information corresponding to each of the multiple different identifier images.
[0009] The target identification image is stored in the second image file storage unit corresponding to the second preset directory; and the name prefix of the target identification image is renamed to the first preset identification name, so that after the substrate management controller page is refreshed and the preset page source code is run, the substrate management controller page displays the target identification image. The rule of the identification image display logic code in the preset page source code is set to display the identification image in the second image file storage unit whose name prefix is the first preset identification name.
[0010] In this embodiment of the invention, when uploading a new identifier image based on the intelligent platform management interface command, the system searches for images and determines whether there are any images already uploaded using other commands in the first preset directory. If not, the identifier image is re-stored in the second preset directory, and its name prefix is changed to the first preset identifier name. Since the preset page source code has already specified the display logic as displaying images with the first preset identifier name prefix, the new identifier image can be directly displayed. Furthermore, since the source code execution rules specify that images with the first preset identifier name prefix should be displayed, identifier images of any name suffix can be displayed without restriction on the format of the identifier image. In contrast, the image display function of the web page of the substrate management controller in related technologies is displayed in the form of soft links. The soft links need to be re-established when the substrate management controller is restarted to update the display content. Soft links can only be set to identifier images corresponding to the format with the .png suffix. However, this invention directly operates on the uploaded image in the file, changing the actual storage location and name of the file. The identifier image display logic code rules in the preset page source code enable the substrate management controller page to flexibly and dynamically display the renamed new identifier image in the second image file storage unit. Therefore, updates can be performed without restarting, reducing user waiting time and the number of restarts. This avoids the security risks caused by frequent restarts of the baseboard management controller and enables efficient replacement of the baseboard management controller's homepage logo image.
[0011] In one optional implementation, multiple different identification images and identification information corresponding to each of the multiple different identification images are stored in a third image file storage unit corresponding to a third preset directory under an electrically erasable programmable read-only memory.
[0012] In this embodiment of the invention, a dedicated directory is set up in the electrically erasable programmable read-only memory to store the identification images, ensuring that the board management controller page can quickly respond and display the correct identification images. It also stores multiple different identification images and the identification information corresponding to each of the multiple different identification images, thereby providing a data foundation for finding the corresponding identification image based on the target identification information.
[0013] In one alternative implementation, the method further includes:
[0014] When it is determined that the target identification image has been stored in the first image file storage unit, the target identification information is extracted from the intelligent platform management interface instruction and stored in the third image file storage unit corresponding to the third preset directory under the electrically erasable programmable read-only memory.
[0015] In this embodiment of the invention, the target identification information is stored in the third image file storage unit corresponding to the third preset directory under EEPROM (Electrically Erasable Programmable Read-Only Memory). If the identification image on the BMC homepage fails to display in subsequent steps, alternative identification images can be searched again based on the target identification information, thus avoiding repeated uploading.
[0016] In one alternative implementation, the method further includes:
[0017] If the image upload instruction is for an image obtained from a preset location;
[0018] After renaming the prefix of the identifier image to the second preset identifier name, it is stored in the first image file storage unit;
[0019] The identifier image is copied from the first image file storage unit to the second image file storage unit as the target identifier image, and the second preset identifier name is changed to the first preset identifier name. After the substrate management controller page refreshes and runs the preset page source code, the substrate management controller page displays the target identifier image.
[0020] In this embodiment of the invention, the instruction to obtain the identification image from a preset location can be used to rename the name prefix of the identification image to a second preset identification name and store it in the first image file storage unit. The identification image can then be copied to the second image file storage unit and renamed again. This ensures that the renamed image is compatible with the page source code operation rules, without needing to restart the backend service. The frontend page only needs to reload the new page source code, avoiding the need to restart the substrate management controller service and achieving efficient replacement of the homepage identification image of the substrate management controller.
[0021] In one optional implementation, the image obtained from the preset location includes: any identifier image stored in any disk file storage unit of the local server, or any identifier image obtained from the preset identifier image server based on the preset identifier image acquisition interface.
[0022] This invention provides embodiments that obtain different source images for identification through different preset locations. Images can be either locally stored or obtained from a dedicated identification image server, thus meeting the personalized identification image needs of different users and improving the user experience.
[0023] In one optional implementation, the process startup time corresponding to the electrically erasable programmable read-only memory is earlier than the process startup time corresponding to the baseboard management controller page, and the method further includes:
[0024] When the process corresponding to the baseboard management controller page is restarted, it is determined whether the target identification image stored in the second image file storage unit corresponding to the second preset directory is lost;
[0025] If the target identifier image stored in the second image file storage unit corresponding to the second preset directory has been lost, then determine whether the first image file storage unit corresponding to the first preset directory stores an identifier image with the name prefix of the second preset identifier name; if the first image file storage unit corresponding to the first preset directory has already stored an identifier image with the name prefix of the second preset identifier name, then copy the identifier image with the name prefix of the second preset identifier name to the second image file storage unit corresponding to the second preset directory as the target identifier image, and change the second preset identifier name to the first preset identifier name;
[0026] Alternatively, if the first image file storage unit corresponding to the first preset directory does not store an identifier image with the name prefix of the second preset identifier name, then based on the target identifier information, the image information in the third image file storage unit corresponding to the third preset directory under the electrically erasable programmable read-only memory is searched, the identifier image corresponding to the target identifier information is obtained, the identifier image corresponding to the target identifier information is copied to the second image file storage unit corresponding to the second preset directory as the target identifier image, and the name prefix of the target identifier image is renamed to the first preset identifier name.
[0027] This invention automatically detects whether a target identifier image is missing in the second preset directory. If a loss is detected, it first searches for the identifier image in the first preset directory. If the identifier image exists in the first preset directory, it is restored from the first preset directory. If the identifier image does not exist in the first preset directory, it uses the target identifier information to search for the image information in the third image file storage unit corresponding to the third preset directory under the electrically erasable programmable read-only memory (EEPROM), obtains the identifier image corresponding to the target identifier information, and then restores the identifier image. This ensures that the board management controller can correctly display the identifier image. Furthermore, by ensuring that the process corresponding to the EEPROM starts first, it can quickly search for the image information under the EEPROM when the target identifier image is found to be missing after the process corresponding to the board management controller page is restarted, without waiting for the delay caused by the process startup order, further improving the identifier image replacement speed.
[0028] In one alternative implementation, the method further includes:
[0029] Based on the script modification instructions, the board management controller factory reset control script is modified according to the preset script modification rules. The modified script is used to copy the target identifier image in the second image file storage unit corresponding to the second preset directory to the image file storage unit corresponding to the preset temporary directory when the board management controller is reset to factory settings. After the board management controller is reset to factory settings, the target identifier image stored in the image file storage unit corresponding to the preset temporary directory is copied back to the second image file storage unit corresponding to the second preset directory. The script also controls the deletion of the preset temporary directory and the image file storage unit corresponding to the preset temporary directory.
[0030] This invention can retain the user-set identifier image when restoring the board management controller to factory settings. Whether the image is uploaded through the intelligent platform management interface command or obtained from a preset location, the target identifier image in the second image file storage unit corresponding to the second preset directory is copied to a temporary directory, and then copied back to the original second preset directory after restoring factory settings. This ensures that the user-set image is not lost and avoids the user having to reset the identifier image after restoring the board management controller to factory settings, thus improving the convenience of image setting.
[0031] In one alternative implementation, the method further includes:
[0032] Add the first preset directory to the preset baseboard management controller firmware upgrade whitelist so that the baseboard management controller retains the information corresponding to the whitelist when upgrading and refreshing firmware information.
[0033] In this embodiment of the invention, the first preset directory is added to the firmware upgrade whitelist of the baseboard management controller. This ensures that the corresponding directory information is not lost when the firmware information is updated, further guaranteeing the preservation and recovery of the identification image, simplifying the user operation process, and improving the convenience of image settings.
[0034] In one optional implementation, the rule for the logic code of the identifier image display area in the preset page source code is set as follows:
[0035] The page displays a preset area frame. If the length of the target logo image is greater than the length set by the preset area frame, or the width of the target logo image is greater than the width set by the preset area frame, the length or width of the target logo image is scaled up by the same preset ratio until the length of the target logo image is less than or equal to the length set by the preset area frame, and the width of the target logo image is less than or equal to the width set by the preset area frame.
[0036] This invention, through its logic code rules for the display area of the identifier image, scales it according to a preset ratio. This maintains the aspect ratio of the image, ensuring that the identifier image displayed within the preset page display area fits the page size and preventing the image from exceeding the page's boundaries. Regardless of image size, it can be placed within the preset display area of the page, without limiting the size of the uploaded identifier image.
[0037] Secondly, the present invention provides a device for setting page identifier images of a substrate management controller, the device comprising:
[0038] The instruction type determination module is used to obtain the identifier image upload instruction triggered on the baseboard management controller page and determine the type of the identifier image upload instruction;
[0039] The identification information extraction module is used to extract target identification information from the intelligent platform management interface command if the identification image upload command is an intelligent platform management interface command;
[0040] The image identification search module is used to search, based on the target identification information, whether the first image file storage unit corresponding to the first preset directory stores a target identification image that corresponds to the target identification information.
[0041] The identification information determination module is used to search for image information in the electrically erasable programmable read-only memory and obtain the target identification image when it is determined that the first image file storage unit does not store the target identification image. The image information includes: multiple different identification images and identification information corresponding to each of the multiple different identification images.
[0042] The identification image display module is used to store the target identification image in the second image file storage unit corresponding to the second preset directory; and to rename the name prefix of the target identification image to the first preset identification name, so that after the substrate management controller page refreshes and runs the preset page source code, the substrate management controller page displays the target identification image. The rule of the identification image display logic code in the preset page source code is set to display the identification image in the second image file storage unit whose name prefix is the first preset identification name.
[0043] Thirdly, the present invention provides a computer device, including: a memory and a processor, the memory and the processor being communicatively connected to each other, the memory storing computer instructions, and the processor executing the computer instructions to perform the method for setting the baseboard management controller page identification image as described in the first aspect or any corresponding embodiment.
[0044] Fourthly, the present invention provides a computer-readable storage medium storing computer instructions for causing a computer to execute the method for setting the baseboard management controller page identifier image according to the first aspect or any corresponding embodiment described above.
[0045] Fifthly, the present invention provides a computer program product, including computer instructions for causing a computer to execute the method for setting the baseboard management controller page identifier image as described in the first aspect or any corresponding embodiment. Attached Figure Description
[0046] To more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the specific embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.
[0047] Figure 1 This is a flowchart illustrating a method for setting the page identifier image of a baseboard management controller according to an embodiment of the present invention;
[0048] Figure 2 This is a flowchart illustrating another method for setting a page identifier image for a baseboard management controller according to an embodiment of the present invention;
[0049] Figure 3 This is a flowchart illustrating another method for setting a page identifier image for a baseboard management controller according to an embodiment of the present invention;
[0050] Figure 4This is a flowchart illustrating another method for setting a page identifier image for a baseboard management controller according to an embodiment of the present invention;
[0051] Figure 5 This is a flowchart illustrating another method for setting a page identifier image for a baseboard management controller according to an embodiment of the present invention;
[0052] Figure 6 This is a flowchart illustrating another method for setting a page identifier image for a baseboard management controller according to an embodiment of the present invention;
[0053] Figure 7 This is a structural block diagram of a device for setting page identifier images of a baseboard management controller according to an embodiment of the present invention;
[0054] Figure 8 This is a schematic diagram of the hardware structure of a computer device according to an embodiment of the present invention. Detailed Implementation
[0055] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0056] In related technologies, the BMC (Baseboard Management Controller) itself uses symbolic links to display images. A symbolic link is essentially a reference to another file. When the BMC system starts, it loads the currently configured Logo (identity image) file. If the Logo is updated, whether via IPMI (Intelligent Platform Management Interface) or uploaded from a preset location, the file pointed to by the internal symbolic links has changed. However, the BMC lacks a mechanism for dynamically updating links; the configuration is only reloaded after a BMC restart. Furthermore, the BMC's storage capacity and processing capabilities only support PNG format and cannot upload images larger than 20KB. If switching from an IPMI command-set Logo to a Web-uploaded Logo, based on the principle of symbolic links, a BMC restart is also required for the changes to take effect.
[0057] The present invention provides a method for setting the identifier image on the BMC page, which is applied in server and data management scenarios where the identifier image needs to be frequently changed or the interface needs to be dynamically updated remotely. It can dynamically update the identifier image without restarting the BMC. By renaming the name prefix of the target identifier image and setting the display logic of the page source code, the new identifier image can be loaded with just a page refresh, avoiding restart and reducing loading time. This solves the problem that the BMC needs to be restarted when changing the identifier image in related methods.
[0058] According to an embodiment of the present invention, a method for setting a page identifier image of a baseboard management controller is provided. It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions. Furthermore, although a logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in a different order than that shown here.
[0059] This embodiment provides a method for setting the page identifier image of a baseboard management controller, which can be used in the aforementioned computer. Figure 1 This is a flowchart of a method for setting the page identifier image of a baseboard management controller according to an embodiment of the present invention, such as... Figure 1 As shown, the process includes the following steps:
[0060] Step S101: Obtain the identifier image upload instruction triggered on the substrate management controller page, and determine the type of identifier image upload instruction.
[0061] It's important to note that the Baseboard Management Controller (BMC) is a dedicated microcontroller on the server used to monitor and manage the server's operational status. The Baseboard Management Controller page is the web interface of the BMC, which users or administrators access via a web browser to remotely manage and configure the server's hardware. The image upload command refers to a command operation that allows users to upload specific image files (such as company logos) to the server for display on the BMC's web interface or other interfaces.
[0062] It is understandable that obtaining the identifier image upload command triggered on the baseboard management controller page is to identify the user-initiated operation of uploading identifier images, determine how the upload command was sent (e.g., IPMI command), and then determine how to implement subsequent steps to ensure that operations between different upload types do not conflict with each other.
[0063] Step S102: If the image upload instruction is a smart platform management interface command, then extract the target identification information from the smart platform management interface command.
[0064] It should be noted that the Intelligent Platform Management Interface (IPMI) command is a standard command that the BMC can receive. IPMI commands can be executed remotely over a network to perform operations such as obtaining server system status, controlling server system power, and updating server firmware. The Intelligent Platform Management Interface command includes a data section, which stores target identification information. This target identification information refers to different formatted identifiers used to identify or associate with a specific identifier image. The format can be a number or a key-value pair (e.g., target identification information is 001, 0x02, etc.) used to find the corresponding identifier image.
[0065] It is understandable that extracting the target identification information from the IPMI command is the basis for finding the corresponding identification image, and accurately extracting the target identification information can ensure that subsequent steps accurately find or update the correct identification image.
[0066] Step S103: Based on the target identification information, check whether the target identification image corresponding to the target identification information is stored in the first image file storage unit corresponding to the first preset directory.
[0067] It should be noted that the first preset directory refers to a specified directory preset on the server, and the storage unit under the first preset directory is used to store the uploaded identification image.
[0068] Understandably, determining whether a corresponding identifier image has already been uploaded is equivalent to deciding whether to retrieve an image from the backup storage. If a corresponding identifier image already exists in the first preset directory, there is no need for further searching, thus improving the efficiency of the identifier image update operation.
[0069] Step S104: When it is determined that the target identifier image is not stored in the first image file storage unit, search for the image information in the electrically erasable programmable read-only memory to obtain the target identifier image.
[0070] The image information includes: multiple different logo images, and the logo information corresponding to each of the multiple different logo images.
[0071] It should be noted that electrically erasable programmable read-only memory (EEPROM) is used to store identification images and their corresponding identification information. Multiple different identification images and their corresponding identification information refer to a series of identification images (such as different company logo images) and their respective identification information (number or key value). The identification images and identification information are in one-to-one correspondence.
[0072] Understandably, by storing the identifier image and its corresponding identifier information in the EEPROM, it can be ensured that the image can be retrieved from the EEPROM even if it cannot be found in the first preset directory.
[0073] Step S105: Store the target identifier image in the second image file storage unit corresponding to the second preset directory; and rename the name prefix of the target identifier image to the first preset identifier name, so that after the substrate management controller page refreshes and runs the preset page source code, the substrate management controller page displays the target identifier image.
[0074] The rule for displaying the identifier image in the preset page source code is set to display an identifier image whose name prefix is the first preset identifier name in the second image file storage unit.
[0075] It should be noted that the second preset directory refers to another designated directory on the server, which is different from the first preset directory. The image file storage unit under the second preset directory is used to store the target identifier image to be displayed on the BMC web page. The first preset identifier name refers to a specific file name prefix set for the target identifier image stored in the second preset directory.
[0076] Understandably, when a BMC web page needs to display a logo image, it will search for the image in the second preset directory according to the preset logic code. The prefix of the image file name will be set in the code logic rules to clearly indicate that this is the target logo image to be displayed on the web page.
[0077] For example, refer to Figure 2 The administrator sends an IPMI command via the IPMI tool to upload the logo from the BMC page. The IPMI command includes a data portion, such as 0x01, representing the logo identifier. This command is recognized as an IPMI command, and 0x01 is extracted as the target identifier. Based on the extracted identifier 0x01, the system checks if a corresponding image file exists in the preset directory / usr / share / webLogo. If a file named upload_logo.png exists, and if no image corresponding to 0x01 is found in the / usr / share / webLogo directory, the system checks if the corresponding image information is stored in the EEPROM. If there is a mapping between 0x01 and logo_1.jpg in the EEPROM, the specific identifier image to be used is known. The system finds logo_1.jpg, copies it to the second preset directory / web / logo, and renames it to web_logo.jpg. In this way, when the BMC web page is loaded or refreshed next time, the default page source code will display an image named web_logo.jpg, which is the newly set company logo, according to the settings.
[0078] In this embodiment of the invention, when uploading a new identifier image based on the intelligent platform management interface command, the system searches for images and determines whether there are any images already uploaded using other commands in the first preset directory. If not, the identifier image is re-stored in the second preset directory, and its name prefix is changed to the first preset identifier name. Since the preset page source code has already specified the display logic as displaying images with the first preset identifier name prefix, the new identifier image can be directly displayed. Furthermore, since the source code execution rules specify that images with the first preset identifier name prefix should be displayed, identifier images of any name suffix can be displayed without restriction on the format of the identifier image. In contrast, the image display function of the web page of the substrate management controller in related technologies is displayed in the form of soft links. The soft links need to be re-established when the substrate management controller is restarted to update the display content. Soft links can only be set to identifier images corresponding to the format with the .png suffix. However, this invention directly operates on the uploaded image in the file, changing the actual storage location and name of the file. The identifier image display logic code rules in the preset page source code enable the substrate management controller page to flexibly and dynamically display the renamed new identifier image in the second image file storage unit. Therefore, updates can be performed without restarting, reducing user waiting time and the number of restarts. This avoids the security risks caused by frequent restarts of the baseboard management controller and enables efficient replacement of the baseboard management controller's homepage logo image.
[0079] In one optional implementation, multiple different identification images and identification information corresponding to each of the multiple different identification images are stored in a third image file storage unit corresponding to a third preset directory under an electrically erasable programmable read-only memory.
[0080] Specifically, a set of identification information and its mapping relationship with the corresponding identification image files are predefined; a storage unit is created in the third preset directory under EEPROM to save the above mapping relationship; the storage unit is the third image file storage unit.
[0081] For example, the identification information consists of key values from 0x00 to 0x10, with corresponding identification image filenames such as logo1.png, logo2.png, etc. The mapping relationship is used to determine which identification image file the identification information corresponds to. The storage unit contains a data table, with each row of the data table corresponding to a mapping item. One column stores the identification information (e.g., 0x00), and the other column stores the corresponding image filename (e.g., logo1.png), which is placed in the / usr / share / www directory.
[0082] In this embodiment of the invention, a dedicated directory is set up in the electrically erasable programmable read-only memory to store the identification images, ensuring that the board management controller page can quickly respond and display the correct identification images. It also stores multiple different identification images and the identification information corresponding to each of the multiple different identification images, thereby providing a data foundation for finding the corresponding identification image based on the target identification information.
[0083] Specifically, the process involves searching for image information in an electrically erasable programmable read-only memory (EEPROM) to obtain the target identifier image, including:
[0084] A hash function is used to map a set of identifier information as keys and the corresponding identifier image files as values to a hash table. The target identifier information is then mapped to a lookup index using the hash function to retrieve the target identifier image corresponding to the target identifier information. Alternatively, an ordered linked list is constructed based on the identifier information and the corresponding identifier image. A preset number of lookup indexes are added to the ordered linked list, and the target identifier image corresponding to the target identifier information is retrieved by searching the preset number of lookup indexes based on the target identifier information.
[0085] Understandably, using a hash table to look up the target identifier image has lower time complexity, directly identifying the image corresponding to the target identifier information, resulting in a relatively fast lookup speed. Conversely, using an ordered list with multi-level indexes simplifies implementation, reduces development time, and also provides a relatively fast image lookup speed, maintaining high efficiency even with relatively small datasets. Utilizing both hash tables and ordered linked lists to search for target identifier images efficiently improves the response speed of the baseboard management controller page.
[0086] In one optional implementation, when it is determined that the target identifier image has been stored in the first image file storage unit, the target identifier information extracted from the intelligent platform management interface instruction is stored in the third image file storage unit corresponding to the third preset directory under the electrically erasable programmable read-only memory.
[0087] Understandably, when the target identifier image already exists in the first image file storage unit, the uploaded target identifier image is given priority as the displayed image, while the target identifier information set based on the IPMI command is used as a backup identifier information. If necessary (e.g., the target identifier image is accidentally deleted or misplaced), the system will revert to the EEPROM to find the target identifier image corresponding to the backup identifier information, thus preventing unnecessary duplicate uploads and saving storage space.
[0088] In this embodiment of the invention, the target identification information is stored in the third image file storage unit corresponding to the third preset directory under EEPROM (Electrically Erasable Programmable Read-Only Memory). If the identification image on the BMC homepage fails to display in subsequent steps, alternative identification images can be searched again based on the target identification information, thus avoiding repeated uploading.
[0089] This embodiment provides a method for setting the page identifier image of a baseboard management controller, which can be used in the aforementioned computer. Figure 3 This is a flowchart of a method for setting the page identifier image of a baseboard management controller according to an embodiment of the present invention, such as... Figure 3 As shown, the process includes the following steps:
[0090] Step S301: Obtain the identifier image upload command triggered on the substrate management controller page, and determine the type of the identifier image upload command. For details, please refer to [link to relevant documentation]. Figure 1 Step S101 of the illustrated embodiment will not be described again here.
[0091] Step S302: If the image upload instruction is an instruction for an image obtained from a preset location.
[0092] It should be noted that the instruction to obtain the identification image from the preset location refers to an operation instruction used to tell the system to obtain the identification image from a predefined location.
[0093] In one optional implementation, the image obtained from the preset location includes: any identifier image stored in any disk file storage unit of the local server, or any identifier image obtained from the preset identifier image server based on the preset identifier image acquisition interface.
[0094] It should be noted that the default identifier image server is a remote server that stores identifier images. The server itself is configured with an API or interface so that users can remotely view and download specific images.
[0095] For example, when setting up a preset logo image server, the server stores different versions of the company's logo and logo images of other organizations. The server provides an API to access and download logo images via a preset, fixed URL path. When the logo needs to be updated on the BMC interface, BMC sends a request to the preset logo image server, uses the API to obtain a list of currently available logos, selects a new logo from the list, downloads the logo image file using the API, and sets it as the interface logo image. If a new logo needs to be added, simply upload the new image file to the preset logo image server, and the image can be accessed and updated at any time via the API.
[0096] This invention provides embodiments that obtain different source images for identification through different preset locations. Images can be either locally stored or obtained from a dedicated identification image server, thus meeting the personalized identification image needs of different users and improving the user experience.
[0097] Step S303: Rename the prefix of the identifier image to the second preset identifier name and then store it in the first image file storage unit.
[0098] Understandably, the second preset identifier name is a temporary prefix name given to the image before it is moved from its original location to the first preset directory. This avoids conflicts with other files with the same name during the process, which could lead to errors in the transmission of the identifier image and ensure that the target identifier image can be accurately located throughout the entire process.
[0099] Step S304: Copy the identifier image from the first image file storage unit to the second image file storage unit as the target identifier image, and change the second preset identifier name to the first preset identifier name, so that after the substrate management controller page refreshes and runs the preset page source code, the substrate management controller page displays the target identifier image.
[0100] Understandably, changing the second identifier name to the first identifier name is to ensure that the source code of the baseboard management controller page can recognize and display the target identifier image. Since the first preset identifier name is the name used in the page source code to identify and display the identifier image, changing the image's name prefix to the first identifier name ensures that the identifier image can be correctly displayed on the page.
[0101] For example, refer to Figure 3 The administrator uploads the BMC logo via the BMC web page. Upon receiving the instruction to upload the logo image, the administrator determines whether the instruction instructs the image to be retrieved from a preset location (e.g., a local disk file). The prefix of the logo image retrieved from the preset location is renamed to a second preset logo name, such as upload_logo.jpg, and then saved to the file storage unit under the / usr / share / webLogo directory. Next, the upload_logo.jpg file in the / usr / share / webLogo directory is copied to a second image file storage unit, such as the / web / logo directory, as the target logo image. The second preset logo name in the filename is changed to the first preset logo name web_logo.jpg so that the BMC page can display the new logo image according to the preset page source code logic. The new logo image is successfully uploaded and set as the logo displayed on the BMC page. The entire process does not require restarting the BMC service, avoiding potential service interruptions caused by restarting the service.
[0102] In an optional implementation, the process startup time corresponding to the electrically erasable programmable read-only memory is earlier than the process startup time corresponding to the board management controller page. The method for setting the board management controller page identifier image provided in this embodiment further includes:
[0103] When the process corresponding to the baseboard management controller page is restarted, it is determined whether the target identification image stored in the second image file storage unit corresponding to the second preset directory is lost;
[0104] If the target identifier image stored in the second image file storage unit corresponding to the second preset directory has been lost, then determine whether the first image file storage unit corresponding to the first preset directory stores an identifier image with the name prefix of the second preset identifier name; if the first image file storage unit corresponding to the first preset directory has already stored an identifier image with the name prefix of the second preset identifier name, then copy the identifier image with the name prefix of the second preset identifier name to the second image file storage unit corresponding to the second preset directory as the target identifier image, and change the second preset identifier name to the first preset identifier name;
[0105] Alternatively, if the first image file storage unit corresponding to the first preset directory does not store an identifier image with the name prefix of the second preset identifier name, then based on the target identifier information, the image information in the third image file storage unit corresponding to the third preset directory under the electrically erasable programmable read-only memory is searched, the identifier image corresponding to the target identifier information is obtained, the identifier image corresponding to the target identifier information is copied to the second image file storage unit corresponding to the second preset directory as the target identifier image, and the name prefix of the target identifier image is renamed to the first preset identifier name.
[0106] For example, refer to Figure 4If the logo to be displayed by BMC is located in the ` / web / logo` directory and the file name is `web_logo.xxx`, and the `web_logo.xxx` image is accidentally deleted, the BMC process needs to be restarted to apply the update. During the restart process, the BMC startup program first checks if a file named `upload_logo.xxx` exists in the ` / usr / share / webLogo` directory. If `upload_logo.xxx` exists, it means the logo was uploaded through the BMC web interface. In this case, the mapping relationship in the EEPROM will not be checked; instead, `upload_logo.xxx` will be directly copied to the ` / web / logo` directory and restarted. The file is named web_logo.xxx to ensure that even if the logo is accidentally deleted, the logo uploaded via the web can be recovered. If upload_logo.xxx does not exist, the logo is set via IPMI. The BMC startup program will query the mapping relationship in the EEPROM to determine the logo image to use. After finding the corresponding logo, the program will copy the logo from the specified location to the / web / logo directory and rename it to web_logo.xxx. Whether the logo is set via IPMI or uploaded via the web, it can be displayed correctly after the BMC restarts, ensuring that the user-set logo can still be recovered in abnormal situations.
[0107] This invention automatically detects whether a target identifier image is missing in the second preset directory. If a loss is detected, it first searches for the identifier image in the first preset directory. If the identifier image exists in the first preset directory, it is restored from the first preset directory. If the identifier image does not exist in the first preset directory, it uses the target identifier information to search for the image information in the third image file storage unit corresponding to the third preset directory under the electrically erasable programmable read-only memory (EEPROM), obtains the identifier image corresponding to the target identifier information, and then restores the identifier image. This ensures that the board management controller can correctly display the identifier image. Furthermore, by ensuring that the process corresponding to the EEPROM starts first, it can quickly search for the image information under the EEPROM when the target identifier image is found to be missing after the process corresponding to the board management controller page is restarted, without waiting for the delay caused by the process startup order, further improving the identifier image replacement speed.
[0108] In this embodiment of the invention, the instruction to obtain the identification image from a preset location can be used to rename the name prefix of the identification image to a second preset identification name and store it in the first image file storage unit. The identification image can then be copied to the second image file storage unit and renamed again. This ensures that the renamed image is compatible with the page source code operation rules, without needing to restart the backend service. The frontend page only needs to reload the new page source code, avoiding the need to restart the substrate management controller service and achieving efficient replacement of the homepage identification image of the substrate management controller.
[0109] In an optional implementation, the method further includes: modifying the board management controller factory reset control script according to preset script modification rules based on script modification instructions, wherein the modified script is used to copy the target identifier image in the second image file storage unit corresponding to the second preset directory to the image file storage unit corresponding to the preset temporary directory when the board management controller is reset to factory settings; after the board management controller is reset to factory settings, copy the target identifier image stored in the image file storage unit corresponding to the preset temporary directory back to the second image file storage unit corresponding to the second preset directory; and control the deletion of the preset temporary directory and the image file storage unit corresponding to the preset temporary directory.
[0110] For example, script modification instructions and preset script modification rules are used to determine how to modify the specific rules and instructions of the obmc-init.sh script. The specific rules are modified in the script file. For example, the obmc-init.sh script defines two variables, representing the paths of the temporary directory and the / web / logo directory where the logo image is stored. When restoring BMC to factory settings, the obmc-init.sh script will copy the contents of the / web / logo directory to a temporary directory. After the BMC default configuration is completed, it will copy the contents of the temporary directory back to the / web / logo directory and delete the temporary directory.
[0111] This invention can retain the user-set identifier image when restoring the board management controller to factory settings. Whether the image is uploaded through the intelligent platform management interface command or obtained from a preset location, the target identifier image in the second image file storage unit corresponding to the second preset directory is copied to a temporary directory, and then copied back to the original second preset directory after restoring factory settings. This ensures that the user-set image is not lost and avoids the user having to reset the identifier image after restoring the board management controller to factory settings, thus improving the convenience of image setting.
[0112] In one alternative implementation, the method further includes:
[0113] Add the first preset directory to the preset baseboard management controller firmware upgrade whitelist so that the baseboard management controller retains the information corresponding to the whitelist when upgrading and refreshing firmware information.
[0114] For example, by adding the / usr / share / webLogo directory to the whitelist, directories other than those in the whitelist will be deleted when upgrading the BMC firmware. This way, the logo uploaded through the web page will be retained regardless of whether the BMC default configuration is restored or the BMC firmware is upgraded.
[0115] In this embodiment of the invention, the first preset directory is added to the firmware upgrade whitelist of the baseboard management controller. This ensures that the corresponding directory information is not lost when the firmware information is updated, further guaranteeing the preservation and recovery of the identification image, simplifying the user operation process, and improving the convenience of image settings.
[0116] In one optional implementation, the rule for the logic code of the identifier image display area in the preset page source code is set as follows:
[0117] The page displays a preset area frame. If the length of the target logo image is greater than the length set by the preset area frame, or the width of the target logo image is greater than the width set by the preset area frame, the length or width of the target logo image is scaled up by the same preset ratio until the length of the target logo image is less than or equal to the length set by the preset area frame, and the width of the target logo image is less than or equal to the width set by the preset area frame.
[0118] For example, the front-end page will set a box at a certain location on the homepage, and the required length and width can be adjusted via code. The logo set via IPMI command and the logo uploaded via the web will be filled into this box. Images exceeding the set length and width will be scaled proportionally; images within the set length and width will be enlarged proportionally.
[0119] This invention, through its logic code rules for the display area of the identifier image, scales it according to a preset ratio. This maintains the aspect ratio of the image, ensuring that the identifier image displayed within the preset page display area fits the page size and preventing the image from exceeding the page's boundaries. Regardless of image size, it can be placed within the preset display area of the page, without limiting the size of the uploaded identifier image.
[0120] In this embodiment of the invention, reference is made to Figure 5Users can set the logo in two different ways. The first is through IPMI commands to control the logo change. Using IPMI's remote control function, if an image named `upload logo.xxx` exists in the ` / usr / share / webLogo` directory, the IPMI command mapping is stored in the EEPROM. If no image named `upload logo.xxx` exists, the IPMI command finds the corresponding logo image based on the EEPROM mapping, copies the corresponding image from the ` / usr / share / www` directory to the ` / web / logo` directory, renames it to `web logo.xxx`, and refreshes the page to see the logo in the upper left corner of the homepage. The second method is to upload the logo directly on the web page. Users can select a photo locally and click upload, or select a suitable photo from the logo server and click upload. Refreshing the page will then display the logo in the upper left corner of the homepage, providing timely feedback to the user.
[0121] In this embodiment of the invention, reference is made to Figure 6 When a user executes the IPMI command to set the logo, if the ` / usr / share / webLogo` directory contains an image named `upload logo.xxx`, the program stores the mapping relationship in the EEPROM. If the ` / usr / share / webLogo` directory does not contain an image named `upload logo.xxx`, the IPMI command finds the corresponding logo image based on the mapping relationship in the EEPROM, copies the corresponding image from the ` / usr / share / www` directory to the ` / web / logo` directory, and renames it to `web logo.xxx`. The front-end sets the width and height of the `web logo.xxx` image to the size set by the program, refreshes the page, and the web homepage logo is the logo set by IPMI.
[0122] This embodiment also provides a device for setting the page identifier image of a baseboard management controller. This device is used to implement the above embodiments and preferred embodiments, and will not be repeated as already described. As used below, the term "module" can be a combination of software and / or hardware that implements a predetermined function. Although the device described in the following embodiments is preferably implemented in software, hardware implementation, or a combination of software and hardware, is also possible and contemplated.
[0123] This embodiment provides a device for setting page identifier images on a substrate management controller, such as... Figure 7 As shown, it includes:
[0124] The instruction type determination module is used to obtain the identifier image upload instruction triggered on the baseboard management controller page and determine the type of the identifier image upload instruction;
[0125] The identification information extraction module is used to extract target identification information from the intelligent platform management interface command if the identification image upload command is an intelligent platform management interface command;
[0126] The image identification search module is used to search, based on the target identification information, whether the first image file storage unit corresponding to the first preset directory stores a target identification image that corresponds to the target identification information.
[0127] The identification information determination module is used to search for image information in the electrically erasable programmable read-only memory and obtain the target identification image when it is determined that the first image file storage unit does not store the target identification image. The image information includes: multiple different identification images and identification information corresponding to each of the multiple different identification images.
[0128] The identification image display module is used to store the target identification image in the second image file storage unit corresponding to the second preset directory; and to rename the name prefix of the target identification image to the first preset identification name, so that after the substrate management controller page refreshes and runs the preset page source code, the substrate management controller page displays the target identification image. The rule of the identification image display logic code in the preset page source code is set to display the identification image in the second image file storage unit whose name prefix is the first preset identification name.
[0129] In one optional implementation, multiple different identification images and identification information corresponding to each of the multiple different identification images are stored in a third image file storage unit corresponding to a third preset directory under an electrically erasable programmable read-only memory.
[0130] In one optional embodiment, the above-described apparatus further includes:
[0131] The identification information backup module is used to extract the target identification information from the intelligent platform management interface command and store it in the third image file storage unit corresponding to the third preset directory under the electrically erasable programmable read-only memory when it is determined that the target identification image has been stored in the first image file storage unit.
[0132] In one optional embodiment, the above-described apparatus further includes:
[0133] The preset location image acquisition module is used if the image upload instruction is to acquire an image from a preset location.
[0134] The identification image storage module is used to rename the name prefix of the identification image to a second preset identification name and then store it in the first image file storage unit;
[0135] The identifier image copying module is used to copy the identifier image from the first image file storage unit to the second image file storage unit as the target identifier image, and change the second preset identifier name to the first preset identifier name, so that after the substrate management controller page refreshes and runs the preset page source code, the substrate management controller page displays the target identifier image.
[0136] In one optional implementation, the image obtained from the preset location includes: any identifier image stored in any disk file storage unit of the local server, or any identifier image obtained from the preset identifier image server based on the preset identifier image acquisition interface.
[0137] In one optional embodiment, the process startup time corresponding to the electrically erasable programmable read-only memory is earlier than the process startup time corresponding to the baseboard management controller page, and the above-mentioned device further includes:
[0138] The image information detection module is used to determine whether the target identification image stored in the second image file storage unit corresponding to the second preset directory is lost after the process corresponding to the baseboard management controller page is restarted.
[0139] The first image retrieval module is used to determine whether an identifier image with a name prefix of the second preset identifier name is stored in the first image file storage unit corresponding to the first preset directory if the target identifier image stored in the second image file storage unit corresponding to the second preset directory has been lost; if the identifier image with a name prefix of the second preset identifier name is stored in the first image file storage unit corresponding to the first preset directory, the identifier image with a name prefix of the second preset identifier name is copied to the second image file storage unit corresponding to the second preset directory as the target identifier image, and the second preset identifier name is changed to the first preset identifier name.
[0140] The second image retrieval module is used to, if the first image file storage unit corresponding to the first preset directory does not store an identifier image with the name prefix of the second preset identifier name, then search for the image information in the third image file storage unit corresponding to the third preset directory under the electrically erasable programmable read-only memory according to the target identifier information, obtain the identifier image corresponding to the target identifier information, copy the identifier image corresponding to the target identifier information to the second image file storage unit corresponding to the second preset directory as the target identifier image, and rename the name prefix of the target identifier image to the first preset identifier name.
[0141] In one optional embodiment, the above-described apparatus further includes:
[0142] The script modification module is used to modify the board management controller factory reset control script according to preset script modification rules based on script modification instructions. The modified script is used to copy the target identifier image in the second image file storage unit corresponding to the second preset directory to the image file storage unit corresponding to the preset temporary directory when the board management controller is reset to factory settings. After the board management controller is reset to factory settings, the target identifier image stored in the image file storage unit corresponding to the preset temporary directory is copied back to the second image file storage unit corresponding to the second preset directory. The module also controls the deletion of the preset temporary directory and the image file storage unit corresponding to the preset temporary directory.
[0143] In one optional embodiment, the above-described apparatus further includes:
[0144] The whitelist setting module is used to add the first preset directory to the preset baseboard management controller firmware upgrade whitelist list, so that the baseboard management controller retains the information corresponding to the whitelist list when upgrading and refreshing firmware information.
[0145] In one optional implementation, the rule for the logic code of the identifier image display area in the preset page source code is set as follows:
[0146] The page displays a preset area frame. If the length of the target logo image is greater than the length set by the preset area frame, or the width of the target logo image is greater than the width set by the preset area frame, the length or width of the target logo image is scaled up by the same preset ratio until the length of the target logo image is less than or equal to the length set by the preset area frame, and the width of the target logo image is less than or equal to the width set by the preset area frame.
[0147] Further functional descriptions of the above modules and units are the same as those in the corresponding embodiments described above, and will not be repeated here.
[0148] In this embodiment, the device for setting the page identifier image of the baseboard management controller is presented in the form of a functional unit. Here, a unit refers to an ASIC (Application Specific Integrated Circuit) circuit, a processor and memory that execute one or more software or fixed programs, and / or other devices that can provide the above functions.
[0149] This invention also provides a computer device having the above-described features. Figure 7 The device for setting the label image on the board management controller page shown.
[0150] Please see Figure 8 , Figure 8 This is a schematic diagram of the structure of a computer device provided in an optional embodiment of the present invention, such as... Figure 8 As shown, the computer device includes one or more processors 10, memory 20, and interfaces for connecting the components, including high-speed interfaces and low-speed interfaces. The components communicate with each other via different buses and can be mounted on a common motherboard or otherwise installed as needed. The processors can process instructions executed within the computer device, including instructions stored in or on memory to display graphical information of a GUI on external input / output devices (such as display devices coupled to the interfaces). In some alternative implementations, multiple processors and / or multiple buses can be used with multiple memories and multiple memory modules, if desired. Similarly, multiple computer devices can be connected, each providing some of the necessary operations (e.g., as a server array, a group of blade servers, or a multiprocessor system). Figure 8 Take a processor 10 as an example.
[0151] Processor 10 may be a central processing unit, a network processor, or a combination thereof. Processor 10 may further include a hardware chip. The hardware chip may be an application-specific integrated circuit (ASIC), a programmable logic device (PLD), or a combination thereof. The programmable logic device may be a complex programmable logic device (CAMP), a field-programmable gate array (FPGA), a general-purpose array logic (GDA), or any combination thereof.
[0152] The memory 20 stores instructions executable by at least one processor 10 to cause at least one processor 10 to perform the method shown in the above embodiments.
[0153] The memory 20 may include a program storage area and a data storage area. The program storage area may store the operating system and applications required for at least one function; the data storage area may store data created based on the use of the computer device. Furthermore, the memory 20 may include high-speed random access memory and may also include non-transitory memory, such as at least one disk storage device, flash memory device, or other non-transitory solid-state storage device. In some alternative embodiments, the memory 20 may optionally include memory remotely located relative to the processor 10, and these remote memories may be connected to the computer device via a network. Examples of such networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.
[0154] The memory 20 may include volatile memory, such as random access memory; the memory may also include non-volatile memory, such as flash memory, hard disk or solid-state drive; the memory 20 may also include a combination of the above types of memory.
[0155] The computer device also includes a communication interface 30 for communicating with other devices or communication networks.
[0156] This invention also provides a computer-readable storage medium. The methods described above according to embodiments of the invention can be implemented in hardware or firmware, or implemented as computer code that can be recorded on a storage medium, or implemented as computer code downloaded via a network and originally stored on a remote storage medium or a non-transitory machine-readable storage medium and then stored on a local storage medium. Thus, the methods described herein can be processed by software stored on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. The storage medium can be a magnetic disk, optical disk, read-only memory, random access memory, flash memory, hard disk, or solid-state drive, etc.; further, the storage medium can also include combinations of the above types of memory. It is understood that computers, processors, microprocessor controllers, or programmable hardware include storage components capable of storing or receiving software or computer code, which, when accessed and executed by the computer, processor, or hardware, implements the methods shown in the above embodiments.
[0157] A portion of this invention can be applied as a computer program product, such as computer program instructions, which, when executed by a computer, can invoke or provide the methods and / or technical solutions according to the invention through the operation of the computer. Those skilled in the art will understand that the forms in which computer program instructions exist in a computer-readable medium include, but are not limited to, source files, executable files, installation package files, etc. Correspondingly, the ways in which computer program instructions are executed by a computer include, but are not limited to: the computer directly executing the instructions, or the computer compiling the instructions and then executing the corresponding compiled program, or the computer reading and executing the instructions, or the computer reading and installing the instructions and then executing the corresponding installed program. Here, the computer-readable medium can be any available computer-readable storage medium or communication medium accessible to a computer.
[0158] Although embodiments of the invention have been described in conjunction with the accompanying drawings, those skilled in the art can make various modifications and variations without departing from the spirit and scope of the invention, and such modifications and variations all fall within the scope defined by the claims.
Claims
1. A method for setting the page identifier image of a baseboard management controller, characterized in that, The method includes: Obtain the identifier image upload command triggered on the baseboard management controller page, and determine the type of the identifier image upload command; If the image upload instruction is a smart platform management interface instruction, then the target identification information is extracted from the smart platform management interface instruction; Based on the target identification information, check whether the first image file storage unit corresponding to the first preset directory stores a target identification image corresponding to the target identification information; When it is determined that the target identification image is not stored in the first image file storage unit, the image information in the electrically erasable programmable read-only memory is searched to obtain the target identification image. The image information includes: multiple different identification images, and identification information corresponding to each of the multiple different identification images. The target identification image is stored in the second image file storage unit corresponding to the second preset directory; and the name prefix of the target identification image is renamed to the first preset identification name, so that after the substrate management controller page is refreshed and the preset page source code is run, the substrate management controller page displays the target identification image. The rule of the identification image display logic code of the preset page source code is set to display the identification image in the second image file storage unit whose name prefix is the first preset identification name. The plurality of different identification images, and the identification information corresponding to the plurality of different identification images, are stored in the third image file storage unit corresponding to the third preset directory under the electrically erasable programmable read-only memory; The method further includes: If the instruction to upload the identification image is an instruction to obtain an identification image from a preset location; The name prefix of the identified image is renamed to the second preset identifier name and then stored in the first image file storage unit; The identification image is copied from the first image file storage unit to the second image file storage unit as the target identification image, and the second preset identification name is changed to the first preset identification name, so that after the substrate management controller page is refreshed and the preset page source code is run, the substrate management controller page displays the target identification image; The process startup time corresponding to the electrically erasable programmable read-only memory is earlier than the process startup time corresponding to the baseboard management controller page, and the method further includes: When the process corresponding to the baseboard management controller page is restarted, it is determined whether the target identification image stored in the second image file storage unit corresponding to the second preset directory is lost; If the target identifier image stored in the second image file storage unit corresponding to the second preset directory has been lost, then determine whether the first image file storage unit corresponding to the first preset directory stores an identifier image with the name prefix of the second preset identifier name; if the first image file storage unit corresponding to the first preset directory has already stored an identifier image with the name prefix of the second preset identifier name, then copy the identifier image with the name prefix of the second preset identifier name to the second image file storage unit corresponding to the second preset directory as the target identifier image, and change the second preset identifier name to the first preset identifier name; Alternatively, if the first image file storage unit corresponding to the first preset directory does not store an identifier image with the name prefix of the second preset identifier name, then the image information in the third image file storage unit corresponding to the third preset directory under the electrically erasable programmable read-only memory is searched according to the target identifier information to obtain the identifier image corresponding to the target identifier information; The identification image corresponding to the target identification information is copied to the second image file storage unit corresponding to the second preset directory as the target identification image, and the name prefix of the target identification image is renamed to the first preset identification name.
2. The method according to claim 1, characterized in that, The method further includes: When it is determined that the target identification image has been stored in the first image file storage unit, the target identification information extracted by the intelligent platform management interface instruction is stored in the third image file storage unit corresponding to the third preset directory under the electrically erasable programmable read-only memory.
3. The method according to claim 1, characterized in that, Images obtained from preset locations include: any identifier image stored in any disk file storage unit of the local server, or any identifier image obtained from the preset identifier image server based on the preset identifier image acquisition interface.
4. The method according to any one of claims 1 to 3, characterized in that, The method further includes: Obtain script modification instructions; Based on the script modification instructions, the board management controller factory reset control script is modified according to the preset script modification rules. The modified script is used to copy the target identifier image in the second image file storage unit corresponding to the second preset directory to the image file storage unit corresponding to the preset temporary directory when the board management controller is reset to factory settings. After the board management controller is reset to factory settings, the target identifier image stored in the image file storage unit corresponding to the preset temporary directory is copied back to the second image file storage unit corresponding to the second preset directory. The script also controls the deletion of the preset temporary directory and the image file storage unit corresponding to the preset temporary directory.
5. The method according to any one of claims 1 to 3, characterized in that, The method further includes: The first preset directory is added to the preset baseboard management controller firmware upgrade whitelist so that the baseboard management controller retains the information corresponding to the whitelist when upgrading and refreshing firmware information.
6. The method according to any one of claims 1 to 3, characterized in that, The rules for the logic code of the identifier image display area in the preset page source code are set as follows: The page displays a preset area frame. If the length of the target identifier image is greater than the length set by the preset area frame, and / or the width of the target identifier image is greater than the width set by the preset area frame, then the length or width of the target identifier image is scaled up by the same preset ratio until the length of the target identifier image is less than or equal to the length set by the preset area frame, and the width of the target identifier image is less than or equal to the width set by the preset area frame.
7. A device for setting page identifier images on a substrate management controller, characterized in that, The device includes: The instruction type determination module is used to obtain the identifier image upload instruction triggered on the baseboard management controller page and determine the type of the identifier image upload instruction; The identification information extraction module is used to extract target identification information from the intelligent platform management interface instruction if the identification image upload instruction is an intelligent platform management interface instruction; The image identification module is used to search, based on the target identification information, whether the first image file storage unit corresponding to the first preset directory stores a target identification image that corresponds to the target identification information. The identification information determination module is used to search for image information in an electrically erasable programmable read-only memory to obtain the target identification image when it is determined that the first image file storage unit does not store the target identification image. The image information includes: multiple different identification images and identification information corresponding to each of the multiple different identification images. The identification image display module is used to store the target identification image in the second image file storage unit corresponding to the second preset directory; and to rename the name prefix of the target identification image to a first preset identification name, so that after the substrate management controller page refreshes and runs the preset page source code, the substrate management controller page displays the target identification image. The rule of the identification image display logic code in the preset page source code is set to display identification images in the second image file storage unit whose name prefix is the first preset identification name. The plurality of different identification images, and the identification information corresponding to the plurality of different identification images, are stored in the third image file storage unit corresponding to the third preset directory under the electrically erasable programmable read-only memory; The device further includes: The preset location image acquisition module is used if the image upload instruction is to acquire an image from a preset location. The identification image storage module is used to rename the name prefix of the identification image to a second preset identification name and then store it in the first image file storage unit; The identification image copying module is used to copy the identification image from the first image file storage unit to the second image file storage unit as the target identification image, and change the second preset identification name to the first preset identification name, so that after the substrate management controller page refreshes and runs the preset page source code, the substrate management controller page displays the target identification image; The process startup time corresponding to the electrically erasable programmable read-only memory is earlier than the process startup time corresponding to the baseboard management controller page. The device also includes: The image information detection module is used to determine whether the target identification image stored in the second image file storage unit corresponding to the second preset directory is lost after the process corresponding to the baseboard management controller page is restarted. The first image retrieval module is used to determine whether an identifier image with a name prefix of the second preset identifier name is stored in the first image file storage unit corresponding to the first preset directory if the target identifier image stored in the second image file storage unit corresponding to the second preset directory has been lost; if the identifier image with a name prefix of the second preset identifier name is stored in the first image file storage unit corresponding to the first preset directory, the identifier image with a name prefix of the second preset identifier name is copied to the second image file storage unit corresponding to the second preset directory as the target identifier image, and the second preset identifier name is changed to the first preset identifier name. The second image retrieval module is used to, if the first image file storage unit corresponding to the first preset directory does not store an identifier image with the name prefix of the second preset identifier name, then search for the image information in the third image file storage unit corresponding to the third preset directory under the electrically erasable programmable read-only memory according to the target identifier information, obtain the identifier image corresponding to the target identifier information, copy the identifier image corresponding to the target identifier information to the second image file storage unit corresponding to the second preset directory as the target identifier image, and rename the name prefix of the target identifier image to the first preset identifier name.
8. A computer device, characterized in that, include: A memory and a processor are communicatively connected, the memory stores computer instructions, and the processor executes the computer instructions to perform the method for setting the page identification image of the baseboard management controller as described in any one of claims 1-6.
9. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions for causing the computer to execute the method for setting the baseboard management controller page identification image according to any one of claims 1-6.
10. A computer program product, characterized in that, Includes computer instructions, which are used to cause a computer to execute the method for setting the baseboard management controller page identification image according to any one of claims 1-6.
Citation Information
Patent Citations
Method and device for realizing personalized interface identification in mobile terminal
CN101661377A
Television and starting LOGO upgrading method thereof
CN102170539A