[p2p-hackers] Modelling Latency and Packet Loss on the Public Net

Will Morton will at memefeeder.com
Tue May 16 18:57:15 UTC 2006


Greetings all;

I am building a test rig for our p2p application and am trying to  
simulate conditions on the public Internet, specifically latency and  
packet loss.  As such I need to create distribution graphs for both  
these quantities between two arbitrary points of the network.  Has  
anyone done any work in this area, or have any pointers?

Apologies if this has been asked before.  My Googling (hmm, do  
initial caps stay after verbage?) led only to highly complex analyses  
for the purposes of better TCP algorithms.  While this is no doubt  
worthy work, it is far too in-depth for my requirements.  I only need  
roughly correct distributions so that I can be confident that  
successful network operation in the test rig is likely to mean  
successful operation on the Public Net (at least regarding packet  
loss and latency...)

Some playing around with Excel, with no more exact criteria than  
'that looks about right' produced the following formulae:

Packet Loss (probability than on a given connection between two  
arbitrary nodes, a particular packet will get lost)
P = (1.2^n)/800000000 for n = [1, ..., 100], n chosen randomly once  
for each connection
When n=0, P=0; n=50, P=0; n=100, P=0.1

Latency (delay in packet reception on a given connection between two  
arbitrary nodes)
L = (1.04^n')*20 ms for n' = [1, ..., 100], n' chosen randomly once  
for each connection
When n'=0,L=21; n'=50, L=142; n'=100, L=1010

Does this sound believable?  Of course this assumes constant latency  
and packet loss for the life of the connection, which is a gross over- 
simplification, but I don't have any feel for what would be 'about  
right' for variance over time for the above figures.  Additionally n  
and n' are chosen independently; it seems likely they'd be correlated  
to an extent, but to what extent I don't know.  My plan is to build  
data collection into our app so that I can create a more accurate  
test rig for 1.1.

Any feedback, comments, flames etc welcomed, on-list or off

Cheers

Will




More information about the P2p-hackers mailing list