Note

Access to this page requires authorization. You can try signing in or .

Access to this page requires authorization. You can try .

New-CMTSStepPrestartCheck

Create a Check Readiness step, which you can add to a task sequence.

Syntax

Default (Default)

New-CMTSStepPrestartCheck
 [-CheckCMClientMinVersion <Boolean>]
 [-CheckMaxOSVersion <Boolean>]
 [-CheckMemory <Boolean>]
 [-CheckMinOSVersion <Boolean>]
 [-CheckNetworkConnected <Boolean>]
 [-CheckNetworkWired <Boolean>]
 [-CheckTpmEnabled <Boolean>]
 [-CheckTpmActivated <Boolean>]
 [-CheckOS <Boolean>]
 [-CheckOSArchitecture <Boolean>]
 [-CheckOSLanguageId <Boolean>]
 [-CheckPowerState <Boolean>]
 [-CheckSpace <Boolean>]
 [-CheckSpeed <Boolean>]
 [-CheckUefi <Boolean>]
 [-CMClientMinVersion <String>]
 [-DiskSpace <Int32>]
 [-MaxOSVersion <String>]
 [-Memory <Int32>]
 [-MinOSVersion <String>]
 [-OS <OSType>]
 [-OSArchitecture <OSArch>]
 [-OSLanguageId <Int32>]
 [-Speed <Int32>]
 [-Condition <IResultObject[]>]
 [-ContinueOnError]
 [-Description <String>]
 [-Disable]
 -Name <String>
 [-DisableWildcardHandling]
 [-ForceWildcardHandling]
 [-WhatIf]
 [-Confirm]
 [<CommonParameters>]

Description

This cmdlet creates a new Check Readiness step object. Then use the Add-CMTaskSequenceStep cmdlet to add the step to a task sequence. For more information on this step, see About task sequence steps: Check Readiness.

Note

Run Configuration Manager cmdlets from the Configuration Manager site drive, for example PS XYZ:\>. For more information, see getting started.

Examples

Example 1

This example first splats the cmdlet parameters into the parameters variable.

Next it creates an object for the Check Readiness step, passing the collection of values in parameters.

It then gets a task sequence object, and adds this new step to the task sequence at index 11.

$parameters = @{
 Name = "Check Readiness"
 CheckMemory = $true
 Memory = 4096
 CheckSpeed = $true
 Speed = 1024
 CheckSpace = $true
 DiskSpace = 512000
 CheckOS = $true
 OS = "Client"
 CheckOSArchitecture = $true
 OSArchitecture = "Arch64"
 CheckMinOSVersion = $true
 MinOSVersion = "10.0.16299"
 CheckMaxOSVersion = $true
 MaxOSVersion = "10.0.99999"
 CheckCMClientMinVersion = $true
 CMClientMinVersion = "5.00.8913.1005"
 CheckOSLanguageId = $true
 OSLanguageID = 1033
 CheckPowerState = $true
 CheckNetworkConnected = $true
 CheckNetworkWired = $false
 CheckUefi = $true
}

$step = New-CMTSStepPrestartCheck @parameters

$tsNameOsd = "Default OS deployment"
$tsOsd = Get-CMTaskSequence -Name $tsNameOsd -Fast

$tsOsd | Add-CMTaskSequenceStep -Step $step -InsertStepStartIndex 11

Parameters

-CheckCMClientMinVersion

Set this parameter to $true to enable the Minimum client version check. Use the parameter CMClientMinVersion to set the specific client version number.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False
Aliases:CheckClientMinVersion

Parameter sets

-CheckMaxOSVersion

Set this parameter to $true to enable the Maximum OS version check. Use the parameter MaxOSVersion to set the specific OS version number.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False
Aliases:EnableCheckMaxOSVersion

Parameter sets

-CheckMemory

Set this parameter to $true to enable the Minimum memory (MB) check. Use the parameter Memory to set the specific memory size.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False
Aliases:EnableCheckMemory

Parameter sets

-CheckMinOSVersion

Set this parameter to $true to enable the Minimum OS version check. Use the parameter MinOSVersion to set the specific OS version number.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False
Aliases:EnableCheckMinOSVersion

Parameter sets

-CheckNetworkConnected

Set this parameter to $true to enable the Network adapter connected check.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False
Aliases:NetworkConnected

Parameter sets

-CheckNetworkWired

Set this parameter to $true to enable the Network adapter is not wireless check.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False
Aliases:NetworkWired

Parameter sets

-CheckOS

Set this parameter to $true to enable the check for the type of OS, either client or server. Use the parameter OS to set the specific OS type.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False
Aliases:EnableCheckOSType

Parameter sets

-CheckOSArchitecture

Set this parameter to $true to enable the Architecture of current OS check. Use the parameter OSArchitecture to set the specific architecture type.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False
Aliases:EnableCheckOSArchitecture

Parameter sets

-CheckOSLanguageId

Set this parameter to $true to enable the check of the Language of current OS. Use the parameter OSLanguageID to set the specific language.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False
Aliases:EnableOSLanguageId

Parameter sets

-CheckPowerState

Set this parameter to $true to enable the AC power plugged in check.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False
Aliases:NotBattery

Parameter sets

-CheckSpace

Set this parameter to $true to enable the Minimum free disk space (MB) check. Use the parameter DiskSpace to set the specific size.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False
Aliases:EnableCheckFreeDiskSpace

Parameter sets

-CheckSpeed

Set this parameter to $true to enable the Minimum processor speed (MHz) check. Use the parameter Speed to set the specific speed.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False
Aliases:EnableCheckProcessorSpeed

Parameter sets

-CheckTpmActivated

Applies to version 2111 and later. Set this parameter to $true to enable the TPM 2.0 or above is activated check.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False
Aliases:TpmActivated

Parameter sets

-CheckTpmEnabled

Applies to version 2111 and later. Set this parameter to $true to enable the TPM 2.0 or above is enabled check.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False
Aliases:TpmEnabled

Parameter sets

-CheckUefi

Applies to version 2006 and later. Set this parameter to $true to enable the Computer is in UEFI mode check.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

-CMClientMinVersion

Use this parameter to configure the specific client version. Specify the client version in the following format: 5.00.8913.1005. Use the parameter CheckCMClientMinVersion to enable or disable the check.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False
Aliases:ClientMinVersion

Parameter sets

-Condition

Specify a condition object to use with this step. To get this object, use one of the task sequence condition cmdlets. For example, Get-CMTSStepConditionVariable.

Parameter properties

Type:

IResultObject[]

Default value:None
Supports wildcards:False
DontShow:False
Aliases:Conditions

Parameter sets

-Confirm

Prompts you for confirmation before running the cmdlet.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False
Aliases:cf

Parameter sets

-ContinueOnError

Add this parameter to enable the step option Continue on error. When you enable this option, if the step fails, the task sequence continues.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

-Description

Specify an optional description for this task sequence step.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

-Disable

Add this parameter to disable this task sequence step.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False
Aliases:DisableThisStep

Parameter sets

-DisableWildcardHandling

This parameter treats wildcard characters as literal character values. You can't combine it with ForceWildcardHandling.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

-DiskSpace

Use this parameter to configure the specific size for the minimum free disk space check. Specify an integer value for the size in MB. Use the parameter CheckSpace to enable or disable the check.

Parameter properties

Type:Int32
Default value:None
Supports wildcards:False
DontShow:False
Aliases:MinimumFreeDiskSpace

Parameter sets

-ForceWildcardHandling

This parameter processes wildcard characters and may lead to unexpected behavior (not recommended). You can't combine it with DisableWildcardHandling.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

-MaxOSVersion

Use this parameter to configure the specific OS version. Specify the maximum OS version with major version, minor version, and build number. For example, 10.0.18356. Use the parameter CheckMaxOSVersion to enable or disable the check.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False
Aliases:CurrentMaxOSVersion

Parameter sets

-Memory

Use this parameter to configure the specific size for the minimum memory check. Specify an integer value for the size in MB. Use the parameter CheckMemory to enable or disable the check.

Parameter properties

Type:Int32
Default value:None
Supports wildcards:False
DontShow:False
Aliases:MinimumMemory

Parameter sets

-MinOSVersion

Use this parameter to configure the specific OS version. Specify the minimum OS version with major version, minor version, and build number. For example, 10.0.16299. Use the parameter CheckMinOSVersion to enable or disable the check.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False
Aliases:CurrentMinOSVersion

Parameter sets

-Name

Specify a name for this step to identify it in the task sequence.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False
Aliases:StepName

Parameter sets

-OS

Use this parameter to configure the specific OS type: Client or Server. Use the parameter CheckOS to enable or disable the check.

Parameter properties

Type:OSType
Default value:None
Accepted values:Client, Server
Supports wildcards:False
DontShow:False
Aliases:CurrentOSType

Parameter sets

-OSArchitecture

Use this parameter to configure the specific OS architecture: Arch32 for 32-bit or Arch64 for 64-bit. Use the parameter CheckOSArchitecture to enable or disable the check.

Parameter properties

Type:OSArch
Default value:None
Accepted values:Arch32, Arch64
Supports wildcards:False
DontShow:False
Aliases:CurrentOSArchitecture

Parameter sets

-OSLanguageId

Use this parameter to configure the specific OS language. This check compares the language ID to the OSLanguage property of the Win32_OperatingSystem WMI class on the client. For example, 1033 for English (United States). Use the parameter CheckOSLanguageId to enable or disable the check.

Parameter properties

Type:Int32
Default value:None
Supports wildcards:False
DontShow:False
Aliases:LanguageId

Parameter sets

-Speed

Use this parameter to configure the specific speed for the minimum processor speed check. Specify an integer value for the speed in MHz. Use the parameter CheckSpeed to enable or disable the check.

Parameter properties

Type:Int32
Default value:None
Supports wildcards:False
DontShow:False
Aliases:MinimumProcessorSpeed

Parameter sets

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet doesn't run.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False
Aliases:wi

Parameter sets

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

Inputs

None

Outputs

IResultObject

Notes

For more information on this return object and its properties, see SMS_TaskSequence_PrestartCheckAction server WMI class.

Related Links


Feedback

Was this page helpful?