Connect to Mint 18.3 remote desktop

All Gurus once were Newbies
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Please stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions prefer the other forums within the support section.
Before you post please read how to get help
Post Reply
serozhka
Level 1
Level 1
Posts: 2
Joined: Tue Feb 13, 2018 2:21 am

Connect to Mint 18.3 remote desktop

Post by serozhka » Wed Mar 21, 2018 4:58 am

Dear all,
I was enjoying Windows 7/10 RDP clients till moment I went to Linux Mint 18.3. Currently I have to connect to my Mint remotely, i.e. I am looking for how to connect from Windows to Mint using RDP or any compatible protocols. For some reasons, ssh is not enough for me and I want to know if there any anything similar to Windows RDP.
Is there any simple way to make Vino working without extra effort? I didnt find any solution for known-error "Either upgrade VNC Server to a more recent version from RealVNC, or select a weaker level of encryption.", I believe this is pretty straightforward that I will not diable encryption because I connect to my PC from outside of home network. Mint has all possible upgrades, including 3rd and 4th levels.
Also, I did some reading and understood that VNC is not that safest thing to use. Any other options how can I connect to Mint?

SC23
Level 4
Level 4
Posts: 218
Joined: Sun Jun 23, 2013 12:54 am
Location: Asheville North Carolina, US.

Re: Connect to Mint 18.3 remote desktop

Post by SC23 » Wed Mar 21, 2018 1:15 pm

Ive been stumped by this for 2 days now. You can connect with the default Vino VNC server if you enable it and disable the encryption (search for that). You can also connect with x11vnc, tigervnc, tightvnc, and others. I had RealVNC which worked until they went to subscription only model. Unfortunately only RealVNC easily allowed for connections before an X session login. My problem is if I reboot or the screen locks, the X Session ends and I get a black screen. I have been chasing tape and gum solutions to this problem. A headless server is not very useful if you cant log into it after the screen saver locks the screen. This really should be an out of the box no brainer but it is very difficult to make happen right in Mint.

User avatar
coffee412
Level 5
Level 5
Posts: 837
Joined: Mon Nov 12, 2012 7:38 pm
Location: Indiana, USA
Contact:

Re: Connect to Mint 18.3 remote desktop

Post by coffee412 » Wed Mar 21, 2018 2:36 pm

Boy do I know this feeling!

I have been using Teamviewer but I would rather have an open source solution instead. Even though TV is free for personal use they did change their price structure for business use to about 600 bucks a year! I am grandfathered in with TV version 9 but soon I will probably have to move on to something else to support my clients.

I did try Anydesk but I found it a bit clumsy to use. Also, I could not transfer files between computers. Other solutions run into issues too. For the VNC type I found that the screen redraws where slow or the resolutions were out of whack.

Wonder why some programmer doesnt show interest in writing up something like TV? I would be willing to pay a bit for the use but geez! not 600 a year.
Ryzen x1800 Asus Prime x370-Pro 32 gigs Ram RX480 graphics
IceWarp * Samba AD * Mint 18.1 * RAID 1/5 * OpenVPN * Linux since kernel 2.0.36

User avatar
smurphos
Level 6
Level 6
Posts: 1386
Joined: Fri Sep 05, 2014 12:18 am
Location: Britisher...

Re: Connect to Mint 18.3 remote desktop

Post by smurphos » Wed Mar 21, 2018 4:49 pm

serozhka wrote:
Wed Mar 21, 2018 4:58 am
For some reasons, ssh is not enough for me and I want to know if there any anything similar to Windows RDP.
If you can SSH into the machine then you should be able to tunnel VNC via SSH. x11vnc is the best server for this due to it's host of command line options. The basic method is to SSH in and start an on-demand x11vnc session and forward the X-server output to your local machine. On the local machine you simply connect to localhost using whatever VNC client you like. If you fail to connect within a specified timeout or terminate the session x11vnc will kill itself.

This is the script I use to launch x11vnc via SSH into my plex server on the local network.

Code: Select all

#!/bin/bash
#Script to start VNC via SSH.
ssh 192.168.1.3 -L 5900:localhost:5900 "x11vnc -safer -localhost -once -timeout 60 -nopw -auth guess -display :0 -noxdamage"
The only potential issue is if you are using Light Locker as your lock screen on the remote. I know it causes issues with VINO, I'm not 100% sure if this method avoids those issues. The machine I connect to is XFCE and has been upgraded to 18.3 and I chose to leave the lock screen to be managed by x-screensaver rather than install Light Locker.

Linux does have an RDP server - xrdp - it's in the repos. Other than the fact it exists I don't really know anything else about it - sorry!

SC23
Level 4
Level 4
Posts: 218
Joined: Sun Jun 23, 2013 12:54 am
Location: Asheville North Carolina, US.

Re: Connect to Mint 18.3 remote desktop

Post by SC23 » Wed Mar 21, 2018 11:35 pm

@smurphos

I SSH'd in, started the server with the code, then connected locally via localhost and still got the black screen because the server was at the login screen. Mint Mate relatively latest version and patches.. Im just about to give up on this one...

User avatar
phd21
Level 16
Level 16
Posts: 6729
Joined: Thu Jan 09, 2014 9:42 pm
Location: Florida

Re: Connect to Mint 18.3 remote desktop

Post by phd21 » Thu Mar 22, 2018 12:18 am

Hi serozhka, & Everyone Else Interested in this,

I just read your post and the good replies to it. Here are my thoughts on this as well.

I love TeamViewer for accessing remote computers no matter what operating system they use, but they are a little pricey for commercial use especially for small businesses. I have never tried AnyDesk, but I would be surprised if it did not do file transfers. Have you tried "NoMachine"? I like SSH and it can run programs remotely as well.

NoMachine - Free Remote Desktop For Everybody
https://www.nomachine.com/

SSH: An Easier-Than-You-Thought Tutorial
http://pclosmag.com/html/Issues/201102/page18.html

SSH: Setting Up a Home Network with Linux Mint
https://www.maketecheasier.com/setting- ... inux-mint/


As for running an RDP client (Remote Desktop Program) from or to Windows or Linux Mint, there are a few RDP applications that can do remote desktop control and or to run applications on the remote computer(s), "Remmina" and its plug-ins (see below), Krdp / Krdc, "rdesktop", "xrdp", "FreeRDP", etc... Always check for recommended and suggested packaged for these in the "Synaptic Package Manager (SPM)".

Unlike TeamViewer, AnyDesk, or NoMachine, and some other remote control applications which can bypass the Linux software Firewall and hardware routers, RDP applications usually require adding one or more Firewall rules to allow incoming and outgoing ports that a particular RDP application uses. And a MS Windows server or workstation may also have specific ports and or IP addresses that may need to be used. You can temporarily disable the Linux firewall to see if that is causing any issues and if it works, then you need to add one or more firewall rules to your Linux and or Windows software firewall. Do not forget to enable the firewall afterward. I do not know which RDP protocol that you should use to connect with, RDP, VNC, NX, or SSH. That is something you have to determine for yourselves.

Years ago when I provided tech support for business customers nationwide using MS Windows (mixed versions) and RDP with networked computers was a real pain, in order to access specific workstations each workstation had to have a unique and specific static IP address and a specific port setup on each workstation's MS Windows OS and the hardware router also had to be configured to allow incoming and outgoing traffic for those IP Addresses and related ports; try talking through non-computer people to set that up, talk about frustrating and time-consuming! This is why I love applications like TeamViewer, AnyDesk, NoMachine, etc... for remote support.

I would also recommend the newer version of Remmina and its plugins are installed using information in the link below:
Remmina
https://www.remmina.org/wp/

Code: Select all

sudo apt-add-repository ppa:remmina-ppa-team/remmina-next

Code: Select all

sudo apt-get update

Code: Select all

sudo apt-get install remmina remmina-plugin-rdp remmina-plugin-secret remmina-plugin-vnc
User's Guide
https://github.com/FreeRDP/Remmina/wiki ... er's-guide

Although remmina is considered one of the best RDP apps, do not forget to try KRDP/KRDC, or one of the others.

Krdc - KDE UserBase Wiki
https://userbase.kde.org/Krdc

Best Linux remote desktop clients: Top 5 RDC in 2018 TechRadar
https://www.techradar.com/news/5-of-the ... op-clients

5 of the Best Linux Remote Desktop Apps to Remote Access a Computer
https://www.maketecheasier.com/best-lin ... ktop-apps/

Hope this helps ...
Remmina1.jpg
Remmina - new version
Last edited by phd21 on Thu Mar 22, 2018 1:12 am, edited 3 times in total.
Phd21: Mint KDE 17.3 & 18.3, 64-bit Awesome OS, Ancient Dell OptiPlex 780 Core2Duo E8400 3GHz,4gb Ram,256gb SDD, Video: Intel 4 Graphics, DVD Lightscribe. Why I use KDE?:https://opensource.com/life/15/4/9-reasons-to-use-kde

User avatar
smurphos
Level 6
Level 6
Posts: 1386
Joined: Fri Sep 05, 2014 12:18 am
Location: Britisher...

Re: Connect to Mint 18.3 remote desktop

Post by smurphos » Thu Mar 22, 2018 12:46 am

SC23 wrote:
Wed Mar 21, 2018 11:35 pm
I SSH'd in, started the server with the code, then connected locally via localhost and still got the black screen because the server was at the login screen. Mint Mate relatively latest version and patches.. Im just about to give up on this one...
Login Screen or Screenlock? Are you using lightDM and light-locker or something else? I don't know what is default in Mate (and what is default probably depends which 18.x you are on and whether it is an upgraded system or not).

There are potential workarounds if it is lightDM and light-locker. Sorry I've got no idea which is the best route.

This one looks to me like you may be able to pass additional parameters to x11vnc to open lightDM
https://askubuntu.com/questions/767752/ ... less-16-04

Configuration changes to lightDM suggested on the Archwiki
https://wiki.archlinux.org/index.php/LightDM#VNC_Server

An xrdp based solution
https://unix.stackexchange.com/question ... 199#391199

The last workaround here is interesting - launching GUI apps directly via SSH tunnel rather than using VNC
https://bugs.launchpad.net/ubuntu/+sour ... ug/1287171

Edit to add - this is covered in the SSH tutorial provided by phd21 http://pclosmag.com/html/Issues/201102/page18.html

A VNC based solution
https://ubuntuforums.org/showthread.php?t=2342561

User avatar
smurphos
Level 6
Level 6
Posts: 1386
Joined: Fri Sep 05, 2014 12:18 am
Location: Britisher...

Re: Connect to Mint 18.3 remote desktop

Post by smurphos » Thu Mar 22, 2018 1:01 am

Just tried directly tunnelling individual applications and it works like a charm if you know your package names.

ssh -X steve@192.168.1.3
thunar &

I'm now looking at my XFCE's systems file manager on my Cinnamon system - no VNC involved - no worries about lock screen - result.

apt list --installed after SSHing in will give you a list of installed packages,

Somethings don't work that well...
mintupdate & works OK to display Update Manager from the remote. However on clicking install the password prompt appears in the SSH terminal not as a GUI and it won't accept the password.

User avatar
phd21
Level 16
Level 16
Posts: 6729
Joined: Thu Jan 09, 2014 9:42 pm
Location: Florida

Re: Connect to Mint 18.3 remote desktop

Post by phd21 » Thu Mar 22, 2018 1:24 am

Hi smurphos,

SSH does work very well.

FYI-1: You can run the entire graphical desktop thru SSH if you want, or just the individual applications. You might be running Cinnamon, but the computer you SSH into is running Mate, KDE, or Xfce, and you can run that entire desktop regardless of what your desktop is running.

Tutorial: Accessing a Linux Desktop Remotely With SSH and VNC | From: hypervisor
https://blog.ssdnodes.com/blog/tutorial ... h-and-vnc/

ssh - How to remotely log in with full graphical desktop over X11 - Unix & Linux Stack Exchange
https://unix.stackexchange.com/question ... p-over-x11

FYI-2: As for Mint Update, you can run that from the console terminal as well... You might be able to pass the sudo password to an application as an ssh parameter to.

FYI-3: I have not had a chance to try this new version of Remmina yet, but it also has SSH connection option and extra SSH configuration options, so it too may be able to run the remote computer's entire graphical desktop and all its apps using just the SSH or a combination of RDP or VNC with SSH.

Hope this helps ...
Remmina_SSH.jpg
Remmina SSH
Last edited by phd21 on Thu Mar 22, 2018 2:33 am, edited 3 times in total.
Phd21: Mint KDE 17.3 & 18.3, 64-bit Awesome OS, Ancient Dell OptiPlex 780 Core2Duo E8400 3GHz,4gb Ram,256gb SDD, Video: Intel 4 Graphics, DVD Lightscribe. Why I use KDE?:https://opensource.com/life/15/4/9-reasons-to-use-kde

User avatar
smurphos
Level 6
Level 6
Posts: 1386
Joined: Fri Sep 05, 2014 12:18 am
Location: Britisher...

Re: Connect to Mint 18.3 remote desktop

Post by smurphos » Thu Mar 22, 2018 2:07 am

Thanks phd21 - more informative links :D

The mintupdate experiment was just to check something I thought wouldn't work straight off. I normally check the update status of this machine via regular SSH and the CLI mintupdate-tool

This is a little bit trippy

ssh -C -X steve@192.168.1.3
xfce4-session

I've now got my xfce machine desktop with cinnamon desklets and panel still available. I can mix and match between apps launched on the remote machine and the local machine. Remote machine windows appear in cinnamons window list.....

Image

It's much smoother than VNC - particularly using the -C option. Looks like Update manager works fine as-well.

User avatar
phd21
Level 16
Level 16
Posts: 6729
Joined: Thu Jan 09, 2014 9:42 pm
Location: Florida

Re: Connect to Mint 18.3 remote desktop

Post by phd21 » Thu Mar 22, 2018 2:17 am

Hi smurphos,

You are welcome...

I just updated my last reply a little, so you might want to re-read that...

Do not forget to secure SSH like changing the default SSH port 22 to something else (update or change the firewall for this), perhaps installing "fail2ban", or something like it.

5 SSH Hardening Tips
https://www.linux.com/learn/5-ssh-hardening-tips

How to Configure Custom SSH Connections to Simplify Remote Access
http://www.tecmint.com/configure-custom ... s+Guide%29

Top 20 OpenSSH Server Best Security Practices
https://www.cyberciti.biz/tips/linux-un ... tices.html
Phd21: Mint KDE 17.3 & 18.3, 64-bit Awesome OS, Ancient Dell OptiPlex 780 Core2Duo E8400 3GHz,4gb Ram,256gb SDD, Video: Intel 4 Graphics, DVD Lightscribe. Why I use KDE?:https://opensource.com/life/15/4/9-reasons-to-use-kde

SC23
Level 4
Level 4
Posts: 218
Joined: Sun Jun 23, 2013 12:54 am
Location: Asheville North Carolina, US.

Re: Connect to Mint 18.3 remote desktop

Post by SC23 » Thu Mar 22, 2018 4:25 am

@smurphos

I think its just the basic Mint Mate manager and it happens at the login prompt..basically when X closes... whether you reboot to the login screen or it times out inactivity and dumps to login..
I tried just running the apps over SSH and that worked, I can deal with that :)

serozhka
Level 1
Level 1
Posts: 2
Joined: Tue Feb 13, 2018 2:21 am

Re: Connect to Mint 18.3 remote desktop

Post by serozhka » Thu Mar 22, 2018 1:26 pm

Thank you all, guys.
But main question was - how to connect from Windows. Actually tutorials show how to connect between Linux's. I didnt find a simple quote - e.g. which port should I put in my Windows RDP program?
Sorry if this post is aggresive - but can newbies like me just receive manual, what to do in windows and what to do in linux to make connection in order to see Cinnamon UI?

User avatar
smurphos
Level 6
Level 6
Posts: 1386
Joined: Fri Sep 05, 2014 12:18 am
Location: Britisher...

Re: Connect to Mint 18.3 remote desktop

Post by smurphos » Thu Mar 22, 2018 11:13 pm

You don't sound aggressive.

Refer to my first post in the chain - viewtopic.php?f=90&t=266128#p1447103

I'd suggest trying this as you imply you already have SSH set up on the Cinnamon machine. If you are remoting into to a Cinnamon machine you are not using light-locker as the lock-screen so that shouldn't be an issue. Cinnamon (installed from an 18.2 or 18.3 iso) does use lightDM as the log-in manager so that will be a problem if you are expecting to remote in and be able to log in from the login screen. If the Mint machine is configured for auto-login that won't be an issue. Replacing lightDM with MDM (mint's default login manager prior to 18.2) is another potential work-around if you do need to be presented with a user log-in screen.

I would not recommend using any flavour of VNC over the net without an SSH tunnel.

If you try the method suggested you are connecting using whatever SSH port you have configured on the Cinnamon machine. Your VNC client connects to localhost on your windows machine.

I don't know if the Windows RDP client supports other protocols? You may need to install a VNC client. I use Chrome and can recommend the RealVNC chrome app from the Chrome webstore. TightVNC https://www.tightvnc.com/download.php & TigerVNC http://tigervnc.org/ are other options.

Alternatively, if you want to set up an RDP server on Mint 18 try xrdp - I've found another link to a Mint specific set up tutorial here - http://c-nergy.be/blog/?p=10241.
More on xrdp - http://ubuntuwiki.net/index.php/Xrdp,_installing

If that is all to painful revert to the easy option - Teamviewer, or if you use Chrome set up Chrome Remote Desktop

Unfortunately, Linux is not like windows in that for these use cases there is not a one size fits all solution other than the likes of Teamviewer due to the variety of Desktop environments, lock screen managers, login screen managers etc - even in different editions of Mint and in some cases the same edition of Mint. E.g. a fresh 18.3 Cinnamon installation will have lightDM as the login manager, whilst one upgraded from 18.1 or 18 will still have MDM unless the user has specifically installed lightDM.

Post Reply

Return to “Newbie Questions”