sstableupgrade

Upgrades the SSTables in the given table or snapshot to the current version of DataStax Enterprise while the DSE node is offline.

Restriction: Stop DataStax Enterprise before you run this command.

The default location of this SSTable tool depends on the type of installation:

  • Package installations: /usr/bin/

  • Tarball installations: <installation_location>/resources/cassandra/tools/bin

Synopsis

sstableupgrade
[--debug]
[-h | --help]
[[-k | --keep-source] | --keep-generation]
[-b | --backups]
[-o | --output-dir <output-dir>]
[--schema <schema-file> [--schema <schema-file2> ... ]]
[--sstable-files <sstable>]
[-t | --throughput <rate-limit>]
[--temp-storage <tmp-dir>]
<keyspace_name> <table_name>
[snapshot_name]

Definition

The short form and long form parameters are comma-separated.

Command arguments

--debug

Display stack traces.

-h, --help

Display the usage and listing of the commands.

-k, --keep-source

Do not delete the source SSTables. Do not use with the --keep-generation option.

-b, --backups

Rewrite incremental backups for the given table. May not be combined with the snapshot_name option.

--keep-generation

Keep the generated SSTables. Do not use with the --keep-source option.

-o, --output-dir

Rewritten files are placed in output-dir/keyspace-name/table-name-and-id.

--schema

Allows upgrading and downgrading SSTables using the schema of the table in a CQL file containing the DDL statements to re-create the schema. Must be a DDL file that allows the recreation of the table including dropped columns. Repeat the option to specify multiple DDL schema files.

Always use the schema.cql from a snapshot of the table so that the DDL has all of the information omitted by DESCRIBE TABLE, including dropped columns.

--sstable-files

Instead of processing all SSTables in the default data directories, process only the tables specified via this option. If a single SSTable file, only that SSTable is processed. If a directory is specified, all SSTables within that directory are processed. Snapshots and backups are not supported with this option.

-t, --throughput

Set to limit the maximum disk read rate in MB/s.

--temp-storage

When used with --schema, specifies location of temporary data. Directory and contents are deleted when the tool terminates. Directory must not be shared with other tools and must be empty. If not specified the default directory is /tmp.

keyspace_name

Keyspace name. Required.

table_name

Table name. Required.

snapshot_name

Snapshot name.

  • Rewrites only the specified snapshot.

  • Replaces files in the given snapshot and breaks any hard links to live SSTables.

  • Required when before attempting to restore a snapshot taken in a different DSE version than the one that is currently running.

Examples

Upgrade events table in the cycling keyspace

Restriction: Stop DataStax Enterprise before you run this command.

sstableupgrade cycling events
Found 0 sstables that need upgrading.

The SSTables are already on the current version, so the command returns immediately and no action is taken.

Was this helpful?

Give Feedback

How can we improve the documentation?

© 2024 DataStax | Privacy policy | Terms of use

Apache, Apache Cassandra, Cassandra, Apache Tomcat, Tomcat, Apache Lucene, Apache Solr, Apache Hadoop, Hadoop, Apache Pulsar, Pulsar, Apache Spark, Spark, Apache TinkerPop, TinkerPop, Apache Kafka and Kafka are either registered trademarks or trademarks of the Apache Software Foundation or its subsidiaries in Canada, the United States and/or other countries. Kubernetes is the registered trademark of the Linux Foundation.

General Inquiries: +1 (650) 389-6000, info@datastax.com