There are several ways to check the firmware or BIOS version on Linux, which helps troubleshoot hardware issues and is essential for keeping the system secure and up to date. In this article, we learn about the tools and commands to get our system’s firmware version, which is about BIOS, UEFI, or device-specific firmware. Each method provides a straightforward approach to help you quickly determine your current firmware version and maintain your system efficiently.
Method 1: Using dmidecode
One of the easiest ways to get detailed information about the system hardware, including the firmware, is by using the “demidecode“. It reads the DMI table to display the required system information. Although your Linux will already have this tool by default, if not installed already, then you can use the given command as per your Linux distro:
#For Debian or Ubuntu:
sudo apt install dmidecode
#For CentOS/RHEL/Almalinux/Fedora/Rocky/Oracle:
sudo dnf install dmidecode
Check Firmware Version:
Here is the command to check the firmware using demidecode. This command will display BIOS information, including the version.
sudo dmidecode -t bios
You can run only “sudo demidecode
” to get all available hardware information or add a type, as we did in the above command, which is “bios.” The other types are system, baseboard, chassis, processor, memory, cache, connector, and slot.
You can also get only the BIOS version and its release date using the given Demiocode commands:
sudo dmidecode -s bios-version
sudo dmidecode -s bios-release-date
Method 2: Using fwupdmgr
fwupdmgr is also an open-source tool available to install on Linux using the default system repository; it helps manage firmware updates and displays the current firmware version.
Install fwupdmgr (if not already installed):
#On Debian or Ubuntu
sudo apt install fwupd
For CentOS/RHEL/Almalinux/Fedora/Rocky/Oracle:
sudo dnf install fwupd
Check Firmware Version:
sudo fwupdmgr get-devices
This command will display information about available devices and their firmware versions.
Method 3: Using dmesg
The dmesg command prints the kernel’s message buffer, which can include firmware version information, especially on systems using UEFI.
Check Firmware Version:
dmesg | grep -i "firmware"
This command searches for firmware-related messages in the kernel message buffer.
Method 4: Using /sys File System
Firmware information can be found on some systems in the /sys file system. The given will read the BIOS version directly from the system’s hardware information files.
cat /sys/class/dmi/id/bios_version
Method 5: With Inxi Utility
Another utility known as “Inxi” can find the firmware or BIOS version by reading the data available /proc/cpu. However, this utility is not available on your Linux system by default; therefore, before using it, install Inxi first.
Installing Inxi:
on Debian or Ubuntu
sudo apt install inxi
on RHEL or Fedora-based systems
sudo dnf install inxi
Check the BIOS version and read other available information:
sudo inxi -M
To get CPU details as well with INXI, use:
sudo inxi -C -a
Method 7: Using Lshw command
The “lshw” command in Linux provides details about the system’s BIOS or firmware and can also display information about the CPU, memory, storage devices, network interfaces, and more.
Installing Lshw
# for debian or Ubuntu
sudo apt install lshw
# for RHEL or Fedora
sudo dnf install lshw
To check or display only the firmware version using the lshw command:
sudo lshw | grep -A8 '*-firmware'
Extra: If users want to list the current firmware version of the Storage device on Linux, they can use the given command.
You can replace “/dev/nvme0” with the location of your storage drive on the system.
sudo smartctl --xall /dev/nvme0 | grep -i firmware
Ending Note:
The different methods given in this tutorial to check the firmware version on a Linux system depend on the availability of the tools, so if you want to try any of the given commands, remember to install the corresponding required tool first.
Other Articles: