DBBUILD
Section: User Commands (1)
Updated: November 2000
Index
Return to Main Contents
NAME
dbbuild - XPAT database build control program
SYNOPSIS
dbbuild
[
-ver
]
[
-v
]
[
-no_run
]
[
-l "logfile"
]
[
-no_ff
]
[
-no_opt
]
[
-merge
]
[
-dos
]
[
-m " memory"
k|m ]
[
-o " output_prefix"
]
[
-w " word_wheel"
]
[
-wwdb
]
[
-f " Fast_Region_file"
]
[ [
-t " tags_file"
] |
[
-inp " inp_file"
] |
[
-c " regions_config_file"
] ]
[
-O " optimize_file"
]
[
-tmp " temp_file"
]
[
-u " user_tags_file"
]
[
-r " phase_count"
]
-D
data_dictionary
DESCRIPTION
dbbuild builds all the necessary files for the database specified
by data_dictionary. A data_dictionary must be prepared before using dbbuild, as well as a template file
for any user meta-data (see mfsbld(1)). Refer
to the Database Administration Guide for further details.
OPTIONS
- -ver
-
version - display version number. This option identifies the version number of the
program and then exits.
- -v
-
verbose - specify verbose mode. This option tells dbbuild to turn on the verbose
mode of all the index-building programs it runs. With verbose mode turned
on, these programs print progress messages as they proceed.
By default, dbbuild works quietly, only printing a minimum of messages.
- -no_run
-
do not run- specify that dbbuild should not run the index builders. This option
tells dbbuild to display the
commands that it would issue to build the database. This allows the user to
redirect the output from dbbuild to a file, which could then be executed as a shell
script. In this mode, the commands themselves are not executed.
- -l log_file
-
log - specify the log file. This option tells dbbuild
to send all the progress information that is produced by
the programs that it runs to the specified log_file. This option
is very useful for recording the details of the build process in long
build operations or in helping to diagnose any build problems that might
occur. This option can be used in
combination with the -v option, in which case the
diagnostic output is sent to both the screen and the log file.
- -no_ff
-
no Fast Find indices - eliminates the building of Fast Find indices. Open
Text strongly recommends the building of Fast Find indices, especially for MFS
databases. Fast Find indices are built by default.
- -no_opt
-
no optimization - turn optimization off. When building MFS databases, dbbuild
uses an optimization method by default. This optimization
involves generating the virtual text of the entire MFS database
and writing it out to a temporary file on disk at the same time as it builds
the FileMap.
dbbuild then runs all the index-building programs on that text file.
It deletes the text file when all the necessary files have been built.
This temporary text file is usually considerably smaller than the total
size of all the word processor files combined, especially
in databases which consist mainly of word processor files.
This is because a significant amount of space is used in
each file for word processor formatting commands and related overhead.
-
In some situations, the disk space required for this file is simply
not available. In these cases, the -no_opt option may be
specified to allow dbbuild to proceed with the database build, at a
somewhat slower speed.
- -merge
-
region merging - make multirgn and sgmlrgn to merge the new regions into the existing
regions. If the regions with the same name happens in different region building
phase, the later set of regions will completely replace the old region set.
This option allows the regions with the same name to be merged into the same
region set without replacement.
- -dos
-
dos processing option - make sgmlrgn processing aware of special MS-DOS characters.
With this option, sgmlrgn will replace the special MS-DOS characters to blank
in order to avoid error during parsing.
- -m Nk
-
- -m Nm
-
memory - use N kilobytes or N
megabytes of physical memory during the database building process.
The speed with which the various index building programs operate
is affected by the amount of physical memory available. By
default, dbbuild allocates 512 KB of memory for the index building programs it
runs. While this is adequate for very small databases, larger databases
benefit by allocating more physical memory. The -m option specifies
how much memory
programs can use. A number immediately followed by the letter k
specifies that number of kilobytes. A number immediately followed by
the letter m specifies that number of megabytes. For instance,
`-m 4m' allocates 4 megabytes of memory for use by programs invoked by
dbbuild. For large databases (where the text is broken into more than 10 chunks
by xpatbld), the amount of memory that is specified is critical to the efficiency
of the build operation. Refer to the xpatbld(1) man page and the section on xpatbld
parameters in the Database Administration Guide for the details on how to specify this memory parameter.
- -o output_prefix
-
output filename prefix - specify the prefix to use for output files.
This option explicitly specifies the output filename prefix
for the files produced by the indexing programs. The
default prefix is the prefix of the data_dictionary.
- -w word_wheel
-
word wheel - specify that dbbuild is to build a word wheel file.
dbbuild will build this file using any regions prefixed with a
``*'' character in the regions_list_file. See the Database Administration Guide for
an explanation of the word wheel.
- -wwdb
-
word wheel - specify that dbbuild is to build a XPAT database on the
word wheel file specified with the
-w
word_wheel option.
dbbuild will also build
region indices in the word wheel database for any regions prefixed with a
``*'' character in the regions_list_file. See the Database Administration Guide for
an explanation of the word wheel.
- -f Fast_Region_file
-
Fast-Region list file -
specify that dbbuild is to build Fast-Region indices over the regions listed in
the Fast_Region_file. The file should contain one region
name per line.
If a region name is prefixed with a "*"
character, dbbuild will build regions indices for the corresponding region in the
word wheel database (see the -w option).
See the Database Administration Guide for an explanation
of Fast-Regions.
- -t tag_file
-
tag names file -
specify that dbbuild is to build region indices over the tags in the database
listed in the tag_file file.
This file is passed directly to multirgn.
The tag names file is only used with consolidated databases.
Refer to the sections on building Release 5.0
databases in the Database Administration Guide and the multirgn(1) man page for more information
on the tag_file file.
The -t, -inp and -c options are mutually exclusive. The -t and -inp files are
used with consolidated databases. The -c option is used with MFS databases.
- -inp inp_file
-
inp file -
specify that dbbuild is to build region indices over the database using the sgmlrgn
program in region mode.
Refer to the sections on building Release 5.0
databases in the Database Administration Guide and the sgmlrgn(1) man page for more information on
the inp_file file.
The -t, -inp and -c options are mutually exclusive. The -t and -inp files are
used with consolidated databases. The -c option is used with MFS databases.
- -c regions_config_file
-
regions configuration file -
specify that dbbuild is to build region indices over the sections of the MFS
database specified in the regions_config_file. The regions configuration file
is only used with MFS databases.
The regions configuration file can consist of a mixture two types of regions
specifications: multirgn and sgmlrgn. multirgn regions specifications consist of the
following tags:
<Regions><DisplayFmt></DisplayFmt><TagFile></TagFile></Regions>
Each such specification instructs dbbuild to invoke multirgn to build region indices
over the files referenced in the Data Dictionary by the DisplayFmt using TagFile specified.
See the multirgn(1) man page for further details.
sgmlrgn regions specifications consist of the following tags:
<Regions><GroupName></GroupName><INPFile></INPFile></Regions>
Each such specification instructs dbbuild to invoke sgmlrgn to build region indices
over the files references in the Data Dictionary by the GroupName, using the .inp
file specified. See the sgmlrgn(1) man page for further details.
The -t, -inp and -c options are mutually exclusive. The -t and -inp files are
used with consolidated databases. The -c option is used with MFS databases.
- -O optimize_file
-
optimize file - specify the name and location of the MFS optimization file.
This is useful if there is not enough space on the current disk to hold both
the database and the optimization file.
If both -no_opt and -O options are specified on the command line,
dbbuild will take the last specification as the correct specification.
- -tmp temp_file
-
temporary filename prefix - specify the file name prefix and location of
the xpatbld and
xpatffi temporary files. This is useful if the current disk does not have enough
space to hold both the database and the temporary files.
- -r phase_count
-
restart - specify that dbbuild is to restart from the last successful build
phase and continue for another phase_count phases. This is useful for
stepping through each of the phases of dbbuild. If more phases are specified then
remain in the database build, dbbuild continues until it has finished. If the
-r option is specified for a dbbuild that was never started, dbbuild starts from
the beginning of the database building process. The phase information is
stored in the file called restart.ot in the local directory.
- -u user_tags_file
-
tags file for user meta data - specify that dbbuild should use the
user_tags_file to build regions within the user meta data. The format of
the user_tags_file is as for the -t option. The -u option
is used with MFS databases.
EXAMPLE
A typical consolidated database building session is invoked with the following
parameters:
dbbuild -v -l logfile -m 28m -o db -D db.dd
This example specifies that messages generated during the building
process should be echoed to the screen (-v) and to the log file
called logfile (-l logfile). 28 megabytes of memory
are allocated to dbbuild (-m 28m) and the index
files are all named with the prefix `db' (-o db). The Data
Dictionary is called `db.dd' (-D db.dd).
Should the user stop the build process before it completes, the following will
restart dbbuild after the last successful build phase and will stop after the next
two phases are complete:
dbbuild -r 2
A typical MFS database building session is invoked with the following
parameters:
dbbuild -v -l logfile -m 28m -o db -c db.cfg -D db.dd
All the parameters for this build operation are the same as for the
consolidated database example, except that db.dd is an MFS
Data Dictionary and there is a regions configuration file (db.cfg).
For this example, assume the Data Dictionary had the following FilterChain
specifications:
<FilterChain>
<SearchView>meta</SearchView>
<DisplayView>meta</DisplayView>
<RawView>meta</RawView>
<DisplayFmt>wp</DisplayFmt>
<FileGroup>
<MfsDir>wp</MfsDir>
<MfsFile>wp*</MfsFile>
<MfsExpand>tree</MfsExpand>
</FileGroup>
</FilterChain>
<FilterChain>
<SearchView>meta</SearchView>
<DisplayView>meta</DisplayView>
<RawView>meta</RawView>
<DisplayFmt>bus</DisplayFmt>
<FileGroup>
<MfsDir>bus</MfsDir>
<MfsFile>bus.txt</MfsFile>
<MfsExpand>file</MfsExpand>
</FileGroup>
</FilterChain>
<FilterChain>
<SearchView>meta</SearchView>
<DisplayView>meta</DisplayView>
<RawView>meta</RawView>
<DisplayFmt>sgml,simple</DisplayFmt>
<FileGroup>
<MfsDir>simple</MfsDir>
<MfsFile>simple.sgm</MfsFile>
<MfsExpand>file</MfsExpand>
</FileGroup>
</FilterChain>
This Data Dictionary specifies three FilterChains which we will characterize by
their DisplayFmts. The first FilterChain consists of a directory of word
processor files, which have no structure tags. The second FilterChain consists
of a file called bus, which is a tagged text file suitable for multirgn to
build region indices over. The third FilterChain consists of an SGML file,
which is suitable for sgmlrgn to build region indices over.
The following is an appropriate regions configuration file (db.cfg) for
the above Data Dictionary:
<Regions><DisplayFmt>bus</DisplayFmt><TagFile>bus/bus.tag</TagFile></Regions>
<Regions><GroupName>simple</GroupName><INPFile>simple/simple.inp</INPFile></Regions>
When dbbuild is run with this regions configuration file, multirgn will be run over the
files specified by the bus DisplayFmt using the bus/bus.tag
tag names file. sgmlrgn will be run over the files specified by the
sgml,simple DisplayFmt using the .inp called
simple/simple.inp.
Note that no region indices will be built over the word processor files
specified by the wp DisplayFmt.
Again, the user can also use the restart option.
DETAILED OPERATION
The dbbuild program works by invoking each of the necessary database
building tools in the correct sequence. The following paragraphs
describe how each of these tools works.
The first phase in building an MFS database is to generate the
FileMap. The FileMap is generated by the mfsbld program. This program
reads the MFS fields in the Data Dictionary and generates the three
FileMap files. Refer to the mfsbld(1) man page for further details.
This phase is skipped for regular databases.
Once mfsbld has finished building the FileMap, dbbuild calls the
xpatbld program to build the Main Index. Refer to the xpatbld(1) man
page for further details on this process.
The next phase builds the Fast-Find Index. This index is built
using the xpatffi and xpatffw programs. Refer to the xpatffi(1) and xpatffw(1)
man pages for further details on the Fast-Find indices and their build programs.
The final phase involves building the region indices using the multirgn program.
Note that dbbuild passes
the name of the tag_names file directly to multirgn. Refer to
the multirgn(1) man page for further details about this program.
Once the region building process has completed, dbbuild removes any
temporary files and then exits. The database is then ready to be
searched with xpat.
SEE ALSO
mfsbld(1), xpatbld(1), multirgn(1), xpatfsr(1), xpatffi(1), xpatffw(1), data_dict(5), mfs(5)
Index
- NAME
-
- SYNOPSIS
-
- DESCRIPTION
-
- OPTIONS
-
- EXAMPLE
-
- DETAILED OPERATION
-
- SEE ALSO
-
This document was created by
man2html,
using the manual pages.
Time: 18:03:38 GMT, March 26, 2001