8.4 Setting environment variables
This section explains the environment variables that will be set by HADB administrators and the OS users that belong to the HADB administrators group.
Make sure that the values that you set are valid in the shell when the HADB server is used. For details about how to set the environment variables, see the documentation for the operating system you are using.
If you are using the multi-node function, set the environment variables on all nodes.
- Important
-
The HADB server must be stopped before you set environment variables. You can stop the HADB server by executing the adbstop command.
The following table shows the values to be specified in the environment variables.
No. |
Environment variable |
Value to be specified |
---|---|---|
1 |
LANG |
Specify the character encoding for the operating system.#
|
2 |
LD_LIBRARY_PATH |
Add the following directories to this environment variable:
When either of the following conditions are satisfied, also add $ADBDIR/client/lib to this environment variable:
|
3 |
PATH |
Add the following directories to this environment variable:
|
4 |
TZ |
Specify the time zone of the machine on which the HADB server is to be installed. Do not specify a time zone that supports leap seconds.
|
5 |
ADBDIR |
This environment variable is used to specify the absolute path to the server directory. |
6 |
ADBLANG |
Specify the character encoding to be used by the HADB server.#
|
7 |
ADBMSGLOGSIZE |
Specify, in megabytes, the maximum size of each server message log file. A value between 1 and 2,000 can be specified. The HADB server creates four server message log files. If this environment variable is omitted, the maximum size of each server message log file is 16 megabytes. |
8 |
ADBSYSLOGLV |
If this environment variable is specified, you can suppress the messages that are output to syslog based on the output level. To suppress the messages that are output to syslog, specify this environment variable. Specify a value between 0 and 6 for the output level. For a list of the output levels of messages output to syslog, see 10.4.5 Suppressing message output to syslog. An error occurs if a value outside the range of 0 to 6 is specified for the output level. If this environment variable is not specified, 6 is assumed for the output level. |
9 |
ADBCLTDIR |
Specify the directory in which the HADB client's various types of files are to be stored. Specify the absolute path to the server directory for this environment variable. Set this environment variable when either of the following conditions are satisfied:
|
10 |
ADBCLTLANG |
Specify the character encoding to be used by HADB clients.#
Set this environment variable when either of the following conditions are satisfied:
|
11 |
ADBSQLNULLCHAR |
If the adbsql command's retrieval results might contain a null value, specify in this environment variable the character string to be used to indicate the null value (character string displaying a null value). A character string consisting of 0 to 32 bytes is permitted. If a zero-byte character string is specified, the space is displayed as the null value. If this environment variable is omitted, the asterisk (*) is displayed as the null value. Specify this environment variable when retrieval data might contain asterisks or if you want to display a desired character as the null value. Note that if a multi-byte character is specified, the retrieval results might not be displayed correctly. Consider setting this environment variable when the adbsql command will be executed on the HADB server. |
12 |
CLASSPATH |
Specify this environment variable if you plan to develop or execute Java applications on the HADB server (when using the JDBC driver). Specify the absolute path to the JAR file for this environment variable. Specify the following path:
If you change the preceding storage location for the JAR file, specify the absolute path of the new storage location. To work directly with classes provided by the JDBC driver, such as with non-standard JDBC methods provided by the JDBC driver (for example, connection information setup and acquisition interface methods), specify this environment variable before compiling the application. |
- #
-
Select the same character encoding for the LANG, ADBLANG, and ADBCLTLANG environment variables.
Example 1: Unicode (UTF-8) is used in a Japanese language environment
LANG="ja_JP.UTF-8" ADBLANG=UTF8 ADBCLTLANG=UTF8
Example 2: Unicode (UTF-8) is used in an English language environment
LANG="en_US.UTF-8" ADBLANG=UTF8 ADBCLTLANG=UTF8