For local debugging of the service, I needed to install Apache Cassandra on Windows 10. Only DataStax had a normal installer, but they stopped supporting it.
In this article I will describe how to install Apache Cassandra on Windows as a service.
Cassandra requires Java 8 - JavaSE or OpenJDK. On newer versions of Java, Cassandra does not start.
After trying several OpenJDK distributions, I chose Amazon Corretto - Cassandra started and worked on it. Other distributions may cause problems.
You can download Amazon Corretto here
When installing, make sure that the "Setup Enviroment" component is enabled. Otherwise, you will have to manually set the environment variable 'JAVA_HOME'.
prunsrv.exe
Unpack the archive with Cassandra in the folder where it will be installed.
From the commons-daemon
archive, copy the prunsrv.exe
file of the desired architecture to the __cassandra\bin\daemon
. If the daemon
folder does not exist, then it must be created.
__cassandra\bin
.\cassandra.ps1 -install
After that, Cassandra will be installed as a service that can be managed through the service management console.
cqlsh
requires Python 2.7 installed.
In many cases, you need to set the CASSANDRA_HOME
environment CASSANDRA_HOME
, pointing to the bin
folder of Cassandra.