Building the database

How

The database needs only be built once and for all. To do so, run the

hal_build_db

command-line program with the right options.

hal_build_db usage

To see the hal_build_db usage, run the following command:

hal_build_db --help

This displays the following output:

hal_build_db version <version-number> on <backend-name>
Usage: hal_build_db [options]
OPTIONS:
   -d , --dbname db     Use this database
   -f textfilename      Use this text input file
   -o wordlistfilename  Use this wordlist output file
   --help               Show this help
   -V , --version       Show version
   -h , --host host     Set hostname to connect to
   -u , --user user     Set database user to connect as (default: 'emdf')
   -p , --password pwd  Set password to use for database user

Example

Assume that you want the following:

  • Build a database called hal_test
  • using an input-file called mytext.txt
  • writing a word-list to a file called wordlist.txt

And assume the following (not necessary if using SQLite 2 or SQLite 3):

  • You have set up your backend database with the user called emdf
  • having a password called changeme.
  • You are using MySQL as a backend.

The the following command-line would do it:

hal_build_db -d hal_text -f mytext.txt -o wordlist.txt -p changeme -u emdf -b m

That's it.

If you want to use PostgreSQL as a backend, use "-b p" instead of "-b m".


Previous:Part II: Running
Up:Part II: Running
Next:Querying the database