VNC to my Deb 9 from Windows

New to Debian (Or Linux in general)? Ask your questions here!

VNC to my Deb 9 from Windows

Postby white_tee_shirt » 2018-02-09 07:32

Hi all,

I'm usually away from my laptop (which is on network) and would be downstairs at a different workstation, and I'd like to remote/VNC to my Deb 9 like this userhttps://askubuntu.com/questions/3934/is-it-possible-to-use-remote-desktop-from-windows-7-to-ubuntu.
So far, I've installed the vncserver :

Code: Select all
sudo apt install vnc4server

Code: Select all
$ touch ~/.vnc/xstartup
$ sudo gedit ~/.vnc/xstartup
#!/bin/sh
xterm &


Then I started VNC server on my laptop:
Code: Select all
$ vncserver -localhost no -geometry 800x600 -depth 24

Code: Select all
$ vncserver -list
TigerVNC server sessions:
X DISPLAY #     PROCESS ID
:1              2776

Code: Select all
$ ss -ltp | grep vnc
LISTEN     0      5          *:5901                     *:*                     users:(("Xtigervnc",pid=2776,fd=7))
LISTEN     0      5         :::5901                    :::*                     users:(("Xtigervnc",pid=2776,fd=8))


Then, when I go to my Windows station and I check if I can see my linux laptop :
Code: Select all
C:\>nmap warmachine -O
Starting Nmap 7.60 ( https://nmap.org ) at 2018-02-08 19:17 Pacific Standard Time
Nmap scan report for warmachine (10.62.108.109)
Host is up (0.00s latency).
rDNS record for 10.62.108.109: warmachine.xxxxxxxxx.com
Not shown: 999 closed ports
PORT     STATE SERVICE
5900/tcp open  vnc
Device type: general purpose
Running: Linux 3.X|4.X
OS CPE: cpe:/o:linux:linux_kernel:3 cpe:/o:linux:linux_kernel:4
OS details: Linux 3.2 - 4.8
Network Distance: 4 hops

OS detection performed. Please report any incorrect results at https://nmap.org/submit/ .
Nmap done: 1 IP address (1 host up) scanned in 2.84 seconds


Excellent. My windows station is able to see my linux Deb 9 station on the network, and knows that there's an open VNC port.
Now, I fire up VNC and try to connect to my Deb 9, and I get an error message :

"Unable to connect to VNC Server using your chosen security setting. Either upgrade VNC Server to a more recent version from RealVNC, or select a weaker level of encryption."

Any idea why I get this error, and how may I VNC to my Deb 9 ? This would be a tremendous help to me. :(

Edit: For our corporate use, we have an Enterprise version of RealVNC server and viewer for use from RealVNC (4.6.3). And it by default asks/takes our corporate logins (which it checks to make sure are valid corporate logins, though can also be configured to use other passwords as well). Here, in my case, I don't know that's matters, is required.
Last edited by white_tee_shirt on 2018-02-09 14:09, edited 1 time in total.
white_tee_shirt
 
Posts: 17
Joined: 2018-02-08 17:03

Re: VNC to my Deb 9 from Windows

Postby pekwalker » 2018-02-09 13:25

I am still relatively new to Linux and Debian in general and am not sure if it is an option, but perhaps you could install RealVNC on your Debian machine? I use RealVNC to connect to a Raspberry Pi 3 setup that I have and RealVNC VIewer on a Desktop and the two work perfectly together under that setup. I found this https://www.realvnc.com/en/connect/docs ... emove.html that may help get you setup. Again, I am new to all of this and apologize if it has nothing to do with your issue but hopefully it will help.

Peter
pekwalker
 
Posts: 4
Joined: 2018-02-07 13:27
Location: Roanoke, TX USA

Re: VNC to my Deb 9 from Windows

Postby white_tee_shirt » 2018-02-09 20:16

pekwalker wrote:I am still relatively new to Linux and Debian in general and am not sure if it is an option, but perhaps you could install RealVNC on your Debian machine? I use RealVNC to connect to a Raspberry Pi 3 setup that I have and RealVNC VIewer on a Desktop and the two work perfectly together under that setup. I found this https://www.realvnc.com/en/connect/docs ... emove.html that may help get you setup. Again, I am new to all of this and apologize if it has nothing to do with your issue but hopefully it will help.

Peter

I don't want to download RealVNC from their website and then unpack the tarball and have it's files installed in my ~/Downloads directory. I wish to have it installed in the right directory. Ideally I want a .deb file so that I can add it to my repository and install the package. RealVNC site doesn't give any info about how to install that way. To answer, I haven't tried realvnc, I couldn't find much help online and I have written them an email this morning ask how may I install and use without tarballs.
white_tee_shirt
 
Posts: 17
Joined: 2018-02-08 17:03

Re: VNC to my Deb 9 from Windows

Postby TheExplorer » 2018-02-12 18:22

Why not install something like Vino from the repos?
Money is the evil of all root. Be free. Use Linux.
User avatar
TheExplorer
 
Posts: 241
Joined: 2010-05-31 15:04

Re: VNC to my Deb 9 from Windows

Postby GarryRicketson » 2018-02-12 19:08

by white_tee_shirt »I don't want to download RealVNC from their website and then unpack the tarball and have it's files installed in my ~/Downloads directory. I wish to have it installed in the right directory.

So, why don't you create the directory you want to have it in ?
Code: Select all
mkdir "anyname"

Code: Select all
man mkdir

Then move the downloaded file to that directory,
Code: Select all
mv this-foo.tar /path/to/anydir/

Code: Select all
man mv

Unpack it there. Just because it is in the Download directory , (which is normal for downloaded files) does not meant you have to unpack it there, or leave it. The same if you download a .deb file, unless you specify a different directory, it is going to go to the Downloads directory, however with the .deb , if you use gdebi, or 'dpkg', it will install to the appropriate directories and libraries as needed.

by white_tee_shirt »
Then, when I go to my Windows station ---- snip------

Sorry , I have never used,and never will be using Windows, so I can't help with that.
But this seems straightforward and clear enough:
"Unable to connect to VNC Server using your chosen security setting. Either upgrade VNC Server to a more recent version from RealVNC, or select a weaker level of encryption."


Any idea why I get this error, and how may I VNC to my Deb 9 ? This would be a tremendous help to me. :(

The error message tells you why : Your choosen security setting is not acceptable.
It also tells you quite clearly: "Either upgrade VNC Server to a more recent version from RealVNC, or select a weaker level of encryption."
That is not hard to understand even for me, and I am not very smart.
2 choices, upgrade it to a more rent version, or select weaker encryption.
User avatar
GarryRicketson
 
Posts: 4950
Joined: 2015-01-20 22:16
Location: Durango, Mexico

Re: VNC to my Deb 9 from Windows

Postby white_tee_shirt » 2018-02-12 21:21

GarryRicketson wrote: So, why don't you create the directory you want to have it in ?

Hi Garry, I agree w. you 100%. It was a continuation of some my gripe with some other packages who doesn't offer a standard directory to install, and I didn't know where `anydir` should be. If I moved them to `/etc/opt` then I am needed to be in root to execute, which I don't desire to. As for why not .deb , and use gdebi, or 'dpkg', While it is true that it will install to the appropriate directories and libraries as needed, I was un-successful in finding a .deb from RealVNC for their server and client.
GarryRicketson wrote: Sorry , I have never used,and never will be using Windows, so I can't help with that. But this seems straightforward and clear enough:

I have no choice but use Windows workstations at my work environment as thats what IT provided us with here. The security I chose was a normal vnc password setup. As for the version, it was indeed a latest version of the VNC server and client available to me, just not a version the Windows client wanted it to be. So I think thats' where the issue lie. Thanks for replying.
white_tee_shirt
 
Posts: 17
Joined: 2018-02-08 17:03

Re: VNC to my Deb 9 from Windows

Postby GarryRicketson » 2018-02-12 22:21

Have you tried this ?:
https://archive.realvnc.com/products/vnc/documentation/4.5/unix/install_debian.html
Using desktop tools (preferred)

Open the VNC Enterprise Edition .deb file using a package manager, and follow its instructions.

If you encounter an error message, install at the command line instead (see below).
At the command line

Type dpkg -i <package>, where <package> is a relative path to the VNC Enterprise Edition .deb file.

If you are upgrading to version 4.5.4, you can safely ignore any warning message you may encounter.

OR, they also show this:(the tar ball you are talking about)
From: https://archive.realvnc.com/products/vnc/documentation/4.5/unix/install_tar_gz.html You can install VNC Enterprise Edition from unpackaged binaries and, where appropriate, installation scripts (a tarball).

The following instructions apply to all UNIX and Linux platforms. Where an example is given, the syntax is valid for Ubuntu 8.10 Linux.

Open a Terminal window and switch to root, or to a user with equivalent permissions.
Extract and decompress the contents of the tarball, for example tar -xvzf <tarball>, where <tarball> is the full path to the downloaded .tar.gz file. A new sub-directory is created with the root name of the .tar.gz file.
Navigate to this newly-created directory and run the vncinstall script, for example ./vncinstall.

The vncinstall script installs programs into default system directories; examine the script for details. To specify different directories, run vncinstall with the following parameters:

vncinstall <program-dir> <manual-dir> <module-dir>

where <program-dir> is the full path to a directory for VNC programs, <manual-dir> is the full path to a directory for VNC man documentation pages, and <module-dir> is the full path to a directory for the vnc.so module. Note that all three parameters are mandatory; if you specify one you must specify them all.

When VNC Enterprise Edition has successfully installed you can delete the newly-created directory.


It seems pretty straight forward, but let' break it down a little:
Extract and decompress the contents of the tarball, for example
Code: Select all
tar -xvzf <tarball>, where <tarball>
is the full path to the downloaded .tar.gz file. A new sub-directory is created with the root name of the .tar.gz file.

In situations like this, I find it easier to first move the tarball out of my Downloads dir. So first I make a dir for it:
Code: Select all
$mkdir /home/garry/VNC

Then go to my Downloads dir:
Code: Select all
mv <tarball> /home/garry/VNC

And I extract it there, how ever they say it will create a subdirectory, you could just do it this way:
Code: Select all
tar -xvzf <tarball> /home/garry/VNC

It should create a sub directory in the /home/garry/VNC dir, it will be the name that the "tar.gz" file has.
I prefer moving the file to the directory I created first, but in any event
since it creates it's own sub dir when you unpack it, it is no big deal, if it is not where you want it, you can delete or remove the same dir, and try again.

Navigate to this newly-created directory and run the vncinstall script, for example ./vncinstall.

To run the script, do like it says, as a normal user:
for example:
Code: Select all
$ cd /home/garry/VNC/newVNCsubdir

Use 'ls' to check, you should see the filename : "vcinstall", to run it:
Type:
Code: Select all
./vncinstall

It should start installing to the appropriate places.
Note: You may have to also use 'chmod' to make it executable, :
Code: Select all
$ chmod +x vncinstall

========
The vncinstall script installs programs into default system directories; examine the script for details. To specify different directories, run vncinstall with the following parameters:

vncinstall <program-dir> <manual-dir> <module-dir>

where <program-dir> is the full path to a directory for VNC programs, <manual-dir> is the full path to a directory for VNC man documentation pages, and <module-dir> is the full path to a directory for the vnc.so module. Note that all three parameters are mandatory; if you specify one you must specify them all.


I don't think you should or need to do this part, it is hard to say on that, I would try it with out changing anything first. If you get errors, and don't understand , we would need to see the script as well.

After all said and done, I think it would be easier and better if you just used some VNC packages that are in the Debian repositories , instead of this, but that is your option.
User avatar
GarryRicketson
 
Posts: 4950
Joined: 2015-01-20 22:16
Location: Durango, Mexico

Re: VNC to my Deb 9 from Windows

Postby GarryRicketson » 2018-02-12 22:32

Postby white_tee_shirt » Ideally I want a .deb file so that I can add it to my repository and install the package. RealVNC site doesn't give any info about how to install that way.

Yes it does, see my previous post, and here is where you can get the .deb
file.

https://www.realvnc.com/en/connect/download/vnc/linux/

The "viewer" (client ) is here:
https://www.realvnc.com/en/connect/download/viewer/linux/

It seems like you are not really reading anything very carefully, their web site documents all of this , rather well.
User avatar
GarryRicketson
 
Posts: 4950
Joined: 2015-01-20 22:16
Location: Durango, Mexico


Return to Beginners Questions

Who is online

Users browsing this forum: No registered users and 2 guests

fashionable