我试图从logstash中读取rabbitmq队列中的日志,然后将其传递给elasticsearch。但没有成功。这是我的logstash配置。
input {
rabbitmq {
host => "localhost"
port => 15672
heartbeat => 30
durable => true
exchange => "logging_queue"
exchange_type => "logging_queue"
}
}
output {
elasticsearch {
hosts => "localhost:9200"
}
stdout {}
}
答案 0 :(得分:0)
我认为正确的(默认)端口是5672,因为15672是Web管理控制台的端口。
input {
rabbitmq {
host => "localhost"
port => 5672 <--- change this
heartbeat => 30
durable => true
exchange => "logging_queue"
exchange_type => "logging_queue"
}
}
output {
elasticsearch {
hosts => "localhost:9200"
}
stdout {}
}