7.2.1 CTM user environment variable definition file
- Organization of this subsection
(1) Format
Specify the file in the following format:
environment-variable-name=value
-
You cannot omit the environment variable name, the equal sign (=), or the value.
-
The characters from the beginning of a line to the character immediately before the first equal sign (=) are regarded as the environment variable name.
-
The characters from the character immediately after the first equal sign to the character immediately before the end of the line or file are regarded as the value.
-
A line beginning with a hash mark (#) is regarded as a comment. If there is a hash mark in the middle of the line, characters from the character after the hash mark to the end of the line are regarded as a comment. Spaces and tabs specified before a hash mark are ignored.
-
You cannot specify a hash mark (#) as the value of an environment variable.
-
To specify one definition on multiple lines, put a continuation character (\) immediately before the line break. Spaces and tabs immediately before the continuation character are ignored. If there is a continuation character in the middle of the line, the characters from the character after the continuation character to the end of the line are regarded as a comment. For this reason, to specify a continuation character, specify it at the end of the line.
-
If the specified environment variable already exists, the value of that environment value will be overwritten with the specified value. If the specified environment variable does not already exist, it will be added.
(2) File storage location
You can specify a storage location and file name of your choice. You can use the following characters in the file name:
-
In Windows
Alphanumeric characters, periods (.), backslashes (\), colons (:), plus signs (+), and hyphens (-)
-
In UNIX
Alphanumeric characters, periods (.), forward slashes (/), plus signs (+), and hyphens (-)
(3) Functionality
This file is used to specify the environment variables required for executing the ctmstart command (start the CTM daemon).
(4) Specifiable keys
You can specify any environment variable name except for the following:
-
Environment variable names beginning with CTM or ctm
(5) Examples of coding
-
In Windows
# Comment line LANG=ja_JP.SJIS # Comment. C:\Program Files\HITACHI\Cosminexus\CTM\lib\ctmj2sv.jar: \ C:\Program Files\HITACHI\Cosminexus\java\classes.zip # Continued line
-
In UNIX
# Comment line LANG=ja_JP.SJIS # Comment CLPATH=/opt/Cosminexus/CTM/lib/ctmj2sv.jar: \ /opt/java/lib/classes.zip # Continued line
(6) Notes
-
You cannot specify an environment variable name beginning with CTM or ctm.
-
You can specify a string consisting of alphanumeric characters or underscores (_) for an environment variable name.
-
You cannot specify spaces or tabs before the environment variable name. You must specify the environment variable name from the beginning of the line.
-
You cannot specify spaces or tabs between the environment variable name and the equal sign (=) or between the equal sign and the environment variable definition.
-
If the environment variable definition file contains %AAA% (in Windows) or $AAA (in UNIX), the string %AAA% or $AAA is treated as a character string and is not expanded to the environment variable AAA.
-
To specify a blank line, which does not contain any environment variable definition or comment, specify a line break code only (without spaces or tabs).
-
The definition is considered invalid in the following cases:
-
The environment variable definition does not contain an equal sign (=).
-
A line begins or ends with an equal sign (=).
-
An environment variable name begins with CTM or ctm.
-
A line contains only spaces or tabs.
-
-
When specifying environment variables in Windows, note the following regarding the use of continuation characters (\):
-
Make sure that a backslash (\) used to specify a path name is not confused with a continuation character (\).
-
Make sure that necessary spaces are not omitted.
The following are examples of specifications, where <LF> represents a line break code.
- Example 1: Specifying c:\ for the environment variable ROOT_PATH
-
Item
Incorrect example
Correct example
Coding of the CTM user environment variable definition file
ROOT_PATH=c:\<LF>
ROOT_PORT=18000<LF>
ROOT_PATH=c:\#<LF>
ROOT_PORT=18000<LF>
Specified environment variable
ROOT_PATH=c:ROOT_PORT=18000
ROOT_PATH=c:\
ROOT_PORT=18000
In the incorrect example, the backslash (\) in c:\ is misinterpreted as a continuation character. In such cases, specify a hash mark (#) immediately after the backslash (\) so that the backslash will not be treated as a continuation character.
- Example 2: Specifying C:\Program Files\Cosminexus\CTM for the environment variable CTMDIR
-
Item
Incorrect example
Correct example
Coding of the CTM user environment variable definition file
CTMDIR=C:\Program \<LF>
Files\Cosminexus\CTM<LF>
CTMDIR=C:\Program Files\<LF>
\Cosminexus\CTM<LF>
Specified environment variable
CTMDIR=C:\ProgramFiles\Cosminexus\CTM
CTMDIR=C:\Program Files\Cosminexus\CTM
In the incorrect example, the space in Program Files is omitted because it is specified immediately before the continuation character. Revise the specification so that the continuation character is not directly preceded by a space.
-