Edit

Share via


Move-RDVirtualDesktop

Moves a virtual desktop to a new Remote Desktop Virtualization Host (RD Virtualization Host) server.

Syntax

Default (Default)

Move-RDVirtualDesktop
    [-SourceHost] <String>
    [-DestinationHost] <String>
    [-Name] <String>
    [[-ConnectionBroker] <String>]
    [[-Credential] <PSCredential>]
    [<CommonParameters>]

Description

The Move-RDVirtualDesktop cmdlet moves a virtual desktop to a new Remote Desktop Virtualization Host (RD Virtualization Host) server.

Examples

Example 1: Move a virtual desktop to a new RD Virtualization Host server

PS C:\>Enable-WSManCredSSP -Role "Client" -DelegateComputer * -Force
PS C:\> Enable-WSManCredSSP -Role "Server" -DelegateComputer * -Force
PS C:\> $Creds = Get-Credential
PS C:\> Move-RDVirtualDesktop -SourceHost "rdvh-1.contoso.com" -DestinationHost "rdvh-2.contoso.com" -Name "RDS-WKS-A2" -Credential $Creds

This example moves a virtual desktop from one RD Virtualization server to another. The commands run on the RD Connection Broker and move virtual desktops from the source host to the destination host.

The first command enables Credential Security Support Provider (CredSSP) authentication on the destination host. The Enable-WSManCredSSP cmdlet delegates the client credentials to the delegate server.

The second command enables CredSSP authentication on the source host. The Enable-WSManCredSSP cmdlet delegates the server credentials to the delegate server.

The third command gets a credential object based on the user name and password that the user enters. The command stores the results in the $Creds variable.

The fourth command moves the virtual desktop named RDS-WKS-A2 from the source host named rdvh-1.contoso.com to the destination host named rdvh-2.contoso.com. The command uses the credential object stored in the $Creds variable.

Parameters

-ConnectionBroker

Specifies the Remote Desktop Connection Broker (RD Connection Broker) server for a remote desktop deployment. If you do not specify a value, the cmdlet uses the fully qualified domain name (FQDN) of the local computer.

Parameter properties

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

Parameter sets

(All)
Position:3
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Credential

Specifies a PSCredential object that contains the user credentials for the virtual desktop. Remote Desktop Services does not require user credentials if you run the cmdlet from the source host. If you do not specify user credentials for the virtual desktop and you run the cmdlet on a remote host, the server prompts you for credentials.

Parameter properties

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

Parameter sets

(All)
Position:4
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-DestinationHost

Specifies the fully qualified domain name (FQDN) of the new RD Virtualization Host server for the virtual desktop.

Parameter properties

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

Parameter sets

(All)
Position:1
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Name

Specifies the name of a virtual desktop.

Parameter properties

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

Parameter sets

(All)
Position:2
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-SourceHost

Specifies the fully qualified domain name (FQDN) of the current RD Virtualization Host server for the virtual desktop.

Parameter properties

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

Parameter sets

(All)
Position:0
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

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.

Outputs

undefined