{
"error": {
"root_cause": [
{
"type": "illegal_argument_exception",
"reason": "unknown setting [index.atype_id] please check that any required plugins are installed, or check the breaking changes documentation for removed settings"
}
],
"type": "illegal_argument_exception",
"reason": "unknown setting [index.atype_id] please check that any required plugins are installed, or check the breaking changes documentation for removed settings",
"suppressed": [
{
"type": "illegal_argument_exception",
"reason": "unknown setting [index.id] please check that any required plugins are installed, or check the breaking changes documentation for removed settings"
},
{
"type": "illegal_argument_exception",
"reason": "unknown setting [index.name] please check that any required plugins are installed, or check the breaking changes documentation for removed settings"
},
{
"type": "illegal_argument_exception",
"reason": "unknown setting [index.package] please check that any required plugins are installed, or check the breaking changes documentation for removed settings"
},
{
"type": "illegal_argument_exception",
"reason": "unknown setting [index.rank] please check that any required plugins are installed, or check the breaking changes documentation for removed settings"
},
{
"type": "illegal_argument_exception",
"reason": "unknown setting [index.state] please check that any required plugins are installed, or check the breaking changes documentation for removed settings"
},
{
"type": "illegal_argument_exception",
"reason": "unknown setting [index.status] please check that any required plugins are installed, or check the breaking changes documentation for removed settings"
}
]
},
"status": 400
}

当出现   illegal_argument_exception 时候 意思是非法参数异常。也就是URI 缺少参数。在创建Elasticsearch的index 有一个 type (也就是Mysql数据中的表名), 在curl的时候没有输入这个type的话

就会报错

unknown setting [index.status] please check that any required plugins are installed, or check the breaking changes documentation for removed settings出现这个错误,这个错误就说明 你在插入数据的时候 不知道你要把你的这条数据插入到哪个表里面去,所以就报错了。类似于Mysql 因为要指定一张表的插入,不能随便插入不是。。。。

所以 正确的方法 URL 是

curl -H "Content-Type: application/json" -X PUT 'http://localhost:9200/index/type' -d

  

  

Elasticsearch PUT 插入数据的更多相关文章

  1. Elasticsearch教程(七) elasticsearch Insert 插入数据(Java)

    首先我不赞成再采用一些中间件(jar包)来解决和 Elasticsearch  之间的交互,比如 Spring-data-elasticsearch.jar 系列一样,用就得依赖它.而 Elastic ...

  2. 第五篇 elasticsearch express插入数据

    1.后端 在elasticsearch.js文件夹下添加: function addDocument(document) { return elasticClient.index({ index: i ...

  3. elasticsearch REST API方式批量插入数据

    elasticsearch REST API方式批量插入数据 1:ES的服务地址  http://127.0.0.1:9600/_bulk 2:请求的数据体,注意数据的最后一行记得加换行 { &quo ...

  4. 使用Hive或Impala执行SQL语句,对存储在Elasticsearch中的数据操作(二)

    CSSDesk body { background-color: #2574b0; } /*! zybuluo */ article,aside,details,figcaption,figure,f ...

  5. 使用Hive或Impala执行SQL语句,对存储在Elasticsearch中的数据操作

    http://www.cnblogs.com/wgp13x/p/4934521.html 内容一样,样式好的版本. 使用Hive或Impala执行SQL语句,对存储在Elasticsearch中的数据 ...

  6. 用elasticsearch索引mongodb数据

    参照网页:单机搭建elasticsearch和mongodb的river 三个步骤: 一,搭建单机replicSet二,安装mongodb-river插件三,创建meta,验证使用 第一步,搭建单机m ...

  7. 用Elasticsearch做大规模数据的多字段、多类型索引检索

    本文同时发布在我的个人博客 之前尝试了用mysql做大规模数据的检索优化,可以看到单字段检索的情况下,是可以通过各种手段做到各种类型索引快速检索的,那是一种相对简单的场景. 但是实际应用往往会复杂一些 ...

  8. python批量插入数据到es和读取es数据

    一.插入数据 1.首先准备类似如下数据 {"_type": "type1", "_id": 1, "_index": & ...

  9. 在ES批量插入数据超时时自动重试

    当我们使用ES批量插入数据的时候,一般会这样写代码: from elasticsearch import Elasticsearch,helpers es =Elasticsearch(hosts=[ ...

随机推荐

  1. 脚本自动统计安卓log中Anr、Crash等出现的数量(Python)

    作为测试,在测试工作中一定会经常抓log,有时log收集时间很长,导致log很大,可能达到几G,想找到能打开如此大的log文件的工具都会变得困难:即使log不大时,我们可以直接把log发给开发同学去分 ...

  2. CountDownLatch(闭锁)、Semaphore(信号量)、CyclicBarrier

    一.CountDowmLatch(闭锁)(倒计数锁存器) CountDownLatch类位于java.util.concurrent包下,在完成某些运算时,只有其他所有线程的运算全部完成,当前运算才继 ...

  3. wamp环境下composer及laravel的安装配置

    laravel: PHP Web开发框架 composer: PHP 的一个依赖管理工具.它允许你申明项目所依赖的代码库,它会在你的项目中为你安装他们. 一.composer安装 参考:Windows ...

  4. HTTP相关知识总结

    HTTP协议特点 支持客户端/服务器模式 简单快速 灵活.允许传输任意类型的数据对象 限制每次连接只处理一个请求(http最初设计思想,现在为了提升传输效率,一次请求完成后不会立即断开连接) 无连接: ...

  5. css为图片添加一层蒙版并在上层显示文字等

    效果图: 代码如下: <div class="row" style="width:100%; position:relative;z-index:1;margin: ...

  6. qt 网络库使用介绍

    qt 网络库使用介绍 在.pro文件中,要手动添加network模块:QT += network 有三个核心类, QNetworkAccessManager: 发送get或者post请求. 用get方 ...

  7. Shell命令-系统信息及显示之df、top

    文件及内容处理 - df.top 1. df:报告文件系统磁盘空间的使用情况 df命令的功能说明 df 命令用于显示目前在Linux系统上的文件系统的磁盘使用情况统计. df命令的语法格式 df [O ...

  8. 1、mongoDB服务器的搭建与连接

    下载----编译----安装之后: 1.首先,创建一个mongodb_simple的目录,进入到目录中. 2.创建文件夹:data,用来存储数据库的数据文件. 3.创建文件夹:log,用来存储数据库的 ...

  9. CMD控制台如何把XXX.sql导入到数据库

    mysql -u root -proot <"F:\Git\cyb.sql" 注意:mysql -u 用户名 -p没有空格加上密码 <"sql文件的路径&qu ...

  10. (五)Amazon Lightsail 部署LAMP应用程序之迁移到Amazon RDS实例

    迁移到您的Amazon RDS实例 在某些时候,您的应用程序需求可能需要在 Amazon Lightsail中找不到的功能.幸运的是,将应用程序的一个或所有部分移动到其他AWS服务中非常简单 您将数据 ...