Bringing together the Apache Cassandra experts from the community and DataStax.

Want to learn? Have a question? Want to share your expertise? You are in the right place!

Not sure where to begin? Getting Started

 

question

michael.guissine_30999 avatar image
michael.guissine_30999 asked ·

Does OpsCenter support restoring data to a different table than the source table?

Hi,

Is it possible to restore a table (cf) to a new table in existing cluster using OpsCenter, for example I'd like to restore keyspace1.table1 to keyspace1.table1_20190101. Essentially I'd like to create a copy of existing table using Backup service.


The use case for me is to be able to periodically test backups integrity without the need to provision a new DSE cluster.


Thanks!

opscenterbackuprestore
10 |1000 characters needed characters left characters exceeded

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

1 Answer

Erick Ramirez avatar image
Erick Ramirez answered ·

@michael.guissine_30999 You won't be able to do it via OpsCenter. You will have to do it manually by copying the contents of the relevant snapshot directory to the directory of the new table and running nodetool refresh. See Restoring from a snapshot for details. Cheers!

3 comments Share
10 |1000 characters needed characters left characters exceeded

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Thanks @Erick Ramirez, this is easy when restoring from local but quite challenging if you need to restore from centralized backups because one needs to crawl through backup metadata to find which sstables to restore so would be nice if OpsCenter can help.

0 Likes 0 · ·

@michael.guissine_30999 If you mean S3 for centralised backups, will knowing the directory structure help you? It looks like this:

  bucket_name/
    snapshots/
      id_of_node/
        sstables/
        backup_id-date_of_backup/
          backup.json
          keyspace/schema.json
0 Likes 0 · ·

Within each node's subdirectory is a list of backups. If you are able to locate the date you wish to restore, you can workout from the backup.json file the list of SSTables which belong to that backup.

It isn't ideal but I hope it helps. Cheers!

0 Likes 0 · ·