BIOS tool

This tool simplifies managing BIOS settings across multiple servers, ensuring consistency and reducing manual configuration efforts.

BIOS tool overview

The bios_tool is a command-line utility designed to manage BIOS settings on WEKA servers. It lets administrators view, set, and correct BIOS configurations across multiple servers. This tool is crucial for ensuring that servers in a cluster are properly configured and compliant with desired BIOS settings, using pre-defined configuration files or command-line inputs.

You can find the BIOS tool on GitHub at: https://github.com/weka/tools/tree/master/bios_tool.

Features

  • View and set BIOS settings: Inspect and apply BIOS settings across multiple servers.

  • BMC configuration: Configure BMC (Baseboard Management Controller) to allow RedFish and IPMI Over LAN access.

  • Fix BIOS settings: Correct any BIOS settings that deviate from specified configurations.

  • Reboot control: Optionally reboot servers after applying BIOS changes.

  • Compare settings: Diff the BIOS configurations between two servers to identify mismatches.

  • Support for multiple manufacturers: Compatible with servers from manufacturers like Dell, HPE, Lenovo, and Supermicro.

Usage

The bios_tool offers several command-line options to customize its behavior:

bios_tool [-h] [-c [HOSTCONFIGFILE]] [-b [BIOS]] [--bmc_config] [--fix] [--reboot] [--dump] [--reset_bios] [--diff DIFF DIFF] [--bmc_ips [BMC_IPS ...]] [--bmc_username BMC_USERNAME] [--bmc_password BMC_PASSWORD] [-v] [--version]

Parameters

Getting started

The bios_tool requires two configuration files:

  • Host configuration file (host_config.yml or host_config.csv)

  • BIOS settings configuration file (bios_config.yml)

You can use the default filenames or specify custom ones using the command-line options -c/--hostconfigfile for the host configuration file and -b/--bios or --bmc_ips for BIOS settings.

Host configuration (host_config.yml or .csv)

The host configuration file defines the servers (hosts) and their corresponding BMC credentials (IPMI, iLO, iDRAC). You can use either YAML or CSV format, indicated by the file extension (.yml or .csv).

The default format is CSV, which can be easily edited in spreadsheet tools like Excel. Example CSV format:

name,user,password
172.29.3.164,ADMIN,_PASSWORD_1!
172.29.3.1,Administrator,Administrator
172.29.1.74,root,Administrator
172.29.1.75,root,Administrator

Alternatively, you can use YAML for more structured data:

hosts:
  - name: 172.29.3.1
    user: Administrator
    password: Administrator
  - name: 172.29.3.2
    user: Administrator
    password: Administrator

Define all the servers you plan to manage in this file.

BIOS configuration (bios_config.yml and others)

The BIOS settings configuration file (bios_config.yml) specifies the BIOS configurations you want applied to the servers listed in the host configuration file.

There are additional preset files available, such as Dell-Genoa-bios.yml for Dell servers with Genoa AMD processors, and WEKApod.yml for WEKApod servers (which come pre-configured but can be applied to similar servers).

The BIOS configuration file follows standard YAML format. Example:

server-manufacturer:
  architecture:
    setting: value
    setting: value
  architecture2:
    setting: value
    setting: value

The server-manufacturer corresponds to the Oem field in RedFish data, allowing compatibility with most RedFish-supported manufacturers. Supported manufacturers include Dell, HPE, Lenovo, and Supermicro, and defaults for these are included in the sample file.

The architecture can be either AMD or Intel(no other architectures are supported).

For a detailed example, refer to the provided bios_config.yml. Here’s a sample snippet:

Dell:
  AMD:
    LogicalProc: Disabled
    NumaNodesPerSocket: "1"
    PcieAspmL1: Disabled
    ProcCStates: Disabled
    ProcPwrPerf: MaxPerf

Default mode

When run without command-line options, bios_tool operates in a read-only mode, scanning the hosts listed in the host_config.csv and comparing their current BIOS settings with those specified in the bios_settings.yml file. No changes are applied to the servers during this process.

Example output:

Fetching BIOS settings of host 172.29.3.1
Fetching BIOS settings of host 172.29.3.2
Fetching BIOS settings of host 172.29.3.3
[...snip...]
No changes are needed on 172.29.3.1
No changes are needed on 172.29.3.2
No changes are needed on 172.29.3.3
[...snip...]
172.29.3.4: BIOS setting ApplicationPowerBoost is Enabled, but should be Disabled
172.29.3.4: BIOS setting CStateEfficiencyMode is Enabled, but should be Disabled
172.29.3.4: BIOS setting DataFabricCStateEnable is Auto, but should be Disabled
172.29.3.4: BIOS setting DeterminismControl is DeterminismCtrlAuto, but should be DeterminismCtrlManual
[...snip...]

In this mode, the tool provides a detailed report on any discrepancies between the current BIOS configurations and the desired settings, allowing you to review changes without affecting the servers.

Optional modes

BMC configuration mode

Using the --bmc_config option, bios_tool will SSH into each server to enable both RedFish and IPMI Over LAN. RedFish is required for the tool’s operation, while IPMI Over LAN is necessary for WMS deployment, so it is automatically enabled.

Fix mode

The --fix option allows bios_tool to apply the BIOS settings specified in the bios_settings.yml file. The tool does not reboot the servers unless the --reboot option is also specified.

Reboot mode

When used with the --fix option, --reboot will instruct bios_tool to reboot the servers after applying any BIOS changes. Only servers that have been modified will be rebooted, ensuring the changes take effect.

Dump mode

The --dump option provides a read-only output of all current BIOS settings for each server. No changes are made to the servers in this mode.

Diff mode

Using --diff compares BIOS settings between two servers and highlights any discrepancies.

Example diff output:

Fetching BIOS settings of host 172.29.3.1
Fetching BIOS settings of host 172.29.3.6

Settings that are different between the servers:
Setting                     172.29.3.1                 172.29.3.6
--------------------------  -------------------------  ----------------------------
ApplicationPowerBoost       Disabled                   Enabled
CStateEfficiencyMode        Disabled                   Enabled
DataFabricCStateEnable      Disabled                   Auto
DeterminismControl          DeterminismCtrlManual      DeterminismCtrlAuto
InfinityFabricPstate        P0                         Auto
MinProcIdlePower            NoCStates                  C6
NumaGroupSizeOpt            Clustered                  Flat
NumaMemoryDomainsPerSocket  TwoMemoryDomainsPerSocket  Auto
PerformanceDeterminism      PerformanceDeterministic   PowerDeterministic
PowerRegulator              StaticHighPerf             OsControl
ProcAmdIoVt                 Disabled                   Enabled
ProcSMT                     Disabled                   Enabled
SerialNumber                MXQ2201FNK                 MXQ2201FND
Sriov                       Disabled                   Enabled
ThermalConfig               IncreasedCooling           OptimalCooling
WorkloadProfile             I/OThroughput              GeneralPowerEfficientCompute

Last updated