Database Reference
In-Depth Information
Here parameters passed with the
nodetool refresh
command are the key-
space followed by the table name. This refreshes the data, which can be verified by
running the
select
command.
Using clearsnapshot
Taking snapshots periodically for backup purposes consumes a lot of space on disk;
hence, it also requires that you clear obsolete ones from time to time. We can clear the
snapshot directory periodically by using
nodetool clearsnapshot
command as
follows:
vivek@vivek-Vostro-3560:~$ $CASSANDRA_HOME/bin/nodetool
-h localhost -p 7199 clearsnapshot
The preceding command will clear snapshot directories from all keyspaces. We can
also clear snapshot directories for one or more keyspaces like this:
/home/vivek/software/local-cluster/node1/bin/nodetool -h
localhost -p 7199 clearsnapshot twitter anotherkeyspace
Here,
twitter
and
anotherkeyspace
are selected keyspaces to clear snap-
shot directories.
In this section, we saw how we can use various utilities to perform database backup
and restoration processes. Next we will discuss various monitoring tools.
Cassandra Monitoring Tools
System monitoring is a process of analyzing and gathering the state of the system. Al-
though Cassandra is distributed and fault-tolerant, it also depends on how it is used to
build the application. A few key issues which must be taken care periodically are
•
Performance
•
Data access
•
Monitoring node's state