Eduardo has posted comments on this change.
Change subject: Fix block volume atomicity creation issue.
......................................................................
Patch Set 2: (2 inline comments)
....................................................
File vdsm/storage/blockVolume.py
Line 547: return self.metaoff
Line 548: try:
Line 549: md = _getVolumeTag(self.sdUUID, self.volUUID,
TAG_PREFIX_MD)
Line 550: except se.MissingTagOnLogicalVolume:
Line 551: self.log.error("missing offset tag on volume %s/%s",
More clear since we have no need to deduce which tag is absent and which is the
operation that failed. The stack trace will be more complete here and you
requested the lower log.
Since it is actually a low possibility race (negative flow) should be rare and
not clutter the log. If not we should fix the race and not remove logs.
Line 552: self.sdUUID, self.volUUID, exc_info=True)
Line 553: raise se.VolumeMetadataReadError("missing offset tag on
volume"
Line 554: "%s/%s" % (self.sdUUID,
self.volUUID))
Line 555: else:
Line 640:
Line 641: def _getVolumeTag(sdUUID, volUUID, tagPrefix):
Line 642: tags = lvm.getLV(sdUUID, volUUID).tags
Line 643: if TAG_VOL_UNINIT in tags:
Line 644: log.warning("Reloading uninitialized volume %s/%s", sdUUID,
volUUID)
This race is new and is a challenge for some design assumptions of the whole
system.
It is assumed that the storage ovirt data (MD, pool Md, volume layout, etc) is
stable when the HSM is using it and if it is changed, the SPM or the engine
should request a refresh of the HSM view of the storage.
Then this race should be extraordinary (like today) but in any case is not the
only possible one. Then a log warning would alert us that we are changing the
usage pattern of the system.
Other races should be checked too and avoided.
This is not a "normal" situation and this type of behaviour should be avoided.
The complete solution is looking in the HSM for "volumes only", only when they
are needed, and only at the start of the requested API operation.
Line 645: lvm.invalidateVG(sdUUID)
Line 646: tags = lvm.getLV(sdUUID, volUUID).tags
Line 647: if TAG_VOL_UNINIT in tags:
Line 648: log.error("Found uninitialized volume: %s/%s", sdUUID,
volUUID)
--
To view, visit http://gerrit.ovirt.org/9358
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I40cd67e563935de663d938cbc1bc9cf152802448
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Eduardo <[email protected]>
Gerrit-Reviewer: Ayal Baron <[email protected]>
Gerrit-Reviewer: Eduardo <[email protected]>
Gerrit-Reviewer: Haim Ateya <[email protected]>
Gerrit-Reviewer: oVirt Jenkins CI Server
_______________________________________________
vdsm-patches mailing list
[email protected]
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches