grommunio-index(8)

Name
grommunio-index — Fulltext search index generator for grommunio mailboxes

Synopsis
grommunio-index [-c] [-e host] [-o file] [-p port] [-qrv] userpath

grommunio-index -A [-c] [-p port] [-qrv]

Description
grommunio-index builds and maintains SQLite-based fulltext search indexes for grommunio mailboxes. It connects to the exmdb service to retrieve message properties, extracts and sanitizes text from plain-text and HTML bodies, and writes the results into per-user FTS5 databases.

In single-user mode, the tool indexes the mailbox at the given userpath. In all-user mode (-A), it reads the user list from the grommunio MySQL database and processes every user automatically, writing index databases into a shared directory tree.

grommunio-index is typically invoked via its companion systemd timer (grommunio-index.timer) rather than manually.

Options

-A, --all
    Automatically process all local users. Cannot be combined with -e, -o, or a positional userpath argument.

-c, --create
    Create a new index from scratch instead of updating an existing one.

-e host, --host host
    Hostname of the exmdb server to connect to.
    Default: localhost (overridable via index.cfg)

-h, --help
    Show a help message and exit.

-o file, --out file
    Write the index database to a specific file or directory instead of the default location inside the user's maildir.

-p port, --port port
    Port of the exmdb server.
    Default: 5000 (overridable via index.cfg)

-q, --quiet
    Reduce verbosity level. Can be specified multiple times.

-r, --recheck
    Check all messages regardless of folder timestamps. Normally, folders whose local-commit-time-max has not changed since the last run are skipped.

-v, --verbose
    Increase verbosity level. Can be specified multiple times.

Configuration file
The optional configuration file /etc/gromox/index.cfg can be used to override built-in defaults. The file uses a simple key-value format with one directive per line. Lines starting with # are comments, and whitespace around the = sign is ignored.

Command-line arguments take precedence over configuration file values. If the file is absent, all built-in defaults apply and no error is raised.

  Configuration directives

index_root
    Root directory under which per-user index databases are stored in all-user mode (-A). Each user gets a subdirectory named after their login, with index.sqlite3 inside it.
    Default: /var/lib/grommunio-web/sqlite-index

user
    System user to switch to when running as root. Only relevant in all-user mode.
    Default: groindex

group
    System group to switch to when running as root. Only relevant in all-user mode.
    Default: groweb

exmdb_host
    Default hostname of the exmdb server. Overridden by the -e command-line option.
    Default: localhost

exmdb_port
    Default port of the exmdb server. Overridden by the -p command-line option.
    Default: 5000

Files

/etc/gromox/index.cfg
    Optional configuration file for grommunio-index.

/etc/gromox/mysql_adaptor.cfg
    MySQL connection parameters, used in all-user mode to retrieve the user list.

See also
gromox.cfg(5)