Scylla Documentation Logo Documentation
  • Server
    • Scylla Open Source
    • Scylla Enterprise
    • Scylla Alternator
  • Cloud
    • Scylla Cloud
    • Scylla Cloud Docs
  • Tools
    • Scylla Manager
    • Scylla Monitoring Stack
    • Scylla Operator
  • Drivers
    • CQL Drivers
    • DynamoDB Drivers
Download
Menu

Caution

You're viewing documentation for a previous version of Scylla Manager. Switch to the latest stable version.

Scylla Manager Restore Extract schema from system_schema keyspace

Extract schema from system_schema keyspaceΒΆ

Prerequisites

  1. You have the snapshot tag.

  2. The snapshot contains system_schema keyspace.

Procedure

  1. List files of snapshot we want to restore (replace <node_id> with ID of one of the nodes in the cluster.

    sctool backup files --cluster my-cluster -T sm_20200513104924UTC -K system_schema --with-version | grep "<node_id>" > backup_files.out
    
  2. Create a directory, and recreate table directories in it.

    mkdir scylla
    cd scylla
    cat ../backup_files.out | awk '{print $2}' | sort | uniq | xargs mkdir -p
    
  3. Download the SSTables to the created directories

    cat ../backup_files.out | xargs -n2 aws s3 cp
    cd ..
    
  4. Start the Scylla container with mounted data volume. Make sure to use the same Scylla version used to create the backup.

    docker run --name scylla -p 9042:9042 -v `pwd`/scylla:/var/lib/scylla/data --memory 1G --rm -d scylladb/scylla:4.3.0
    
  5. Extract schema:

    cqlsh 127.0.0.1 -e "DESCRIBE SCHEMA"  > db_schema.cql
    
PREVIOUS
Extract schema from metadata
NEXT
Repair
  • 2.3
    • 2.6
    • 2.5
    • 2.4
    • 2.3
    • 2.2
  • Install Scylla Manager
  • Install Scylla Manager Agent
  • Add a Cluster
  • Backup
    • Setup AWS S3
    • Setup S3 compatible storage
    • Setup Google Cloud Storage
    • Examples
  • Restore
    • Extract schema from metadata
    • Extract schema from system_schema keyspace
  • Repair
    • Repair faster
    • Repair slower
    • Examples
  • Health Check
  • CLI sctool
    • Global flags and variables
    • Cluster
    • Backup
    • Repair
    • Status
    • Suspend & Resume
    • Task
    • Version
  • Configuration Files
    • Scylla Manager Config
    • Scylla Manager Agent Config
  • Scylla Monitoring
  • Troubleshooting
  • Older Versions
  • Slack
  • Create an issue
  • Edit this page
Logo
Docs Contact Us About Us
Mail List Icon Slack Icon
© 2022, ScyllaDB. All rights reserved.
Last updated on 04 May 2022.
Powered by Sphinx 4.3.2 & ScyllaDB Theme 1.2.1