Updating the Data Center compatibility level to 4.3 can result in a non-responsive DC and no SPM

Solution Unverified - Updated

Environment

  • Red Hat Virtualization (RHV) 4.3

Issue

  • While updating the Data Center compatibility mode to 4.3, the Data Center became 'Non Responsive' and no SPM could be elected.

  • VMs could not be started.

  • The engine reported Meta Data key not found error.

  • VDSM on the hosts reported MetaDataKeyNotFoundError.

Resolution

  • A bug, This content is not included.BZ 1713724, was opened to address this.

  • This has been fixed in vdsm-4.30.17-1 in RHV 4.3.

  • The immediate work-around is to create valid metadata for the volume(s) in question, just to allow the update to complete. Please contact Red Hat Technical Support for assistance with this.

  • After that, these volumes should be checked to see if they should or should not exist. They most likely should no longer exist, and so can be removed. However, even though they should no longer exist, they may still exist in the RHV database. Please contact Red Hat Technical Support for assistance with this, as care needs to be taken when doing this.

Root Cause

  • Part of the Data Center compatibility mode upgrade for 4.3 includes upgrading the storage domains to Version 5. This involves processing all of the volume metadata areas in each storage domain.

  • The problem occurred because the volume metadata for some volumes did not exist, or more accurately had been reset, which happens when a volume is being removed. So, at some time in the past, one or more volume must have failed to have been removed, and so they still existed, but with no valid metadata.

Diagnostic Steps

  • engine log repetitive sequence;
2019-05-23 03:42:15,572-03 INFO  [org.ovirt.engine.core.vdsbroker.irsbroker.IrsProxy] (EE-ManagedThreadFactory-engineScheduled-Thread-23) [] starting spm on vds 'Host-A', storage pool 'DC-X', prevId '-1', LVER '-1'
2019-05-23 03:42:23,666-03 ERROR [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] (EE-ManagedThreadFactory-engineScheduled-Thread-23) [] EVENT_ID: VDS_BROKER_COMMAND_FAILURE(10,802), VDSM Host-A command HSMGetTaskStatusVDS failed: Meta Data key not found error: ("Missing metadata key: 'SIZE': found: {'NONE': '######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################'}",)
2019-05-23 03:42:23,666-03 ERROR [org.ovirt.engine.core.vdsbroker.vdsbroker.SpmStartVDSCommand] (EE-ManagedThreadFactory-engineScheduled-Thread-23) [] Start SPM Task failed - result: 'cleanSuccess', message: VDSGenericException: VDSErrorException: Failed to HSMGetTaskStatusVDS, error = Meta Data key not found error: ("Missing metadata key: 'SIZE': found: {'NONE': '######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################'}",), code = 751
2019-05-23 03:42:27,442-03 INFO  [org.ovirt.engine.core.vdsbroker.irsbroker.IrsProxy] (EE-ManagedThreadFactory-engineScheduled-Thread-23) [795baf08] starting spm on vds 'Host-B', storage pool 'DC-X', prevId '-1', LVER '-1'
2019-05-23 03:42:33,484-03 ERROR [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] (EE-ManagedThreadFactory-engineScheduled-Thread-23) [795baf08] EVENT_ID: VDS_BROKER_COMMAND_FAILURE(10,802), VDSM Host-B command HSMGetTaskStatusVDS failed: Meta Data key not found error: ("Missing metadata key: 'SIZE': found: {'NONE': '######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################'}",)
2019-05-23 03:42:33,485-03 ERROR [org.ovirt.engine.core.vdsbroker.vdsbroker.SpmStartVDSCommand] (EE-ManagedThreadFactory-engineScheduled-Thread-23) [795baf08] Start SPM Task failed - result: 'cleanSuccess', message: VDSGenericException: VDSErrorException: Failed to HSMGetTaskStatusVDS, error = Meta Data key not found error: ("Missing metadata key: 'SIZE': found: {'NONE': '######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################'}",), code = 751
  • vdsm log error;
2019-05-24 16:16:59,985-0400 INFO  (jsonrpc/5) [vdsm.api] FINISH upgradeStoragePool error=Meta Data key not found error: ("Missing metadata key: 'SIZE': found: {'NONE': '####################################################################
##############################################################################################################################################################################################################################################
####################################################################################################################################################################################################'}",) from=::ffff:10.18.49.10,33120, flow_
id=529ad2d1-ccad-4604-8b67-67cdd7928314, task_id=c9eb763e-76e2-44d1-aeb0-584e1270ad68 (api:52)
2019-05-24 16:16:59,985-0400 ERROR (jsonrpc/5) [storage.TaskManager.Task] (Task='c9eb763e-76e2-44d1-aeb0-584e1270ad68') Unexpected error (task:875)
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/vdsm/storage/task.py", line 882, in _run
    return fn(*args, **kargs)
  File "<string>", line 2, in upgradeStoragePool
  File "/usr/lib/python2.7/site-packages/vdsm/common/api.py", line 50, in method
    ret = func(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/vdsm/storage/hsm.py", line 3434, in upgradeStoragePool
    pool._upgradePool(targetDomVersion, lockTimeout=0)
  File "/usr/lib/python2.7/site-packages/vdsm/storage/securable.py", line 79, in wrapper
    return method(self, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/vdsm/storage/sp.py", line 484, in _upgradePool
    str(targetDomVersion))
  File "/usr/lib/python2.7/site-packages/vdsm/storage/sp.py", line 1108, in _convertDomain
    targetFormat)
  File "/usr/lib/python2.7/site-packages/vdsm/storage/formatconverter.py", line 447, in convert
    converter(repoPath, hostId, imageRepo, isMsd)
  File "/usr/lib/python2.7/site-packages/vdsm/storage/formatconverter.py", line 405, in v5DomainConverter
    domain.convert_volumes_metadata(target_version)
  File "/usr/lib/python2.7/site-packages/vdsm/storage/fileSD.py", line 815, in convert_volumes_metadata
    vol_md = vol.getMetadata()
  File "/usr/lib/python2.7/site-packages/vdsm/storage/volume.py", line 819, in getMetadata
    return self._manifest.getMetadata(metaId)
  File "/usr/lib/python2.7/site-packages/vdsm/storage/fileVolume.py", line 160, in getMetadata
    md = VolumeMetadata.from_lines(lines)
  File "/usr/lib/python2.7/site-packages/vdsm/storage/volumemetadata.py", line 114, in from_lines
    "Missing metadata key: %s: found: %s" % (e, md))
MetaDataKeyNotFoundError: Meta Data key not found error: ("Missing metadata key: 'SIZE': found: {'NONE': '####################################################################################################################################
##############################################################################################################################################################################################################################################
####################################################################################################################################'}",)

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.