有时候企业内部网络限制,不能够直接互通、传输数据。数据传输路径:filebeat——>haproxy——>kafka(logstash)
这个时候问题了相对安全吧,使用haproxy进行代理转发,haproxy支持tcp和http的转发(3层和7层),想着4层转发也像路由一样,对上层的具体内容无影响。但是配置了以后,怎么着都不行?
着重说明,我的haproxy配置时没问题的,服务端口都是正常的:
1、haproxy配置也没问题,我测试转发apache的请求,可以正常访问apache的默认页面;
2、不使用haproxy,直接filebeat到logstash,内容可以正常输出,配置也是没问题的,但一加入haproxy就不行了
-----------------------------------haproxy配置:
[root@localhost haproxy]# vim haproxy.cfg
listen ssacc
bind *:5000
mode tcp
server localhost localhost:5044
-----------------------------------filebeat配置
采集部分不贴了,输出部分:
#----------------------------- Logstash output --------------------------------
output.logstash:
# The Logstash hosts
hosts: ["localhost:5000"]
-----------------------------------logstash配置
[root@localhost config]# cat ssacc.conf
input {
beats {
port => 5044
}
}
output {
stdout {
}
}
[root@localhost config]#
------------------------------------------------filebeat报错信息如下:
2020-05-12T16:33:53.935+0800 INFO pipeline/output.go:95 Connecting to backoff(async(tcp://localhost:5000))
2020-05-12T16:33:53.936+0800 INFO pipeline/output.go:105 Connection to backoff(async(tcp://localhost:5000)) established
2020-05-12T16:33:53.937+0800 ERROR logstash/async.go:256 Failed to publish events caused by: EOF
2020-05-12T16:33:53.937+0800 ERROR logstash/async.go:256 Failed to publish events caused by: client is not connected
2020-05-12T16:33:55.453+0800 ERROR pipeline/output.go:121 Failed to publish events: client is not connected
2020-
参考网上https://stackoverflow.com/ques ... proxy
https://stackoom.com/question/ ... ogzio
也看不出什么,求指导!
这个时候问题了相对安全吧,使用haproxy进行代理转发,haproxy支持tcp和http的转发(3层和7层),想着4层转发也像路由一样,对上层的具体内容无影响。但是配置了以后,怎么着都不行?
着重说明,我的haproxy配置时没问题的,服务端口都是正常的:
1、haproxy配置也没问题,我测试转发apache的请求,可以正常访问apache的默认页面;
2、不使用haproxy,直接filebeat到logstash,内容可以正常输出,配置也是没问题的,但一加入haproxy就不行了
-----------------------------------haproxy配置:
[root@localhost haproxy]# vim haproxy.cfg
listen ssacc
bind *:5000
mode tcp
server localhost localhost:5044
-----------------------------------filebeat配置
采集部分不贴了,输出部分:
#----------------------------- Logstash output --------------------------------
output.logstash:
# The Logstash hosts
hosts: ["localhost:5000"]
-----------------------------------logstash配置
[root@localhost config]# cat ssacc.conf
input {
beats {
port => 5044
}
}
output {
stdout {
}
}
[root@localhost config]#
------------------------------------------------filebeat报错信息如下:
2020-05-12T16:33:53.935+0800 INFO pipeline/output.go:95 Connecting to backoff(async(tcp://localhost:5000))
2020-05-12T16:33:53.936+0800 INFO pipeline/output.go:105 Connection to backoff(async(tcp://localhost:5000)) established
2020-05-12T16:33:53.937+0800 ERROR logstash/async.go:256 Failed to publish events caused by: EOF
2020-05-12T16:33:53.937+0800 ERROR logstash/async.go:256 Failed to publish events caused by: client is not connected
2020-05-12T16:33:55.453+0800 ERROR pipeline/output.go:121 Failed to publish events: client is not connected
2020-
参考网上https://stackoverflow.com/ques ... proxy
https://stackoom.com/question/ ... ogzio
也看不出什么,求指导!
0 个回复