Smart Systems for Home

Plain how-to guides for smart home, security and home Wi-Fi

Set Up Remote Desktop Access on Linux: Step-by-Step

· 4 min read · Home Tech

In this article
  1. What You'll Need
  2. Step-by-Step
  3. Common Mistakes
  4. Tips
  5. Troubleshooting
  6. Frequently Asked Questions

Remote desktop lets you control your Linux computer from another device as if you were sitting in front of it. The easiest way is to use RDP (Remote Desktop Protocol) with the built-in GNOME Remote Desktop (for GNOME desktops) or install xrdp for other desktops. This guide covers both, plus a VNC option for flexibility.

What You'll Need

  • A Linux computer (Ubuntu, Debian, Fedora, or similar) with a desktop environment installed.
  • Another device (Windows, macOS, Linux, or mobile) with an RDP or VNC client.
  • Administrative (sudo) access on the Linux machine.
  • Network connectivity – both devices on the same network, or you'll need to configure port forwarding on your router (explained in Tips).

Step-by-Step

For GNOME desktop (default on Ubuntu, Fedora Workstation):

  1. Open Settings from the app grid or top-right menu.
  2. Click System (or Sharing on older versions).
  3. Enable Remote Desktop toggle.
  4. Under Remote Desktop, turn on Remote Desktop and Remote Control if you want to control the mouse and keyboard.
  5. Set a Username and Password – this is what you'll use to connect from another device.
  6. Note the IP address shown (e.g., 192.168.1.100) – you'll need it later.

For other desktop environments (KDE, XFCE, etc.) using xrdp:

  1. Open a terminal (Ctrl+Alt+T).
  2. Install xrdp: sudo apt install xrdp (Debian/Ubuntu) or sudo dnf install xrdp (Fedora).
  3. Start the service: sudo systemctl enable --now xrdp.
  4. Check it's running: sudo systemctl status xrdp – you should see “active (running)”.
  5. Find your IP address: ip addr show or hostname -I.

Connecting from another device:

  1. On Windows: press Win+R, type mstsc, enter the Linux IP address, and click Connect.
  2. On macOS: download “Microsoft Remote Desktop” from the App Store (free). Enter the IP and connect.
  3. On Linux: use Remmina (install with sudo apt install remmina). Choose RDP protocol, enter IP, and connect.
  4. Enter the username and password you set (for GNOME) or your Linux login credentials (for xrdp).

Common Mistakes

  • Using the wrong username/password: For GNOME Remote Desktop, you create a separate login; for xrdp, you use your normal Linux user account.
  • Firewall blocking the port: RDP uses port 3389, VNC uses 5900. If you can't connect, open these ports in your firewall.
  • Connecting to the wrong IP: Make sure you use the local IP (like 192.168.x.x), not a public one.
  • Not enabling “Remote Control” – you can view but not interact.

Tips

  • For better performance, use a wired Ethernet connection on the Linux machine.
  • If you need access from outside your home, set up port forwarding on your router for port 3389 (RDP) or 5900 (VNC) to the Linux IP. Be aware this exposes your computer to the internet – use strong passwords and consider a VPN instead.
  • If you use a different desktop environment, you can install a VNC server like TigerVNC (sudo apt install tigervnc-standalone-server) and connect with a VNC client.
  • For headless servers (no monitor), use xrdp – it works without a physical display.

Troubleshooting

  1. Can't connect at all: First, check that both devices are on the same network. Ping the Linux IP from the client. If ping fails, check your router's client list.
  2. Connection refused: Ensure the remote desktop service is running. For GNOME, check Settings > System > Remote Desktop is on. For xrdp, run sudo systemctl restart xrdp.
  3. Firewall blocking: On Ubuntu, allow the port: sudo ufw allow 3389/tcp (for RDP) or sudo ufw allow 5900/tcp (for VNC). On Fedora, use sudo firewall-cmd --add-port=3389/tcp --permanent and reload.
  4. Blank screen after connecting: This often happens with xrdp on some desktops. Log out of the local session first, then try connecting again. If it persists, try a different desktop environment (e.g., install XFCE and use it via xrdp).
  5. Slow or laggy: Reduce the resolution and color depth in your client settings. Also close heavy applications on the Linux machine.
  6. Password not accepted: For GNOME Remote Desktop, ensure you've set the remote desktop password correctly. For xrdp, make sure you're using your Linux login password (not a PIN).

Frequently Asked Questions

Can I use this to access my Linux computer from anywhere?

Yes, but you'll need to configure port forwarding on your router or use a VPN. Be cautious with security – use strong passwords and consider SSH tunneling.

Is RDP better than VNC?

RDP is generally faster and more responsive on Windows clients, while VNC is more cross-platform and works better with Linux desktops. For Linux-to-Linux, VNC is often simpler.

Do I need a static IP address?

Not for local use – a dynamic IP is fine. For remote access, a static IP or dynamic DNS service helps, but you can also just check your IP when you need it.

Can I connect from my phone or tablet?

Yes. Use the Microsoft Remote Desktop app (iOS/Android) for RDP, or a VNC viewer app for VNC. Just enter the same IP and credentials.

Will this work if my Linux computer is a laptop that sleeps?

No – the computer must be awake. Disable sleep when on AC power in power settings, or use Wake-on-LAN if supported.

What if I'm using a non-GNOME desktop like KDE?

Use xrdp – it works with most desktop environments. For KDE, you may need to install xrdp and possibly xorgxrdp for better performance.