Tech:CirrusSearch

Troubleshooting

illegal_argument_exception: no mapping found for field [suggest]

This was seen in T13277 and T13334 when checking Greylog for a failed search request. This error is related to #Primary index was expected to be an alias, and it can be fixed by fixing that as well.

Primary index was expected to be an alias

This was first seen in T13334 when running CirrusSearch:UpdateSearchIndexConfig on a wiki exhibiting “illegal_argument_exception: no mapping found for field [suggest]”. Unfortunately, it is not yet known what causes this. For now, this can be worked around by manually deleting the wiki’s indices:

$ curl -X DELETE https://opensearch-mw.wikitide.net/testwiki_{content,general}

The output should be

{"acknowledged":true}{"acknowledged":true}

.

Afterwards, rebuild the search index from scratch. This would normally incur downtime for searching, but considering that searching is already broken, this doesn’t really matter. Instructions (copied from CirrusSearch README):

$ mwscript CirrusSearch:UpdateSearchIndexConfig testwiki --startOver
$ mwscript CirrusSearch:ForceSearchIndex testwiki

This problem was once recorded to have happened ever since CirrusSearch was enabled on the wiki (T13277#266442).


Go to Source →