There are various approaches for operational monitoring of Dremio nodes.
Metrics Monitoring using JMX
Monitoring the following metrics are recommended:
- Heap memory usage and GC frequency
- Direct memory usage
- Used lightweight threads
Heap Memory Usage and GC Frequency
Dremio uses heap memory for planning, coordination, UI serving, query management, connection management and some types of record reading etc. type of tasks. Heap memory is expected to be higher in coordinator nodes in high concurrency deployments. When observed together, continued high garbage collection (GC) frequency and high heap memory usage would indicate an undersized cluster/node.
Heap usage can be tracked via
Garbage collection can be tracked by monitoring cumulative counts and times over time:
gc.PS-Scavenge.time. Please note that garbage collection logging is already enabled by default on all Dremio nodes.
Direct Memory Usage
Dremio uses direct memory for query execution tasks — directly affecting performance and concurrency. Dremio also uses direct memory for RPC communication between executor and coordinator nodes, as well as communicating with the end users. Direct memory is expected to be used heavily during query execution on the executor nodes. Continued high direct memory usage would indicate the cluster/node approaching it’s capacity.
Direct memory allocated/used by the execution engine can be tracked via
dremio.memory.direct_current. Total direct memory given to the JVM can be tracked via
Used lightweight Threads
Depending on how much work Dremio is doing, the system might be aggressively parallel. Sometimes this can mean that Dremio is designed to allow for even a single query to use as many cores as available to the process. The number of threads running on each executor node describes the total amount of parallelization Dremio is using.This number maybe substantially more than the number of cores as Dremio is very effective at scheduling between different threads.
If this metric goes more than 10-20 times the number of logical cores, you are probably slowing down individual queries due to contention. You can better understand the impact of contention on a per query basis by looking at the query profile and viewing “Wait Time” value under the “Thread Overview” section per phase. This describes how long each lightweight thread has work available to do but is not scheduled due to CPU contention. Note that this thread count is not directly correlated to kernel threads.
Lightweight threads can be tracked via
Available JMX Metrics
The following is a list of all available JMX metrics.
Remote JMX Monitoring
To set up your environment for remote monitoring,
add the following properties to each Dremio node's dremio-env file
DREMIO_JAVA_SERVER_EXTRA_OPTS property (without newlines):
[info] Note: Local monitoring is enabled by default.
DREMIO_JAVA_SERVER_EXTRA_OPTS=' -Dcom.sun.management.jmxremote.port=<monitoring port> -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false'
In production environments, Dremio strongly recommends using both SSL client certificates to authenticate the client host and password authentication for user management. See Monitoring and Management Using JMX Technology, Out-of-the-Box Monitoring and Management Properties section, for more configuration information.
The Server Status REST end-point can be used to check the health of a node. See Server Status for more information.
On a responsive node, the following response should be returned:
Failing to complete a request to this end-point or delays in getting a response might signal problems with the node.
Please note that, when using internal user management, if no users have been defined, this end point returns the following error:
'No User Available'