1.kibana等都统一版本了,5.4版本的kibana要5.4版本的elasticsearch
2.现有架构:
logstash
logstash读取日志--------》内网redis做队列------------------》写入elasticsearch集群--------》kibana读取集群数据
3.升级版本要求:
Upgrade From Upgrade To Supported Upgrade Type
1.x 5.x Reindex to upgrade
2.x 2.y Rolling upgrade (where y > x)
2.x 5.x Full cluster restart
5.0.0 pre GA 5.x Full cluster restart
5.x 5.y Rolling upgrade (where y > x)
不同主版本之间需要全部关停升级,同一个主版本可以短时间不同小版本es之间运行,高版本的es不会像低版本的同步shards
4.升级注意事项
/etc/sysctl.conf
vm.max_map_count = 262144
 
/etc/security/limits.conf
* soft nofile 655350
* hard nofile 655360
还有应用到的参数,很多改变了,需要提前修改
 
升级步骤:
1.配置项变更
2.禁用自动分片 disabled shard allocation
curl -XPUT 'localhost:9200/_cluster/settings?pretty' -H 'Content-Type: application/json' -d'
{
"persistent": {
"cluster.routing.allocation.enable": "none"
}
}
'
 
3.将内存数据同步到磁盘
curl -XPOST 'localhost:9200/_flush/synced?pretty'
A synced flush request is a “best effort” operation. It will fail if there are any pending indexing operations, but it is safe to reissue the request multiple times if necessary.
 
4.关闭节点,执行升级
升级详细步骤:
tips:这里是源码包升级
(1)解压到安装目录,不要覆盖原程序目录
(2)从老程序复制config下面的文件到新程序中
  • Either copy the files in the  directory from your old installation to your new installation, or set the environment variable  to the location of the  file and use the  option on the command line to point to an external config directory.
(3)复制老程序/data目录下的数据到新目录到新的数据目录或者改改路径到老目录
  • Either copy the files in the  directory from your old installation to your new installation, or configure the location of the data directory in the  file, with the  setting.
(4)更新所有插件
Elasticsearch plugins must be upgraded when upgrading a node. Use the  script to install the correct version of any plugins that you need.
5.启用节点,开始自动分片(会先变为yellow状态,最后变绿),查看是否加入集群
Start the now upgraded node and confirm that it joins the cluster by checking the log file or by checking the output of this request:
curl -XGET 'localhost:9200/_cat/nodes?pretty'
 
6.重新开始分片Reenable shard allocation
Once the node has joined the cluster, reenable shard allocation to start using the node:
curl -XPUT 'localhost:9200/_cluster/settings?pretty' -H 'Content-Type: application/json' -d'
{
"transient": {
"cluster.routing.allocation.enable": "all"
}
}
'
7.等集群恢复 Wait for the node to recover
ou should wait for the cluster to finish shard allocation before upgrading the next node. You can check on progress with the request。
snapshot and restore官方有提供一个升级兼容性检测工具: https://github.com/elastic/elasticsearch-migration/。 这个工具可以发现不兼容的集群配置项,这些配置项需要在部署5.x的时候按照建议做相应的修改。另外如果集群里有1.x创建的索引,这个工具也会指出来,并且可以直接在界面上点点按钮做reindex。
 
not_analyzed字段升级后依然是string / not_analyzed,并不会自动改成keyword,但是5.x可以兼容这个字段类型,数据写入没问题。
 
迁移帮助工具(elasticsearch-migration)
 
 
参考文档:
 
 

elk升级文档的更多相关文章

  1. 李洪强iOS开发之-环信02.1_环信 SDK 2.x到3.0升级文档

    李洪强iOS开发之-环信02.1_环信 SDK 2.x到3.0升级文档 SDK 2.x 至 3.0 升级指南 环信 SDK 3.0 升级文档 3.0 中的核心类为 EMClient 类,通过 EMCl ...

  2. ORACLE 12.1.0.1 至12.1.0.2升级文档(单机版 DBUA方式)

    12C DBUA新特性 1. 新的pre-upgrade 检查工具. 2. 并行升级. 3. DBUA升级时,默认并行度为CPU个数或2. 并行度可调整. 4. 在升级过程中,DBUA工具可再次调用( ...

  3. ELK安装文档

    ELK安装文档: http://cuidehua.blog.51cto.com/5449828/1769525 如何将客户端日志通过ogstash-forwarder发送给服务端的logstash h ...

  4. ELK的文档搭建

    一.安装elasticsearch 官网:https://www.elastic.co/guide/index.html https://www.elastic.co/guide/en/elastic ...

  5. ELK 部署文档

    1. 前言 在日常运维工作中,对于系统和业务日志的处理尤为重要.尤其是分布式架构,每个服务都会有很多节点,如果要手工一个一个的去取日志,运维怕是要累死. 简单介绍: ELK 是 elasticsear ...

  6. Filebeat+ELK部署文档

    在日常运维工作中,对于系统和业务日志的处理尤为重要.今天,在这里分享一下自己部署的Filebeat+ELK开源实时日志分析平台的记录过程,有不对的地方还望指出. 简单介绍: 日志主要包括系统日志.应用 ...

  7. ELK帮助文档

    elasticsearch: API中文指南:https://es.xiaoleilu.com/010_Intro/15_API.html 官方文档:https://www.elastic.co/cn ...

  8. struts2升级文档

    http://www.linuxdiyf.com/viewarticle.php?id=537212

  9. Redhat 6.7 x64升级SSH到OpenSSH_7.4p1完整文档

    原文链接:https://www.cnblogs.com/xshrim/p/6472679.html 导语 Redhat企业级系统的6.7版自带SSH版本为OpenSSH_5.3p1, 基于审计和安全 ...

随机推荐

  1. array数据初始化

    #include <iostream> int main() { ]={}; std::cout<<array[]<<]; } 试了试上面的代码发现,数组在用{}赋 ...

  2. js-offsetX、pageX、clientX、layerX、screenX

    真心地我也是懵逼的 clientX,clientY:针对屏幕有效区域,不包括滚动部分,坐标(0,0)一直在有效区域的左上角 X,Y:            针对屏幕有效区域,不包括滚动部分,坐标(0, ...

  3. 设置iframe高度自适应屏幕高度

    写在前面: 最近在搭建项目前台页面框子的时候,把iframe设置成了固定的高度,导致不同的电脑尺寸访问的时候,高度差异较大,故查了下,将iframe设置成自动适应屏幕高度的方式,这里记录下. 还是直接 ...

  4. Multithreading and Grand Central Dispatch on iOS for Beginners Tutorial

    Have you ever written an app where you tried to do something, and there was a long pause while the U ...

  5. andriod 读取通讯录

    package com.example.yanlei.wifi; import android.content.ContentResolver;import android.database.Curs ...

  6. MVC中自定义ViewPage和WebViewPage

    ViewPage和WebViewPage的作用就是将Controller中数据返回给页面,一个是针对aspx一个相对cshtml的.代码如下: public abstract class WebVie ...

  7. mysql 的常用查询

    Ø 基本常用查询 --select select * from student;   --all 查询所有 select all sex from student;   --distinct 过滤重复 ...

  8. [置顶] kubernetes将外部服务映射为内部服务

    在实际应用中,一般不会把mysql这种重IO.有状态的应用直接放入k8s中,而是使用专用的服务器来独立部署.而像web这种无状态应用依然会运行在k8s当中,这时web服务器要连接k8s管理之外的数据库 ...

  9. selenium 截图

    http://blog.csdn.net/u010953692/article/details/78320025 # coding:utf-8 # coding:cp936 from selenium ...

  10. input 中 datetime-local 方法

    <input  type=" datetime-local "> 这个标签是H5新增的对象方法 能把现有的时间赋值给它 但是注意:必须是  yyyy-MM-ddTHH: ...