Connect to Hyper-Converged Database (HCD) with CQL shell (cqlsh)

You can use the CQL shell (cqlsh) to connect to Hyper-Converged Database (HCD) and test any feature such as vector search. Make sure your cqlsh version supports HCD.

Install Python

CQL shell requires Python.

HCD 1.1 supports Python 3.8 to 3.13. HCD 1.1.5 or later is required for Python 3.12 or 3.13.

If you have multiple Python versions installed, run cqlsh in a virtual environment that uses a supported Python version.

Use the embedded cqlsh in Mission Control

Mission Control provides a web-based interface for managing your HCD clusters. DataStax recommends using Mission Control to manage your clusters and perform cluster operations. For more information, see Use the CQL console to interact with the databases in your datacenter.

Use a standalone cqlsh installation

Depending on your HCD installation type, there are several ways to use a standalone cqlsh installation:

  • Use the version bundled with the tarball. If you have installed HCD from the tarball, you can find cqlsh in the bin directory of the HCD installation directory.

  • Use the version bundled with the HCD Docker container. If you are using the HCD Docker container, you can run cqlsh inside the container from the bin directory of the HCD installation directory.

Connect locally

To connect to the local node, start cqlsh in the terminal:

bin/cqlsh

If cqlsh starts properly, it prints connection details and version numbers. You can pass CQL and cqlsh commands at the cqlsh prompt.

If cqlsh fails to connect and shows a port other than 9042, check your ~/.cassandra/cqlshrc file. This file can alter the default settings for your cqlsh connection.

Connect remotely

To connect to a remote HCD cluster, specify the IP address of a node in the cluster:

bin/cqlsh 10.0.0.1

Connect with authentication

If you use security features, provide the username and password to authenticate with the database:

bin/cqlsh -u jane -p ScoobiePeanut&!

Use a cqlshrc file

bin/cqlsh CQLSHRC="~/<directory_name>"

You can use several options with cqlsh. For a complete list of options, see the cqlsh reference page in the CQL documentation.

Help and options for cqlsh

Use --help to get help information for cqlsh:

bin/cqlsh --help

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