tbarbugli / cassandra_snapshotter

A tool to backup cassandra nodes using snapshots and incremental backups on S3
Other
222 stars 122 forks source link

add support for cassandra 2.1 #23

Closed tbarbugli closed 8 years ago

tbarbugli commented 10 years ago

data directory structure changed

ivanyu commented 9 years ago

Hi! I really want Cassandra 2.1 support and going to implement it. Could you direct me where should I start?

tbarbugli commented 9 years ago

afaik the main changes are related to where snapshots are stored (different naming convention). so you probably only need to change the part where the upload manifest is created. https://github.com/tbarbugli/cassandra_snapshotter/blob/master/cassandra_snapshotter/agent.py#L138 is where the list of files to upload (based on data_dir and snapshot name) is created.

ivanyu commented 9 years ago

What should be the signs of failure with Cassandra 2.1? I'm asking because I've tried cassandra_snapshotter from PyPI and it's backuped and listed correctly (at first glance).

tbarbugli commented 9 years ago

well the absence of snapshot files on S3 for once

ivanyu commented 9 years ago

Well, it seems to fail when a table is specified, but works correctly with keyspaces. I believe it's due to table name postfix introduced in 2.1: glob.glob doesn't catch it.

I think I know how to fix it. Is there an accepted way to distinguish Cassandra versions in the agent?

tbarbugli commented 9 years ago

There is no cassandra version detected, I think the best would be to add a command line option to use cassandra 2.1 dir structure (unless you know a reliable to add version discovery). ᐧ

On Tue, Jun 16, 2015 at 10:31 PM, Ivan Yurchenko notifications@github.com wrote:

Well, it seems to fail when a table is specified, but works correctly with keyspaces. I believe it's due to table name postfix introduced in 2.1: glob.glob doesn't catch it.

I think I know how to fix it. Is there an accepted way to distinguish Cassandra versions in the agent?

— Reply to this email directly or view it on GitHub https://github.com/tbarbugli/cassandra_snapshotter/issues/23#issuecomment-112559966 .