Kibana:无法在 Sense Web 插件上导入 Shakespeare.json [英] Kibana: Cant import Shakespeare.json on Sense Web Plugin

查看:32
本文介绍了Kibana:无法在 Sense Web 插件上导入 Shakespeare.json的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试按照弹性搜索教程导入 Shakespeare.json.

I am trying to import shakespeare.json as per elastic search tutorial.

[环境]

  1. 弹性搜索 2.1
  2. Sense -Chrome 扩展

[背景]

当我粘贴 curl -XPUT localhost:9200/_bulk --data-binary @shakespeare.json在感知选项卡上(扩展程序打开一个带有 2 个窗口的新选项卡)它被转换为 PUT/_bulk 并且输出是

When I paste curl -XPUT localhost:9200/_bulk --data-binary @shakespeare.json on the sense tab(the extensions opens a new tab with 2 windows) It's converted to PUT /_bulk and the output is

{
   "error": {
      "root_cause": [
         {
            "type": "parse_exception",
            "reason": "Failed to derive xcontent"
         }
      ],
      "type": "parse_exception",
      "reason": "Failed to derive xcontent"
   },
   "status": 400
}

[我的发现]

  1. 我已经在本地下载了shakespeare.json,但我认为Sense不是能够找到文件所在的路径(可能是我的文件位置不正确)
  2. 我也尝试查找 Sense 的当前目录,但我不确定在 Windows 中在哪里可以找到该插件的 chrome-extension 的 index.html.
  3. 无论我找到什么文档,都是特定于 Linux 的.

感谢任何输入.

推荐答案

您不应该在 Sense 中执行此操作,而应从命令行执行此操作

You should not do this in Sense, but simply from the command line

curl -XPUT localhost:9200/_bulk --data-binary @shakespeare.json

如果 shakespeare.json 文件不在您所在的目录中,请确保指向它的正确路径.

Make sure to point to the correct path of the shakespeare.json file if it is not located in the directory you're in.

curl -XPUT localhost:9200/_bulk --data-binary @/path/to/shakespeare.json

更新

如果您在 Windows 上运行并且没有 cURL 命令,您可以在 https 下载 cURL://curl.haxx.se/download.html

If you run on Windows and you don't have the cURL command present, you can download cURL at https://curl.haxx.se/download.html

这篇关于Kibana:无法在 Sense Web 插件上导入 Shakespeare.json的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆