Appliance 1.6.8 CMK Update 2.1.0p36.cee > 2.1.0p45.cee

CMK version: 2.1.0p36.cee
OS version: Appliance 1.6.8

**Error message:

Error during update:
Cannot execute omd command omd -f -V 2.1.0p45.cee update --conflict=install hannover: Cleaning up tmp directory...OK
2024-07-11 01:49:13 - Updating site 'hannover' from version 2.1.0p34.cee to 2.1.0p45.cee...

 * Updated        etc/nagvis/apache.conf
 * Updated        etc/cron.d/diskspace
 * Updated        etc/init.d/mkeventd
 * Updated        etc/init.d/redis
Creating temporary filesystem /omd/sites/hannover/tmp...OK
Executing update-pre-hooks script "01_mkp-disable-outdated"...OK
Executing update-pre-hooks script "02_cmk-update-config"...
-| Initializing application...
-| Updating Checkmk configuration...
-| ATTENTION: Some steps may take a long time depending on your installation, e.g. during major upgrades.
-|  1/32 Rewriting password store...
-|  2/32 Migrate Visuals context...
-|  3/32 Update global settings...
-|  4/32 Rewriting tags...
-|  5/32 Rewriting hosts and folders...
-|  6/32 Rewriting rulesets...
-| Extracting excluded SNMP sections
-| Replacing ruleset non_inline_snmp_hosts with snmp_backend_hosts
-|  7/32 Rewriting discovered host labels...
-|  8/32 Rewriting autochecks...
-|  9/32 Cleanup version specific caches...
-|  10/32 Migrating fs_used name...
-|  + "Migrating fs_used name" failed
-| Traceback (most recent call last):
-|   File "/omd/sites/hannover/lib/python3/cmk/update_config.py", line 346, in run
-|     step_func()
-|   File "/omd/sites/hannover/lib/python3/cmk/update_config.py", line 420, in _update_fs_used_name
-|     cmk.update_rrd_fs_names.update()
-|   File "/omd/sites/hannover/lib/python3/cmk/update_rrd_fs_names.py", line 217, in update
-|     update_service_info(config_cache, get_hostnames(config_cache))
-|   File "/omd/sites/hannover/lib/python3/cmk/update_rrd_fs_names.py", line 207, in update_service_info
-|     rename_journal.update(update_files(hostname, description, entry.item, "pnp4nagios"))
-|   File "/omd/sites/hannover/lib/python3/cmk/update_rrd_fs_names.py", line 136, in update_files
-|     entry_to_rename = update_pnp_info_files(perfvar, new_name, filepath)
-|   File "/omd/sites/hannover/lib/python3/cmk/update_rrd_fs_names.py", line 189, in update_pnp_info_files
-|     os.rename(rrdfile, rrdfilenew)
-| FileNotFoundError: [Errno 2] No such file or directory: '/opt/omd/sites/hannover/var/pnp4nagios/perfdata/wgh315/Filesystem____.rrd' -> '/opt/omd/sites/hannover/var/pnp4nagios/perfdata/wgh315/Filesystem___fs_used.rrd'
-|  11/32 Migrate pagetype topics...
-|  12/32 Migrate dashlets...
-|  13/32 Migrate LDAP connections...
-|  14/32 Rewrite BI Configuration...
-| Skipping conversion of bi.mk (already done)
-|  15/32 Set version specific user attributes...
-|  16/32 Check for insecure password hashes, enforce password reset...
-| e[93m Users with insecure password hashes have been found in the htpasswd file. These users will be required to change their password on their next login.
-| Please ensure that the affected users log in and change their password before updating to Checkmk version 2.2. Otherwise these users will not be able to log in anymore and their passwords will need to be reset manually by an administrator (either the user configuration or via the cmk-passwd command).
-| The following users are affected:
-| api_wertgarantie_de
-| skle[00m
-|  17/32 Rewriting inventory data...
-| Skipping py2 inventory data update (already done)
-|  18/32 Migrate audit log...
-| New audit log already existing. Skipping.
-|  19/32 Sanitize audit log (Werk #13330 & #17056)...
-| Skipping (Werk #13330 already done)
-| Wrote audit log backup to /omd/sites/hannover/audit_log_backup. Please check if the audit log in the GUI works as expected. In case of problems you can copy the backup files back to /omd/sites/hannover/var/check_mk/wato/log. Please check the corresponding files in /omd/sites/hannover/var/check_mk/wato/log for any leftover automation secrets and remove them if necessary. If everything works as expected you can remove the backup. For further details please have a look at Werk #17056.
-| Start sanitize of /omd/sites/hannover/var/check_mk/wato/log/wato_audit.log
-| Finished sanitize of /omd/sites/hannover/var/check_mk/wato/log/wato_audit.log
-| Wrote sanitization flag file /omd/sites/hannover/var/check_mk/wato/log/.werk-17056
-|  20/32 Rename discovered host label files...
-|  21/32 Rewriting host, service or contact groups...
-|  22/32 Rewriting notification configuration for ServiceNow...
-|  23/32 Renewing certificates without server name extension...
-| Skipping (nothing to do)
-|  24/32 Adding site CA to trusted CAs...
-|  25/32 Rewrite mknotifyd config for central site...
-|  26/32 Rewriting InfluxDB connections...
-|  27/32 Disabling unsafe EC rules...
-|  28/32 Update bakery links and settings...
-|  29/32 Remove old custom logos (CME)...
-|  30/32 Fix registered hosts symlinks...
-|  31/32 Update license usage history...
-|  32/32 Synchronize automationuser secrets...
-| Done
ERROR (exit code: 1)

**

Output of “cmk --debug -vvn hostname”: (If it is a problem with checks or plugins)

Hi sebo,

there seems to be a problem with an rrd file that should be converted during the update.
It seems to me that the Drive letter is missing, maybe there went something wrong during the creation of these files in the past.

You can try a cmk --convert-rrds --debug -vvv to see if that throws any error or can fix the problem.

Depending on how important the metrics for that server are, you can just choose the hard way and delete the whole folder /opt/omd/sites/hannover/var/pnp4nagios/perfdata/wgh315

What i would take a look at is that you are still using the old pnp4nagios format and not the checkmk format of the rrds despite you are using the enterprise edition.

ls -al /opt/omd/sites/hannover/var/check_mk/rrd/ | wc -l
147
ls -al /opt/omd/sites/hannover/var/pnp4nagios/perfdata | wc -l
29

yes you are right there are 29 Hosts in both folders, should i just delete the old dir /opt/omd/sites/hannover/var/pnp4nagios/perfdata

ls -al /opt/omd/sites/hannover/var/pnp4nagios/perfdata | grep wgh315
drwxrwxr-x 2 hannover hannover 4096 Aug 16 2022 wgh315

ls -al /opt/omd/sites/hannover/var/check_mk/rrd/ | grep wgh315
drwxrwx— 2 hannover hannover 4096 Oct 17 2023 wgh315

No, i would check that the two rrd rules for the checkmk services and the hosts are setup are correctly configured and then run the convert-rrds command as described in the documentation.

ok thanks, both are with the correct rrd format:

so i stop the site do the conversion, resxtart and do the upgrade.

Thanks for your help.

1 Like