UdpClientHelper : experiencing packet loss when Inter packet time is less than 3ms

107 views
Skip to first unread message

Luigi G

unread,
Feb 22, 2019, 8:37:27 AM2/22/19
to ns-3-users
Hi all,

I have an unexpected result testing a very simple scenario with ns-3-dev. 
I've setup 2 wireless nodes, one AP and one STA, with QoSSupported so it is 802.11e.  . 

I've put an UDPServer on the AP and a UDPClient on the STA.
Server starts at time 0 and ends at simulationTime +1 , client starts at time 1 and ends at simulationTime+1. 
There is a FlowMonitor in order to capture the flow stats.

First case is the following. 

The udp flow is defined as follows :
  
  - MaxPackets : 10
  - Interval :  2.5ms
  - PacketSize: 972 byte

The simulationTime is 10s. 

Output:

 Tx Bytes : 10000
  Rx Bytes : 9000
  Througput : 0.00686646 Mbps
  Mean delay:   0.00175804 ms
  Mean Jitter: 0.000813754 ms
  Lost packets: 0

In the pcap file there are 9 packet sent from the STA and 9 packet received from the AP. But Flow Monitor shows 0 Lost Packets.

If I change simulationTime to 20s.

Output:
 Tx Bytes : 10000
  Rx Bytes : 9000
  Througput : 0.00343323 Mbps
  Mean delay:   0.00175804 ms
  Mean Jitter: 0.000813754 ms
  Lost packets: 1

The flowMonitor detects the lost packet, but the pcap still shows 9 packets sent and 9 packets received.


Second case is using the same MaxPackets , PayloadSize and changing Interval from 2.5 ms to 3 ms.

Output: 
 Tx Bytes : 10000
  Rx Bytes : 10000
  Througput : 0.0038147 Mbps
  Mean delay:   0.00134004 ms
  Mean Jitter: 0.00081267 ms
  Lost packets: 0



The question is :

Why i am experiencing packet loss with Inter packet time less than 3ms ? Also, the weird thing is that packets are not even showing up in the pcap file. I thought it was some queueing problem due to the small Inter packet time, but even setting MaxPackets to 10000 I receive 9999 packets with interval of 2.5ms and 10000 with  interval of 3ms.
 
It can be some limitation due to NS-3 but I couldn't find the answer anywhere.

jared...@gmail.com

unread,
Feb 25, 2019, 3:17:09 PM2/25/19
to ns-3-users
Luigi,

I do not know about your exact config but I will offer this: since you have a STA and AP, could there be some delay in actually associating the two at sim startup?  Could that first application packet be sent before the association and hence dropped at the net device?  Maybe set the application start time to 1s or something?

Just a shot in the dark, good luck,
Jared.

Luigi Girletti

unread,
Feb 26, 2019, 9:34:07 AM2/26/19
to ns-3-...@googlegroups.com
I've found the problem. There is a default value for ArpCache which is 3. When packets are sent with a low inter packet time at the first round this cache gets full and drops one packet which will never be sent again.
I've used this :
Config::SetDefault("ns3::ArpCache::PendingQueueSize", UintegerValue(10));   

In order to change the pending queue size from 3 to 10 for example.


--
Posting to this group should follow these guidelines https://www.nsnam.org/wiki/Ns-3-users-guidelines-for-posting
---
You received this message because you are subscribed to the Google Groups "ns-3-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ns-3-users+...@googlegroups.com.
To post to this group, send email to ns-3-...@googlegroups.com.
Visit this group at https://groups.google.com/group/ns-3-users.
For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages