Using SSH to tunnel to my Raspberry Pi and eliminate the need for VNC..
Please share this article:
You may have read my post on setting up the Raspberry Pi to access the desktop remotely. I got most of that accomplished with a bit of determination and some help from the good people of Reddit /RaspberryPi. Once I’d sent reddit my post, u/newdles and u/wittless both made some really good suggestions about using an SSH Tunnel to route traffic from the browser on my current computer to the Rasberry Pi. This eliminates the need for any remote desktop software like VNC which is inherently insecure because the data it sends isn’t encrypted.
SSH (Secure SHell) is a much better option than my original plan for a few reasons. First as the name implies, it’s relatively secure. The web traffic is encrypted while it’s travelling back and forth between my laptop and the Raspberry Pi. For the time being, short of the NSA, most people won’t have access to the traffic stream.
Second, it’s far faster than VNC. Because VNC has to send graphics data between two computers it tends to be pretty slow and finicky when you’re trying to move about the desktop, open files and applications, and manipulate settings. It’s always been like this and even with significantly higher internet speeds, it hasn’t drastically improved in the 15 years I’ve used it.
I found a great walk through from Hey Stephen Wood on SSH Tunnelling on the Mac, and since I was already set up for SSH terminal access, it was really just the proxy configuration I needed. The only thing different in my own setup was that I’d changed my default port from 22 to (something else) on the advice of u/witless on that reddit thread.
Stephen suggests using this to connect to your Pi:
$ ssh -D 8888 firstname.lastname@example.org -vv
But when the default port has been changed, this is actually what you’ll need to do.
$ ssh -D 8888 -p [YourNewPortNumber] email@example.com -vv
I got a bit confused by his 8888, and tried to jam my port number in there unsuccessfully. The -D 8888 specifies a port on the local computer where that tunnel can transit through. Obviously my non-default port needed to be specified separately. :)
Please share this article:
Jordan is... Well, um, a lot of things. Most of them are even good.
currentlycontinually seeking a definition for myself that inspires, enlightens and enriches the lives of others. This is long-term work in progress.
Jobs I've held run from busboy to bartender, computer guy to directional driller, photographer and tour guide too.. Rarely do I ever identify myself by a job title though.
Over the past ten or fifteen years, I've traveled through some 40 countries and always relish the opportunity to do things that are out of the ordinary.
On this site, you'll find musings about photography, the oil and gas industry, travel, robotics, electronics, full time RV living, and social responsibility among other bits of my life.
Jordan is currently...
on the road!
You may catch me by telephone
or email, or postal mail if you so choose, but you’ll have to take a peek at the contact page for that info!
Browse for stuff..
- Community Building (2)
- Food (5)
- General Announcements (110)
- Industrial (1)
- Learning Journey (6)
- Linux (1)
- Maker (2)
- Making (2)
- Motorcycle (15)
- Oil & Gas (1)
- Personal Note (5)
- photography (9)
- photos (25)
- Raspberry Pi (2)
- Renovations (2)
- sustainability (1)
- Tech Stuff (7)
- Travel (22)
- universal understanding (4)
- Unix (3)
- waste (2)
- Web Development (3)
- workflow (1)
- Youth Photo Initiative (1)