loading

Setting Up NoMachine for Remote Desktop Access on your Server

Updated at
20/12/2023
Views
1128

Introduction: NoMachine is a free, proprietary software solution for remote desktop access and file transfer. It leverages NX technology, delivering enhanced features and superior performance compared to other remote desktop tools like Xrdp and VNC. What sets NoMachine apart is its true cross-platform compatibility, seamlessly running on Windows, Mac, Linux, Android, and iOS devices. This allows you to access your server from virtually anywhere and at any time.

This tutorial will guide you through the process of installing Xfce, a lightweight desktop environment, and configuring NoMachine for remote access on your Ubuntu server.

Prerequisites:

  1. An Ubuntu server
  2. SSH access with sudo privileges

Step 1 - Installing Xfce: Begin by updating the list of available packages using apt:

sudo apt update

Installing Xfce is straightforward:

sudo apt install xfce4

Depending on your Ubuntu version, the installation may prompt you to choose a default display manager. You can select the default display manager and proceed with the installation.

Step 2 - Installing NoMachine: To install NoMachine, you'll need to download the .deb package from the official website. Given Hetzner Cloud's modern infrastructure, you likely need the amd64 architecture. To confirm your architecture, you can use the command:

dpkg --print-architecture

At the time of writing this tutorial, you can download the latest version (8.8) of NoMachine with the following command:

wget https://download.nomachine.com/download/8.8/Linux/nomachine_8.8.1_1_amd64.deb

Now, install the .deb package:

sudo dpkg -i nomachine_8.8.1_1_amd64.deb

Step 3 - Configuring NoMachine: If you followed this tutorial and installed Xfce, there's no need to modify the default NoMachine configuration located at /usr/NX/etc/node.cfg.

However, if you installed a different desktop environment, navigate to /usr/NX/etc/node.cfg and adjust the DefaultDesktopCommand to match your environment:

  • GNOME: DefaultDesktopCommand /usr/bin/gnome-session
  • KDE Plasma: DefaultDesktopCommand /usr/bin/startplasma-x11
  • LXDE: DefaultDesktopCommand /usr/bin/startlxde
  • Xfce: DefaultDesktopCommand /usr/bin/startxfce4

After making changes, restart NoMachine:

sudo /etc/NX/nxserver --restart

Note: If your server has an active firewall, allow connections to port 4000:

sudo ufw allow 4000

Step 4 - Connecting from the Client: Finally, visit the NoMachine download page and install the NoMachine client on your local device for connecting to the server. Launch the NoMachine client, click the "Add" button, enter your server's public IP address in the "Host" field, and leave other parameters as default.

Next, click "Connect," and provide your Ubuntu username (e.g., root by default) and password. If you haven't set a password yet, you can do so interactively using the passwd command.

Conclusion: This tutorial has guided you through the installation of the Xfce desktop environment and NoMachine on your Ubuntu server for remote desktop access. Additionally, you've configured NoMachine step by step for seamless remote access to your server.

YottaSrc footer

why choose us?

Better Pricing, Fast SSD Storage and Real 24/7
Technical Support.

control panel icon
cPanel

Managing Your Site Through CPanel With The Latest Version

security icon
FAST, RELIABLE & SECURE

99.8% Uptime Guarantee.
So Focus On Your Work!

support icon
24/7/365 Support

Day or night, rain or shine,
our team is here for you!

cloud backup icon
Daily Backup

Daily & Weekly Backup.
Your Files Are Safe!