Try "Netem"
netem provides Network Emulation
functionality for testing protocols by emulating the properties of wide area
networks. The current version emulates variable delay, loss, duplication and
re-ordering.
If you run a current 2.6 distribution, (Fedora, OpenSuse, Gentoo, Debian,
Mandriva, Ubuntu),
then netem is already enabled in the kernel and a current version of iproute2
is included. The netem kernel
component is enabled under: Networking -->
Networking Options -->
QoS and/or fair queuing -->
Network emulator
Netem is controlled by the command line tool 'tc' which is part of the iproute2
package of tools. The tc command
uses shared libraries and data files in the /usr/lib/tc directory.
> Date: Wed, 5 Sep 2012 15:24:31 -0400
> From: [email protected]
> To: [email protected]
> Subject: [Live-devel] simulate RTP packet loss
>
> Hi all,
>
> I would like to simulate packet loss of RTP packets on the network, and
> I would like to use Live555 to do this. In fact, there already is some
> code in MultiFramedRTPSink (in the
> MultiFramedRTPSink::sendPacketIfNecessary() function) which is contained
> in a "TEST_LOSS" macro, and is hardcoded to simulate 10% loss:
>
> #ifdef TEST_LOSS
> if ((our_random()%10) != 0) // simulate 10% packet loss #####
> #endif
>
> I would like to do some more sophisticated testing (e.g. change the
> packet loss to 5% or 25%). What is the "right" way to do this? Ideally
> I would subclass MultiFramedRTPSink and then override the
> sendPacketIfNecessary() function. But sendPacketIfNecessary() is
> declared as "private" and so I cannot override.
>
> How best to simulate the packet loss without modifying the Live555 code
> directly?
>
> Regards,
>
> --Andy Stevens
> New York, USA
> _______________________________________________
> live-devel mailing list
> [email protected]
> http://lists.live555.com/mailman/listinfo/live-devel
_______________________________________________
live-devel mailing list
[email protected]
http://lists.live555.com/mailman/listinfo/live-devel