Bug 739962 - VDSM - Storage: Can't activate formerly broken domain
Summary: VDSM - Storage: Can't activate formerly broken domain
Alias: None
Product: oVirt
Classification: Retired
Component: vdsm
Version: unspecified
Hardware: Unspecified
OS: Linux
Target Milestone: ---
: 3.3.4
Assignee: Dan Kenigsberg
QA Contact:
Whiteboard: storage
Depends On:
TreeView+ depends on / blocked
Reported: 2011-09-20 14:46 UTC by Daniel Paikov
Modified: 2016-02-10 16:53 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2013-01-30 22:51:40 UTC
oVirt Team: Storage

Attachments (Terms of Use)
vdsm.log (97.55 KB, application/x-gzip)
2011-09-20 14:46 UTC, Daniel Paikov
no flags Details

Description Daniel Paikov 2011-09-20 14:46:59 UTC
Created attachment 524051 [details]

* Pool with one data domain.
* Backup metadata; corrupt domain by echo 1 > metadata.
* RHEVM sets domain to Inactive.
* Overwrite metadata with the backed up metadata.
* Try to activate the domain.
* Activate fails, even though metadata is now ok. Setup goes back to normal only after maintenance/activate of host.

The failure in RHEVM looks like this:
Error connecting to the Storage Pool Manager service.
Possible reasons:
 - Storage Pool Manager service is in non-active state.
 - No Active Host in the Data Center.
(Error code: 5009)

The failure in VDSM looks like this:
Thread-5769::ERROR::2011-09-20 17:42:39,399::dispatcher::103::Storage.Dispatcher.Protect::(run) {'status': {'message': "Meta Data parameter i
nvalid: ('Version or spm id invalid',)", 'code': 755}}
Thread-4307::ERROR::2011-09-20 17:42:41,967::sp::103::Storage.StatsThread::(run) Unexpected error
Traceback (most recent call last):
  File "/usr/share/vdsm/storage/sp.py", line 98, in run
    stats, code = self._statsfunc(self._domain)
  File "/usr/share/vdsm/storage/sp.py", line 1292, in _repostats
    stats['masterValidate'] = domain.validateMaster()
  File "/usr/share/vdsm/storage/sd.py", line 438, in validateMaster
    if not self.isMaster():
  File "/usr/share/vdsm/storage/sd.py", line 661, in isMaster
    return self.getMetaParam(DMDK_ROLE).capitalize() == MASTER_DOMAIN
  File "/usr/share/vdsm/storage/sd.py", line 621, in getMetaParam
    return self._metadata[key]
  File "/usr/share/vdsm/storage/persistentDict.py", line 63, in __getitem__
    return dec(self._dict[key])
  File "/usr/share/vdsm/storage/persistentDict.py", line 173, in __getitem__
    raise KeyError(key)
KeyError: 'ROLE'

Comment 2 Dan Kenigsberg 2011-10-03 16:36:03 UTC
since this is a second-order problem, I'm pushing this to upstream - unless this is shown to break a common use case.

Comment 3 Itamar Heim 2013-01-30 22:51:40 UTC
Closing old bugs. If this issue is still relevant/important in current version, please re-open the bug.

Note You need to log in before you can comment on or make changes to this bug.