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

Improve schema backup #4008

Merged
merged 8 commits into from
Sep 6, 2024
Merged

Improve schema backup #4008

merged 8 commits into from
Sep 6, 2024

Conversation

Michal-Leszczynski
Copy link
Collaborator

@Michal-Leszczynski Michal-Leszczynski commented Aug 29, 2024

This PR makes a several changes regarding schema backup.
They aim to increase schema backup safety by making it impossible to skip schema backup by simply not providing CQL creds (which was possible for Scylla version >= 6.0). Skipping schema backup is still possible (some users might not want to provide the CQL creds), but requires user to deliberately add the new --skip-schema flag.
They also make the schema backup more robust for multi Scylla version cluster, or a cluster where SM does not have CQL access to all of the nodes.

Fixes #4007
Fixes #3995

@Michal-Leszczynski
Copy link
Collaborator Author

@karol-kokoszka This PR is ready for review!

@Michal-Leszczynski
Copy link
Collaborator Author

@karol-kokoszka I believe that this should also be included in 3.3.2 for safety reasons.

In case of a cluster with only some nodes supporting desc schema backup/restore,
SM should assume that the schema will be restored to a cluster with desc schema restore support.
This means that SM should back up desc schema with internals output from a node which supports it.
It is possible that even though SM has CQL credentials,
it can directly connect to only some of the nodes via CQL.

Fixes #4007
…chema

Backups of clusters that restore from desc schema shouldn't be allowed
when the CQL creds are not set. This might break some backup tasks, but
it is better than silently skipping this step and founding out about it
during restore.

Fixes #3995
Previous commit made it impossible to perform backup of cluster that
restores schema from desc schema without CQL creds.
In order to make up for that, backup properties are extended with
DontBackupSchema which can be deliberately set in order to skip
schema backup and allow to back up user data when no CQL creds were set.
@karol-kokoszka karol-kokoszka merged commit e8d64bc into master Sep 6, 2024
44 of 51 checks passed
@karol-kokoszka karol-kokoszka deleted the ml/improve-schema-backup branch September 6, 2024 10:24
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.

Don't assume that SM can connect to all hosts via CQL Dont allow to backup without schema
2 participants