开发者

Mono dropping packets when receiving lots of multicast

开发者 https://www.devze.com 2023-01-20 09:44 出处:网络
I am creat开发者_StackOverflowing a program that listens to video streams over multicast. Listening to one feed with Mono on Linux works fine but listening to 15 feeds drops packets. Running the code

I am creat开发者_StackOverflowing a program that listens to video streams over multicast. Listening to one feed with Mono on Linux works fine but listening to 15 feeds drops packets. Running the code on Windows .NET does not drop packets and listening to the feeds with a C program on Linux does not drop packets. Is there something I could do to optimize this?


Depending on what mechanism you use, code wise, you may not be capturing the packets fast enough. That would result in drops of multicast data, which by its very nature is unreliable. Without more info about the mechanism employed, it's difficult to give you any more specific advice.

Update based on comments:

If you have a thread per receiver and more threads than CPUs, you may be oversubscribing your threads, causing a lot of expensive context switching. This could lead to dropped packets.

0

精彩评论

暂无评论...
验证码 换一张
取 消