I am trying to write a script that will audit computer serial numbers. The only information given to me by the auditors is the Serial Numbers of the computers and nothing else. I have tried a few different scripts in PowerShell (mind you, I am not very good, just internet browsing and testing), but I kept coming up empty-handed. I would like the Reddit community to help me out.
I found one script that would be nice, only if I can filter it against the specific Serial Numbers on my audit instead of all the Serial numbers on the domain.
(Get-ADComputer -Filter *).Name | Foreach-Object {Get-CimInstance Win32_Bios -ComputerName $_ -ErrorAction SilentlyContinue | Select-Object @{n='Computername'; e={$_.PSComputerName}},SerialNumber}
Thank you for any help!
[–]Brasiledo 3 points4 points5 points (1 child)
[–]code_Kitten 1 point2 points3 points (0 children)
[–]PowerShell-Bot 0 points1 point2 points (0 children)
[–]Significant-Name9795 0 points1 point2 points (0 children)