indextool command reference
indextool is one of the helper tools within
the Sphinx package, introduced in version 0.9.9-rc2. It is used to
dump miscellaneous debug information about the physical index.
(Additional functionality such as index verification is planned
in the future, hence the indextool name rather than just indexdump.)
Its general usage is:
indextool <command> [options]
Options apply to all commands:
--config <file>(-c <file>for short) overrides the built-in config file names.--quiet(-qfor short) keep indextool quiet - it will not output banner, etc.
The commands are as follows:
--checkconfigjust loads and verifies the config file to check if it's valid, without syntax errors. This option was added in version 2.1.1-beta.--build-infixes INDEXNAMEbuild infixes for an existing dict=keywords index (upgrades .sph, .spi in place). You can use this option for legacy index files that already use dict=keywords, but now need to support infix searching too; updating the index files with indextool may prove easier or faster than regenerating them from scratch with indexer. This option was added in version 2.1.1-beta.--dumpheader FILENAME.sphquickly dumps the provided index header file without touching any other index files or even the configuration file. The report provides a breakdown of all the index settings, in particular the entire attribute and field list. Prior to 0.9.9-rc2, this command was present in now removed CLI search utility.--dumpconfig FILENAME.sphdumps the index definition from the given index header file in (almost) compliantsphinx.conffile format. Added in version 2.0.1-beta.--dumpheader INDEXNAMEdumps index header by index name with looking up the header path in the configuration file.--dumpdict INDEXNAMEdumps dictionary. This was added in version 2.1.1-beta.--dumpdocids INDEXNAMEdumps document IDs by index name. It takes the data from attribute (.spa) file and therefore requires docinfo=extern to work.--dumphitlist INDEXNAME KEYWORDdumps all the hits (occurrences) of a given keyword in a given index, with keyword specified as text.--dumphitlist INDEXNAME --wordid IDdumps all the hits (occurrences) of a given keyword in a given index, with keyword specified as internal numeric ID.--fold INDEXNAME OPTFILEThis options is useful too see how actually tokenizer proceeds input. You can feed indextool with text from file if specified or from stdin otherwise. The output will contain spaces instead of separators (accordingly to your charset_table settings) and lowercased letters in words.--htmlstrip INDEXNAMEfilters stdin using HTML stripper settings for a given index, and prints the filtering results to stdout. Note that the settings will be taken from sphinx.conf, and not the index header.--morph INDEXNAMEapplies morphology to the given stdin and prints the result to stdout.--check INDEXNAMEchecks the index data files for consistency errors that might be introduced either by bugs inindexerand/or hardware faults. Starting with version 2.1.1-beta,--checkalso works on RT indexes, RAM and disk chunks.--strip-pathstrips the path names from all the file names referenced from the index (stopwords, wordforms, exceptions, etc). This is useful for checking indexes built on another machine with possibly different path layouts.--optimize-rt-klistsoptimizes the kill list memory use in the disk chunk of a given RT index. That is a one-off optimization intended for rather old RT indexes, created by development versions prior to 1.10-beta release. As of 1.10-beta releases, this kill list optimization (purging) should happen automatically, and there should never be a need to use this option.--rotateworks only with--checkand defines whether to check index waiting for rotation, i.e. with .new extension. This is useful when you want to check your index before actually using it.
