Remote Desktop Cmdlets in Windows PowerShell

Windows PowerShell® es un lenguaje de scripting y shell de línea de comandos basado en tareas diseñado especialmente para la administración del sistema. En este tema de referencia para los profesionales de tecnologías de la información (TI) ofrece ayuda en el uso de los cmdlets de Windows PowerShell para crear scripts y automatizar las tareas.

Remote Desktop Services Cmdlets

This reference provides cmdlet descriptions and syntax for all Remote Desktop Service-specific cmdlets. It lists the cmdlets in alphabetical order based on the verb at the beginning of the cmdlet.

Cmdlet Description

Add-RDServer

Adds a server to a remote desktop deployment.

Add-RDSessionHost

Adds one or more Remote Desktop Session Host (RD Session Host) servers to a session collection.

Add-RDVirtualDesktopToCollection

Adds one or more virtual desktops to an existing virtual desktop collection.

Disable-RDVirtualDesktopADMachineAccountReuse

Prevents the Remote Desktop Connection Broker (RD Connection Broker) server from reusing existing Active Directory (AD) computer accounts when creating new virtual machines from a template in a managed virtual desktop collection.

Disconnect-RDUser

Disconnects a specified user from a session running on the remote server.

Enable-RDVirtualDesktopADMachineAccountReuse

Configures the Remote Desktop Connection Broker (RD Connection Broker) server to reuse existing Active Directory (AD) computer accounts for pooled virtual desktops created from a template in a managed collection.

Export-RDPersonalVirtualDesktopAssignment

Saves the current associations between users and personal virtual personal desktops to a delimited text file.

Get-RDAvailableApp

Gets a list of applications that can be published from the collection specified in the CollectionName parameter.

Get-RDCertificate

Gets the certificate associated with a Remote Desktop Services role.

Get-RDConnectionBrokerHighAvailability

Retrieves the high availability settings for the Remote Desktop Connection Broker (RD Connection Broker) server.

Get-RDDeploymentGatewayConfiguration

Gets configuration settings for the Remote Desktop Gateway (RD Gateway) for the remote desktop deployment.

Get-RDFileTypeAssociation

Displays the file extensions associated with a given RemoteApp program.

Get-RDLicenseConfiguration

Gets the current settings for the RD Licensing server and licensing mode of the remote desktop deployment.

Get-RDPersonalVirtualDesktopAssignment

Gets a list of personal virtual desktops and associated user accounts.

Get-RDPersonalVirtualDesktopPatchSchedule

Gets patch schedule details for the specified personal virtual desktop.

Get-RDRemoteApp

Gets a list of RemoteApp programs for a given collection or for the remote desktop deployment.

Get-RDRemoteDesktop

Gets a list of published remote desktops in the collection.

Get-RDServer

Gets a list of servers in a remote desktop deployment.

Get-RDSessionCollection

Gets a list of session collections in the remote desktop deployment.

Get-RDSessionCollectionConfiguration

Gets configuration details for the specified session collection.

Get-RDSessionHost

Gets a list of Remote Desktop Session Host (RD Session Host) servers in a session collection.

Get-RDUserSession

Gets a list of all user sessions in a collection, or in the remote desktop deployment.

Get-RDVirtualDesktop

Gets a list of virtual desktops in the remote desktop deployment.

Get-RDVirtualDesktopCollection

Gets a list of existing virtual desktops in a remote desktop deployment.

Get-RDVirtualDesktopCollectionConfiguration

Gets configuration details for the specified virtual desktop collection.

Get-RDVirtualDesktopCollectionJobStatus

Gets status information for the job run most recently on the specified virtual desktop collection.

Get-RDVirtualDesktopConcurrency

Gets the number of virtual desktops that can be created in parallel on the specified Remote Desktop Virtualization Host (RD Virtualization Host) servers.

Get-RDVirtualDesktopIdleCount

Get-RDVirtualDesktopTemplateExportPath

Gets the export path setting of the virtual desktop template used for the virtual-machine based desktop deployment.

Get-RDWorkspace

Gets the workspace name for a remote desktop deployment.

Grant-RDOUAccess

Grants access to the Remote Desktop Connection Broker (RD Connection Broker) server for one or more organizational units (OUs) in a given domain of the Active Directory Domain Services (AD DS) server.

Import-RDPersonalVirtualDesktopAssignment

Creates associations between user accounts and personal virtual desktops by importing the settings specified in a delimited text file.

Invoke-RDUserLogoff

Ends the specified session, closing all running applications.

Move-RDVirtualDesktop

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

New-RDCertificate

Creates a new certificate for a Remote Desktop Services role.

New-RDPersonalVirtualDesktopPatchSchedule

Creates a new patch schedule for a personal virtual desktop.

New-RDRemoteApp

Publishes a RemoteApp program to the remote desktop deployment.

New-RDSessionCollection

Creates a new session collection from the specified Remote Desktop Session Host (RD Session Host) servers.

New-RDSessionDeployment

Installs the required role services for a Virtual Desktop Infrastructure (VDI) to create a Remote Desktop Services session-based desktop deployment.

New-RDVirtualDesktopCollection

Creates a new virtual desktop collection.

New-RDVirtualDesktopDeployment

Installs required role services for Virtual Desktop Infrastructure (VDI) to create a virtual machine-based desktop deployment.

Remove-RDPersonalVirtualDesktopAssignment

Removes the association between a personal virtual desktop and a user.

Remove-RDPersonalVirtualDesktopPatchSchedule

Deletes an existing patch schedule from the specified personal virtual desktop.

Remove-RDRemoteApp

Removes a RemoteApp program from a remote desktop deployment.

Remove-RDServer

Removes the specified server from a remote desktop deployment.

Remove-RDSessionCollection

Removes a session collection from the remote desktop deployment.

Remove-RDSessionHost

Removes one or more Remote Desktop Session Host (RD Session Host) servers from a session collection.

Remove-RDVirtualDesktopCollection

Deletes the specified virtual desktop collection from a remote desktop deployment.

Remove-RDVirtualDesktopFromCollection

Removes a virtual desktop from the specified virtual desktop collection.

Send-RDUserMessage

Sends a system message to the specified user session.

Set-RDActiveManagementServer

Sets the active Remote Desktop Connection Broker (RD Connection Broker) server, or management server, in a remote desktop deployment.

Set-RDCertificate

Specifies configuration details of a certificate for use with a Remote Desktop Services role.

Set-RDClientAccessName

Set-RDConnectionBrokerHighAvailability

Specifies high availability settings for the Remote Desktop Connection Broker (RD Connection Broker) server.

Set-RDDatabaseConnectionString

Configures the database connection string to the SQL Server database that you have set up for high availability.

Set-RDDeploymentGatewayConfiguration

Specifies settings for the Remote Desktop Gateway (RD Gateway) server for the remote desktop deployment.

Set-RDFileTypeAssociation

Modifies the file type association of a RemoteApp program in the remote desktop deployment.

Set-RDLicenseConfiguration

Specifies settings for the Remote Desktop Licensing (RD Licensing) server and licensing mode of the remote desktop deployment.

Set-RDPersonalVirtualDesktopAssignment

Creates an association between a personal virtual desktop and a user account.

Set-RDPersonalVirtualDesktopPatchSchedule

Configures patch schedule settings for a personal virtual desktop with an existing patch schedule.

Set-RDRemoteApp

Specifies configuration details for a RemoteApp program running in the remote desktop deployment.

Set-RDRemoteDesktop

Publishes a remote desktop to the specified collection.

Set-RDSessionCollectionConfiguration

Specifies configuration options for an existing session collection.

Set-RDSessionHost

Configures one or more Remote Desktop Session Host (RD Session Host) servers in a session collection.

Set-RDVirtualDesktopCollectionConfiguration

Specifies configuration details for an existing virtual desktop collection.

Set-RDVirtualDesktopConcurrency

Specifies the number of virtual desktops that can be created in parallel on the specified Remote Desktop Virtualization Host (RD Virtualization Host) servers.

Set-RDVirtualDesktopIdleCount

Set-RDVirtualDesktopTemplateExportPath

Configures the path to use when exporting the virtual desktop templates for the virtual machine-based desktop deployment.

Set-RDWorkspace

Assigns a workspace name for a remote desktop deployment.

Stop-RDVirtualDesktopCollectionJob

Forcibly ends a job that is currently running, or is scheduled to run, on the specified virtual desktop collection.

Test-RDOUAccess

Verifies that the Remote Desktop Connection Broker (RD Connection Broker) server has access to the Active Directory Domain Services (AD DS) organizational unit (OU).

Test-RDVirtualDesktopADMachineAccountReuse

Detects whether the Remote Desktop Connection Broker (RD Connection Broker) server is configured to reuse existing Active Directory (AD) computer accounts when creating new virtual machines from a template in a managed virtual desktop collection.

Update-RDVirtualDesktopCollection

Associates an existing virtual desktop collection with a new virtual desktop template.

Nota

To list all the cmdlets that are available, use the Get-Command –Module RemoteDesktopServices cmdlet.

Para conocer más información o la sintaxis de cualquiera de los cmdlets, use el cmdlet Get-Help <nombre de cmdlet>, donde <nombre de cmdlet> es el nombre del cmdlet del que quiere información. Para obtener información más detallada, puede ejecutar cualquiera de los siguientes cmdlets:

Get-Help <nombre de cmdlet> -Detailed
Get-Help <nombre de cmdlet> -Examples
Get-Help <nombre de cmdlet> -Full