Set custom Remote Desktop Protocol (RDP) properties on a host pool in Azure Virtual Desktop
Članek
When users sign in to Windows App or the Remote Desktop app, desktops and applications that they have access to are shown. For each desktop and application, there is a corresponding .rdp file that contains all the connection properties to use when connecting to a remote session over the Remote Desktop Protocol (RDP). These RDP properties are set per host pool.
Each host pool has a set of default RDP properties and values. You can add other properties to the default set or override the default values by setting custom RDP properties. This article shows you how to set custom RDP properties on a host pool by using the Azure portal, Azure PowerShell, and Azure CLI.
Default host pool RDP properties
Host pools have the following RDP properties and values by default:
RDP Property
Details
audiomode:i:0
Determines whether the local or remote machine plays audio.
devicestoredirect:s:*
Determines which peripherals that use the Media Transfer Protocol (MTP) or Picture Transfer Protocol (PTP), such as a digital camera, are redirected from a local Windows device to a remote session.
drivestoredirect:s:*
Determines which fixed, removable, and network drives on the local device will be redirected and available in a remote session.
enablecredsspsupport:i:1
Determines whether the client will use the Credential Security Support Provider (CredSSP) for authentication if it's available.
redirectclipboard:i:1
Determines whether to redirect the clipboard.
redirectcomports:i:1
Determines whether serial or COM ports on the local device are redirected to a remote session.
redirectprinters:i:1
Determines whether printers available on the local device are redirected to a remote session.
redirectsmartcards:i:1
Determines whether smart card devices on the local device will be redirected and available in a remote session.
redirectwebauthn:i:1
Determines whether WebAuthn requests from a remote session are redirected to the local device allowing the use of local authenticators (such as Windows Hello for Business and security keys).
usbdevicestoredirect:s:*
Determines which supported USB devices on the client computer are redirected using opaque low-level redirection to a remote session.
use multimon:i:1
Determines whether the remote session will use one or multiple displays from the local device.
videoplaybackmode:i:1
Determines whether the connection will use RDP-efficient multimedia streaming for video playback.
In the search bar, enter Azure Virtual Desktop and select the matching service entry.
Select Host pools, then select the name of the host pool you want to update.
Select RDP Properties, then select the Advanced tab.
Add extra RDP properties or make changes to the existing RDP properties in a semicolon-separated format, like the default values already shown.
When you're done, select Save to save your changes. Users need to refresh their resources to receive the changes.
To configure RDP properties using Azure PowerShell, use the following examples. Be sure to change the <placeholder> values for your own. For a full list of supported properties and values, see Supported RDP properties with Azure Virtual Desktop.
Open Azure Cloud Shell in the Azure portal with the PowerShell terminal type, or run PowerShell on your local device.
Use one of the following examples based on your requirements:
To add custom RDP properties to a host pool and keep any existing custom properties already set, run the following commands. RDP properties need to be written in a semi-colon-separated format. This example adds disabling clipboard and printer redirection:
To replace all existing custom properties with a new set of custom RDP properties, run the following command. This example only sets disabling clipboard and printer redirection:
To remove all custom RDP properties from a host pool, run the following command. This example passes an empty string to the CustomRdpProperty parameter:
Check the custom RDP properties set on the same host pool by running the following command:
Get-AzWvdHostPool -Name $hostPool -ResourceGroupName $resourceGroup | FT Name, CustomRdpProperty
The output should be similar to the following example:
Name : contoso-hp01
CustomRdpProperty : use multimon:i:1;redirectclipboard:i:0;redirectprinters:i:0;
Users need to refresh their resources to receive the changes.
To configure RDP properties using Azure CLI, use the following examples. Be sure to change the <placeholder> values for your own. For a full list of supported properties and values, see Supported RDP properties with Azure Virtual Desktop.
Open Azure Cloud Shell in the Azure portal with the Bash terminal type, or run the Azure CLI on your local device.
Use one of the following examples based on your requirements:
To add custom RDP properties to a host pool and keep any existing custom properties already set, run the following commands. RDP properties need to be written in a semi-colon-separated format. This example adds disabling clipboard and printer redirection to the existing custom properties:
To replace all existing custom properties with a new set of custom RDP properties, run the following command. This example only sets disabling clipboard and printer redirection:
To remove all custom RDP properties from a host pool, run the following command. This example passes an empty string to the --custom-rdp-property parameter:
Check the custom RDP properties set on the same host pool by running the following command:
az desktopvirtualization hostpool show \
--name $hostPool \
--resource-group $resourceGroup \
--query "{name:name, customRdpProperty:customRdpProperty}" \
--output table
The output should be similar to the following example:
Name CustomRdpProperty
-------- ------------------------------------------------------------
contoso-hp01 use multimon:i:0;redirectclipboard:i:0;redirectprinters:i:0;
Users need to refresh their resources to receive the changes.