VNC Server (Tiger VNC) on CENTOS 8

Hi guys, I'm running into a connection issue when trying to connect to my linode CENTOS 8 using VNC viewer.

I have followed the guide from:
https://www.linode.com/docs/guides/centos-install-and-configure-vnc-server/

and I have confirmed all the install settings and I am running on port 5901

I received the error: "The connection closed unexpectedly" window when I try to connect using localhost:5901.

I tried researching this on https://help.realvnc.com/hc/en-us/articles/360002254738-VNC-Connect-Error-Messages

and scrolled down to the message: "The connection closed unexpectedly" and the possible root cause:

VNC Server’s private key is missing or corrupt.

and the fix:

You should investigate why this has occurred. On a remote Mac or Linux computer, note the location of the private key is determined by the VNC Server RsaPrivateKeyFile parameter.

You can restart VNC Server to regenerate the private key, or alternatively at the command line without restarting by running <server-binary>-service -generatekeys</server-binary>

Have you guys run into this issue? Am I missing something? The guide from Linode didn't mention anything on this… please let me know your guys thoughts or any pointers would be greatly appreciated.

1 Reply

Hey @Merlin116,

Have you tried to connect to your server's GUI using Glish. If connecting via the Glish console works without issue, it's likely a bandwidth/connection issue. Try to lower the resolution setting in ~/.vnc/config or /etc/tigervnc/vncserver-config-defaults.

Can you specify which Operating system you're using to connect to your vncserver? If you're connecting using a Linux machine, don't forget to tunnel your VNC connection over SSH.

 ssh -f <your-vnc-username>@<your-linodes-ipaddress> -L 5901:localhost:5901 -N

Creating an SSH secure tunnel on a Windows machine requires PuTTY. The instructions are at the link below:

  • Windows creating and connecting using PuTTy.

It may also help to verify your settings in your VNC Client software.

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct