Start the Administration CLI

Before running the Admin CLI and continuing further, you must have already completed all of the configuration steps described in Configuring your data store installation.

The runadmin utility provides the Admin command line interface (CLI). You can use the runadmin utility for a number of purposes. In this section, you use it to administer the Storage Nodes in your data store. First, you supply the details of the Storage Node and registry port that runadmin can use to connect to the data store.

If this is the first Storage Node you are connecting to that data store using the CLI, the Storage Node is designated as the one on which the master copy of the administration database resides.

Note:

You cannot change whatever Storage Node you use to initially configure the data store, such as node01 in this example. Carefully plan the Storage Node to which runadmin first connects.

In the example below, you use $KVHOST to represent the network name of the Storage Node to which runadmin connects, and you use 5000 as the registry port.

One of the most important aspects of this Storage Node is that it must run the Storage Node Agent (SNA). All Storage Nodes should have an SNA running on them at this point. If any do not, complete the instructions in Installing Oracle NoSQL Database before proceeding further.

To start runadmin to use the Admin command line interface (CLI) for administration purposes, use these commands:

ssh node01
> java -Xmx64m -Xms64m \
-jar $KVHOME/lib/kvstore.jar runadmin \ 
-host $KVHOST -port 5000 \
-security $KVROOT/security/client.security

With this runadmin example, you specify a single host and port (-host node01 -port 5000), permitting one Storage Node host to run an Admin process. The Admin process lets you run Admin CLI commands. If you want more than one Storage Node to support CLI commands, use the runadmin utility –helper-hosts flag and list two or more Storage Nodes and ports, rather than –host <name> –port <value>. For example, the next command starts an Admin process on three different Storage Nodes, which can then service CLI commands (<host2>, <host3>, and <host4>):

ssh node01
> java -Xmx64m -Xms64m \
-jar $KVHOME/lib/kvstore.jar runadmin \ 
-helper-hosts <host2>:5000, <host3>:5000, <host4>:5000 \
-security $KVROOT/security/client.security

Note:

You need to complete the steps in Create users and configure security with remote access, to use therunadmin command to access the Admin node running on a Storage Node from any another Storage node.

After starting the Admin CLI, you can invoke the help command to describe all of the CLI commands.

You can collect the configuration steps that this section describes into a file, and then pass the script to the CLI utility using the -scriptoption. See Create a script to configure the data store for more information.