Install cassandra | Debian 12 (bookworm)
Cassandra Database
Install | Debian (12) Bookworm
- Official site
- ssh and update linux system
install java 11 (openjdk11)
- list java
- install example temurin
install cassandra
Bash
echo "deb [signed-by=/etc/apt/keyrings/apache-cassandra.asc] https://debian.cassandra.apache.org 41x main" | sudo tee -a /etc/apt/sources.list.d/cassandra.sources.list
- crush default java path with new java installed from sdk
configure cassandra
- tweak heap size here
- just fling everything in the terminal
Bash
sudo systemctl stop cassandra
sudo rm -rf /var/lib/cassandra/data
sudo install -g cassandra -o cassandra -d /var/lib/cassandra/data
sudo sed -i [email protected]@$(ip route get 8.8.8.8 | sed -n '/src/{s/.*src *\([^ ]*\).*/\1/p;q}')@g /etc/cassandra/cassandra.yaml
sudo sed -i s@localhost@$(ip route get 8.8.8.8 | sed -n '/src/{s/.*src *\([^ ]*\).*/\1/p;q}')@g /etc/cassandra/cassandra.yaml
# - suggested setup for big cassandra db
sudo sed -i s@"read_request_timeout: 5000ms"@"read_request_timeout: 15000ms"@g /etc/cassandra/cassandra.yaml
sudo sed -i s@"range_request_timeout: 10000ms"@"range_request_timeout: 200000ms"@g /etc/cassandra/cassandra.yaml
sudo sed -i s@"write_request_timeout: 2000ms"@"write_request_timeout: 20000ms"@g /etc/cassandra/cassandra.yaml
sudo systemctl start cassandra