On Wed, Apr 7, 2021 at 5:41 AM Hooge, Thomas <[email protected]> wrote:

> Hello,
>
> for my monitoring-system (zabbix) i want to query guacamole
> about e.g. current connection count and other interesting
> data.
> How do i achieve this? Is that even possible?
>
>
There is no built-in instrumentation for guacd that would provide these
results directly, but there are a couple of possible things you could do:
* You could query the number of running guacd processes, which should be
the number of active connections + 1 (for the parent guacd process).
* You could query the Guacamole Client REST API for active connections. I
believe Zabbix's APM functionality would accomplish this pretty easily -
pulling the data sources and then the active connections per data source
should be reasonably straight-forward:
** When you POST to the api/tokens endpoint you get a JSON response that
includes an array of the availableDataSources.
** For each of the available data sources you can
GET api/session/data/<data source name>/activeConnections, which will give
you the current active connections for that data source.

If you're using the JDBC module to store your connections, you just need to
query using an admin user account and that should give you all of the
active connections. If you're using some other module for connections -
JSON or LDAP, for example - this won't be quite so straight-forward, as
there isn't an admin user who can see all of the active connections for all
users, so this may not give the data you want.

-Nick

Reply via email to