Command Line Interface
Below are the available commands for the Search Ultimate module.
Running Reindex from console
Console reindexing can be performed for the entire store (without mode options), a specific index (see Managing Indexes), or a chosen store.
bin/magento mirasvit:search:reindex
Possible options are:
| Option | Description |
|---|---|
| --index=catalogsearch_fulltext | allows reindexing of a specific index. For example, to reindex only the Catalog Search index, use catalogsearch_fulltext. |
| --store=2 | allows reindexing of all indices for the store with ID 2. |
You can get the possible index codes directly in the console by executing the following command:
bin/magento mirasvit:search:reindex --index=default
Command options can be combined:
bin/magento mirasvit:search:reindex --index=catalogsearch_fullindex --store=2
Managing Stopwords from console
Console stopword management allows you to import and remove stopwords. To remove stopwords, use the following command:
bin/magento mirasvit:search:stopword
Possible options are:
| Option | Description |
|---|---|
| --file=stopwords.csv | defines, which CSV file will be used for stopwords importing. Format of CSV file, which is used for managing stopwords, can be seen here.!!!!!!!! |
| --remove | the command to remove stopwords instead of importing them. This requires the previous option. |
| --store=2 | required argument that forces the import/remove action to be performed only on a specific store (e.g., store ID=2). |
Managing Synonyms from console
Console synonym management allows you to import and remove synonyms. To remove synonyms, use the following command:
bin/magento mirasvit:search:synonym
Possible options are:
| Option | Description |
|---|---|
| --file=synonyms.csv | defines, which CSV file will be used for synonyms importing. Format of CSV file, which is used for managing synonyms, can be seen here.!!!!!!!! |
| --remove | the command to remove synonyms instead of importing them. This requires the previous option. |
| --store=2 | required argument that forces the import/remove action to be performed only on a specific store (e.g., store ID=2). |
There is no console command to export synonyms or stopwords. To back them up or move them to another store, see Exporting synonyms and Exporting stopwords.
Managing Search Sphinx from console
bin/magento mirasvit:search-sphinx:manage
Console management of Search Sphinx includes the following commands:
| Option | Description |
|---|---|
| --start | starts the Search Daemon. |
| --stop | stops the Search Daemon. |
| --restart | kills the Search Daemon process and starts it with clean data. |
| --reset | clears temporary search data. |
| --status | displays current status of Search Sphinx engine. |
| --ensure | special command that automatically checks the status and starts the daemon only if it is not running. |