Remove-CMDistributionPoint
Remove-CMDistributionPoint
Removes a distribution point.
Syntax
Parameter Set: SearchByNameMandatory
Remove-CMDistributionPoint -SiteCode <String> -SiteSystemServerName <String> [-Force] [-Confirm] [-WhatIf] [ <CommonParameters>]
Parameter Set: SearchByValueMandatory
Remove-CMDistributionPoint -InputObject <IResultObject> [-Force] [-Confirm] [-WhatIf] [ <CommonParameters>]
Detailed Description
The Remove-CMDistributionPoint cmdlet removes a distribution point. When you remove a distribution point, you remove the designation of a site system server to function as a distribution center for content files for applications, packages, software updates, and operating system deployment.
Parameters
-Force
Forces the command to run without asking for user confirmation.
Aliases |
none |
Required? |
false |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
True (ByPropertyName) |
Accept Wildcard Characters? |
false |
-InputObject<IResultObject>
Specifies a CMDistributionPoint object. To obtain a CMDistributionPoint object, use the Get-CMDistributionPoint cmdlet.
Aliases |
none |
Required? |
true |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
True (ByPropertyName) |
Accept Wildcard Characters? |
false |
-SiteCode<String>
Specifies the site code that is associated with the distribution point.
Aliases |
none |
Required? |
true |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
True (ByPropertyName) |
Accept Wildcard Characters? |
false |
-SiteSystemServerName<String>
Specifies a fully qualified domain name (FQDN) of the server that hosts the site system role.
Aliases |
none |
Required? |
true |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
True (ByPropertyName) |
Accept Wildcard Characters? |
false |
-Confirm
Prompts you for confirmation before running the cmdlet.
Required? |
false |
Position? |
named |
Default Value |
false |
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
-WhatIf
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Required? |
false |
Position? |
named |
Default Value |
false |
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
<CommonParameters>
This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216).
Inputs
The input type is the type of the objects that you can pipe to the cmdlet.
Outputs
The output type is the type of the objects that the cmdlet emits.
Examples
Example 1: Remove a distribution point by using a site code and site system role
This command removes the distribution point that is associated with the site code CM1 and the site system role named CMCEN-DIST02.TSQA.CORP.CONTOSCO.COM.
PS C:\> Remove-CMDistributionPoint -SiteSystemServerName "CMCEN-DIST02.TSQA.CORP.CONTOSCO.COM" -SiteCode "CM1"
Example 2: Remove a distribution point by using an object variable
The first command gets a distribution that is associated with the site code ST1 and the site system role named PptCmdv-1.DIST01.CORP.CONTOSCO.com. The command stores the results to the $Di variable.
The second command removes the distribution point stored in the $Di variable.
PS C:\> $Di = Get-CMDistributionPoint -SiteSystemServerName "PptCmdv-1.DIST01.CORP.CONTOSCO.com" -SiteCode "ST1"
PS C:\> Remove-CMDistributionPoint -InputObject $Di