-
Notifications
You must be signed in to change notification settings - Fork 132
Description
Hello. We're using samplicator to copy statsd metric traffic (UDP packets) to two destinations. My question is, should we expect that samplicator fails to copy 100% of the traffic to every destination if there is a high packet rate?
In our setup, samplicator listens on port 8125, and forwards to ports 8124 and 9125. Here are some outputs for 5 minutes worth of pcaps on each of the 3 ports. The traffic going into samplicator is roughly 2x that of what is going into each destination:
Samplicator port, 5 minutes of packets:
user@host $ sudo tcpdump -G 300 -W 1 udp -i any 'dst port 8125' -s 0 -w ~/8125.pcap
tcpdump: listening on any, link-type LINUX_SLL (Linux cooked), capture size 262144 bytes
Maximum file limit reached: 1
33512370 packets captured
67426415 packets received by filter
392293 packets dropped by kernel
Destination 1:
user@host $ sudo tcpdump -G 300 -W 1 udp -i any 'dst port 8124' -s 0 -w ~/8124.pcap
tcpdump: listening on any, link-type LINUX_SLL (Linux cooked), capture size 262144 bytes
Maximum file limit reached: 1
16446120 packets captured
33060123 packets received by filter
166158 packets dropped by kernel
Destination 2:
user@host $ sudo tcpdump -G 300 -W 1 udp -i any 'dst port 9125' -s 0 -w ~/9125.pcap
tcpdump: listening on any, link-type LINUX_SLL (Linux cooked), capture size 262144 bytes
Maximum file limit reached: 1
17295917 packets captured
34708450 packets received by filter
114771 packets dropped by kernel
The size of the pcap files also show the difference in captured packets (largest file is the samplicator port, two smaller ones are the two destinations):
user@host $ ls -latrh *.pcap
-rw-r--r-- 1 root root 5.3G Apr 12 13:43 8125.pcap
-rw-r--r-- 1 root root 2.6G Apr 12 13:48 8124.pcap
-rw-r--r-- 1 root root 2.8G Apr 12 13:57 9125.pcap
Our next plan is to run some more synthetic load tests to find out at exactly what packet rate does samplicator break down and stop being able to send 100% of traffic.
It also that samplicator is at 98+% CPU usage throughout (monitored via htop).