Citrix Daas SDK

Remove-HypMetadata

Removes metadata from a hypervisor connection or hosting unit.

Syntax

Remove-HypMetadata
      [-Property <String>]
      [-LiteralPath] <String>
      [-LoggingId <Guid>]
      [<CitrixCommonParameters>]
      [<CommonParameters>]
<!--NeedCopy-->

Description

Use this command to remove custom data from a specific hosting unit or hypervisor connection. If the Property parameter is not provided, all metadata is removed from the specified item.

Examples

EXAMPLE 1

The command removes the metadata with the property “MyProperty” from the hypervisor connection called “MyConnection”.

Remove-HypMetadata -LiteralPath XDHyp:\Connections\MyConnection -Property MyProperty
<!--NeedCopy-->

EXAMPLE 2

The command removes all the metadata from the hypervisor connection called “MyConnection”.

Remove-HypMetadata -LiteralPath XDHyp:\Connections\MyConnection
<!--NeedCopy-->

EXAMPLE 3

The command removes all the metadata from all the hypervisor connections.

dir XDHyp:\connections | Remove-HypMetadata
<!--NeedCopy-->

Parameters

-LiteralPath

Specifies the path within a Host Service provider to the hosting unit or hypervisor connection item from which to remove the metadata. The path specified must be in one of the following formats:

<drive>:\HostingUnits\<HostingUnitName>

or <drive>:\HostingUnits{<HostingUnit Uid>}

or <drive>:\Connections\<Connection Name>

or <drive>:\Connections{<Connection Uid>}

Type: String
Position: 1
Default value: None
Required: True
Accept pipeline input: True (ByValue)
Accept wildcard characters: False

-Property

Specifies the property name of the metadata to be removed.

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

-LoggingId

Specifies the identifier of the high-level operation this cmdlet call forms a part of. Citrix Studio and Director typically create high-level operations. PowerShell scripts can also wrap a series of cmdlet calls in a high-level operation by way of the Start-LogHighLevelOperation and Stop-LogHighLevelOperation cmdlets.

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

CitrixCommonParameters

This cmdlet supports the common Citrix parameters: -AdminAddress, -AdminClientIP, -BearerToken, -TraceParent, -TraceState and -VirtualSiteId. For more information, see about_CitrixCommonParameters.

CommonParameters

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

Inputs

String

You can pipe a string that contains a path to Remove-HypMetadata (Path parameter).

Outputs

None

By default, this cmdlet returns no output.

Notes

In the case of failure, the following errors can result.

Error Codes


InvalidPath

The path provided is not in the required format.

HostingUnitMetadataObjectToDeleteDoesNotExist

The hosting unit supplied in the path does not exist.

HypervisorConnectionObjectToDeleteDoesNotExist

The hypervisor connection supplied in the path does not exist.

MetadataContainerUndefined

The specified path does not reference a hosting unit or a hypervisor connection.

DatabaseError

An error occurred in the service while attempting a database operation.

DatabaseNotConfigured

The operation could not be completed because the database for the service is not configured.

DataStoreException

An error occurred in the service while attempting a database operation - communication with the database failed for

various reasons.

CommunicationError

An error occurred while communicating with the service.

PermissionDenied

The user does not have administrative rights to perform this operation.

ExceptionThrown

An unexpected error occurred. To locate more details, see the Windows event logs on the controller being used or examine the XenDesktop logs.

Remove-HypMetadata