Compare Dell Bios parameters between Pcs
This Powershell script compares the parameters of Bios between Pcs
Function Get_Dell_BIOS_Settings
{
BEGIN {}
PROCESS
{
$Script:Selected_Manufacturer = "Dell"
If (Get-Module -ListAvailable -Name DellBIOSProvider)
{}
Else
{
Install-Module -Name DellBIOSProvider -Force -SkipPublisherCheck -Confirm:$false
}
get-command -module DellBIOSProvider | out-null
$Script:Get_BIOS_Settings = get-childitem -path DellSmbios:\ | select-object category |
foreach {
get-childitem -path @("DellSmbios:\" + $_.Category) | select-object attribute, currentvalue
#get-childitem -path @("DellSmbios:\" + $_.Category) | select attribute, currentvalue, possiblevalues, PSPath
}
$Script:Get_BIOS_Settings = $Get_BIOS_Settings | % { New-Object psobject -Property @{
Setting = $_."attribute"
Value = $_."currentvalue"
}} | select-object Setting, Value
$Get_BIOS_Settings
}
END{ }
}
#compare a remote pc with the current pc
#Compare-Object Get_Dell_BIOS_Settings (Invoke-Command -ComputerName "test1" -ScriptBlock ${Function:Get_Dell_BIOS_Settings}) -IncludeEqual
# compare two remote Pc
#Compare-Object (Invoke-Command -ComputerName "test1" -ScriptBlock ${Function:Get_Dell_BIOS_Settings}) (Invoke-Command -ComputerName "test2" -ScriptBlock ${Function:Get_Dell_BIOS_Settings}) -IncludeEqual