How to disable _all field in production mode?


(Majid Zarrin) #1

Hello
I had Elasticsearh v5.6.2 and I do upgrade to v6.0.1.
I expected Elasticsearch removes _all field because I didn't explicitly declare it as true on the mapping but it didn't.
Is there any way that I disable _all field in production mode?
thank you.


(Mark Walkom) #2

See https://www.elastic.co/guide/en/elasticsearch/reference/6.0/mapping-all-field.html


(Majid Zarrin) #3

Thank you @warkolm,
I tried that before but I got an error on disabling _all .

#1 try
PUT /users/_mapping/messages
{
"_all": {
"enabled": false
}
}
#1 response
{
"error": {
"root_cause": [
{
"type": "illegal_argument_exception",
"reason": "mapper [_all] enabled is true now encountering false"
}
],
"type": "illegal_argument_exception",
"reason": "mapper [_all] enabled is true now encountering false"
},
"status": 400
}
#2 try
PUT /users
{
"mapping": {
"messages": {
"_all": {
"enabled": false
}
}
}
}
#2 response
{
"error": {
"root_cause": [
{
"type": "illegal_argument_exception",
"reason": "unknown setting [index.mapping.messages._all.enabled] please check that any required plugins are installed, or check the breaking changes documentation for removed settings"
}
],
"type": "illegal_argument_exception",
"reason": "unknown setting [index.mapping.messages._all.enabled] please check that any required plugins are installed, or check the breaking changes documentation for removed settings"
},
"status": 400
}


(Lucas Fernandes) #4

I have the same issue. I'm trying to disable _all to update to ES 6.1 but i get this error:

{"type":"illegal_argument_exception","reason":"mapper [_all] enabled is true now encountering false"}

(David Pilato) #5

You don't need to enable or disable it anymore. It's not a field anymore but a feature.


(system) #6

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