Skip to Main Content
Apache Cassandra Essentials
book

Apache Cassandra Essentials

by Nitin Padalia
November 2015
Beginner to intermediate content levelBeginner to intermediate
172 pages
3h 47m
English
Packt Publishing
Content preview from Apache Cassandra Essentials

Restoring data to Cassandra

In order to restore data from a snapshot onto a node, follow these steps:

  1. Shut down the node.
  2. Delete the old commitlog files:
    // package based installation
    $ rm /var/lib/cassandra/commitlog/*
    // Tar based installation
    $ rm <install-directory/data/commitlog/*
    
  3. Delete the old SSTable files from <data-dir>/<keyspace-name>/<column-family-name>/:
    // package based installation
    $ rm /var/lib/Cassandra/data/apache_cassandra_demo_db/user_table-f99a8ec0110611e5833fa9b7a6da1962/*.db
    // Tar based installation, considering tar is unpacked at /opt/cassandra location
    $ rm /opt/cassandra/data/data/apache_cassandra_demo_db/user_table-f99a8ec0110611e5833fa9b7a6da1962/*.db
    
  4. Copy the latest snapshots from the snapshot location to the data ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Mastering Apache Cassandra - Second Edition

Mastering Apache Cassandra - Second Edition

Nishant Neeraj
Learning Apache Cassandra - Second Edition

Learning Apache Cassandra - Second Edition

Sandeep Yarabarla, Graham Doman

Publisher Resources

ISBN: 9781783989102