这是我的logstash.conf
:
input {
http {
host => "127.0.0.1"
port => 31311
}
}
output {
elasticsearch {
hosts => ["http://localhost:9200"]
}
stdout {
codec => "rubydebug"
}
}
作为测试,我在PowerShell中运行了以下命令:
C:\ Users \ Me \ Downloads \ curl-7.64.1-win64-mingw \ bin>。\ curl.exe -XPUT “ http://127.0.0.1:31311/customer?pretty”
在我的Logstash
控制台上,按预期,我看到了以下输出:
{
"@timestamp" => 2019-04-08T13:45:40.267Z,
"headers" => {
"http_host" => "127.0.0.1:31311",
"http_user_agent" => "curl/7.64.1",
"request_path" => "/customer?pretty",
"content_length" => "0",
"request_method" => "PUT",
"http_version" => "HTTP/1.1",
"http_accept" => "*/*"
},
"host" => "127.0.0.1",
"@version" => "1",
"message" => ""
}
然后我运行以下命令:
C:\ Users \ Me \ Downloads \ curl-7.64.1-win64-mingw \ bin>。\ curl.exe -XGET “ http://127.0.0.1:9200/_cat/indices?v”
我希望看到customer
索引也是在我的ES服务器上创建的;但是,我所看到的只是
health status index uuid pri rep docs.count docs.deleted store.size pri.store.size
有一组空结果。
我想念什么?