To uninstall the Rhino SLEE:
-
If a Cassandra database has been used for a Rhino persisting resource such as the key/value store or session ownership store, or the pool clustering mode was being used, remove the keyspaces that these resources were using (see below).
-
Remove the database that the Rhino SLEE was using (see below).
-
Delete the directory into which the Rhino SLEE was installed.
The Rhino SLEE keeps all of its files in the same directory and does not store data elsewhere on the system except for the state kept in the PostgreSQL database.
Removing Cassandra database keyspaces
To remove the Cassandra database keyspaces that Rhino uses for its persisting resources:
-
Export the persisting resource data definitions from Rhino as a zip file as described in exporting persisting resource data definitions. This must be done while at least one Rhino SLEE node is still operational.
-
This zip file contains the CQL statements that create the keyspaces and tables that the persisting resources need. These statements can be used as a basis for determining which keyspaces to drop, and can be converted to the necessary DROP KEYSPACE statements using a single command-line operation such as this:
$ unzip -p exported-data-definitions.zip | \ grep "CREATE KEYSPACE" | \ sed -e "s/CREATE/DROP/g" -e "s/IF NOT/IF/g" -e "s/ WITH.*/;/g" > drop_keyspaces.cql $ cat drop_keyspaces.cql DROP KEYSPACE IF EXISTS rhino_pool_maintenance; DROP KEYSPACE IF EXISTS rhino_kv_default; DROP KEYSPACE IF EXISTS rhino_session_ownership_default;
These statements can be piped directly into cqlsh
to remove the keyspaces and tables:
$ cat drop_keyspaces.cql | cqlsh
While obtaining the data definition export requires an operational Rhino SLEE node, it’s best to wait until the Rhino SLEE cluster has been completely shut down before effecting the removal of any keyspaces. |
Removing PostgreSQL database
To remove the database, run psql -d
The name of the database is stored in the file node-NNN/config/config_variables
as the setting for MANAGEMENT_DATABASE_NAME
.
Do the following, substituting MANAGEMENT_DATABASE_NAME
for the value from config_variables
:
$ psql -d template1 Welcome to psql 8.0.7, the PostgreSQL interactive terminal. Type: \copyright for distribution terms \h for help with SQL commands \? for help with psql commands \g or terminate with semicolon to execute query \q to quit template1=# drop database MANAGEMENT_DATABASE_NAME; DROP DATABASE template1=#