Ubuntu

How to Enable Remote Desktop on Ubuntu Desktop 22.04 LTS and Access it from Windows

On earlier versions of Ubuntu Desktop, you could only use the VNC protocol to remotely access and control the Ubuntu desktop environment. On the latest version of Ubuntu – Ubuntu Desktop 22.04 LTS, you can use the RDP protocol to remotely access and control the Ubuntu desktop environment as well. The new update allows you to remotely access the Ubuntu desktop environment from Windows 10/11 using the Remote Desktop Connection app – the default RDP client of Windows 10/11.

In this article, I am going to show you how to enable remote desktop on Ubuntu Desktop 22.04 LTS and access it from Windows 10/11 using the Remote Desktop Connection app.

Table of Contents:

  1. Preparing Ubuntu Desktop 22.04 LTS for Remote Login
  2. Enabling Automatic Login
  3. Disabling Screen Blanking and Automatic Screen Lock
  4. Enabling Remote Desktop
  5. Finding the IP Address
  6. Accessing Ubuntu Desktop 22.04 LTS Remotely from Windows 10/11
  7. Conclusion
  8. References

Preparing Ubuntu Desktop 22.04 LTS for Remote Login:

For remote desktop to work on Ubuntu Desktop 22.04 LTS, you have to enable automatic login and disable screen blanking and automatic screen lock on your computer. Otherwise, you won’t be able to connect to your Ubuntu Desktop 22.04 LTS remotely from Windows 10/11 using the Remote Desktop Connection app.

On Ubuntu Desktop 22.04 LTS, the remote desktop service is configured as a user service. So, you have to log in to the system for the remote desktop service to start. If you want to use Ubuntu Desktop 22.04 LTS remotely in headless mode (without attaching a monitor, keyboard, and mouse to your Ubuntu computer), I highly recommend you enable automatic login.

On Ubuntu Desktop 22.04 LTS, screen blanking and automatic screen lock are enabled by default. You will get disconnected from the remote desktop session if your Ubuntu desktop is idle/inactive for a while and the screen is blanked/turned off or locked automatically. To solve this , you will have to disable screen blanking and automatic screen lock for a seamless Ubuntu Desktop 22.04 LTS remote desktop session.

Enabling Automatic Login:

You can enable automatic login from the Settings app.

To open the Settings app, click on Settings from the system tray as marked in the screenshot below.

From the Users section1, click on Unlock2 as marked in the screenshot below.

Type in your login password and click on Authenticate.

Click on the Automatic Login toggle button to enable automatic login.

Automatic login should be enabled.

Disabling Screen Blanking and Automatic Screen Lock:

You can disable screen blanking and automatic screen lock from the Settings app.

To open the Settings app, click on Settings from the system tray as marked in the screenshot below.

Click on Privacy.

From the Screen section, you can configure Blank Screen Delay1 and Automatic Screen Lock2.

By default, the Blank Screen Delay is set to 5 minutes. So, Ubuntu will automatically turn off the screen after 5 minutes of inactivity and you will be disconnected from the remote desktop session immediately.

To disable screen blanking, you will have to set the Blank Screen Delay to Never from the dropdown menu.

Click on the Blank Screen Delay dropdown menu.

Click on Never.

Screen blanking should be disabled.

To disable automatic screen lock, click on the Automatic Screen Lock toggle button as marked in the screenshot below.

Automatic screen lock should be disabled.

Enabling Remote Desktop:

You can enable remote desktop on Ubuntu Desktop 22.04 LTS from the Settings app.

To open the Settings app, click on Settings from the system tray as marked in the screenshot below.

From the Sharing tab1, enable Sharing using the toggle button2.

Click on Remote Desktop.

To enable remote desktop, toggle on Remote Desktop as marked in the screenshot below.

Also, toggle on Remote Control as marked in the screenshot below.

Set a User Name and Password for the remote desktop as well. The User Name and Password you set will be used for authentication when you’re accessing Ubuntu Desktop 22.04 LTS remotely using the Remote Desktop Connection app on Windows 10/11.

Once you’re done, close the Remote Desktop window.

For the changes to take effect, restart your computer.

To restart your computer, click on Power Off/Log Out > Restart… from the system tray.

Click on Restart. Your computer should restart.

Remote desktop should be enabled the next time your computer boots.

Finding the IP Address:

To access Ubuntu Desktop 22.04 LTS remotely using the Remote Desktop Connection app on Windows 10/11, you need to know the IP address of your computer.

To find the IP address of your computer, open a Terminal app and run the following command:

$ hostname -I

The IP address of my computer is 192.168.0.105. It will be different for you. So, make sure to replace it with yours.

Accessing Ubuntu Desktop 22.04 LTS Remotely from Windows 10/11:

You can use the Remote Desktop Connection app (the default RDP client of the Windows operating system) on Windows 10/11 to access Ubuntu Desktop 22.04 LTS running on your remote computer.

First, search for the Remote Desktop Connection app from the Start Menu of Windows 10/11. Once you find it, click on it as marked in the screenshot below.

The Remote Desktop Connection app should be opened.

Type in the IP address of your Ubuntu Desktop 22.04 LTS computer, and click Connect.

The Remote Desktop Connection app is establishing a remote connection to your Ubuntu computer. It will take a few seconds to complete.

Once a connection is established, you will be asked to type in the username and password of the remote Ubuntu computer.

Type in the username and password that you’ve set during remote desktop configuration on Ubuntu Desktop 22.04 LTS1.

If you want the Remote Desktop Connection app to remember the username and password, check the Remember me checkbox2.

Then, click on OK3.

You will be asked to verify the certificate of the remote Ubuntu computer. Click on Yes to confirm it1.

If you don’t want to see this window the next time you try to access your Ubuntu computer remotely, check the Don’t ask me again for connections to this computer checkbox2 before you click on Yes.

The Remote Desktop Connection app should be connected to your Ubuntu computer remotely as you can see in the screenshot below.

Now, you can use Ubuntu Desktop 22.04 LTS remotely from a Windows 10/11 computer using the Remote Desktop Connection app.

Conclusion:

In this article, I have shown you how to enable remote desktop on Ubuntu Desktop 22.04 LTS and access it from Windows 10/11 using the Remote Desktop Connection app – the default RDP client of Windows.

References:

1. https://ubuntuhandbook.org/index.php/2022/04/ubuntu-22-04-remote-desktop-control/

About the author

Shahriar Shovon

Freelancer & Linux System Administrator. Also loves Web API development with Node.js and JavaScript. I was born in Bangladesh. I am currently studying Electronics and Communication Engineering at Khulna University of Engineering & Technology (KUET), one of the demanding public engineering universities of Bangladesh.