Elastic Search - Limit of total fields [1000] - How to set in Docker compose file?

I use ES 6.24 what is running via Docker image configured in docker compose file.
After some time I got error Limit of total fields [1000] in index my_index has been exceeded.
I tried to use set this limit in environment part:
environment: - FIELDS_LIMIT=3000
but the error still occurs. When I used command bellow the size was increased
curl -X PUT "localhost:9200/_all/_settings" -d '{"template": "*","order": 0,"settings": {"index": {"mapping": {"total_fields": { "limit": 3000 }}}}}'

Is any solution for this issue?
I tried to add the curl command to command property in yml file but it failed. Probably because the ES hasn't started yet.

That setting can not be set through the configuration file so the best option is probably to add an index template.

What ES version supports property FIELDS_LIMIT? I used for test image with 7.16.1 and there were fields limit set correctly by this property. Is it 7.X.X and above?

If that is a feature that has been available, I was not aware of it. I therefore do not think I can help much.

Please note that version is EOL and no longer supported, you should be looking to upgrade as a matter of urgency.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.