Installation on a Singular Node

This section will layout the steps to installing GridDB. These instructions have been confirmed to work on CentOS version 6.7. First, download the GridDB RPM: here. Switch to the root user and install the RPM by using the “rpm” command:

$ su
# rpm -ivh griddb_nosql-X.X.X-linux.x86_64.rpm
Preparing...                ########################################### [100%]

------------------------------------------------------------
Information:
User gsadm and group gridstore have been registered.
GridDB uses new user and group.
------------------------------------------------------------

   1:griddb_nosql           ########################################### [100%]
   

Confirmation After Installation

After installing GridDB's node module, the user “gsadm” and the group “gridstore” are created. Use the user and group for running a node module and operational commands. And please note that a password for the new user gsadm is not automatically set upon creation, so please take the time to set one. If installation completed normally, the following directories and files are created as well as necessary modules and commands.

/var/lib/gridstore/        # GridDB home directory
   backup/               # Backup directory(unused)
   conf/                 # Directory storing definition files
         gs_cluster.json   # Cluster definition file
         gs_node.json      # Node definition file
         password          # User definition file
   data/                 # Directory storing database files
   log/                  # Directory storing event log files

We should also confirm that the following files and directories exist:

$ ls /var/lib/gridstore/*
/var/lib/gridstore/backup:

/var/lib/gridstore/conf:
gs_cluster.json  gs_node.json  password

/var/lib/gridstore/data:

/var/lib/gridstore/log:

Confirm the directory structure of the installed GridDB client libraries. If installation completed normally, the following files are created.

$ ls -l /usr/share/java/*gridstore*
lrwxrwxrwx 1 gsadm gridstore 46 Apr 11 20:43 /usr/share/java/gridstore-conf.jar -> /usr/griddb-X.X.X/bin/gridstore-conf-X.X.X.jar
lrwxrwxrwx 1 gsadm gridstore 41 Apr 11 20:43 /usr/share/java/gridstore.jar -> /usr/griddb-X.X.X/bin/gridstore-X.X.X.jar

If you start a GridDB node and then access and run the node from a client, the following files are created in the directories to store database files and event log files.

/var/lib/gridstore/        # GridDB home directory
   data/                 # Directory storing database files
         gs_log_n_m.log    # File recording transaction logs (n, m: positive number)
         gs_cp_n_p.dat     # Checkpoint file recording data regularly (n, p: positive number)

The event log file will be in the following location

/var/lib/gridstore/              # GridDB home directory
   log/                        # Directory storing event logs
         gridstore-%Y%m%d-n.log  # Event log file

Setting up an Administrator User

After all of this, you must create an administrator user to use GridDB. The administrator user information is stored in the User Definition file. The default file is as shown here: $GS_HOME/conf/password.

After installation a default user called “admin” will be created. The operating commands used to change the default users’ information are shown below.

CommandFunction
gs_adduserAdd an administrator user
gs_deluserDelete an administrator user
gs_passwdChange the password of an administrator user

It is recommended that you add a password to the user “admin” as one is not set upon creation.

$ gs_passwd admin
Password:(Input password)
Retype password:(Input password again)

If you’d like to add another user beyond the default “admin” user, it must start with “gs#”

$ gs_adduser gs#newuser
Password:(Input password)
Retype password:(Input password again)

Once the changes you wanted to make are done, you will need to restart the node for the changes to have effect.