kibana从7.0降级到6.8启动报错

 log   [01:05:02.064] [warning][browser-driver][reporting] Enabling the Chromium sandbox provides an additional layer of protection.
  log   [01:05:02.065] [warning][reporting] Generating a random key for xpack.reporting.encryptionKey. To prevent pending reports from failing on restart, please set xpack.reporting.encryptionKey in kibana.yml
  log   [01:05:02.092] [info][status][plugin:reporting@6.8.0] Status changed from uninitialized to green - Ready
  log   [01:05:02.491] [warning][task_manager] Task vis_telemetry "oss_telemetry-vis_telemetry" failed in attempt to run: [version_conflict_engine_exception] [_doc][oss_telemetry-vis_telemetry]: version conflict, required seqNo [4], primary term [1]. current document has seqNo [5] and primary term [1], with { index_uuid="0XW9whzqSM2kTmvA9aBJoQ" & shard="0" & index=".kibana_task_manager" }
  log   [01:05:02.499] [error][status][plugin:spaces@6.8.0] Status changed from yellow to red - Index .kibana belongs to a version of Kibana that cannot be automatically migrated. Reset it or use the X-Pack upgrade assistant.
  log   [01:05:02.501] [fatal][root] { Error: Index .kibana belongs to a version of Kibana that cannot be automatically migrated. Reset it or use the X-Pack upgrade assistant.
    at assertIsSupportedIndex (/opt/es/kibana-6.8.0-linux-x86_64/src/server/saved_objects/migrations/core/elastic_index.js:246:15)
    at Object.fetchInfo (/opt/es/kibana-6.8.0-linux-x86_64/src/server/saved_objects/migrations/core/elastic_index.js:52:12)
  isBoom: true,
  isServer: true,
  data: null,
  output:
   { statusCode: 500,
     payload:
      { statusCode: 500,
        error: 'Internal Server Error',
        message: 'An internal server error occurred' },
     headers: {} },
  reformat: [Function],
  [Symbol(SavedObjectsClientErrorCode)]: 'SavedObjectsClient/generalError' }

 FATAL  Error: Index .kibana belongs to a version of Kibana that cannot be automatically migrated. Reset it or use the X-Pack upgrade assistant.

 

 

 

https://www.elastic.co/guide/en/kibana/6.0/migrating-6.0-index.html

 

 

The following will make transformations to your Kibana index. It is recommended you backup your Kibana index prior to running any of the following commands.

In order to migrate to Kibana 6, your Kibana index needs to be reindexed. This will make transformations to the data model, removing types which are being removed in Elasticsearch.

A UI is available in X-Pack 5.6 to assist with the migration. The following is provided should you be required to run the migration manually. The commands assume you’re using the default .kibana index, without an alias. If kibana.index is set to something different in your kibana.yml, or you’re using an alias, you will need to modify the commands.

 

To perform this migration without downtime, you will need to be running Kibana 5.6. This is the only version which supports both of the index types. When running 5.6, add "index.format": 6 and "index.mapping.single_type": true under settings in the second step to ensure additional types will not be added after migrating.

  1. Set .kibana index to read-only:

    PUT .kibana/_settings
    {
      "index.blocks.write": true
    }

    Copy as cURLView in Console 

  2. Create .kibana-6 index

    PUT .kibana-6
    {
      "settings" : {
        "number_of_shards" : 1,
        "index.mapper.dynamic": false
      },
      "mappings" : {
        "doc": {
          "properties": {
            "type": {
              "type": "keyword"
            },
            "updated_at": {
              "type": "date"
            },
            "config": {
              "properties": {
                "buildNum": {
                  "type": "keyword"
                }
              }
            },
            "index-pattern": {
              "properties": {
                "fieldFormatMap": {
                  "type": "text"
                },
                "fields": {
                  "type": "text"
                },
                "intervalName": {
                  "type": "keyword"
                },
                "notExpandable": {
                  "type": "boolean"
                },
                "sourceFilters": {
                  "type": "text"
                },
                "timeFieldName": {
                  "type": "keyword"
                },
                "title": {
                  "type": "text"
                }
              }
            },
            "visualization": {
              "properties": {
                "description": {
                  "type": "text"
                },
                "kibanaSavedObjectMeta": {
                  "properties": {
                    "searchSourceJSON": {
                      "type": "text"
                    }
                  }
                },
                "savedSearchId": {
                  "type": "keyword"
                },
                "title": {
                  "type": "text"
                },
                "uiStateJSON": {
                  "type": "text"
                },
                "version": {
                  "type": "integer"
                },
                "visState": {
                  "type": "text"
                }
              }
            },
            "search": {
              "properties": {
                "columns": {
                  "type": "keyword"
                },
                "description": {
                  "type": "text"
                },
                "hits": {
                  "type": "integer"
                },
                "kibanaSavedObjectMeta": {
                  "properties": {
                    "searchSourceJSON": {
                      "type": "text"
                    }
                  }
                },
                "sort": {
                  "type": "keyword"
                },
                "title": {
                  "type": "text"
                },
                "version": {
                  "type": "integer"
                }
              }
            },
            "dashboard": {
              "properties": {
                "description": {
                  "type": "text"
                },
                "hits": {
                  "type": "integer"
                },
                "kibanaSavedObjectMeta": {
                  "properties": {
                    "searchSourceJSON": {
                      "type": "text"
                    }
                  }
                },
                "optionsJSON": {
                  "type": "text"
                },
                "panelsJSON": {
                  "type": "text"
                },
                "refreshInterval": {
                  "properties": {
                    "display": {
                      "type": "keyword"
                    },
                    "pause": {
                      "type": "boolean"
                    },
                    "section": {
                      "type": "integer"
                    },
                    "value": {
                      "type": "integer"
                    }
                  }
                },
                "timeFrom": {
                  "type": "keyword"
                },
                "timeRestore": {
                  "type": "boolean"
                },
                "timeTo": {
                  "type": "keyword"
                },
                "title": {
                  "type": "text"
                },
                "uiStateJSON": {
                  "type": "text"
                },
                "version": {
                  "type": "integer"
                }
              }
            },
            "url": {
              "properties": {
                "accessCount": {
                  "type": "long"
                },
                "accessDate": {
                  "type": "date"
                },
                "createDate": {
                  "type": "date"
                },
                "url": {
                  "type": "text",
                  "fields": {
                    "keyword": {
                      "type": "keyword",
                      "ignore_above": 2048
                    }
                  }
                }
              }
            },
            "server": {
              "properties": {
                "uuid": {
                  "type": "keyword"
                }
              }
            },
            "timelion-sheet": {
              "properties": {
                "description": {
                  "type": "text"
                },
                "hits": {
                  "type": "integer"
                },
                "kibanaSavedObjectMeta": {
                  "properties": {
                    "searchSourceJSON": {
                      "type": "text"
                    }
                  }
                },
                "timelion_chart_height": {
                  "type": "integer"
                },
                "timelion_columns": {
                  "type": "integer"
                },
                "timelion_interval": {
                  "type": "keyword"
                },
                "timelion_other_interval": {
                  "type": "keyword"
                },
                "timelion_rows": {
                  "type": "integer"
                },
                "timelion_sheet": {
                  "type": "text"
                },
                "title": {
                  "type": "text"
                },
                "version": {
                  "type": "integer"
                }
              }
            },
            "graph-workspace": {
              "properties": {
                "description": {
                  "type": "text"
                },
                "kibanaSavedObjectMeta": {
                  "properties": {
                    "searchSourceJSON": {
                      "type": "text"
                    }
                  }
                },
                "numLinks": {
                  "type": "integer"
                },
                "numVertices": {
                  "type": "integer"
                },
                "title": {
                  "type": "text"
                },
                "version": {
                  "type": "integer"
                },
                "wsState": {
                  "type": "text"
                }
              }
            }
          }
        }
      }
    }

    Copy as cURLView in Console 

  3. Reindex .kibana into .kibana-6:

    POST _reindex
    {
      "source": {
        "index": ".kibana"
      },
      "dest": {
        "index": ".kibana-6"
      },
      "script": {
        "inline": "ctx._source = [ ctx._type : ctx._source ]; ctx._source.type = ctx._type; ctx._id = ctx._type + \":\" + ctx._id; ctx._type = \"doc\"; ",
        "lang": "painless"
      }
    }

    Copy as cURLView in Console 

  4. Alias .kibana-6 to .kibana and remove legacy .kibana index:

    POST /_aliases
    {
      "actions" : [
        { "add":  { "index": ".kibana-6", "alias": ".kibana" } },
        { "remove_index": { "index": ".kibana" } }
      ]
    }

    Copy as cURLView in Console

 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值