Troubleshoot a crashing agent
Under very rare circumstances the monitoring agent crashes. Learn how to trace the reasons.
CloudRadar has a very strict quality assurance and every new release of the monitoring agent is tested intensively on dozens of different operating systems and hardware. Nevertheless, very rarely agents don't operate properly or they crash.
You might experience one of these problems
    1.
    The host has a green light on my.cloudradar.io and it's displayed as connected. But you don't get any metrics. The latest data section is almost empty. This indicates the agent is partially working sending at least the heartbeat.
    2.
    The host has an orange or red light on my.cloudradar.io and it's displayed as pending or disconnected. You don't get any metrics. This indicated the agent is not working at all.

first measure - Enable the debug log.

Open the configuration file /etc/cagent/cagent.conf or C:\Program Files\cagent\cagent.conf and append or change the following line log_level = "debug"
Restart the agent and look what gets logged in /var/log/cagent/cagent.log or C:\Program Files\cagent\cagent.log If the information is too complex, please open a support ticket and provide your log to the support.

second measure- disable parts of the monitoring

Starting with version 1.10 of the agent you fine control what the agent monitors. Very likely a crash is provoked by fetching data from a subsystem and disabling it will solve your problem. Enter the following lines to the configuration file.
1
# operation_mode, possible values:
2
# "full": perform all checks unless disabled individually through other config option. Default.
3
# "minimal": perform just the checks for CPU utilization, CPU Load, Memory Usage, and Disk fill levels.
4
# "heartbeat": Just send the heartbeat according to the heartbeat interval.
5
# Applies only to io_mode = http, ignored on the command line.
6
operation_mode = "full"
7
8
#
9
# Turn on or off parts of the monitoring.
10
# Presets of the operation_mode have precedence.
11
# What's disabled by the operation_mode can't be turned on here.
12
# But it can still be turned off.
13
#
14
# Turn on/off the monitoring of temperature sensors
15
temperature_monitoring = true
16
17
# Turn on/off the monitoring of memory
18
mem_monitoring = true
19
20
# Turn on/off any CPU related monitoring including the cpu_utilisation_analysis
21
cpu_monitoring = true
22
23
# Turn on/off any disk- and filesystem-related monitoring like fill levels and iops
24
fs_monitoring = true
25
26
# Turn on/off any network-related monitoring
27
net_monitoring = true
Copied!
Turn of parts of the monitoring one by one, restarting the agent after each change to the configuration file.
You can check the changes immediately on the console. You don't have to wait until data is submitted to my.cloudradar.io. Just dump all the measurements to the console executing the following command.
cagent -r -o - |jq
You might need to install the command line utility jq. Windows users can download it freely here . Place it in C:\Program Files\cagent and rename the download to jq.exe
You might get a lot of output. If you want to read the data with an editor, execute the following command.
cagent -r -o - |jq . > cagent-data.json
Open cagent-data.json with an editor.
Last modified 1yr ago