More on Debian Jessie/Ubuntu Trusty packet capture woes

Jim Hague PCAP Networks PCAP C C++
Back in September I wrote about a problem we’d come across when capturing traffic with pcap_dispatch() or pcap_next_ex() on Ubuntu Trusty or Debian Jessie. When the traffic was slow, we saw packets not being captured. We’ve since done a bit more digging. The problem, we think, is a bug in the Linux kernel select() system call. With both pcap_dispatch() and pcap_next_ex() we’re using a central loop …

Packet capture woes with libpcap on Ubuntu Trusty and Debian Jessie

Jim Hague PCAP Networks PCAP C C++
Usually when you’re using libpcap to capture network traffic, your chief worry will be whether or not your application will keep up with the flow of traffic. Today, though, I’ve stubbed my toe on a problem with traffic that’s too slow. It happens with both Ubuntu Trusty and Debian Jessie. If there’s a gap between packets of more than about 50 milliseconds, the first packet to arrive after the gap …