Hello,
Could someone help solve this problem? ES documentation says:
"A snapshot of an index created in 1.x can be restored to 2.x."
However when trying to restore an index I'm getting the following error:
{"error":{"root_cause":[{"type":"snapshot_restore_exception","reason":"[myRepo:all_01_24_2017] cannot restore index [source] because it cannot be upgraded"}],"type":"snapshot_restore_exception","reason":"[myRepo:all_01_24_2017] cannot restore index [source] because it cannot be upgraded","caused_by":{"type":"illegal_state_exception","reason":"unable to upgrade the mappings for the index [source], reason: [Field name [contents.contract.contractId] cannot contain '.']","caused_by":{"type":"mapper_parsing_exception","reason":"Field name [contents.contract.contractId] cannot contain '.'"}}},"status":500}
<<<
I'm not sure what to make of this error message, I could restore a similar index before (also with dots in field names) and there were no issues.
I'd appreciate any help in this matter.
Thanks,
Hello,
I checked index settings and it turned out that there was a field added that had a dot in its name. I thought dots were not treated as special characters by ES, but apparently that's the case.
Does anyone know if there is a doc that spells out which characters are illegal as far as index property/field names go?
Thanks,
You should be able to restore them to later versions in the 2.x branch that
re-added support for dots in field names. Hopefully someone else will chime
in for the exact version.
In case anyone else has this problem, you can manually edit the index definition file (JSON) for the given snapshot and remove the offending field. Snapshot will proceed without that field being included.
And yes the problem was that there was a field (a mapping entry) that included dots.
Thanks to all who answered,
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.