Hello,
I have ElasticSearch and Logstash installed on same machine(Ubuntu).
I have the below apache_logs.conf file contents:
input {
file {
path => "/var/log/apache_logs"
type => "apache_log" # a type to identify those logs (will need this later)
start_position => "beginning"
}
}
The command --> sudo service logstash configtest returns "Configuration OK"
The log file is placed in "/var/log/apache_logs"
However, indices are not getting created in elasticsearch and hence not reflected in kibana.
Could you please point out if I have missed out on any settings.
Okay. Logstash is probably tailing the file. In that case clearing the sincedb file will help. Please read the file input documentation and check the numerous posts about this in the past. Increasing Logstash's log level will give more clues about what it's doing.
Okay, so I used the below in the file block:
file {
path => "/var/log/apache_logs"
type => "apache_log" # a type to identify those logs (will need this later)
start_position => "beginning"
sincedb_path => "/dev/null" #to clear since db
}
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.