Skip to content
  • Home
  • Social Media
  • About Us
  • Privacy Policy
    • Cookie Policy
    • Terms of Use
  • Amazon Affiliate Disclaimer
  • Sitemap
Menu

lumialivecentre.com

  • Home
  • Social Media
  • About Us
  • Privacy Policy
    • Cookie Policy
    • Terms of Use
  • Amazon Affiliate Disclaimer
  • Sitemap
Home / World Tech / Using PowerShell to View and Change BIOS Settings
Posted inWorld Tech

Using PowerShell to View and Change BIOS Settings

Posted By Baris Posted on December 24, 2020
Comments are off

You can use PowerShell to view or change the BIOS settings on a Windows computer. Let’s take a look at some examples that allow you to get or change some BIOS settings with PowerShell using WMI (Windows Management Instrumentation) classes on ordinary computers: HP, Lenovo, Dell.

You can view the most important BIOS settings on your computer with the Get-WmiObject command of the Win32_BIOS class :

Get-WmiObject -Class Win32_BIOS | List of formats

This command allows you to view the BIOS version (SMBIOSBIOSVersion, BIOSVersion), the hardware manufacturer, the serial number of the computer, the release date and some other data.

 

You can only list a few of these BIOS settings:

Get-WmiObject -Class Win32_BIOS | Select-Object Manufacturer, SMBIOSVersion

You can use the Win32_BIOS class to display some BIOS information on any Windows computer. However, some hardware manufacturers offer special WMI classes to access the BIOS directly from the Windows operating system (the hardware manufacturer’s native drivers must be installed on the computer).

Lenovo BIOS settings management via PowerShell

Here’s a list of BIOS settings and their values on Lenovo computers:

Get-WmiObject – class Lenovo_BiosSetting – rootwmi namespace

Display only BIOS parameter names and their current values :

Get-WmiObject – Lenovo_BiosSetting class – rootwmi namespace | select object InstanceName, currentSetting

 

Make sure a BIOS password is installed on the Lenovo computer:

(gwmi -Class Lenovo_BiosPasswordSettings -Namespace rootwmi).PasswordState

If the command returns 0, the BIOS password is not set.

 

You can change some BIOS settings on Lenovo computers. For example, activate WOL (Wake-On-LAN) :

$getLenovoBIOS = (gwmi class Lenovo_SetBiosSettings – rootwmi namespace
$getLenovoBIOS.SetBiosSet(WakeOnLAN,Enable)
$SaveLenovoBIOS = (gwmi class Lenovo_SaveBiosSettings – rootwmi namespace)
$SaveLenovoBIOS.SaveBiosSettings()

Changing BIOS settings via PowerShell on Hewlett-Packardcomputers

You can use the following command to obtain the BIOS settings, their values, and options on HP computers:

Get-WmiObject -Namespace root/hp/instrumentedBIOS -Class hp_biosEnumeration | select name, value, possible values -AutoSize

You can change some BIOS settings on HP computers using PowerShell. For example, you may want to disable the startup of the computer from USB devices.

$getHPBios = gwmi -class hp_biossetting interface -name space roothp instrumentedbios
$getHPBios.SetBIOSSet (USB storage boot, disable)

If you need to enter a password to change the BIOS settings, you can use this script:

$HPBIOSPassword = +Passw0rd! 1
$getHPBios = gwmi – class hp_biossetting interface -Name space roothp instrumentedbios
$getHPBios.SetBIOSSetting(‘Network (PXE) Boot’, ‘Disable’,$HPBIOSPassword)

When the last command 0 came back, it was executed successfully. You can use a simple PowerShell manipulator:

ChangeBIOS_State = $bios.setbiossetting(Network (PXE) Boot’, ‘Disable’, $HPBIOSPassword)
$ChangeBIOS_State_Code = $ChangeBIOS_State.
If(($ChangeBIOS_State_Code) -eq 0)
{
write-host OK
}
Else
{
write-host Error – (Return code $ChangeBIOS_State_Code) – Foreground Red
}

If you want to enable the LAN/WLAN connection in your HP notebook BIOS to automatically disconnect the Wi-Fi connection when an Ethernet connection is present, run this command:

$getHPBios.SetBIOSSet (‘LAN/WLAN Switching’, ‘Enable’)

Configuring DELL BIOS settings with PowerShell

You can use the WMI DCIM-BIOSService class or the more modern rootdellomci class (available after installation of the OMCI – Open Manage Client Instrumentation package) to view and manage the BIOS settings on DELL computers.

To view the boot order in the BIOS on Dell computers, run the following command:

Get-WmiObject -NameSpace rootdellomci Dell_BootDeviceSequence | sort boot process | select BootDeviceName, BootOrder

.

For example, B. Activate Wake on LAN in the BIOS :

(Get-WmiObject DCIM-BIOSService – namespace rootdcimsysman).SetBIOSAttributes($null,$null,Wake-On-LAN,4)

Dell has also released a separate PowerShell module, DellBIOSProvider, which is installed with the driver, or you can install it manually with this command:

Installation Module – DellBIOS Vendor Name -Force

This module allows you to view the startup procedure on your Dell computer:

Get-childItem DellSmbios: BootSequence

To change a specific BIOS setting, use the Set-Item command. For example, to change the BIOS password:

Set-Item -Path DellsmbiosSecurityAdminPassword -Value BadDellPa$$ -Password [protected by email].

Using the methods described above, you can create a PowerShell script to export the current BIOS settings from a reference computer (e.g. to a CSV file). You can then use PowerShell to set the same BIOS settings on all computers in your organization.

Related Tags:

powershell enter bios,dell bios powershell,get-wmiobject bios password,update bios powershell,hp wmi namespace,list of bios settings,change hp bios password powershell,set bios password powershell lenovo,hp wmi classes,powershell lenovo bios setting,powershell check if uefi or bios,dell change bios settings from windows,powershell uefi mode,hp set bios password script,hp bios update wmi,hp cmi technical whitepaper,invalid namespace roothpinstrumentedbios,hp cmi whitepaper,hp bios configuration utility remotely,wmic get bios version remotely,hp check bios version powershell,powershell get bios mode uefi,powershell bios install date,how to get bios info from windows,wmi get bios setting,powershell script to change bios settings,powershell lenovo bios settings,powershell change bios settings dell,change bios settings remotely,powershell check if bios password is set,powershell get bios mode,wmic bios powershell

Previous Article What Are the Most Profitable Website Types in 2020
Next Article HappyForms Review: One of the best form plugins on the market

Related Posts

Posted inWorld Tech

HappyForms Review: One of the best form plugins on the market

When I first started working with WordPress, I noticed that I couldn’t record e-mails or questions from customers. When I finished my research, I was bombarded with free and paid plugins that solved the same problem on different levels. Today

Read More about HappyForms Review: One of the best form plugins on the market
Posted By Baris Posted on December 24, 2020
Comments are off
Posted inWorld Tech

What Are the Most Profitable Website Types in 2020

With the improvement of the internet industry, websites are slowly taking over. Thanks to technological progress, you can easily create your website using templates because they are well defined. It should be noted that not all sites have the same

Read More about What Are the Most Profitable Website Types in 2020
Posted By Baris Posted on December 24, 2020
Comments are off
Posted inWorld Tech

10 best software to improve video quality [2021 Guide]

Still, half of the recording work is done with the camera. The other half is done with the PC while you edit and enhance the video as desired. When the shooting method became commonplace, the possibilities for editing software followed

Read More about 10 best software to improve video quality [2021 Guide]
Posted By Baris Posted on December 24, 2020
Comments are off

Recent Posts

  • HappyForms Review: One of the best form plugins on the market
  • Using PowerShell to View and Change BIOS Settings
  • What Are the Most Profitable Website Types in 2020
  • 10 best software to improve video quality [2021 Guide]
  • How to Install Android Q on Windows 10 PC – Latest Version
  • How Web Design affects SEO –
  • How to Stop Programs From Running at Startup on Windows 10 (Updated)
  • How to Fix “The selected virtual disk is incompatible with this workstation…”
  • CleanMyMac X Review –
  • Best Elementor Ecommerce Themes To Use In 2021
  • How to Get YouTube Premium Free Trial of 3 Months using Google One
  • How to Delete a Blogger Blog Permanently in 3 Minutes
  • Find out how Custom Software is Different from Packaged Software.
  • Xender for PC Windows 10/8.1/7 32-64 Bit Laptop Download
  • Best Minecraft taiga biome seeds
© Copyright 2018. Theme by BloomPixel