Encrypting existing Search indexes

Encrypting DSE Search indexes turns on encryption only for new files. Additional steps are required to encrypt existing data. When you encrypt existing DSE Search indexes, a node restart is required.

There are several ways to encrypt existing DSE Search indexes. Choose the method that is appropriate for your environment.

Prerequisites

When using TDE on a secure local file system, encryption keys are stored remotely with KMIP encryption or locally with on-server encryption.

Procedure

Encryption is enabled per core.

  1. To enable encryption for an existing core, edit the solrconfig.xml file to change the class for directoryFactory to solr.EncryptedFSDirectoryFactory:

    <directoryFactory name="DirectoryFactory" class="solr.EncryptedFSDirectoryFactory"/>
  2. Upload the changed solrconfig.xml file.

    For example, you can use dsetool to upload the changed resource file:

    dsetool reload_core <keyspace_name>.<table_name>
  3. Restart the DataStax Enterprise node.

    Enabling encryption does not require a node restart. However, the directoryFactory changes require a node restart.

    Encryption is on only for new files. Additional steps are required to encrypt existing data.

  4. To encrypt existing files, use one of these methods:

    Reload while the node is running

    This is a slow but immediate option. It reindexes while the node is running.

    dsetool reload_core <keyspace_name>.<table_name> deleteAll=true reindex=true
    Rebuild from a remote node

    Offline index encryption is fastest. However, the local node must be offline, and you must have access to a remote node that is running and has the index configuration available.

    The encryption configuration is read from the remote node; the user that runs the command must have read and write permissions to the directory that contains the index files.

    For options, see the dsetool upgrade_index_files reference.

    1. Enable encryption for all nodes that have a search index.

    2. Run the dsetool upgrade_index_files command:

      dsetool upgrade_index_files <keyspace_name>.<table_name> -h <IP_address> [<options>]
    Eventual reindexing

    This option requires the least effort but it is indeterminate.

    If you take no action, the index will eventually be encrypted during compaction or merging of indexes. When this happens depends on new write activity. Because new files are encrypted, your files will eventually be encrypted.

  5. To verify which files are encrypted, use this command to list all DSE Search index files for the specified search core on the local node:

    dsetool list_index_files <keyspace_name>.<table_name> [--index <directory>]

    where --index <directory> specifies the data directory that contains the search index files. When not specified, the default directory is inferred from the search core name.

  6. After you verify which files are encrypted, you can encrypt existing files using a different option.

Next steps

To disable encryption, disable encryption for the backing CQL table. No node restart is required.

Was this helpful?

Give Feedback

How can we improve the documentation?

© Copyright IBM Corporation 2026 | Privacy policy | Terms of use Manage Privacy Choices

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: Contact IBM