Kibana找不到logstash索引错误

ELK中kibana不出索引得错误

我们用 tail -f这个试试查看日志命令 看logstash

[2019-10-13T19:44:50,449][INFO ][logstash.outputs.elasticsearch] ES Output version determined {:es_version=>6}
[2019-10-13T19:44:50,474][WARN ][logstash.outputs.elasticsearch] Detected a 6.x and above cluster: the type event field won’t be used to determine the document _type {:es_version=>6}
[2019-10-13T19:44:50,561][INFO ][logstash.outputs.elasticsearch] New Elasticsearch output {:class=>“LogStash::Outputs::ElasticSearch”, :hosts=>["//192.168.241.131:9200"]}
[2019-10-13T19:44:50,670][INFO ][logstash.outputs.elasticsearch] Using mapping template from {:path=>nil}
[2019-10-13T19:44:50,713][INFO ][logstash.outputs.elasticsearch] Attempting to install template {:manage_template=>{“template”=>“logstash-", “version”=>60001, “settings”=>{“index.refresh_interval”=>“5s”}, “mappings”=>{“default”=>{“dynamic_templates”=>[{“message_field”=>{“path_match”=>“message”, “match_mapping_type”=>“string”, “mapping”=>{“type”=>“text”, “norms”=>false}}}, {“string_fields”=>{“match”=>"”, “match_mapping_type”=>“string”, “mapping”=>{“type”=>“text”, “norms”=>false, “fields”=>{“keyword”=>{“type”=>“keyword”, “ignore_above”=>256}}}}}], “properties”=>{"@timestamp"=>{“type”=>“date”}, “@version”=>{“type”=>“keyword”}, “geoip”=>{“dynamic”=>true, “properties”=>{“ip”=>{“type”=>“ip”}, “location”=>{“type”=>“geo_point”}, “latitude”=>{“type”=>“half_float”}, “longitude”=>{“type”=>“half_float”}}}}}}}}
[2019-10-13T19:44:51,288][INFO ][logstash.inputs.file ] No sincedb_path set, generating one based on the “path” setting {:sincedb_path=>"/var/lib/logstash/plugins/inputs/file/.sincedb_d883144359d3b4f516b37dba51fab2a2", :path=>["/var/log/nginx/access.log"]}
[2019-10-13T19:44:51,437][INFO ][logstash.pipeline ] Pipeline started successfully {:pipeline_id=>“main”, :thread=>"#<Thread:0x7bcb81b5 sleep>"}
[2019-10-13T19:44:51,596][INFO ][filewatch.observingtail ] START, creating Discoverer, Watch with file and sincedb collections
[2019-10-13T19:44:51,608][INFO ][logstash.agent ] Pipelines running {:count=>1, :running_pipelines=>[:main], :non_running_pipelines=>[]}
[2019-10-13T19:44:52,391][INFO ][logstash.agent ] Successfully started Logstash API endpoint {:port=>9600}

看一下我们logstash得配置文件 在
vim /etc/logstash/conf.d/nginx.conf
Kibana找不到logstash索引错误
type 得位置少了个空格

然后 cd /var/log/nginx/文件下 给nginx下得文件添加执行权限
chmod +x /var/log/nginx/*
最后我看到kibana就有目标索引

Kibana找不到logstash索引错误