我想在我的Mac上運行logstash配置文件,但每次我這樣做,我得到這個錯誤:未知設置「託管」的elasticsearch
'Unknown setting 'hosts' for elasticsearch {:level=>:error}
Error: Something is wrong with your configuration.
You may be interested in the '--configtest' flag which you can
use to validate logstash's configuration before you choose
to restart a running system.'
我檢索JIRA數據並將其發送給elasticsearch ,但即使這個簡單的任務也會返回一個錯誤。這裏是我的代碼:
input{
exec {
command => "curl -u username:password https://mycompany.atlassian.net/rest/api/latest/search?maxResults=10"
interval => 300
}
}
output{
elasticsearch{
hosts => ["127.0.0.1:9200"]
index => "test"
}
}
幫助我也是,在我的情況下,我使用的是更新的版本,但是遵循基於舊版本的教程。將主機更改爲主機,並且效果很好。 :) –