Installing Apache Cassandra on Windows
Category : Cassandra
| Sub Category : Cassandra | By Prasad Bonam Last updated: 2023-08-19 19:01:17
Viewed : 47
Installing Apache Cassandra on Windows:
Installing Apache Cassandra on Windows involves several steps. Here is a basic guide to help you get started:
- Java: Cassandra requires Java to run. Make sure you have Java Development Kit (JDK) installed. You can download it from the Oracle website or use OpenJDK.
- Go to the official Apache Cassandra download page: https://cassandra.apache.org/download/
- Choose the desired version. It is recommended to use the latest stable version.
- Download the binary distribution for Windows (ZIP archive).
Extract the Archive:
- Extract the downloaded ZIP archive to a directory of your choice. This will be your Cassandra installation directory.
- Navigate to the "conf" directory within the extracted Cassandra folder.
- Locate the "cassandra.yaml" file and open it in a text editor.
- Update the "data_file_directories" and "commitlog_directory" paths to appropriate directories on your system.
- You can also adjust other configuration options as needed, such as listen address, seed nodes, etc.
- Save the changes.
Set Environment Variables:
- Add the path to the "bin" directory within the Cassandra installation to your systems PATH environment variable.
- This will allow you to run Cassandra commands from any command prompt.
- Open a command prompt and navigate to the Cassandra installation directory.
- Run the following command to start Cassandra:
- Cassandra will start, and you will see log messages indicating its progress.
Verify Cassandra is Running:
- Open another command prompt.
- Navigate to the Cassandra installation directory.
- Run the following command to start the Cassandra command-line interface (CQLSH):
- If you see the CQLSH prompt (
cqlsh>), it means Cassandra is running and you can interact with it using CQL commands.
- To stop Cassandra, go to the command prompt where Cassandra was started and press
Ctrl + C.
These are the basic steps to install Apache Cassandra on a Windows system. Keep in mind that this is a simplified guide, and you might need to adjust certain steps based on your specific environment and requirements. For production environments, you should refer to the official documentation and consider additional configurations and optimizations.
cqlsh> describe keyspaces;
select * from roles;