I want to get the BIOS version from Linux without going directly to the BIOS.

I mean, is there a way to get the BIOS version from inside Linux?


Without superuser privileges

It is as simple as reading the following file:

$ cat /sys/class/dmi/id/bios_version

With superuser privileges

Use dmidecode:

$ sudo dmidecode -s bios-version

Also, you might have to install this package, which is available in:

  • Linux i386, x86-64, ia64
  • FreeBSD i386, amd64
  • NetBSD i386, amd64
  • OpenBSD i386, amd64
  • BeOS i386
  • Solaris x86
  • Haiku i586
  • 14
    The /sys/.... approach should be used if possible. – Thorbjørn Ravn Andersen May 4 '18 at 14:29
  • I believe dmidecode only works if /dev/mem is available, which isn't the case on modern distros. – forest May 6 '18 at 7:04
  • @forest what's modern do you mean? At least it works in my Linux Mint 18.3 – cuonglm May 6 '18 at 7:58
  • Do you have a readable /dev/mem on that system? – forest May 6 '18 at 8:06
  • @forest yes. I don't see any distros with desktop environment don't have /dev/mem – cuonglm May 6 '18 at 10:39

You can use lshw , hwinfo , inxi and hardinfo (DMI):

# lshw -class memory
# hwinfo --bios
$ inxi -M
$ hardinfo

The above command should work after installing them through your package manager.

Only the first answer proposed by @cuonglm allow you the get bios information without installing an additional package:

$ cat /sys/class/dmi/id/bios*

  • 1
    hwinfo and hardinfo are not installed by default on Linux Mint. – Davidw May 6 '18 at 3:59
  • 2
    And none of them are available by default on CentOS 7. – Davidw May 6 '18 at 6:34

I was wandering in /sys folder then I went into /sys/firmware/dmi/tables then got two files DMI and smbios_entry_point. If you read DMI file then in my case first word was LENOVO and second word was BIOS version. I know this is not simple and straight answer but you can get more information regarding your pc from this file.


This is working for me:

sudo dmidecode | grep "BIOS Information" -A10 | grep -e "Version:" -e "Vendor:"
  • 13
    This sort of text filtering is fragile. Much better to make a specific request for the specific information you want, as shown by cuonglm. – Lightness Races in Orbit May 4 '18 at 11:25
  • 1
    will BIOS version is meaning full without vendor name? – Siva May 7 '18 at 12:26
  • I don't understand your comment, sorry. – Lightness Races in Orbit May 7 '18 at 12:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.