我在嘗試獲取Logstash,Elasticsearch & Kibana在我的Windows 7環境中工作的組合很困難。由於缺少索引錯誤導致Logstash無法導入文件
我已經設置了所有3個,他們似乎都運行良好,Logstash和Elasticsearch作爲Windows服務和Kibana作爲IIS中的網站運行。
Logstash從http://localhost:9200
運行我有一個Web應用程序中的.txt創建日誌文件的格式:
Datetime=[DateTime], Value=[xxx]
日誌文件會在此目錄中創建的:
D:\wwwroot\Logs\Errors\
我的logstash.conf文件如下所示:
input {
file {
format => ["plain"]
path => ["D:\wwwroot\Logs\Errors\*.txt"]
type => "testlog"
}
}
output {
elasticsearch {
embedded => true
}
}
我Kibana config.js文件看起來像這樣:
define(['settings'],
function (Settings) {
return new Settings({
elasticsearch: "http://localhost:9200",
kibana_index: "kibana-int",
panel_names: [
'histogram',
'map',
'pie',
'table',
'filtering',
'timepicker',
'text',
'fields',
'hits',
'dashcontrol',
'column',
'derivequeries',
'trends',
'bettermap',
'query',
'terms'
]
});
});
當我查看Kibana我看到的錯誤:
No index found at
http://localhost:9200/_all/_mapping
. Please create at least one index.If you're using a proxy ensure it is configured correctly.
我對如何創建索引不知道,所以如果任何人都可以對我做錯的事情有所瞭解,這將會很棒。
看起來有在elasticsearch沒有數據?你是否開始用logstash索引東西?日誌文件logstash指向什麼東西? – javanna
您是否在Windows中將logstash運行爲集中式或獨立版本?因爲我試圖找到一種在Windows中使用集中式選項的方法,但我不能。如果你做出任何幫助,對我來說將是非常寶貴的。 http://stackoverflow.com/questions/23907747/centralized-log-files-using-windows-server – foc