VNC remote control

Started by Hanfelt, January 17, 2025, 08:00:47 PM

Previous topic - Next topic

Hanfelt

Is there any more documentation about the vnc remote control or how to debug it?
I did everything that it explain but when i do a configuration poll i get:

[2025.01.17 18:51:25]    Checking direct VNC connectivity...
[2025.01.17 18:51:25]    Cannot connect to VNC
[2025.01.17 18:51:25]    Checking VNC connectivity via local agent...
[2025.01.17 18:51:25]    Cannot connect to VNC


I have enabled loopback on tightvnc server and tried with and without firewall, enabled proxy tcp and such.. This is a windows server.

We have this in the documentation:

Remote control option will appear for nodes where VNC install is detected. In order to take advantage of this feature, one should add EnableTCPProxy = yes in agent configuration on remote node followed by agent restart. Run Configuration Poll on the node you want to VNC to. Target VNC may require loopback connection to be enabled as well as firewall settings adjusted. In cases when there is no agent installed on remote node, but VNC is present, we can use agent on NetXMS server or agent serving as zone proxy. In this scenario, one would need to add EnableTCPProxy = yes in agent configuration on server or on agent that acts like proxy for zone. Your NetXMS user should have "Initiate TCP proxy sessions" system access right. In addition, in object tree user should have "Control" access rights to that node.

Filipp Sudanov

First of all, upgrade to the latest version is recommended, as there was a but with connectivity detection at some point.

The idea is that connection goes through netxms agent. It can be either agent on the system where vnc is running (in this case vnc should accept connections from 127.0.0.1), or it can be agent that runs along with netxms server.

So you need to add
EnableTCPProxy = yes
into configuration file on one of the mentioned agents, restart that agent and then try to run configuration poll on that node again.

Hanfelt

#2
Yes ill try and upgrade i have enabled the proxy, and i also have enabled the loopback connection on tightvnc server ill get back to you ;)

Hanfelt

#3
I actually forgot to upgrade the agent on the server when i tested this before now it works like a charm ;)

The only problem i have in the vnc session is that cannot type capital letters so i cannot get the password right.

2025.01.18 14:03:55]    Cannot connect to SSH
[2025.01.18 14:03:55]    Checking direct VNC connectivity...
[2025.01.18 14:03:55]    Cannot connect to VNC
[2025.01.18 14:03:55]    Checking VNC connectivity via local agent...
[2025.01.18 14:03:55]   VNC connection via local agent is available



Filipp Sudanov

Password can be specified in node's properties. 

But the issue with capital letters - is it web or desktop client?

Hanfelt

#5
Im using the jar file packaged as a mac client:

Here is the translation to English:

Install JRE2App

JRE2App is a tool used to convert Java programs into macOS applications.
To install JRE2App, run the following command in the terminal:

brew install python
git clone https://github.com/Jorl17/jar2app
cd jar2app

Next, you need to fetch some specific commits from the JRE2App project:

git pull origin dcda6681c86b22a5dbe2f8ea82f5e02081a78f0f
git pull origin c10df88b3cd94d2d0e83002be2d2f22db80eb88a
git pull origin 58307b345a4a374fe02f053f0c81d382c952994c

Now you have installed and updated the JRE2App tool.

Create a NetXMS App

NetXMS is a network monitoring system.
To create a macOS app for NetXMS, run the following command:

python3 jar2app.py -j "-XstartOnFirstThread" ../NetXMS/nxmc-5.1.1-standalone.jar -r /Users/user/Downloads/jdk-23.0.1.jdk -i ../NetXMS/nxmc.icns

Explanation
python3 jar2app.py: Runs the JRE2App tool.
-j "-XstartOnFirstThread": Adds a JVM parameter to start the program on the main thread.
../NetXMS/nxmc-5.1.1-standalone.jar: The path to the standalone JAR file containing the NetXMS program.
-r /Users/user/Downloads/jdk-23.0.1.jdk: The path to the Java Runtime Environment (JRE) to be used for building the app.
-i ../NetXMS/nxmc.icns: The path to an ICNS file containing the app icon.

By running these commands, you create a macOS app from the NetXMS program using the JRE2App tool. The result is a standalone macOS application that you can distribute and run on your computer.

Hanfelt

I tried the latest netxms console in windows as well and it seems to have the same problem. At least for me.

Filipp Sudanov

These capital letters - are these ASCII characters or from some specific alphabet?
What VNC server are you using, on what OS?

Hanfelt

#8
I have tried Swedish and English keyboard from windows and mac trying to control a windows server set to Swedish and English. No capital letters at login prompt whatever i try. If i use another vnc viewer instead of the built in Netxms console it works.

Im using tightvnc server.