1

My current cassandra cluster setup has 3 nodes of version 1.2.x. I want to upgrade it to latest version currently available as 4.x with more number of nodes Currently vnodes is not configured in existing setup How can i do so?

Can I simply take snapshot from existing cluster and move to new cluster ?

Erick Ramirez
  • 13,964
  • 1
  • 18
  • 23
Zen
  • 31
  • 3

2 Answers2

1

This is a non-trivial upgrade - and would have to bounce through 2.0,2.1,2.2, 3.11, 4 with running ssupgradetables at each step. (I'm not 100% sure you can skip some of the 2 releases or not.)

If you can handle the downtime - I would recommend exporting the data from the 1.2 (with a tool like DS Bulk) and then importing into a fresh 4.x cluster set up. It will be significantly less pain / operational overhead than the upgrade process.

The option of running sstableloader on a snapshot gets tricky because 4.x has no knowledge of the sstableformat from 1.2, the snapshot sstables would need to go through a few upgrades to get to a format that 4.x can understand.

Please note - if your application is using thrift with the C* 1.2, then you will not be able to upgrade to 4, since the protocol is removed, the latest version of 3.11 (3.11.15 at the time of writing) is as far as you can upgrade to.

Andrew
  • 26,629
  • 5
  • 63
  • 86
0

The sstable format for Cassandra 1.2 (-ic-) is too old for the latest versions of Cassandra.

The earliest SSTable format that C* 4.0 and C* 4.1 can read is -ma- (introduced in C* 3.0.0):

        public static final String current_version = "nb";
        public static final String earliest_supported_version = "ma";

The newest version that supports the -ic- SSTable format is C* 2.0 so multiple interim upgrades are required.

The recommended upgrade path from C* 1.2 to 4.x is:

Note that the CQL native binary protocol changed dramatically in the major versions:

  • C* 1.2 - based on native protocol v1
  • C* 2.0 - protocol v2
  • C* 2.1 - protocol v3
  • C* 2.2 - protocol v4
  • C* 4.0 - protocol v5

Depending on your application, (1) it will be necessary to also perform interim upgrades of the Cassandra driver and (2) will require a refactor of your application.

For example, pre-2.1.1 versions of the Cassandra Java driver are only compatible with native protocol v1 and v2. Pre-3.x versions of the Java driver are only compatible with binary protocols v1 to v3.

For details, see Native protocol compatibility in Java driver v3.11 and Java driver v4. Cheers!

Erick Ramirez
  • 13,964
  • 1
  • 18
  • 23