Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CA-400106: disable leaf coalesce with VDI snapshot secondary #711

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

MarkSymsCtx
Copy link
Contributor

When the secondary/mirror option is provided to the vdi_snasphot operation we do not want any leaf coalesce garbage collection taking place. Unfortunately xapi will delete the snapshot once it's finished copying the new parent to the destination SR in SXM and whilst the mirroring operation is still live. This will kick the GC process and if the GC gets to the point of performing the leaf coalesce before the migrate completes will result in a failure of the mirror operation. So block the leaf-coalesce operation in this case. The block will be removed if another snapshot were to be taken but in the case of SXM the next expected operation is a vdi_delete of the leaf which will clear the entire chain.

When the secondary/mirror option is provided to the vdi_snasphot
operation we do not want any leaf coalesce garbage collection taking
place. Unfortunately xapi will delete the snapshot once it's finished
copying the new parent to the destination SR in SXM and whilst the
mirroring operation is still live. This will kick the GC process and
if the GC gets to the point of performing the leaf coalesce before the
migrate completes will result in a failure of the mirror operation. So
block the leaf-coalesce operation in this case. The block will be
removed if another snapshot were to be taken but in the case of SXM
the next expected operation is a vdi_delete of the leaf which will
clear the entire chain.

Signed-off-by: Mark Syms <[email protected]>
@@ -707,7 +707,7 @@ def reset_leaf(self, sr_uuid, vdi_uuid):
vhdutil.killData(self.path)

def _do_snapshot(self, sr_uuid, vdi_uuid, snap_type,
secondary=None, cbtlog=None):
_=False, secondary=None, cbtlog=None):
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This just makes the method signature match the method it is overriding.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants