Configuration tool
Use the configuration tool to customize configuration settings after you install OmniFind Text Search Server for DB2® for i.
To customize most of the configuration settings, you must stop the text search server before running the configuration tool.
- the current authentication token
- the server port
- the current properties of the system
The configServerAndDB2 tool
The configServerAndDB2 (configServerAndDB2.sh) tool is located in integrated-file-system directory /QOpenSys/QIBM/ProdData/TextSearch. This tool can be used to create or modify entries in the DB2 catalog file SYSTEXTSERVERS.
It can also be used to configure the authentication token or the port number associated with the specific server. The tool modifies or sets the values for SERVERAUTHTOKEN and SERVERPORT in the DB2 catalog file SYSTEXTSERVERS.
If you want to create an additional server that runs locally to your system, use the ServerInstance tool instead.
The configServerAndDB2 (configServerAndDB2.sh) tool is called with five parameters:
- The first parameter is either generateToken or configureHTTPListener.
- The second parameter is -serverPath.
- The third parameter is the path to the root node in the integrated file system where the information related to the server is stored. Example: /QOpenSys/QIBM/ProdData/TextSearch/server2.
- The fourth and fifth parameters vary depending on the value of
the first parameter.
- If the first parameter is generateToken, then the fourth parameter is -seed followed by an integer (for example, 1) as the fifth parameter
- If the first parameter is configureHTTPListener, then the fourth parameter is -adminHTTPPort. The fifth parameter is an integer value that is used as the socket port for the server.
STRQSH cd /QOpenSys/QIBM/ProdData/TextSearch configServerAndDB2.sh generateToken -serverPath /QOpenSys/QIBM/ProdData/TextSearch/server2 -seed 1STRQSH cd /QOpenSys/QIBM/ProdData/TextSearch configServerAndDB2.sh configureHTTPListener -serverPath /QOpenSys/QIBM/ProdData/TextSearch/server2 -adminHTTPPort 9997
The configTool script
The configTool.sh script is available for each local server. It is located in Integrated File System (IFS) directory:
/QOpenSys/QIBM/ProdData/TextSearch/server<servernumber>/bin.
This tool can be used to list and set parameters for OmniFind Text Search Server. Prior to using it to modify server configuration, it is recommended that you review the following OmniFind article to understand how to tune OmniFind:
Restriction: Some parameters are read only, while others can only be modified when the OmniFind Text Search Server is stopped.
Authorization
- *ALLOBJ special authority
Syntax
configTool.sh <command> [-command_options] [-locale value] [-configPath value]
Commands and command options
- list -system [-details] [-showAdvanced][-parameter_name]
-
Prints system-level parameters and their current values. See the following sections for descriptions of each parameter.
- -details
- Prints detailed information about each parameter, including a description, default value, type, and whether it is modifiable.
- -showAdvanced
- Prints information about advanced configuration parameters.
- -parameter_name
-
Prints detailed information about the specified parameter.
- set -system -parameter_name value
- Specifies the value of a system-level parameter.
- generateToken
- Generates the authentication token.
- printToken
- Prints the current authentication token and encryption key.
- sysinfo
- Prints system information, such as the build version number, operating system, and JAR manifest version.
Parameters
- -configPath
- Specifies the absolute path to the configuration directory. This directory contains configuration files and the \collections subdirectory. This parameter cannot be modified.
- -directoryTypeForSearch
-
Advanced: The type of file system to use for search. Specify one of the following values:
mmap Specify mmap to store shared indexes by using memory mapped files. Using mmap improves search performance, especially for concurrent searches. Using this option results in increased heap memory consumption.
simple Specify simple for standard file input/output.
noifs Specify niofs to store shared indexes by using New Input/Output (default for OmniFind Text Search Server for DB2 for i).
Important: When you specify mmap, it is recommended to configure 64-bit JVM for OmniFind Text Search Server and increase the heap size accordingly by specifying the maxHeapSize parameter to avoid out-of-memory error.
- -logFolder
- Specifies the absolute path to the log directory.
- -maxDocumentSizeBytes
- Specifies the maximum size (in bytes) of documents that are indexed. The default value is 120000000.
- -maxHeapSize
-
Specifies the maximum heap size of the server. Set this value according to JVM heap size specifications. For example, the maximum heap size that can be allocated to a 32-bit Java virtual machine is 1.8 GB. The default value is 1500M for 32-bit JVMs and 4G for 64-bit JVMs(M=megabytes, G=gigabytes). The value must be an integer. For example, to specify 1.8 gigabytes, enter 1800M. This parameter can be modified only when the server is stopped.
Attention: In OmniFind Text Search Server ECMTS version 1.5.0, maxHeapSize was called startupHeapSize.
- -numberOfIndexerThreads
- Advanced: Specifies the number of indexing threads that run on the server. The default value is 8.
- -numberOfTokenizers
- Specifies the number of language processors that are used for parsing input into tokens. The default value is 20.
- -port
- Specifies the number of the port on which the OmniFind Text Search server listens for requests.
- -queryCacheSizeMB
- Advanced: Specifies the size (in MB) of the query cache. This parameter can be modified only when the server is stopped. The default value is 200 MB.
- -searchableRefreshRateMS
- Advanced: Time period (in milliseconds) for checking whether the index has changed and the searchable must be reopened. The default value is 1.
- -tempDirectory
- Specifies the absolute path to the temporary directory.
- -useQueryCache
- Advanced: Enables query caching. The default value is not to use the query cache
(false).
Important: when you enable the query cache, it is recommended to configure 64-bit JVM for OmniFind Text Search Server and increase the heap size accordingly by specifying the maxHeapSize parameter to avoid out-of-memory error.
Global arguments
- -configPath
- Specifies the absolute path to the configuration folder that contains the config.xml file. This global argument is mandatory.
- -locale
- Optional: Specifies the two- or five-character locale setting for writing messages to the trace
file. If you do not specify this setting, the default value, en (English), is used.
Table 1. The supported locales Locale value Language cs Czech da Danish de German en English es Spanish fi Finnish fr French hu Hungarian it Italian ja Japanese ko Korean nl Dutch no Norwegian pl Polish pt Portuguese pt_BR Brazilian Portuguese ru Russian sv Swedish zh Chinese zh_TW Chinese-Taiwanese
Replaced commands and arguments
With IBM i 7.3, the IBM i OmniFind Text Search Server was upgraded from ECM Text Search (ECMTS) version 1.5.0 to 5.2.1. By upgrading the ECMTS version, DB2 for i OmniFind users received infrastructure improvements, security fixes, and serviceability enhancements. These changes also result in the replacement of some OmniFind configuration commands and arguments. Review the list below to understand the configuration tool changes.
- configureParams
- Use the set –system command instead.
- -adminHTTPPort
- Use the -port parameter instead.
- -logPath
- Use the -logFolder parameter instead.
- -tempDirPath
- Use the -tempDirectory parameter instead.
- -numberOfIndexers
- Use the –numberOfIndexerThreads parameter instead.
- -maxDocumentSize
- Use the -maxDocumentSizeBytes parameter instead.
- printAll
- Use the list -system command instead.
- printAdminHTTPPort
- Use the list -system -port command instead.
Examples
Assume the configuration directory is /QOpenSys/QIBM/ProdData/TextSearch/server1/config.
-
Print the current authentication token.
configTool.sh printToken -configPath /QOpenSys/QIBM/ProdData/TextSearch/server1/config -
List the maximum of documents size (in bytes) that can be indexed.
configTool.sh list -system -details -maxDocumentSizeBytes -configPath /QOpenSys/QIBM/ProdData/TextSearch/server1/config -
Set the maximum heap size of the server to 1800M.
configTool.sh set -system -maxHeapSize 1800M -configPath /QOpenSys/QIBM/ProdData/TextSearch/server1/config -
Increase the index change checking time period to one minute, to reduce index checking contention with search performance.
configTool.sh set -system -searchableRefreshRateMS 60000 -configPath /QOpenSys/QIBM/ProdData/TextSearch/server1/config -
Use mmap to improve search performance.
configTool.sh set -system -directoryTypeForSearch mmap -configPath /QOpenSys/QIBM/ProdData/TextSearch/server1/config -
Enable the query cache to improve search performance and reduce overall CPU consumption.
configTool.sh set -system -useQueryCache true -configPath /QOpenSys/QIBM/ProdData/TextSearch/server1/config