Your Search Administration installation and all routing installations must have access to the Search databases.
Search components rely on two database schemas, one internal, which is used by management applications such as Search Administration and Merchandising (called the management database), and one external, which is used by Search client applications such as Routing, Commerce and Knowledge (called the production database).
Configuring Search Data Sources
Before you run the database import scripts, in your home/localconfig
directory, make the following changes:
Set
FakeXADataSource
to point to the management schema.Set
FakeXADataSource_production
to point to your production schema.Set the
JTDataSource
andJTDataSource_production
components inhome/servers/
server_name
/localconfig
to use a JNDIReference to your application server data source. On the management server, theJTDataSource
should point to the management schema and theJTDataSource_production
should point to the production schema. On the production server, you only need to configure theJTDataSource
, which must refer to the production schema.
Note: If you are running Search Administration by itself, without any other servers, point both FakeXADataSource
and FakeXADataSource_production
to the management database. You should also define the JTDataSource_production
component in your home/servers/
server_name
/localconfig
to point to the production schema.
When you start your management or production server, reference the server_name
in your start command.
Configuring Data Sources for Multi-Product Installations
As explained in the previous sections, a typical Search installation has a management, agent, and production server. It also has three data sources:
Agent data source – Stores versioned Knowledge solutions and internal users
Production data source- Stores Self Service solutions, Search routing and Search Administration data, and external users
Management data source – Required for Knowledge installations
A number of /atg/search/service
components exist to configure your installation. As provided, these components point to the production server and the production data source; this is the recommended configuration, and if you use it, you do not need to change these components. You do need to do the following:
On the agent server, configure
JTDataSource_production
,ClientLockManager_production
andSQLRepositoryEventServer_production
to point to the production server and production data source.On the management server, configure
JTDataSource_production
,ClientLockManager_production
andSQLRepositoryEventServer_production
to point to the management server and management data source.
Creating the Database Schema
After installing ATG Search, create the database schema. The following scripts for are located in the <ATG2007.3dir>\Search2007.3\SearchAdmin\install\
directory:
create-search
—Creates theDAF.Search
tables and theSearchAdmin
tablescreate-daf-search
—Creates only theDAF.Search
tablescreate-search-admin
—Creates only theSearchAdmin
tablesall-create
—Creates all Search tables and also tables for the ATG Business Control Center
If your Search installation is standalone, you can simply run all-create
.
If your installation involves both a production and a management component, tables related to other ATG products have most likely already been installed on both the production and management server, and you only need to create the Search tables. This involves the following steps:
Set your Search database environment variables to point to the production database.
Set your
FakeXADataSource
to point to your management database.Set your
FakeXADataSource_production
to point to your production database.Run
create-search
, which creates both thedaf-search
andsearch-admin
tables and initializes them. It also creates theSearchAccess
role in the management database so the defaultadmin
user can access the Search Administration interface through the BCC on the management server.
Note: ATG Knowledge and ATG Self Service create the daf-search
tables as part of their installation. If you have already installed either product, you should run create-search-admin
instead of create-search
.
Whichever script you use, before running it, edit the search-env.bat
script to set the SEARCH_DB_USER, SEARCH_DB_PWD, and JDBC connection to the correct values for your system (you can also set these using environment variables). Also, configure the SEARCH_MSSQL_DB_NAME and SEARCH_MSSQL_DB_HOST for Microsoft SQL Server, SEARCH_ORACLE_TNS for Oracle, or SEARCH_DB2_DB_NAME for DB2, depending on your database provider.
Note: The schema creation scripts import data using StartSQLRepository
. Make sure your JTDataSource
and FakeXADatasource
are configured to permit this in home/localconfig
. JTDataSource
should automatically point to FakeXADataSource
. FakeXADataSource
should point to the management database, and FaxeXADataSource_production
should point to the production database. Note that some product installation processes, including ATG Self Service, need FakeXADataSource
pointed at the production database, so you may need to change the FakeXADataSource
between installing the different products.
Deleting Database Tables
To delete Search database tables from your installation, run one of the following scripts found in <ATG2007.3dir>\Search2007.3\SearchAdmin\install
, depending on which tables you have created:
drop-search
drop-search-admin
drop-daf-search
all-drop