Unregister-​Service​Fabric​Cluster​Package

Unregisters Service Fabric runtime installation version and/or cluster manifest version from the cluster.

Syntax

Unregister-ServiceFabricClusterPackage
          -ClusterManifestVersion <String>
          -CodePackageVersion <String>
          [-Force]
          [-TimeoutSec <Int32>]
          [-Confirm]
          [-WhatIf]
          [<CommonParameters>]
Unregister-ServiceFabricClusterPackage
          -ClusterManifestVersion <String>
          [-CodePackageVersion <String>]
          [-Config]
          [-Force]
          [-TimeoutSec <Int32>]
          [-Confirm]
          [-WhatIf]
          [<CommonParameters>]
Unregister-ServiceFabricClusterPackage
          [-ClusterManifestVersion <String>]
          [-Code]
          -CodePackageVersion <String>
          [-Force]
          [-TimeoutSec <Int32>]
          [-Confirm]
          [-WhatIf]
          [<CommonParameters>]

Description

The Unregister-ServiceFabricClusterPackage cmdlet unregisters Service Fabric runtime installation version and/or cluster manifest version from the cluster. The versions should be unregistered from the cluster if the versions are no longer used. This cmdlet will fail if the version is currently being used by the cluster.

The list of all registered Service Fabric runtime installation versions registered with the cluster can be obtained by using the Get-ServiceFabricRegisteredClusterCodeVersion cmdlet.

The list of all registered cluster manifest versions registered with the cluster can be obtained by using the Get-ServiceFabricRegisteredClusterConfigVersion cmdlet.

To manage Service Fabric clusters, start Windows PowerShell by using the Run as administrator option. Before you perform any operation on a Service Fabric cluster, establish a connection to the cluster by using the Connect-ServiceFabricCluster cmdlet.

Examples

Example 1: Unregister both cluster manifest and runtime installation version from cluster

PS C:\> Unregister-ServiceFabricClusterPackage -ClusterManifestVersion "V2" -CodePackageVersion "2.0.59.0"

This command unregisters cluster manifest version "V2" and runtime installation version "2.0.59.0" from the cluster.

Example 1: Unregister just the cluster manifest version from cluster

PS C:\> Unregister-ServiceFabricClusterPackage -Config -ClusterManifestVersion "V2"

This command unregisters cluster manifest version "V2" from the cluster.

Example 1: Unregister just the runtime installation version from cluster

PS C:\> Unregister-ServiceFabricClusterPackage -Code -CodePackageVersion "2.0.59.0"

This command unregisters runtime installation version "2.0.59.0" from the cluster.

Required Parameters

-ClusterManifestVersion

Specifies the cluster manifest version to unregister from the cluster.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Code

Indicates that only the Service Fabric runtime installation version needs to be unregistered from the cluster.

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

Specifies the runtime installation version to unregister from the cluster.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Config

Indicates that only the Service Fabric cluster manifest version needs to be unregistered from the cluster.

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

Optional Parameters

-Confirm

Prompts you for confirmation before running the cmdlet.

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

Forces the command to run without asking for user confirmation.

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

Specifies the time-out period, in seconds, for the operation.

Type:Int32
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

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

Inputs

None

You cannot pipe input to this cmdlet.

Outputs

System.Object

This cmdlet returns the status of the operation as a string.