Kibana unaccessible after using Migration UI


(Tyler Smalley) #1

Who is affected?

Kibana installations originating prior to v5.5 and migrating the Kibana index using the Migration UI in v5.6.0 or v5.6.1

Details

Elastic v5.6 is a compatibility release, assisting users with upgrading to v6.x. This upgrade requires users to transform their index, removing the usage of types. There is more information related to this change in Elasticsearch here. In addition to providing information on how to perform this migration, we have also created a Migration UI. This UI not only gives information on deprecations but allows for one-click re-indexing for those internal indices which need re-indexed as well as indices created in Elasticsearch 2.x.

Issue

When the migration UI migrates the index, we are transforming the documents into a single type. After the migration, our compatibility layer attempts to write to the type and if that fails due to a TypeMissingException, we write to the single type created for v6.x.

Kibana installations prior to v5.5, did not disable dynamic mapping. This results in the type being automatically created and the field types inferred. The Kibana health check will then see multiple types and attempt to patch the mappings, resulting in a mapping error and Kibana not able to start.

The status page should look similar to the following:

A similar error will be in the Kibana logs: log [22:09:09.262] [error][status][plugin:elasticsearch@5.6.2] Status changed from yellow to red - [illegal_argument_exception] mapper [version] cannot be changed from type [long] to [integer] followed by a lot of attempts to add the mapping [info][elasticsearch] Adding mappings to kibana index for SavedObject type "visualization".

We have a script to address this issue. It will create a new index, re-indexing your existing data into it, converting the objects created with types back to the single type and disabling dynamic mapping.

1 - Download the fix:

The patch is available to download here. You can download directly to your workstation or server with curl, for example:

curl -L -O http://download.elastic.co/downloads/kibana/6-0-post-migration-fix.sh

2 - Run the hotfix

Without X-Pack Installed

If you are not using X-Pack then you need only specify a URL to a node in your cluster, for example:

./6-0-post-migration-fix.sh http://mycluster:9200

If you do not specify a URL, it defaults to http://localhost:92002

With X-Pack Installed

If you are using X-Pack and have the Security enabled, you'll need to pass credentials for a cluster user (assigned to the superuser built-in role), for example:

./6-0-post-migration-fix.sh https://mycluster:9200 elastic:mypassword


Kibana 5.6.1 remote transport exception
(Tyler Smalley) #2

(Tyler Smalley) #3

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