Elasticsearch必备技能之索引迁移
将ES中的索引拷贝到其他ES中,是不是很重要呢?
长话短说,推荐一个工具:
一、elasticsearch-dump
安装:
#yum install epel-release
#yum install nodejs
#yum install npm
#npm install elasticdump
#cd node_modules/elasticdump/bin
# pwd
/home/tp/node_modules/elasticdump
# ls -al
total 388
drwxr-xr-x 2 root root 4096 Mar 21 15:46 bin
-rw-r--r-- 1 root root 174 Mar 18 2016 Dockerfile
-rw-r--r-- 1 root root 299251 Mar 15 2014 elasticdump.jpg
-rw-r--r-- 1 root root 6172 Feb 2 23:47 elasticdump.js
drwxr-xr-x 2 root root 4096 Jul 13 2016 .github
drwxr-xr-x 3 root root 4096 Mar 21 15:46 lib
-rw-r--r-- 1 root root 11356 May 22 2014 LICENSE.txt
drwxr-xr-x 10 root root 4096 Mar 21 15:46 node_modules
-rw-r--r-- 1 root root 44 May 22 2014 .npmignore
-rw-r--r-- 1 root root 15135 Mar 21 15:46 package.json
-rw-r--r-- 1 root root 13335 Dec 14 06:20 README.md
drwxr-xr-x 3 root root 4096 Mar 21 15:46 test
-rw-r--r-- 1 root root 1150 Dec 2 07:54 .travis.yml
使用:
#拷贝analyzer如分词
elasticdump \
--input=http://production.es.com:9200/old_index \
--output=http://staging.es.com:9200/new_index \
--type=analyzer
#拷贝映射
elasticdump \
--input=http://production.es.com:9200/old_index \
--output=http://staging.es.com:9200/new_index \
--type=mapping
#拷贝数据
elasticdump \
--input=http://production.es.com:9200/lod_index \
--output=http://staging.es.com:9200/new_index \
--type=data
OK ! 迁移成功。

推荐阅读:
Elasticsearch必备技能之索引迁移的更多相关文章
- 自动化部署必备技能—部署yum仓库、定制rpm包
部署yum仓库.定制rpm包 目录 第1章 扩展 - yum缓存 1.1 yum缓存使用步骤... 1 1.1.1 导言... 1 1.1.2 修改配置文件... 1 1.1.3 使用缓存... 1 ...
- Android高工必备技能
转载:http://www.jianshu.com/p/d791bbede02c Step 1. 玩转RxJava 使用RxJava处理异步极其方便,各种操作符可以对数据做流水线式操作,再加上与Ret ...
- 详解linux运维工程师入门级必备技能
详解linux运维工程师入门级必备技能 | 浏览:659 | 更新:2013-12-24 23:23 | 标签:linux it自动化运维就是要很方便的运用各种工具进行管理维护,有效的实施服务器保护 ...
- 【转帖】系统软件工程师必备技能-进程内存的working set size(WSS)测量
系统软件工程师必备技能-进程内存的working set size(WSS)测量 2018年12月28日 18:43:01 Linuxer_ 阅读数:145 https://blog.csdn.net ...
- SQL Server管理员必备技能之性能优化
SQL Server管理员必备技能之性能优化 高文龙关注1人评论1171人阅读2017-09-22 08:27:41 SQL Server 作为企业必不可少的服务之一,所以对于管理员的日常运维是一个极 ...
- Mysql 索引迁移策略
Mysql 索引迁移策略 近日在核查项目中的一些慢sql时发现一个很鸡仔儿的问题,本地开发库表中索引跟生产上差距很大,又因为生产库登录各种麻烦,需要各种验证码,那么多的慢sql分给好些个人,不可能让大 ...
- 高级Linux运维工程师必备技能(扫盲篇)
高级Linux运维工程师必备技能(扫盲篇) 作者:尹正杰 版权声明:原创作品,谢绝转载!否则将追究法律责任. 在了解文件系统之前,我们要学习一下磁盘存储数据的方式,大家都知道文件从内存若要持久化存储的 ...
- 百度Hr分享,一个合格的数据工程师简历中必备技能?
如果你是一名数据科学方面的求职者,你肯定想知道在简历上写些什么才能获得面试的机会:如果你想进入这个领域,你一定想知道具备哪些技术才能成为一名有竞争力的求职者. 在本文中,我们对Indeed中一千份数据 ...
- 第三百六十二节,Python分布式爬虫打造搜索引擎Scrapy精讲—elasticsearch(搜索引擎)基本的索引和文档CRUD操作、增、删、改、查
第三百六十二节,Python分布式爬虫打造搜索引擎Scrapy精讲—elasticsearch(搜索引擎)基本的索引和文档CRUD操作.增.删.改.查 elasticsearch(搜索引擎)基本的索引 ...
随机推荐
- #Java学习之路——基础阶段(第六篇)
我的学习阶段是跟着CZBK黑马的双源课程,学习目标以及博客是为了审查自己的学习情况,毕竟看一遍,敲一遍,和自己归纳总结一遍有着很大的区别,在此期间我会参杂Java疯狂讲义(第四版)里面的内容. 前言: ...
- [Swift]LeetCode158. 用Read4来读取N个字符II $ Read N Characters Given Read4 II
The API: int read4(char *buf) reads 4 characters at a time from a file. The return value is the actu ...
- [Swift]LeetCode238. 除自身以外数组的乘积 | Product of Array Except Self
Given an array nums of n integers where n > 1, return an array outputsuch that output[i] is equa ...
- [Swift]LeetCode437. 路径总和 III | Path Sum III
You are given a binary tree in which each node contains an integer value. Find the number of paths t ...
- [Swift]LeetCode956. 最高的广告牌 | Tallest Billboard
You are installing a billboard and want it to have the largest height. The billboard will have two ...
- [Abp 源码分析]二、模块系统
0.简介 整个 Abp 框架由各个模块组成,基本上可以看做一个程序集一个模块,不排除一个程序集有多个模块的可能性.可以看看他官方的这些扩展库: 可以看到每个项目文件下面都会有一个 xxxModule ...
- 课程五(Sequence Models),第三周(Sequence models & Attention mechanism) —— 2.Programming assignments:Trigger word detection
Expected OutputTrigger Word Detection Welcome to the final programming assignment of this specializa ...
- java代码之美(2)---Java8 Stream
Stream 第一次看到Stream表达式就深深把我吸引,用它可以使你的代码更加整洁而且对集合的操作效率也会大大提高,如果你还没有用到java8的Stream特性,那就说明你确实out啦. 一.概述 ...
- Android--MediaRecorder录音录像
前言 Android除了支持播放多媒体文件之外,还可以从对应的硬件中捕获多媒体,比如从麦克风录音.从摄像头录像等.本篇博客讲解一下Android下如何通过MediaRecorder进行录音以及录像的步 ...
- 《连连看》算法c语言演示(自动连连看)
(图片是游戏的示意图,来自互联网,与本文程序无关) 看题目就知道是写给初学者的,没需要的就别看了,自己都觉得怪无聊的. 很多游戏的耐玩性都来自精巧的算法,特别是人工智能的水平.比如前几天看了著名的Al ...