Raspberry Pi - Remote Desktop Connection
Intro: Raspberry Pi - Remote Desktop Connection
In this project, we will programming Raspberry Pi that could be control remotely via Secure Shell (SSH) from any Computer.
Remote Desktop are useful to communicate between Raspberry PI and another Device remotely through SSH. SSH provides a secure channel over an unsecured network in a client-server architecture to send any information, render data, any other essential process.
STEP 1: Raspberry Pi Installation
Open Terminal in Raspberry Pi, enable SSH (Secure Shell), install xrdp, edit your raspberry's ip to static and you're good to go.
raspi-config
Select option 8 (Advance Option), option A4(SSH), Enable, and OK
sudo apt-get install xrdp
sudo nano /etc/network/interfaces
Replace "iface eth0 inet dhcp" with :
iface eth0 inet staticaddress 192.168.1.20
netmask 255.255.255.0
gateway 192.168.1.1
STEP 2: Windows Installation
Find "remote desktop connection" program on Windows,
Enter raspberry pi IP,
Enter raspberry pi username and pass,
Enjoy configure your Raspberry Pi remotely !
2 Comments
BR549joe 2 years ago
Locally run the Xephyr (or Putty) x-server application. On local Debian or Pi, I run:
$ Xephyr -ac -screen 1728x972 -br -host-cursor -reset -terminate :3.0 &
$ xterm -display :3.0 &
This starts up a local X-11 server (Xephyr) on port :3.0, with an xterm in it. Then in the xterm terminal display, I run (with appropriate IP):
$ ssh -XfC pi@123.123.123.123 exec startlxde
or
$ ssh -XfC pi@145.136.47.9 exec startlxde-pi
This launches the remote PI's desktop normally, as an X-client, but rather than displaying (serving) it on the remote Pi's X-server/hardware (which may be disabled), the Local machine uses it's hardware and CPU to run the X-server and render the image of the desktop, at local resolution, freeing the tiny remote Pi from doing all the work (Pi's Xserver redering on Pi's hardware, then vnc capturing that and sending it to the local machine, and locally rendering that yet again for you to see).
I use startlxde (the X-client) on the remote (and all my Pis), because unlike startlxde-pi, I get multiple desktop work-spaces without duplicate hardware and monitors and such, even within the remote display. This feature has been in most flavors of Linux for -Decades- now, but the kind folk at Raspberry have disabled this in their startlxde-pi.
You can use this procedure for remote access to most any Linux/Unix machine (even a cloud one) as long as you know the commands to start the desktop you prefer (like startlxde).
abendsven 3 years ago