Site icon Database Tutorials

INSTALLATION OF CASSANDRA

 

Pre-Installation Setup

Before installing Cassandra in Linux environment, we require to set up Linux using ssh (Secure Shell). Follow the steps given below for setting up Linux environment.

 

Setting the Path

Set the path of Cassandra path in “/.bashrc” as shown below.

 

Download Cassandra

 

Unzip Cassandra using the command zxvf as shown below.

 

Create a new directory named cassandra and move the contents of the downloaded file to it as shown below.

 

 

Configure Cassandra

Open the cassandra.yaml: file, which will be available in the bin directory of Cassandra.

 

Note: If you have installed Cassandra from a deb or rpm package, the configuration files will be located in /etc/cassandra directory of Cassandra.

The above command opens the cassandra.yaml file. Verify the following configurations. By default, these values will be set to the specified directories.

Make sure these directories exist and can be written to, as shown below.

 

Create Directories

As super-user, create the two directories /var/lib/cassandra and /var./log/cassandra into which Cassandra writes its data.

 

Give Permissions to Folders

Give read-write permissions to the newly created folders as shown below.

 

Start Cassandra

To start Cassandra, open the terminal window, navigate to Cassandra home directory/home, where you unpacked Cassandra, and run the following command to start your Cassandra server.

 

Using the –f option tells Cassandra to stay in the foreground instead of running as a background process. If everything goes fine, you can see the Cassandra server starting.

Exit mobile version