ScanComputers

<< Click to Display Table of Contents >>

ScanComputers

Queues a scan for one or more specific computers. By default the command returns once scans are queued. Use -Wait to block until all scans complete and display per-computer results. If no scan profile is specified, the default scan profile is used.

NOTE: This command requires a PDQ Inventory Enterprise license.

Syntax

PDQInventory ScanComputers -Computers <computer1> [<computer2> ...] [-ScanProfile <profile>] [-IgnoreNotFound] [-Wait] [-Quiet] [-Timeout <seconds>] [-Json | -Csv | -Brief]

Parameters

Parameter

Required

Description

-Computers <computer> ...

Yes

One or more computer names or IDs to scan, separated by spaces.

-ScanProfile <profile>

No

The name or ID of the scan profile to use. Defaults to the default scan profile if not specified. Use GetAllScanProfiles to find profile names.

-IgnoreNotFound

No

Skips computers that do not exist in PDQ Inventory rather than returning an error.

-Wait

No

Blocks until all scans complete, then displays per-computer results including status, duration, and any errors. Without this flag the command returns immediately after queuing scans.

-Quiet

No

Suppresses the real-time progress display while waiting. Requires -Wait.

-Timeout <seconds>

No

Maximum number of seconds to wait before returning current status. Incomplete scans are reported as Timeout. Requires -Wait.

-Json

No

Outputs scan results in JSON format. Mutually exclusive with -Csv and -Brief. Requires -Wait.

-Csv

No

Outputs scan results in CSV format. Mutually exclusive with -Json and -Brief. Requires -Wait.

-Brief

No

Outputs one status line per computer. Mutually exclusive with -Json and -Csv. Requires -Wait.

Exit Codes

Code

Description

0

All scans queued successfully, or all scans completed successfully when using -Wait.

1

One or more scans failed. Only returned when using -Wait.

2

Timeout reached before all scans completed. Only returned when using -Wait with -Timeout.

3

User cancelled the wait with Ctrl+C. Running scans are aborted. Only returned when using -Wait.

Examples

Scan a single computer using the default scan profile:

PDQInventory ScanComputers -Computers WORKSTATION01

Scan multiple computers with a specific scan profile:

PDQInventory ScanComputers -Computers WORKSTATION01 SERVER01 -ScanProfile "Standard"

Scan a list of computers from a text file, ignoring any not found in Inventory:

PDQInventory ScanComputers -Computers (Get-Content computers.txt) -IgnoreNotFound

Scan and wait for completion before continuing:

PDQInventory ScanComputers -Computers WORKSTATION01 SERVER01 -Wait

Scan, wait up to 5 minutes, and output results as JSON for automated processing:

PDQInventory ScanComputers -Computers WORKSTATION01 SERVER01 -ScanProfile "Standard" -Wait -Timeout 300 -Json

 

 

 

© 2026 PDQ.com Corporation. All rights reserved.

PDQ.com is a trademark of PDQ.com Corporation. All other product and company names are the property of their respective owners.

Help Version: 20.0.22.0