Server issue ES - 2.0.1 - enable stemming


Well-known member
Affected version
I tried to enable stemming after the latest upgrade. This also wasn't working in 2.0. I get the following error after clicking Save when enabling stemming, for English:

XFES\Elasticsearch\RequestException: Unknown error (HTTP code: 401) in src/addons/XFES/Elasticsearch/Api.php at line 387

  1. XFES\Elasticsearch\Api->request() in src/addons/XFES/Elasticsearch/Api.php at line 312
  2. XFES\Elasticsearch\Api->requestFromIndex() in src/addons/XFES/Elasticsearch/Api.php at line 299
  3. XFES\Elasticsearch\Api->closeIndex() in src/addons/XFES/Service/Analyzer.php at line 27
  4. XFES\Service\Analyzer->updateAnalyzer() in src/addons/XFES/Admin/Controller/EnhancedSearch.php at line 205
  5. XFES\Admin\Controller\EnhancedSearch->actionIndexConfig() in src/XF/Mvc/Dispatcher.php at line 249
  6. XF\Mvc\Dispatcher->dispatchClass() in src/XF/Mvc/Dispatcher.php at line 88
  7. XF\Mvc\Dispatcher->dispatchLoop() in src/XF/Mvc/Dispatcher.php at line 41
  8. XF\Mvc\Dispatcher->run() in src/XF/App.php at line 1880
  9. XF\App->run() in src/XF.php at line 328
  10. XF::runApp() in admin.php at line 13
FWIW, I think this is probably because how you're connecting to Elasticsearch doesn't have all of the permissions. (This is generally done via a layer in front of Elasticsearch or with something like X-Pack.)

We assume full permissions available when connecting to Elasticsearch (to create indexes and close/re-open them as necessary).
Thanks @Mike - did something change in how this works when comparing xf 1.x to xf 2.x? It broke when I upgraded to xf 2.x (and it's still a problem). AFAIK all the permissions should be OK.
On XF 1.5, it was the same behaviour - you couldn't change stemming. It just silently failed, didn't throw an error there.

@Mike @Chris D That's the most open policy on AWS:
Allow open access to the domain

This policy is not recommended because it allows anyone to delete, modify, or access indexes and documents in your domain. It is intended only as a convenience for testing. Don't load sensitive data to a domain that has these settings.
  "Version": "2012-10-17",
  "Statement": [
      "Effect": "Allow",
      "Principal": {
        "AWS": [
      "Action": [
      "Resource": "your_arn"

I can create and delete the indices over Kibana and a shell without authentication. And creating indices is possible via XF. Does XF need anything else?
Top Bottom