简体   繁体   中英

logstash to elasticsearch show Uknown setting

I just use very simple config which log the data from a file to elasticsearch.

Here is my config

input {
    file {
        path => "/var/log/logstash/logstash.log"
        start_position => beginning 
    }
}
output {
   elasticsearch {
       protocol => "http"
   }
   stdout {}
}

and when I start logstash by

./bin/logstash -f /path/to/mycofig/i-file-o-es.conf

I get error

Unknown setting 'protocol' for elasticsearch {:level=>:error}

I can make this config work by removing protocol=> so I think my plugin is installed correctly.

Anyone met this issue before? Thanks!

I guess you're using Logstash 2.0 beta. In that latest version, they've revamped the elasticsearch output plugin which now doesn't have any protocol setting anymore, since the plugin defaults to using the http protocol .

If you want to be able to specify the protocol setting (ie to use node or transport protocol), you need to use the new elasticsearch_java output plugin

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM