Setting A Bios Setting - Lenovo BIOS Windows Management Deployment Manual

Bios windows management instrumentation interface
Table of Contents

Advertisement

<Command>
gwmi -class Lenovo_BiosSetting -namespace root\wmi | Where-Object
{$_.CurrentSetting.split(",",[StringSplitOptions]::RemoveEmptyEntries) -eq
"AlwaysOnUSB"}
| Format-List CurrentSetting
Remote computer:
<Command>
gwmi -class Lenovo_BiosSetting -namespace root\wmi -ComputerName test-pc -credential
(get-credential) | Where-Object {$_.CurrentSetting.split(",",[StringSplitOptions]
::RemoveEmptyEntries) -eq "AlwaysOnUSB"} | Format-List CurrentSetting
<Sample output>
PS C:\> gwmi -class Lenovo_BiosSetting -namespace root\wmi -ComputerName test-pc
-credential (get-credential) | Where-Object {$_.CurrentSetting.split(",",
[StringSplitOptions]::RemoveEmptyEntries) -eq "AlwaysOnUSB"}
| Format-List CurrentSetting
cmdlet get-credential at command pipeline position 1
Supply values for the following parameters:
Credential
CurrentSetting : AlwaysOnUSB,Disable

Setting a BIOS setting

Use the following script as a template to set the value of a setting. Replace
"WakeOnLAN,Disable" with the item and value of your choice.
Note: The setting string is case sensitive and should be in the format "<item,
<value>".
<Command>
(gwmi -class Lenovo_SetBiosSetting
-namespace root\wmi).SetBiosSetting ("WakeOnLAN,Disable")
__GENUS
__CLASS
__SUPERCLASS
__DYNASTY
__RELPATH
__PROPERTY_COUNT
__DERIVATION
__SERVER
__NAMESPACE
__PATH
return
PS C:\> (gwmi -class Lenovo_SaveBiosSettings -namespace root\wmi).
SaveBiosSettings
MemberType
OverloadDefinitions : {System.Management.ManagementBaseObject
TypeNameOfValue
Value
Name
IsInstance
PS C:\>
: 2
: __PARAMETERS
:
: __PARAMETERS
:
: 1
: {}
:
:
:
: Success
: Method
SaveBiosSettings(System.String parameter)}
: System.Management.Automation.PSMethod
: System.Management.ManagementBaseObject
SaveBiosSettings(System.String parameter)
: SaveBiosSettings
: True
Appendix B. Sample PowerShell scripts for remote BIOS management
23

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents