Remote Desktop Access¶
Run a Desktop environment on your device and access it accessed remotely via network. It is a great option for headless SBC devices.
- TigerVNC Server - Desktop for remote connection
- RealVNC Server - Desktop for remote connection
- XRDP - Remote desktop server for Windows Remote Desktop Client
- NoMachine - Feature rich remote desktop connection
- Remot3.it - (Weaved) Access your device over the internet
- VirtualHere - Share physically attached USB devices from your SBC over the network
How do I run DietPi-Software and install optimised software ?
To install any of the DietPi optimised software listed below run from the command line:
Choose Software Optimised and select one or more items. Finally click on
Install. DietPi will do all the necessary steps to install and start these software items.
To see all the DietPi configurations options, review DietPi Tools section.
From the list of Optimised Software, together with any of the Remote Desktop Software choose also one of Graphical Desktop environment. DietPi will install both of them, enabling you to use your keyboard and mouse to interact with a graphical desktop environment on your device.
You can monitor the VNC service with:
systemctl status vncserver
Although any VNC viewer may work, the latest official TigerVNC viewer can be downloaded here: https://bintray.com/tigervnc/stable/tigervnc/
- Use the IP address of your DietPi device, e.g.:
If you can’t connect, try connecting to screen
- Use the password you entered during the installation. If you would like to change the password execute from the console/terminal, run
- The default port is 5901.
Note: To enable access from outside of your local network, this port needs to be forwarded from your router.
The shared desktop mode is used to have more than one single VNC viewer connected to the same desktop session. To enable this mode, edit
/boot/dietpi.txt, e.g. via
nano /boot/dietpi.txt. Change to value
1 the following line:
A running desktop is required for this mode, therefore enable desktop autostart via
dietpi-autostart 2, or assure that a local desktop session is active before starting TigerVNC manually.
The following shows an example how to run VNC server on screen :1 by creating a new desktop with 1280x720 resolution by editing
and change the following settings:
SOFTWARE_VNCSERVER_WIDTH=1280 SOFTWARE_VNCSERVER_HEIGHT=720 SOFTWARE_VNCSERVER_DEPTH=32 SOFTWARE_VNCSERVER_DISPLAY_INDEX=1
At last restart the service to activate the new settings:
systemctl restart vncserver
TigerVNC is enabled by default to start automatically at boot. Run
systemctl disable vncserver to disable this behaviour and
systemctl start vncserver to start it manually from console.
To re-enabled TigerVNC autostart, run
systemctl enable vncserver, to stop it manually
systemctl stop vncserver can be used.
RealVNC consists of the VNC Server and the VNC Viewer application to share the desktop or control the computer running the VNC Server.
By default DietPi will start a virtual VNC session on boot at screen :1 for user root.
The screen index can be changed via
/boot/dietpi.txt. Logs can be viewed via
journalctl -t Xvnc:1 -t vncserver and in
/root/.vnc/. When you logout (instead of only closing the VNC Viewer window), the session will exit. Restart it via
systemctl restart vncserver.
If you set
/boot/dietpi.txt or select desktop auto login via
dietpi-autostart (index 2), RealVNC server will be started on boot in shared desktop mode, attaching to the first found local desktop session.
Check the service status via
systemctl status vncserver-x11-serviced. Check all logs via
journalctl -u vncserver-x11-serviced.
RealVNC enterprise subscription¶
If you have an enterprise subscription on RealVNC, you can have virtual VNC sessions spawning automatically on demand per-client connection and closing once the client disconnects. That way no resource-intense X11/desktop session needs to be persistently active on the server to allow VNC connections.
To enable this, after adding your enterprise subscription credentials, do the following:
systemctl disable --now vncserverdisables the persistent virtual VNC session on screen :1.
systemctl enable --now vncserver-virtualdenables the on demand VNC session daemon.
Simply select a VNC viewer for your system and download: https://www.realvnc.com/connect/download/viewer/
- To connect on the persistent VNC session on screen :1, add the screen index to your local IP or hostname, e.g.
- To connect to a shared desktop session, skip the screen index, e.g.
- Username =
- Password =
This may be the case e.g. if you want to run Minecraft remotely.
- Enable shared desktop mode:
dietpi-autostart 2to autostart into a desktop session and have RealVNC attached to it automatically.
rebootthe system to have the changes taking effect.
- Follow the instructions within the section Running directly rendered apps such as Minecraft remotely in https://www.realvnc.com/docs/raspberry-pi.html.
XRDP is a remote desktop application using the Windows Remote Desktop Client.
To connect to the desktop, open the remote desktop application in Windows (or any other XRDP compatible client).
Enter the IP address of your DietPi device, e.g.
Click connect and enter the following details once connected:
- Module =
- Username =
- Password =
XRDP uses port 3389 by default, so you need to open/forward it from your router to DietPi.
NoMachine is a remote desktop server with advanced features, such as screen recording. The client also scans for all available NoMachine servers on your network, allowing easy connection and maintenance of your remote desktops.
Download the NoMachine client software from:
Once the NoMachine client is installed, and running on your system, you should see a device named DietPi. Execute the following steps:
- Double click it.
Yesfor Remote host identification has changed.
Yesfor Verify host authenticity.
- Enter the username
Yesfor Do you want NoMachine to create a new display.
You will now be connected to your device.
Remot3.it allows you to easily access your DietPi device over the internet.
Weaved works by connecting you to a specific TCP port on your device, all of which can be customized during first run setup.
Examples of TCP ports for Remot3.it:
- SSH port 22. Open a remote terminal to your device.
- Transmission port 9091. Monitor your BitTorrent downloads.
- Webserver port 80. Access your internal webserver and/or websites.
The first run setup is executed once
dietpi-software has completed the installation and the system is rebooted. Run the following command. Follow the onscreen instructions to setup and link an account:
Once your account is created and linked to this system, you can select a port for Remot3.it to enable remote access.
Sign into your Remot3.it account to access your devices remotely:
- URL = https://www.remote.it
YouTube video tutorial (German language):
Raspberry Pi einfach fernsteuern: Remote.It SSH ohne VPN von überall - Installation unter DietPi.
The VirtualHere package is used to share physically attached USB devices from your SBC over the network to other systems.
Download the client for your PC from:
Once installed, available VirtualHere devices will be shown in the client user interface and can be used on the client PC.
USB Storage WARNING
- As per https://github.com/MichaIng/DietPi/issues/852#issuecomment-292781475 it it highly recommended that you do not install VirtualHere if your DietPi user data is stored on a USB drive.
- VirtualHere does not take into account mounted drives when selecting them for remote use. This is potentially dangerous for any mounted drive that is in use and may cause data loss.
- Do not use drives on the client that are mounted on the SBC.
Unmount the drive before hand in