Closed keyboardfann closed 7 years ago
No, statsrelay only supports TCP for connecting to backends.
Oh, I might be wrong about that... Just reading the code, I think if you do "0:10.62.4.158:12100:udp" in the shard map, it'll work.
Dear @JeremyGrosser , Thank you for answer the question. I add udp to config and start statsrelay , statsrelay show Unexpectedly received zero-length UDP payload.
statsrelay.conf
statsd:
bind: 10.62.4.158:12001
tcp_cork: false
validate: true
shard_map:
0: 10.62.4.158:12100:udp
start statsrelay
/usr/local/bin/statsrelay -c statsrelay.conf
ERROR: stats: Unexpectedly received zero-length UDP payload.
ERROR: stats: Unexpectedly received zero-length UDP payload.
ERROR: stats: Unexpectedly received zero-length UDP payload.
ERROR: stats: Unexpectedly received zero-length UDP payload.
ERROR: stats: Unexpectedly received zero-length UDP payload.
ERROR: stats: Unexpectedly received zero-length UDP payload.
Dear @JeremyGrosser, Ok, I find the problem. The error is because I use keepalive + LVS , and keepalive will use script to check statsrelay port open or not , so cause the error. The udp statsrelay work fine. Thank you.
keepalived.conf
real_server 10.62.4.158 12001 {
weight 10
# MISC_CHECK {
# misc_path "/data01/check_udp.sh 10.62.4.158 12001"
# misc_timeout 10
# }
}
Hello All, Does statsrelay support UDP protocol? Here is my flow , metrics -> LVS -> statsrelay -> telegraf statsd udp input plugin.
statsrelay.conf
telegraf statsd plugin listen on UDP 12100
run statsrelay