Hi all,
I am facing an issue with GELF output plugin in Logstash.
Recently started using Logstash. Wanted to visualize logs in Graylog2 using Logstash. So, gave a basic trail with this.
My config is
input {
file {
path => "/root/Desktop/Graylog/test.log"
start_position => "beginning"
type => "logs"
sincedb_path => "/dev/null"
}
}
filter {
if [type] == "logs" {
mutate {
add_field => {"message" => "%{Message}"}
}
}
}
output {
gelf {
host => ["127.0.0.1:9000"]
}
}
On using stdout {}, logstash runs fine. But gives error on using gelf output plugin.
Error:
Trouble sending GELF event {:gelf_event=>{"short_message"=>["", "%{Message}"], "full_message"=>",%{M........"path"=>"/root/Desktop/Graylog/test.txt", "host"=>"localhost.localdomain", "type"=>"grayLog"}, "severity"]}>>, :error=>#SocketError: send: name or service not known>, :level=:warn}
I have omitted the log and only shown the relevant things.
Can u please help me with this.
using logstash v2.2 with
Graylog 1.3
I am a newbie in linux environment and tools. kindly help me. What could be the reason for this error