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

Merged
merged 1 commit into from
Oct 9, 2024

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 <mark.syms@cloud.com>
@@ -16,6 +16,7 @@
# VDI: Base class for virtual disk instances
#

import cleanup
Copy link
Contributor

Choose a reason for hiding this comment

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

Rather than importing cleanup, maybe at some point the constants you need from cleanup could be moved into their own file.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes probably

@MarkSymsCtx MarkSymsCtx merged commit bc27747 into xapi-project:master Oct 9, 2024
2 checks passed
@MarkSymsCtx MarkSymsCtx deleted the CA-400106 branch October 9, 2024 10:30
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.

4 participants