PowerShell Inventory 8 min read

PowerShell Device Inventory for Useful Fleet Signals

An inventory snapshot should help an operator decide what to do next, not recreate the entire operating system in CSV.

Collect stable signals

Use computer identity, OS version, build, model, serial, encryption state, last boot, and free system-drive space as a starting point. Add a signal only when a workflow consumes it.

Normalize the output

Return consistent property names and units, and include collection time. Avoid mixing local time zones or formatting values for display inside the collection script.

$os = Get-CimInstance Win32_OperatingSystem
$computer = Get-CimInstance Win32_ComputerSystem
[pscustomobject]@{
  DeviceName = $env:COMPUTERNAME
  Model = $computer.Model
  Build = $os.BuildNumber
  CollectedUtc = [DateTime]::UtcNow.ToString('o')
}

Respect privacy and scale

Exclude personal content and unnecessary user identifiers. Run collection on a schedule that matches the decision’s urgency, then expire old snapshots so stale data cannot be mistaken for current state.

Operational checklist

  • Collect only decision-relevant signals.
  • Normalize names, units, and timestamps.
  • Exclude personal content.
  • Mark freshness and expire stale records.

Read more

Technical Discussion & Q&A

Secure PostgreSQL Board

Join the Engineering Discussion

Loading discussion threads...

Akash Nagapure

Akash Nagapure

Microsoft Intune and VMware Architect

Microsoft Intune and VMware Architect specialized in designing scalable cloud infrastructure and zero-trust modern workspace solutions.

Enterprise Homelab
Sponsored

Enterprise Lab Blueprints Pro

Accelerate your cloud architecture transitions with ready-to-deploy Intune policies, configuration baselines, and automated scripts.

Was this guide helpful?

Loading community feedback...