Settings for creating and configuring database stores are managed in the EMS server, and are transparent to clients. To configure the database stores feature, follow these steps:
Includes all the JAR files required by the EMS server when employing the database store feature. This parameter must be set when a store of type
dbstore has been created in the
stores.conf file.
Required JAR files are determined by the installed Hibernate release, and are documented in the
README.txt file that is located in the
lib/ directory of the Hibernate distribution. Many of these JAR files are version-specific, and the required versions may change with new Hibernate releases. You should verify the required version and modify the
dbstore_classpath variable accordingly.
If you are using Hibernate release 3.2.5, for example, the dbstore_classpath should include paths to the following JAR files:
For an example, see EMS_HOME/samples/config/tibemsd-db.conf.
The SQL dialect is defined by Hibernate. For a list of databases and the associated dialects, see the readme.txt file located in the Hibernate install directory archive.
This section describes parameters configured for each database store in the stores.conf file. The
stores.conf includes definitions for both database and file-based stores. For information about configuring file-based stores, see
stores.conf on page 237.
[store_name] # mandatory -- square brackets included.
dbstore_driver_url =
JDBCURL
dbstore_driver_username =
username
dbstore_driver_password =
password
dbstore_driver_url=jdbc:mysql://mysqlsrv_1:3306/sysfs
dbstore_driver_username=admin
dbstore_driver_password=admin123
dbstore_driver_url=jdbc:mysql://mysqlsrv_1:3306/sysmeta
dbstore_driver_username=admin
dbstore_driver_password=admin123
dbstore_driver_url=jdbc:sqlserver://sqlsrv_1:3415;databaseName=sysmeta
dbstore_driver_username=admin
dbstore_driver_password=admin123
dbstore_driver_url=jdbc:sqlserver://sqlsrv_1:3415;databaseName=sysfs
dbstore_driver_username=admin
dbstore_driver_password=admin123
dbstore_driver_url=jdbc:oracle:thin:adminmeta/admin123@//osrv_1:1521/orclperf
dbstore_driver_username=adminmeta
dbstore_driver_password=admin123
dbstore_driver_url=jdbc:oracle:thin:adminfs/admin123@//osrv_1:1521/orclperf
dbstore_driver_username=adminfs
dbstore_driver_password=admin123
dbstore_driver_url=jdbc:oracle:oci:<user>/<passwd>@(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=<host1>)(PORT=1521))(ADDRESS=(PROTOCOL=TCP)(HOST=<host2>)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=orcl)(FAILOVER_MODE=(TYPE=SELECT)(METHOD=BASIC)(RETRIES=180)(DELAY=5))))
dbstore_driver_username=admin
dbstore_driver_password=admin123
dbstore_driver_url=jdbc:db2://db2srv_1:50000/SYSMETA
dbstore_driver_username=admin
dbstore_driver_password=admin123
dbstore_driver_url=jdbc:db2://db2srv_1:50000/SYSFS
dbstore_driver_username=admin
dbstore_driver_password=admin123
To ensure that the EMS server does not lose its connection to the database during a database failover, the server should connect to the database using a Transparent Application Failover (TAF) configured URL. For example: