Block-CMConflictingRecord

Creates a blocked Configuration Manager record for client that has a conflicting record.

Syntax

Block-CMConflictingRecord
     -InputObject <IResultObject>
     [-DisableWildcardHandling]
     [-ForceWildcardHandling]
     [-WhatIf]
     [-Confirm]
     [<CommonParameters>]
Block-CMConflictingRecord
     -Id <String>
     [-DisableWildcardHandling]
     [-ForceWildcardHandling]
     [-WhatIf]
     [-Confirm]
     [<CommonParameters>]
Block-CMConflictingRecord
     -Name <String>
     [-DisableWildcardHandling]
     [-ForceWildcardHandling]
     [-WhatIf]
     [-Confirm]
     [<CommonParameters>]

Description

The Block-CMConflictingRecord cmdlet blocks a record for a client that has a conflicting record in Configuration Manager.

When Configuration Manager recognizes a new client, it uses hardware information to check whether it previously created a record for that computer. For example, you might have reinstalled the operating system. The previous client record still exists with the same hardware information. If you manually resolve conflicts, you have the option to merge the new record with the existing record, create a new record, or create a record as a blocked record. You can also configure Configuration Manager to resolve conflicts automatically.

You can specify a conflict by using a name or ID or you can use the Get-CMConflictingRecord cmdlet to obtain one.

Note

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

Examples

Example 1: Create a blocked record for a named conflict

PS XYZ:\>Block-CMConflictingRecord -Name "CR07"

This command creates a blocked record for the conflict named CR07.

Example 2: Create a blocked record by using a variable

PS XYZ:\> $CMCR = Get-CMConflictingRecord -Name "CR07"
PS XYZ:\> Block-CMConflictingRecord -ConflictingRecord $CMCR

The first command gets a conflicting record named CR07 and saves it in the $CMCR variable.

The second command creates a blocked record for the conflict in $CMCR.

Parameters

-Confirm

Prompts you for confirmation before running the cmdlet.

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

-DisableWildcardHandling

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

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

-ForceWildcardHandling

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

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

-Id

Specifies an ID for the conflicting records.

Type:String
Aliases:SmsId
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-InputObject

Specifies the input to this cmdlet. You can use this parameter, or you can pipe the input to this cmdlet.

Type:IResultObject
Aliases:ConflictingRecord
Position:Named
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-Name

Specifies a name for the conflicting records.

Type:String
Aliases:AgentName
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-WhatIf

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

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

Inputs

Microsoft.ConfigurationManagement.ManagementProvider.IResultObject

Outputs

System.Object