Αναζήτηση αυτού του ιστολογίου

Remote Desktop Connection on Linux with Debian 8.5

Target Set up : Debian 8.5 Sid , 32 bit , LXDE, Teamviewer installed.
Remote PC : Debian 8.5 Sid, 64bit, XFCE, Teamviewer NOT installed, vinagre client installed.

Option 1: Install TeamViewer in Remote PC.
This proved to be a head ache, since teamviewer installers (even the one that is supposed to be 64bit) are using 32bit libraries.

There is a debian wiki on how to install 32bit apps in 64bit systems (https://wiki.debian.org/Multiarch/HOWTO) by enabling multi-arch = multi architecture set up.

Also Check the corresponding section on this post : http://monaxoss.blogspot.gr/2016/07/installing-and-testing-debian.html



Quick Set up :
a) Download teamviewer deb file from teamviewer web page.
b) Enable mulit arch: #dpkg --add-architecture i386
c) Try to install teamviewer.deb with Gdebi.
d) If Gdebi fails (not a surprise in case of Debian Sid due to the sid version of some libraries) then you have to run #dpkg -i teamviewer.deb
e) dpkg will inform you about all the missing dependencies that hold installation of teamviewer.
Try to resolve all dependencies manually.
In some cases to use apt-get install missingpkg is fine. But in some other cases, when pkg is somehow considered critical the apt-get will try automatically to remove almost half of your system elements in order to install just a main 32bit library.
f) If this is the case, then the workaround is #apt-get download missingpkg and then #dpkg -i missingpkg.deb (remember you install using full deb name , you remove using just the pkg name)

Fortunatelly the dpkg is just installing the missingpkg.deb without trying to remove anything from your system, i.e corresponding 64bit pkg or pkgs depending on the 64bit distro version.
Following the terminal advises, you might need to run #apt-get -f install several times or #dpkg configure -a.
g) At the end of the day you will be able to install teamviewer. If you wan you can now disable multiarch to avoid your system to be double updated (for i386 and amd64 libs).

Option 2 : Install TeamViewer as a Chrome Native Client Plugin.
This solution worked really nice in my 64bit remote pc.
You only need Chrome (Chromium is not suitable due to native client plugin missing) and you also need the teamviewer application found in the Chrome Web Store.
Once installed you have to go to chrome://flags and enable the Native Client extension (disabled by default).
The you just press the "apps" button in your chrome (or go to chrome://apps) and you just run TeamViewer from the menu.

Surprise! You are done (!) without any worry about 32-64bit libraries, dependencies , etc.

The minimal teamviewer app will then drive you to https://login.teamviewer.com/ where you can see all the computers available in your TViewer account.

Alternativelly you can go directly to login web page, you can login with your user details in TeamViewer servers, you can see your stored computers, but in order to establish a real connection, teamviewer must be installed somehow in your system (either as a seperate standalone program or as a chrome NaCl extension).
Remember that first connect to tviewer fails because the location is not yet considered to be a trusty location.
This applies to the very first connection no matter from where you connect (teamviewer login page, teamviewer NaCl extension or teamviewer standalone program).

In all first connect failure cases, you have to log in to your email and by following the teamviewer email instructions you have to confirm that new remote connection requested is a safe connection and not a kind of hack attack.

Option 3: Using a local VNC Client / Server application.
Remote PC : In all tests was using Vinagre VNC Client
Host PC: I tried tightvncserver , vino and x11vnc.

* Tightvncserver in host pc worked ok, but was not giving access to the real desktop. It seems that tightvnc is more a remote loging that a real desktop sharing. Could be usefull if you need a remote login without the local user to get's notified / interrupted by his work.

For connection it uses 5901 or 5902 port. In Vinager, you have to select "VNC" and as address you give lanaddress:port
If vncserver is started from root account (i.e root terminal) then remote host will be connected as root.
If vncserver is started from user account, then remote host will be connected as user.

As people say if you need a desktop sharing for your active desktop you need to use a different server like vino or x11vnc instead of tightvnc.

* Vino was tested (runns using vino-server) but i couldn't make a live remote connection.

Maybe due to the fact that vino is targeted to Gnome, and host pc is using LXDE or due to the fact that i didn't set up a SSH connection (all people advsie vino tutorials using ssh. Maybe ssh is a must).

PS: When the connection is not possible, in Vinagre i get an error "Connection Closed" .
In my case, i didn't got "connection closed" . Connection seems to be alive, but a blank / black screen appears in remote pc (vinagre).

Under gnome, most probably command vino-preferences will work.
In my LXDE this doesn't work.
What it works is
$ gsettings list-recursively org.gnome.Vino -> gives a list of all configurable options
To change settings -> $ gsettings set org.gnome.Vino view-only true

* x11vnc was also tested and this time remote connection of vinagre (VNC Mode@5900) was ok but incredibly slow.
Run as x11vnc -display :0 -auth .Xauthority (again no ssh was used).

Also see https://ubuntuforums.org/showthread.php?t=1097683 with same complaints / workarounds.
Also i got my host X server broken, becoming unusable after the vnc section.  This was also reported by x11vnc terminal window (x errors). Maybe i have to use the -noxdamage option.

Option 4 : Try a kind of commercial VNC applications like the well known RealVNC. 
RealVNC supports a wide range of Operating Systems, including Linux .
https://www.realvnc.com/download/vnc/linux/

PS: I refuse to use ssh in my local lan.... it's only me and the host. I don't want to spend time in extra settings and extra troubleshooting for ssh. I need click and go solution. TeamViewer can do the job, but i considered it to be "slow". I thought direct vnc server/client over lan would be hell faster, but it turned out to be that TeamViewer was the most reliable choice.

Tips:
Tip 1: in same cases like tightvnc (vncserver command) , running just vncserver leads to command not found. You have to specify the full path (i thing /usr/lib/vnc/vncserver).
By running dpkg -S vncserver (or installation pkg = tightvnc) will give you info about the locations / files this pkg installed in your system. I think similar result you get with dpkg -L command.

Tip 2: To see your host listeners -> $ sudo netstat -nlp | grep vino

Tip3: To verify if you really use display :0 (or other display like :1 or :2) you can echo $DISPLAY.