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

Dont allow to backup without schema #3995

Closed
Michal-Leszczynski opened this issue Aug 22, 2024 · 0 comments · Fixed by #4008
Closed

Dont allow to backup without schema #3995

Michal-Leszczynski opened this issue Aug 22, 2024 · 0 comments · Fixed by #4008
Assignees
Milestone

Comments

@Michal-Leszczynski
Copy link
Collaborator

For Scylla versions >= 6.0/2024.2 SM backups and restores schema from the output of DESC SCHEMA WITH INTERNALS cql query. This means that schema can be backed up as CQL file only when SM has CQL credentials to the cluster. This results in backups of Scylla 6.0/2024.2 not containing the schema required for restore purposes - SM allows for such backups to proceed because:

  • in previous Scylla versions the CQL credentials weren't needed for the backup to finish
  • there is a workaround to restore schema manually (SM still backs up schema sstables and they can be uploaded to a single node cluster in order to run DESC SCHEMA WITH INTERNALS on it)

This is messy, so SM shouldn't allow for a backup not containing proper schema. It should require CQL creds for Scylla versions >= 6.0/2024.2 for running the backup (in case user would really like to run a backup without CQL creds, we could add a flag like --dont-backup-schema that allows to omit schema backup when deliberately set by the user).

#3831 could make things easier as it would allow for SM to obtain the output of DESC SCHEMA WITH INTERNALS without the need for CQL creds (when the maintenance socket is open).

cc: @karol-kokoszka @pdbossman

@Michal-Leszczynski Michal-Leszczynski self-assigned this Aug 22, 2024
@mykaul mykaul added the high label Aug 25, 2024
@Michal-Leszczynski Michal-Leszczynski added this to the 3.3.2 milestone Aug 26, 2024
Michal-Leszczynski added a commit that referenced this issue Aug 29, 2024
…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
Michal-Leszczynski added a commit that referenced this issue Aug 29, 2024
…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
Michal-Leszczynski added a commit that referenced this issue Sep 5, 2024
…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
karol-kokoszka pushed a commit that referenced this issue Sep 6, 2024
…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
karol-kokoszka pushed a commit that referenced this issue Sep 6, 2024
…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
@karol-kokoszka karol-kokoszka modified the milestones: 3.3.3, 3.3.2 Sep 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants