|
| 1 | +--- |
| 2 | +title: Resolve Dev Box connectivity issues |
| 3 | +description: Learn how to resolve connection issues with dev boxes, including disconnections and sign-in problems, to maintain a stable workflow. |
| 4 | +author: RoseHJM |
| 5 | +ms.author: rosemalcolm |
| 6 | +ms.service: dev-box |
| 7 | +ms.topic: troubleshooting-general |
| 8 | +ms.date: 10/22/2024 |
| 9 | + |
| 10 | +#customer intent: As a developer, I want to troubleshoot my Remote Desktop connection issues with dev boxes so that I can maintain a stable and efficient workflow. |
| 11 | +--- |
| 12 | + |
| 13 | +# Resolve connectivity issues with dev boxes |
| 14 | + |
| 15 | +If you're experiencing problems with your Remote Desktop connection to your dev box, this guide can help you find and fix the issues quickly. Whether it's frequent disconnections, latency, or sign-in problems, we've got solutions that can get you back on track. |
| 16 | + |
| 17 | +## Prerequisites |
| 18 | + |
| 19 | +Before you begin troubleshooting, ensure you have: |
| 20 | + |
| 21 | +- Access to your dev box. |
| 22 | +- Administrative permissions if needed. |
| 23 | +- An understanding of your organization's policies related to dev boxes. |
| 24 | + |
| 25 | +## Steps for troubleshooting |
| 26 | + |
| 27 | +Remote Desktop connections are essential for accessing your Dev Box. However, connectivity issues can sometimes arise due to various factors. This guide provides a comprehensive step-by-step approach to troubleshooting common Remote Desktop connection problems, ensuring that your workflow remains uninterrupted. |
| 28 | + |
| 29 | +Before proceeding with troubleshooting, ensure that your Remote Desktop app is updated and both your client computer, and Dev Box have the latest updates installed. |
| 30 | + |
| 31 | +Any improper network configurations on your Dev Box can disrupt Remote Desktop connections. |
| 32 | + |
| 33 | +Additionally, if you haven't accessed your Dev Box for some time, check whether your organization has a policy that removes users from Microsoft Entra ID due to inactivity. To regain access, contact your support team. |
| 34 | + |
| 35 | +### Step 0: Preliminary Checks |
| 36 | +1. **Internet Connection:** Verify that your local machine has an active internet connection. |
| 37 | +1. **Dev Box Status:** Confirm that your Dev Box is running through the Dev Box portal. |
| 38 | +1. **Proxy Settings:** Incorrect internet proxy settings can interfere with the Remote Desktop experience, so ensure these settings are correctly configured. |
| 39 | + |
| 40 | +### Step 1: Windows Update and App Restart |
| 41 | +1. **Pending Updates:** If Windows is updating, it can take up to 30 minutes, during which your Dev Box won't connect. |
| 42 | +1. **Restart Remote Desktop:** Close all instances of the Remote Desktop app, terminate any 'msrdc.exe' and 'msrdcw.exe' processes via Task Manager, and then to attempt reconnection, reopen the app. |
| 43 | + |
| 44 | +### Step 2: Address App Hang and Authentication Issues |
| 45 | +1. **App Hang:** If the Remote Desktop app hangs, capture a process dump of MSRDC.exe and create a support request. Restart your computer and try connecting again. |
| 46 | +1. **Authentication Errors:** If denied sign-in despite correct credentials, check the join status using `dsregcmd.exe /status`. Resolve any errors with your support team and restart your computer. If authentication errors persist, unsubscribe and resubscribe to your Dev Box pool in the app. |
| 47 | + |
| 48 | +### Step 3: Browser Client Connection |
| 49 | +1. **Browser Access:** Attempt to connect via the browser client by visiting https://DevBox.microsoft.com and selecting "Open in browser". |
| 50 | +1. **Black Screen Issue:** If the Remote Desktop Protocol (RDP) window is black, "Shutdown" or "Stop" your Dev Box via the portal and restart it. |
| 51 | + |
| 52 | +### Step 4: Connection Drops During High CPU Load |
| 53 | +**Registry Adjustment:** If you experience frequent connection drops with the Remote Desktop app during high CPU load, ensure your Dev Box has the latest Windows 11 build. Set the `SetGpuRealtimePriority` registry value to DWORD 2 in the Dev Box and restart. |
| 54 | + |
| 55 | +``` |
| 56 | +key: HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server\WinStations |
| 57 | +value name: SetGpuRealtimePriority |
| 58 | +value: DWORD 2 |
| 59 | +``` |
| 60 | + |
| 61 | +You can set the `SetGpuRealtimePriority` registry value by using this command in an elevated shell: |
| 62 | + |
| 63 | +``` |
| 64 | +reg add "HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server\WinStations" /v SetGpuRealtimePriority /d 2 /t REG_DWORD |
| 65 | +``` |
| 66 | + |
| 67 | +### Step 5: Connection Drops During Low CPU Usage |
| 68 | + |
| 69 | +If you experience frequent connection drops with the Remote Desktop app despite low CPU usage on the Dev Box, switch Remote Desktop to use TCP instead of UDP. |
| 70 | + |
| 71 | +You can configure this setting through a registry edit, or through Group Policy. |
| 72 | + |
| 73 | +#### Use TCP instead of UDP - Registry edit: |
| 74 | +Close the Remote Desktop app, apply the following registry setting on your client computer, and try reconnecting. |
| 75 | + |
| 76 | +``` |
| 77 | +key: HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services\Client |
| 78 | +value name: fClientDisableUDP |
| 79 | +value: DWORD 1 |
| 80 | +``` |
| 81 | + |
| 82 | +You can set the `fClientDisableUDP` registry value by using this command in an elevated shell: |
| 83 | + |
| 84 | +``` |
| 85 | +reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services\Client" /v fClientDisableUDP /d 1 /t REG_DWORD |
| 86 | +``` |
| 87 | + |
| 88 | +#### Use TCP instead of UDP - Group policy: |
| 89 | +Alternatively, use Group Policy Editor on your Dev Box to set RDP transport protocols to "Use only TCP". |
| 90 | + |
| 91 | +1. Open the Group Policy Editor on your Dev Box. |
| 92 | +1. Navigate to **Computer Configuration > Administrative Templates > Windows Components > Remote Desktop Services > Remote Desktop Session Host > Connections**. |
| 93 | +1. Open the policy setting **Select RDP transport protocols**. |
| 94 | +1. Set it to **Enabled**. |
| 95 | +1. For **Select Transport Type**, select **Use only TCP**. |
| 96 | + |
| 97 | +If the preceding steps don't resolve your issue, contact your support team. |
| 98 | + |
| 99 | +Include the following details in your incident report: |
| 100 | + |
| 101 | +- The time the issue occurred |
| 102 | +- Impacted users |
| 103 | +- A detailed description of the problem |
| 104 | +- The Activity ID from your Remote Desktop session, if available. You can find this ID by clicking on the connection bar during your session. |
| 105 | + |
| 106 | + :::image type="content" source="media/how-to-resolve-dev-box-connectivity-issues/troubleshooting-connection-bar.png" alt-text="Screenshot that shows the Remote Desktop connection bar."::: |
| 107 | + |
| 108 | +- Include information from the connection dialog. |
| 109 | + |
| 110 | + :::image type="content" source="media/how-to-resolve-dev-box-connectivity-issues/troubleshooting-connection-information-dialog.png" alt-text="Screenshot that shows the Troubleshooting connection information dialog box."::: |
| 111 | + |
| 112 | +In macOS clients, use the terminal to change connections to TCP instead of UDP: |
| 113 | + |
| 114 | +In the app: |
| 115 | +``` |
| 116 | +defaults write com.microsoft.rdc.macos ClientSettings.EnableAvdUdpSideTransport false |
| 117 | +``` |
| 118 | + |
| 119 | +In the beta app: |
| 120 | +``` |
| 121 | +defaults write com.microsoft.rdc.osx.beta ClientSettings.EnableAvdUdpSideTransport false |
| 122 | +``` |
| 123 | + |
| 124 | + |
| 125 | +## Related content |
| 126 | +- [Troubleshoot and resolve dev box Remote Desktop connectivity issues](how-to-troubleshoot-repair-dev-box.md) |
| 127 | +- [Get support for Microsoft Dev Box](how-to-get-help.md) |
0 commit comments