Common Round Robin Database (RRD) issues

Common Round Robin Database (RRD) issues

This manual provides a checklist for common Round Robin Database (RRD) issues and troubleshooting steps.

LAST TESTED ON CHECKMK 2.4.0P1

Table of Contents

After the RRD migration, the graph does not record values

After the RRD migration, some graphs are not recording values for some reason. See here how to debug that: Troubleshooting graph not recording values after RRD migration

This can also happen after the migration from 1.6 → to 2.0 because we auto-convert the rrds: Debugging corrupted RRD files

Screenshot of an error message. The message reads cannot create graph. Cannot get RRD data for kirchner_check_mk_agent_output.txt

Error during the rrd conversion

In this topic, we collect some common issues during the conversion of pnp4nagios. We know that there are many more, and this manual will not cover all.

If you face an issue not documented here, please use that manual How-to debug corrupted xml filel of pnp4nagios for a detailed debug.

The 'NoneType' object has no attribute 'text'

During the conversion of pnp4nagios files to the rrd format, you may face this error:

OMD[mysite]:~$ cmk -v --convert-rrds --delete-rrds RRD8040 RRD8040: HOST: RRD8040 ERROR: 'NoneType' object has no attribute 'text'

Follow the manual Troubleshooting errors during the RRD conversion for resolution

 

The 'NoneType' object has no attribute 'replace'

HOST: RRD-a ERROR: 'NoneType' object has no attribute 'replace'

Follow the manual Troubleshooting errors during the RRD conversion'' for resolution

'ASCII' codec can't decode characters 

During the conversion of pnp4nagios files to the rrd format, you may face this error:

OMD[mysite]:~$ cmk --convert-rrds localhost Traceback (most recent call last): File "/omd/sites/rrd/bin/cmk", line 94, in <module> exit_status = modes.call(mode_name, mode_args, opts, args) File "/omd/sites/rrd/lib/python/cmk_base/modes/__init__.py", line 72, in call return mode.handler_function(*handler_args) File "/omd/sites/rrd/lib/python/cmk_base/modes/cee.py", line 147, in mode_convert_rrds rrd.do_convert_rrds(*args) File "/omd/sites/rrd/lib/python/cmk_base/cee/rrd.py", line 413, in do_convert_rrds convert_rrds_of_host(hostname) File "/omd/sites/rrd/lib/python/cmk_base/cee/rrd.py", line 428, in convert_rrds_of_host console.error(" %sERROR: %s%s\n" % (tty.red + tty.bold, e, tty.normal)) UnicodeEncodeError: 'ascii' codec can't encode characters in position 70-75: ordinal not in range(128)

Follow the manual 'ASCII' codec can't decode characters for resolution

xml.etree.ElementTree.ParseError: no element found: line 1, column 0

After a Checkmk update or during the execution of cmk-update-config, you may see this error:

OMD[mysite]:~$ cmk-update-config + "Migrating fs_used name" failed Traceback (most recent call last): File "/omd/sites/mysite/lib/python3.8/xml/etree/ElementTree.py", line 1700, in close self.parser.Parse("", 1) # end of data xml.parsers.expat.ExpatError: no element found: line 1, column 0 During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/omd/sites/mysite/lib/python3/cmk/update_config.py", line 158, in run step_func() File "/omd/sites/mysite/lib/python3/cmk/update_config.py", line 199, in _update_fs_used_name cmk.update_rrd_fs_names.update() File "/omd/sites/mysite/lib/python3/cmk/update_rrd_fs_names.py", line 186, in update update_service_info(config_cache, get_hostnames(config_cache)) File "/omd/sites/mysite/lib/python3/cmk/update_rrd_fs_names.py", line 176, in update_service_info update_files(hostname, service.description, service.item, 'pnp4nagios')) File "/omd/sites/mysite/lib/python3/cmk/update_rrd_fs_names.py", line 84, in update_files metrics = get_metrics(filepath, source) File "/omd/sites/mysite/lib/python3/cmk/update_rrd_fs_names.py", line 74, in get_metrics root = ET.parse(filepath).getroot() File "/omd/sites/mysite/lib/python3.8/xml/etree/ElementTree.py", line 1202, in parse tree.parse(source, parser) File "/omd/sites/mysite/lib/python3.8/xml/etree/ElementTree.py", line 602, in parse self._root = parser.close() File "/omd/sites/mysite/lib/python3.8/xml/etree/ElementTree.py", line 1702, in close self._raiseerror(v) File "/omd/sites/mysite/lib/python3.8/xml/etree/ElementTree.py", line 1602, in _raiseerror raise err File "<string>", line None xml.etree.ElementTree.ParseError: no element found: line 1, column 0 Skipping conversion of bi.mk (already done) OMD[mysite]:~$

Please follow that manual to solve that: Troubleshooting errors during the RRD conversion#xml.etree.ElementTree.ParseError:noelementfound:line1,column0

xml.etree.ElementTree.ParseError: unclosed token: line 114, column 0

After a Checkmk update or during the execution of cmk-update-config, you may see this error:

OMD[mysite]:~$ cmk-update-config + "Migrating fs_used name" failed Traceback (most recent call last): File "/omd/sites/mysite/lib/python3.8/xml/etree/ElementTree.py", line 1700, in close self.parser.Parse("", 1) # end of data xml.parsers.expat.ExpatError: unclosed token: line 114, column 0 During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/omd/sites/mysite/lib/python3/cmk/update_config.py", line 158, in run step_func() File "/omd/sites/mysite/lib/python3/cmk/update_config.py", line 199, in _update_fs_used_name cmk.update_rrd_fs_names.update() File "/omd/sites/mysite/lib/python3/cmk/update_rrd_fs_names.py", line 186, in update update_service_info(config_cache, get_hostnames(config_cache)) File "/omd/sites/mysite/lib/python3/cmk/update_rrd_fs_names.py", line 176, in update_service_info update_files(hostname, service.description, service.item, 'pnp4nagios')) File "/omd/sites/mysite/lib/python3/cmk/update_rrd_fs_names.py", line 84, in update_files metrics = get_metrics(filepath, source) File "/omd/sites/mysite/lib/python3/cmk/update_rrd_fs_names.py", line 74, in get_metrics root = ET.parse(filepath).getroot() File "/omd/sites/mysite/lib/python3.8/xml/etree/ElementTree.py", line 1202, in parse tree.parse(source, parser) File "/omd/sites/mysite/lib/python3.8/xml/etree/ElementTree.py", line 602, in parse self._root = parser.close() File "/omd/sites/mysite/lib/python3.8/xml/etree/ElementTree.py", line 1702, in close self._raiseerror(v) File "/omd/sites/mysite/lib/python3.8/xml/etree/ElementTree.py", line 1602, in _raiseerror raise err File "<string>", line None xml.etree.ElementTree.ParseError: unclosed token: line 114, column 0 Skipping conversion of bi.mk (already done)

Please follow that manual to solve that: Troubleshooting errors during the RRD conversion#xml.etree.ElementTree.ParseError:unclosedtoken:line114,column0

Error in cmc.log

after rrd migration

After converting the RRD files to the new format (described here: RRD storage format), in some rare cases, it might happen that data is still written to {{$OMD_ROOT/var/pnp4nagios/perfdata/myhost/}}.

At the same time, you might see error messages in the {{cmc.log}} like below as you can see that some RRD files in {{$OMD_ROOT/var/pnp4nagios/perfdata/myhost/}} are still updated.

2021-09-20 09:18:14 [4] [rrdcached thread] [rrdcached at "/omd/sites/mysite/tmp/run/rrdcached.sock"] [log] -1 No such file: /omd/sites/mysite/var/pnp4nagios/perfdata/myhost/Memory_and_pagefile_pagefile_total.rrd 2021-09-20 09:18:14 [4] [rrdcached thread] [rrdcached at "/omd/sites/mysite/tmp/run/rrdcached.sock"] [log] -1 No such file: /omd/sites/mysite/var/pnp4nagios/perfdata/myhost/Memory_and_pagefile_pagefile_avg.rrd 2021-09-20 09:18:14 [4] [rrdcached thread] [rrdcached at "/omd/sites/mysite/tmp/run/rrdcached.sock"] [log] -1 No such file: /omd/sites/mysite/var/pnp4nagios/perfdata/myhost/Power_cpu0_Cores_w.rrd 2021-09-20 09:18:14 [4] [rrdcached thread] [rrdcached at "/omd/sites/mysite/tmp/run/rrdcached.sock"] [log] -1 No such file: /omd/sites/mysite/var/pnp4nagios/perfdata/myhost/Power_cpu0_DRAM_w.rrd 2021-09-20 09:18:14 [4] [rrdcached thread] [rrdcached at "/omd/sites/mysite/tmp/run/rrdcached.sock"] [log] -1 No such file: /omd/sites/mysite/var/pnp4nagios/perfdata/myhost/Power_cpu0_Graphics_w.rrd 2021-09-20 09:18:14 [4] [rrdcached thread] [rrdcached at "/omd/sites/mysite/tmp/run/rrdcached.sock"] [log] -1 No such file: /omd/sites/mysite/var/pnp4nagios/perfdata/myhost/Power_cpu0_Package_w.rrd

 

The chances are high that not all hosts are affected, but only a few, even less than 10%. To get rid of that, please follow this manual: Error handling with RRD files after conversion to the new format

Cannot create a graph

Screenshot of CPU utilization service for mysite01. Error reads cannot create graph

 

It seems like the .rrd file is missing. Please double-check with the cmc.log:

OMD[mysite]:~$ tail -f var/log/cmc.log 2022-06-02 12:09:41 [4] [main] [rrd] [rrdcached at /omd/sites/mysite/tmp/run/rrdcached.sock] >> -1 No such file: /opt/omd/sites/mysite/var/check_mk/rrd/myhost/CPU_Utilization_Packet_CPU_1.rrd 2022-06-02 12:10:41 [4] [main] [rrd] [rrdcached at /omd/sites/mysite/tmp/run/rrdcached.sock] >> -1 No such file: /opt/omd/sites/mysite/var/check_mk/rrd/myhost/CPU_Utilization_Mgmt_CPU.rrd 2022-06-02 12:10:41 [4] [main] [rrd] [rrdcached at /omd/sites/mysite/tmp/run/rrdcached.sock] >> -1 No such file: /opt/omd/sites/mysite/var/check_mk/rrd/myhost/CPU_Utilization_Packet_CPU_0.rrd

To solve that, please follow the manual: How-to debug graphs not being created

Related articles