This is the recommended configuration if you want to index several projects.
  1. You need to create a database for each source tree (or project)

    An LXR database is defined either as a real independent database, or as an alternate table set in an existing database.

    1. Independent database

      The new database is described by configuration parameters 'dbname', 'dbuser' and 'dbpass'. 'dbprefix' can keep its default value.

      This case does not apply to the Oracle engine.
    2. Alternate table set

      The table names in the new set start with the prefix defined by configuration parameter 'dbprefix'. The 'dbname', 'dbuser' and 'dbpass' parameters keep the same values for all trees.

      It is then wise to "common factor" them in the global parameter group.
    • Version 0.11

      Create the required data bases as you did for the first one.

      Run script initdb-config.sh for every new database (tree) as explained in the data base creation page.

      Next process the resulting customised script through the database engine.

      REMINDER! The database engine, name, user and password must be carried over to lxr.conf tree section.
    • Version 0.10

      Run script initdb-config to generate a customised initdb-xxx script (xxx = mysql, postgres or oracle.sql according to your choice of a relational database).

      $ initdb-config

      and answer questions. Next process the resulting customised script through the database engine.

      CAUTION! If you change the default database name (lxr), you need to create it before running your customised script. Follow these instructions replacing script initdb-xxx with the custom one.
    • Up to version 0.9.10

      In the initdb-xxx script (xxx = mysql, postgres or oracle.sql according to your choice of a relational database) replace all occurrences of lxr_ by another prefix. Run this script (without recreating the lxr DB-user) as explained in the page "Create database".

      Technically, you do not create a new database, you add new tables to the existing one. Creating truly independent databases would require modifying the initdb-xxx scripts in a specific way and eventually running extra commands.
  2. Create a new tree-specific section in lxr.conf This page describes the content of a tree-specific section. See instructions for release 0.11 or prior versions.

    You need to synchronise the Data storage subsection with what you did in the first step.

    • Database description , 'dbname' => db_designation , 'dbprefix' => prefix , 'dbuser' => lxr_db_user , 'dbpass' => lxr_db_password If you only created new tables in the lxr database, you are free to keep the database parameters in the tree-specific section or not.
    • Search directory

      Create a directory and copy its name either in 'glimpsedir' or in 'swishdir':

      , search_engine_dir => directory
  3. Index your trees

    Run the genxref script ( v0.11 or prior versions) for each tree.

    $ ./genxref --url=...