Remote Desktop can t connect to the remote computer for one of these reasons

Khắc phục lỗi "remote desktop can't connect to remote computer" - Hướng dẫn chi tiết nhất

chaupm
1403
24-11-2020

Bên cạnh sự tiện lợi, sự gia tăng nhu cầu làm việc tại nhà cũng thúc đẩy nhu cầu sử dụng các máy tính kết nối từ xa. Tuy nhiên, có thể xảy ra một số lỗi kỹ thuật trong quá trình sử dụng, bao gồm các lỗi phổ biến như "remote desktop không thể kết nối với máy tính từ xa".

Vậy, làm thế nào để khắc phục lỗi này? Để trả lời này hãy cùngBizfly Cloud tìm hiểu một số thông tin cơ bản.

Remote desktop là một tính năng tiện lợi cho phép kết nối ảo với các máy tính khác chạy hệ điều hành Windows. Với tính năng này, người dùng có thể kết nối với các máy tính ở bất kỳ nơi nào trên thế giới, miễn là họ có thông tin đăng nhập (tên người dùng và mật khẩu) phù hợp để kết nối. Ngoài ra, kết nối mạng khỏe cũng là một yêu cầu quan trọng!

Nếu đã có thông tin đăng nhập và kết nối mạng ổn định mà vẫn gặp sự cố này, dưới đây là cách giải quyết:

What causes Remote Desktop connections to fail in Windows?

Although there can be a number of reasons due to which the Remote Desktop connection can fail in Windows, the most frequent cause is having an unstable internet connection or mismatching login credentials. Apart from these reasons, there are some other known causes for the Remote Desktop functionality to break in Windows 10. These are:

  • RDP not working after Windows Update: The Remote Desktop functionality might not work properly after you have upgraded or updated your Windows. Well, it happens because the update might have corrupted the RDP functionality of Windows and would need manual intervention to fix it.
  • Antivirus / Firewall issue: Sometimes, if you install an antivirus, it might block some of the features of RDP in Windows due to which you would not be able to connect successfully to a remote Windows computer.
  • Network Profile Issue: Most of the times, if you have a public network profile or network group in Windows then the remote desktop functionalities will be blocked.

You can follow some of these solutions below in order to get your RDP in Windows to work correctly.

Solution 1: Change/Tweak your Firewall Settings

This thing is a must to do if you are having problems with RDP. Most of the times your firewall will block some incoming and outgoing connections by default. If you have a strict firewall policy setup, then, unfortunately, you will not be able to connect to a remote computer.

If the Remote Desktop feature has been blocked or not allowed through Windows Firewall, then you need to allow it. To do that, it is pretty simple and easy, follow the instructions given down below:

  1. Open Start Menu and type “Allow an app through Windows Firewall” without the quotes.
  2. Click on the first selection that comes in it.
  3. Next click on the Change Settings on the top right corner of the window that comes up.
    Allowing RDP in Windows Firewall
  4. There you will see a list of applications or features that have been allowed or not allowed in Windows Firewall.
  5. Scroll down until you see Remote Desktop and check the checkbox in front of it (Private one).
    Enabling Remote Desktop in Firewall
  6. Close the window and you are done with allowing Remote Desktop through Windows Firewall.

Solution 2: Allow Remote Desktop Connections if not allowed

Another thing you need to check is whether the Remote Desktop connections are allowed in your Windows or not. If that functionality is blocked, even if you allow Remote Desktop through Firewall, Remote Desktop connections would not work. To check that, do the following:

  1. Type ‘Allow Remote Desktop Connections’ in Start Menu.
  2. Then, click on the first selection.
  3. A window will appear; scroll down until you see the heading Remote Desktop. Click on ‘Show settings’ in front of ‘Change settings to allow remote connections to this computer’.
    Allowing RDP Connections
  4. Make sure the option ‘Allow Remote Assistance Connections to this Computer’ is checked. Click on Apply and then OK to close the window.

Solution 3: Reset your Remote Desktop Credentials

Most of the time, when you have saved the credentials for a specific remote computer and you want to connect to another remote computer, then you will get an error because the credentials are not matching. It is because you have saved the Remote Desktop credentials and the other computer with whom you are connecting to, has different credentials.

In order to reset or remove RDP credentials in Windows 10, perform the following actions:

  1. Type Remote Desktop Connection in Start Menu.
  2. Then click on the first selection which is “Remote Desktop”.
  3. Type in the computer IP address. If there are any credentials saved for this specific computer, you will be given the option to either edit or delete
  4. Click on delete to remove the credentials.
    Deleting Saved Credentials

Solution 4: Add the Remote Computer’s IP address to your hosts file

One more thing that you can do is to add the remote computer’s IP address to your hosts file. Some users have problems when they want to connect to a remote computer whose IP address is not in their hosts file. To do that, do the following:

  1. Press Windows Key + X and select Command Prompt (Admin) from the list to open an elevated command prompt.
  2. Once in cmd, type this command:cd C:/Windows/System32/Drivers/etc
  3. Afterward, type this command:notepad hosts
  4. Editing the hosts File
  5. Once the hosts file opens in notepad, add the IP address of the Remote computer to the end of the file. Finally, click on close button and when asked to save changes, click on Save.

Solution 5: Adding the RDGClientTransport Key

Some users have been able to fix their problem with Remote Desktop Connections in Windows by doing a registry tweak. You will have to create a new DWORD key in the Windows Registry which will force the RDP to use RPC/HTTP connections instead of HTTP/UDP. Here’s how to add the key:

  1. Press Windows + R to open the Run
  2. Type regedit and press enter.
  3. Next, navigate to the following path in registry editor by pasting it in the address bar:HKEY_CURRENT_USER/SoftwareMicrosoft/Terminal Server Client
  4. Once there, right click on the right side of the pane and click on New→ DWORD (32-bit Value) and name it RDGClientTransport.
    Adding RDGClientTransport Key
  5. Then, double click on this new key which has been created to open its properties. Now you will see an option to set value data. Set it to 1. Then click on OK and close the Windows Registry.

Solution 6: Changing Network Properties

In some cases, the error might be triggered due to the network that has been set up as Public. Therefore, in this step, we will be changing it to private. For that:

  1. Press “Windows” + “I” to open settings.
  2. Click on the “Network and Internet” option and select “Status”.
    Selecting “Network and Internet” Options
  3. Click on the “Change Connection Properties” option.
    Selecting “Change Connection Properties”
  4. Select the “Private” option.
    Selecting “Private”
  5. Check to see if the issue persists.

How to fix ‘remote desktop can’t connect to the remote computer’

The remote machine connection timed out with PsPing

As you can see in the screenshot above, I was unable to ping the remote machine, and the port was not reachable as well.

If this works, and you are unable to ping the machine using the FQDN name, check whether DNS resolution is working properly. Sometimes the hostnameis pointingto another machine on DNS that is either offline or not in use.

If you can't connect at all, a local firewall (Windows Firewall or third-party security software) or a network firewall might be blocking the port. The PowerShell command below lets you display the Windows Firewall state on the remote machine.

Invoke-Command -ComputerName [ComputerName] -ScriptBlock {netsh advfirewall show allprofiles}

Remote computer firewall status

For testing purposes, you can disable Windows Firewall on the remote computer with this command:

Invoke-Command -ComputerName Win7 -ScriptBlock {netsh advfirewall set allprofiles state off}

Note that you should enable PSRemoting on the remote computer to execute the above command. If not, you can use PsExec to enable PowerShell remoting with the command below:

psexec \\RemoteComputer -u administrator -p PASSWORD netsh advfirewall set allprofiles state off

Video liên quan

Chủ đề