Configuring the Environment Variable

The following environment variables need to be set in order to use the CUBRID. The necessary environment variables are automatically set when the CUBRID system is installed or can be changed, as needed, by the user.

CUBRID Environment Variables

The above mentioned environment variables are set when the CUBRID is installed. However, the following commands can be used to verify the setting.

For Linux :

% printenv CUBRID

% printenv CUBRID_DATABASES

% printenv CUBRID_LANG

In Windows :

C:\> set CUBRID

OS Environment and Java Environment Variables
Configuring the Environment Variable

For Windows

If the CUBRID system has been installed on Windows, then the installation program automatically sets the necessary environment variable. Select [Systems Properties] in [My Computer] and select the [Advanced] tab. Click the [Environment Variable] button and check the setting in the [System Variable]. The settings can be changed by clicking on the [Edit] button. See the Windows help for more information on how to change the environment variable on Windows.

For Linux

If the CUBRID system has been installed on Linux, the installation program automatically creates the .cubrid.sh or .cubrid.csh file and makes configurations so that the files are automatically called from the installation account’s shell log-in script. The following is the .cubrid.sh environment variable setting file that was created in an environment that uses sh, bash, etc.

CUBRID=/home1/cub_user/CUBRID

CUBRID_DATABASES=/home1/cub_user/CUBRID/databases

CUBRID_LANG=en_US

ld_lib_path=`printenv LD_LIBRARY_PATH`

if [ "$ld_lib_path" = "" ]

then

    LD_LIBRARY_PATH=$CUBRID/lib

else

    LD_LIBRARY_PATH=$CUBRID/lib:$LD_LIBRARY_PATH

fi

SHLIB_PATH=$LD_LIBRARY_PATH

LIBPATH=$LD_LIBRARY_PATH

PATH=$CUBRID/bin:$CUBRID/cubridmanager:$PATH

export CUBRID

export CUBRID_DATABASES

export CUBRID_LANG

export LD_LIBRARY_PATH

export SHLIB_PATH

export LIBPATH

export PATH