10.2.1 Definition file for snapshot log collection
The snapshot log collects information required to maintain the system and the applications.
In the definition file for the snapshot log collection, specify the target files for the primarily sent data, secondarily sent data, and definition sending data to be collected as the snapshot log. The specified file will be collected as the snapshot log. You can edit this file to change the path of the definition file for snapshot log collection.
- Organization of this subsection
(1) Format
Specify the definition file in the following format:
-
Specify the collection path as a full path.
-
The line beginning with a hash mark (#) is a comment.
-
Use "/" as a file separator.
-
Use a regular expression# for path elements classified by the file separator.
-
If the format includes an invalid regular expression#, the specification will be ignored.
-
If a file does not exist in the specified path, the specification will be ignored.
- #
-
For details on regular expressions, see the definition of java.util.regex.Pattern.
(2) Storage locations and file names
- When editing the default installation setup file
-
Edit the following files:
-
In Windows
Cosminexus-installation-directory\manager\config\snapshotlog.conf
Cosminexus-installation-directory\manager\config\snapshotlog.2.conf
Cosminexus-installation-directory\manager\config\snapshotlog.param.conf
-
In UNIX
/opt/Cosminexus/manager/config/snapshotlog.conf
/opt/Cosminexus/manager/config/snapshotlog.2.conf
/opt/Cosminexus/manager/config/snapshotlog.param.conf
Specify the files to be collected as primary delivery material in snapshotlog.conf and the files to be collected as secondary delivery material in snapshotlog.2.conf. In snapshotlog.param.conf, specify the data to be collected as the definition sending data.
-
For details about the files collected by snapshot log, see 2.3.3 Collecting the Snapshot Log in the manual uCosminexus Application Server Maintenance and Migration Guide.
- When specifying any file
-
Any storage location and filename is possible.
Copy and use the available template in the following locations:
-
In Windows
Cosminexus-installation-directory\manager\config\templates\
-
In UNIX
/opt/Cosminexus/manager/config/templates/
-
(3) Variables that you can use
You can use the following variables when you specify a path:
Note:
-
The dollar sign ($) indicates the system properties and the ampersand (&) indicates the internal variables of the Management Server.
-
You cannot use variables that include the dollar sign ($) in the value.
-
When you collect log using the snapshot log collection command, you cannot the use internal variables of Management Server that contain the ampersand sign. However, &{ejb.public.directory} can also be used with the snapshot log collection command.
(4) Examples of coding
- When collecting /home/logdir/message1.log
/home/logdir/message1\#.log
- When collecting all the files in the /opt/Cosminexus/manager/log directory
${cosminexus.home}/manager/log/.+#
- When collecting the JavaVM thread dump of the J2EE server (Working directory=/home/workdir, J2EE server name=Server1)
/home/workdir/ejb/Server1/javacore.+\#.txt
- #
-
The backslash (\) is a character that negates the period (.).
The period (.) sign indicates any character.
The plus sign (+) indicates one or more times.