Share via


Start-Scan

Instructs the Microsoft Purview Information Protection scanner to start a one-time scan cycle.

Syntax

Start-Scan
     [-Reset]
     [-Force]
     [<CommonParameters>]

Description

The Start-Scan cmdlet instructs the Microsoft Purview Information Protection scanner to immediately start a one-time scan cycle. The scanner service must be started already and the scanner schedule must be configured for a manual schedule.

To configure the schedule, use the Microsoft Purview portal or the Microsoft Purview compliance portal to configure the scanner.

By default, all files are scanned the first time the scanner runs and then, unless the information protection policy is changed, only new or changed files are scanned. However, you can change this behavior when you use the -Reset parameter with this cmdlet, which forces the scanner to scan all files.

Note

If the scanner schedule is set to Always, this cmdlet is ignored.

Examples

Example 1: Initiate immediate one-time scan for new and changed files

PS C:\> Start-Scan

Because the scanner ran before, and the information protection scanner policy wasn't changed since the last scanning cycle, the scanner initiates an incremental scan for all new or changed files since the last scanning cycle.

Example 2: Initiate immediate one time scan for all files

PS C:\> Start-Scan -Reset

The scanner initiates a full scan of all the files, even if they were scanned before and the information protection scanner policy wasn't changed.

Parameters

-Force

Forces the command to run without asking for user confirmation.

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Reset

Resets the scanner cache so that the scanner initiates a full scan of all the files, even if they were scanned before and the information protection scanner policy wasn't changed.

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

Inputs

None

Outputs

System.Object