Git Product home page Git Product logo

cassandra-snapshot-tools's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

cassandra-snapshot-tools's Issues

SSL Support

It will be good to add SSL , keystore and truststore support for the sstableloader options. Or you can pick up from the Cassandra.yaml as well

getSnapshot fails to parse cassandra.yaml if indented with less than 3 spaces

We hit a confusing bug recently where getSnapshot was printing No data directories, or no cassandra.yaml file found on a new Cassandra installation, even though all our paths were the same as on prior working installations, and our cassandra.yaml looked the same. What had happened was that the YAML had been autoformatted, setting the indentation to our usual in-house value of 2 spaces. It turns out that the awk-based YAML quasi-parser in getSnapshot didn't correctly read the data directories line when it was only indented by two. 3 or 4 worked fine, 2 or 1 didn't. I'd try to offer a fix but don't have enough awk skills to feel safe modifying this.

Failing snippet of cassandra.yaml:

data_file_directories:
  - /var/lib/cassandra/data
$ ./getSnapshot -k the_keyspace -s the_snapshot
No data directories, or no cassandra.yaml file found

Working snippet of cassandra.yaml:

data_file_directories:
    - /var/lib/cassandra/data
$ ./getSnapshot -k the_keyspace -s the_snapshot
Using provided snapshot name the_snapshot
...

Tar command is incorrect on getSnapshot

I believe there is a slight error on the tar command:

tar --directory "$DUMPDIR" \
            -zcvf $FILENAME \
                  $KEYSPACE \
                  $SCHEMA \
                  $KEYSPFILE \
                  $SNAPSFILE \
                  $HOSTSFILE \
                  $DATESFILE >/dev/null 2>&1

$KEYSPACE should not be there, I think.

Error finding required executables: cqlsh

When I run the script Im seeing the following error. I have placed the script in /Users/ksachdeva/dse/bin directory. Any idea ?

Kunals-Mac:bin ksachdeva$ ./getSnapshot -k admin -s admin.backup -y ../resources/cassandra/conf/cassandra.yaml
Error finding required executables: cqlsh

Diagram

May be a simple diagram will make it easy to understand as how it works.

Support SimpleStrategy replica placement

Currently the NetworkTopologyStrategy and its options are assumed (because that's what we currently use) - need to support (and test for) SimpleStrategy as well.

typo in get snapshot

diff getSnapshot.orig getSnapshot
169c169
< for directory in ${data_file_directories_[@]}; do

        for directory in ${data_file_directories[@]}; do

ie. seems to be a trailing underscore. Works for me with it removed.

Snapshot info tool to view snapshot details

Need a simple way to view details about a snapshot file. For example, it would be nice to be able to view the datacenter/replication factor configuration in a given snapshot.

GetSnapshot doesn't handle multiple data directories

On a node where more than one data_file_directory is defined in cassandra.yaml, the getSnapshot script searches for the appropriate keyspace in all data_file_directory entries, but uses only the first directory containing the keyspace and snapshot. This will likely not include all of the necessary SSTables required to successfully restore the keyspace.

Need to implement a loop that searches in all data file directories for the keyspace and snapshot, and includes them in the snapshot dump.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.