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

[Disk Manager] Create snapshot migration task to another database #2820

Open
wants to merge 11 commits into
base: main
Choose a base branch
from

Conversation

jkuradobery
Copy link
Collaborator

@jkuradobery jkuradobery commented Jan 9, 2025

YDB storage does not support backing up tables with external blobs support. So, the process of switching between databases (e.g. cluster migration) can't be performed right now. To avoid this issue, and provide seamless migration we've chosen semi-manual solution:

  • migrate snapshots data manually one by one
  • Shut down controlplane for a short period of time for all the pending tasks to finish.
  • Migrate remaining snapshots
  • Clean up not required snapshots.
  • backup & restore all the tables which do not contain external blobs except chunk map
    Here is implementation of a task which migrates a single snapshot's data to the database.

storageSize := dataChunkCount * chunkSize

t.state.SnapshotSize = size
t.state.SnapshotStorageSize = storageSize
Copy link
Collaborator

Choose a reason for hiding this comment

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

может проверить что storageSize совпадают в src и dst?

cloud/disk_manager/pkg/admin/snapshots.go Show resolved Hide resolved
cloud/disk_manager/pkg/app/dataplane.go Outdated Show resolved Hide resolved
Copy link
Collaborator

@BarkovBG BarkovBG left a comment

Choose a reason for hiding this comment

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

а тесты будут?)

@SvartMetal SvartMetal changed the title [Disk Manager]: Create snapshot migration task to another database [Disk Manager] Create snapshot migration task to another database Jan 20, 2025
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