<div><div><div><div dir="auto">Hi Ishita</div><span style="font-family:tahoma,sans-serif"> </span></div><div dir="auto"></div></div></div><div><blockquote class="gmail_quote" style="width:992px;margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div class="gmail_default" style="font-family:tahoma,sans-serif"><br></div><div class="gmail_default" style="font-family:tahoma,sans-serif">I am trying to download a file using ndnperf client on 10 different nodes and some of them ressult in incomplete downloads. On simply running a "ndnperf prefix" to test the network stats, I see some of the nodes return "Nack receive : Duplicate" after one point.</div></div></div></div></blockquote><div dir="auto"><br></div></div><div><div dir="auto">A Nack~Duplicate occurs when a node receives two Interests with the same nonce.</div><div dir="auto"><br></div><blockquote class="gmail_quote" style="width:992px;margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div class="gmail_default" style="font-family:tahoma,sans-serif"></div></div></div></div></blockquote><div><div class="gmail_quote"></div></div></div><div><div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_default" style="font-family:tahoma,sans-serif">I have 10 containers running on the the node C. Assume each of those 10 containers is trying to download a file from the producer. Some of them have incomplete download.  </div><div class="gmail_default" style="font-family:tahoma,sans-serif"></div></div></blockquote><div dir="auto"><br></div></div></div><div><div><div dir="auto">So the topology is: S—R—W—C0~C9.</div><div dir="auto">S is the producer. R is an NDN forwarder. W is an Ethernet switch. C0~C9 are ten consumers.</div><div dir="auto"><br></div><div dir="auto"><div class="gmail_quote" style="width:992px" dir="auto"></div></div></div></div><div><div><blockquote class="gmail_quote" style="width:992px;margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_default" style="font-family:tahoma,sans-serif"><div dir="ltr" style="font-family:Arial,Helvetica,sans-serif"><div dir="ltr"><div class="gmail_default"><div><font face="tahoma, sans-serif">2. The ethernet faces are automatically available on the FIB. As seen from the topology, R has 2 physical ethernet faces and C has one. I add route for outgoing interface per node(R and C). I looked at the corresponding ethernet face id from "nfdc face" command. Then added "route using "nfdc route add prefix /edu/ishita nexthop <faceid>;" command.</font></div></div></div></div></div></div></blockquote><div dir="auto"><br></div></div></div><div><div><div dir="auto">NFD 0.6.2 prohibits transmitting a Nack on a broadcast or ad hoc wireless face. You can confirm these Ethernet faces have one of these attributes by ‘nfdc face’. (note: these attributes are incorrectly labeled as “multi-access” and “ad hoc”, see <a href="https://redmine.named-data.net/issues/4282" target="_blank">https://redmine.named-data.net/issues/4282</a> ).</div></div><div dir="auto">This means, the Nack~Duplicate seen by the consumer must come from the consumer node itself.</div><div dir="auto"><br></div><div dir="auto">One way for this to happen is:</div><div dir="auto">1. Since C0~C9 are containers in the same physical box, they could share a random seed.</div><div dir="auto">2. If C0~C9 consumers are somehow launched simultaneously, the ndn-cxx non-secure random number generator might be seeded with the same value. Consequently, two or more consumers would be generating the same sequence of nonces.</div><div dir="auto">3. Suppose forwarder C1 first receives an Interest from the network interface, and then receives another Interest with same name and nonce from its local consumer, it would tell consumer Nonce~Duplicate.</div><div dir="auto"><br></div><div dir="auto">You can confirm this hypothesis with tcpdump.</div><div dir="auto">1. Make consumer connect to NFD via TCP loopback rather than Unix.</div><div dir="auto">2. Run tcpdump on loopback interface of each container.</div><div dir="auto">3. Analyze the pcap to see whether there are duplicate nonce across containers.</div><div dir="auto"><br></div><div dir="auto">If this hypithesis is confirmed, one solution is to start consumers at different times. If you want to use a randomized delay to achieve this, you’ll need to pick the delay from outside the container, otherwise you’ll get the same delay as well!</div></div><div dir="auto">Please do consult the technical support of your container technology provider, and see whether they have any suggestions on the random seeding device.</div><div dir="auto"><br></div><div dir="auto">Interestingly, ndn-cxx seeds its random number generator with a single 32-bit integer picked from the random device: <a href="https://github.com/named-data/ndn-cxx/blob/ndn-cxx-0.6.3/src/util/random.cpp#L58">https://github.com/named-data/ndn-cxx/blob/ndn-cxx-0.6.3/src/util/random.cpp#L58</a></div><div dir="auto">The recommended way is to use a random sequence itself: <a href="http://www.pcg-random.org/posts/cpp-seeding-surprises.html">http://www.pcg-random.org/posts/cpp-seeding-surprises.html</a></div><div dir="auto">However, that may or may not help in your case, because the random sequence may as well be duplicating across containers.</div><div><div dir="auto"><br></div><div><blockquote class="gmail_quote" style="width:992px;margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_default" style="font-family:tahoma,sans-serif"><div dir="ltr" style="font-family:Arial,Helvetica,sans-serif"><div dir="ltr"><div class="gmail_default"><div><font face="tahoma, sans-serif">3. I did not add any forwarding straregy of my own. The following default strategies are being used. NFD Version 0.6.2 on all nodes.</font></div></div></div></div><blockquote style="font-family:Arial,Helvetica,sans-serif;margin:0px 0px 0px 40px;border:none;padding:0px"><div><div class="gmail_default" dir="auto"><blockquote class="gmail_quote" style="width:952px;margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><font face="tahoma, sans-serif">  <font size="1"> prefix=/ strategy=/localhost/nfd/strategy/best-route/%FD%05</font></font></blockquote></div></div></blockquote></div></div></blockquote></div></div><div><div><div dir="auto">The effective strategy should be best-route v5.</div></div></div><div><div><div dir="auto"><br></div><blockquote class="gmail_quote" style="width:992px;margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_default" style="font-family:tahoma,sans-serif"><blockquote style="font-family:Arial,Helvetica,sans-serif;margin:0px 0px 0px 40px;border:none;padding:0px"><div><div class="gmail_default" dir="auto"><blockquote class="gmail_quote" style="width:952px;margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><font face="tahoma, sans-serif"><font size="1"></font></font></blockquote></div></div></blockquote><div dir="ltr" style="font-family:Arial,Helvetica,sans-serif"><div dir="ltr"><div class="gmail_default" style="font-family:tahoma,sans-serif"><span style="font-size:12.8px"><br></span></div><div class="gmail_default" style="font-family:tahoma,sans-serif"><span style="font-size:12.8px">4. <b>Comment</b>: What I also observe is file transfer with NDN over UDP is faster and better than compared to NDN over ethernet with intermittent downloads only in case of NDN over ethernet.</span></div></div></div></div></div></blockquote><div dir="auto"><br></div></div></div><div><div><div dir="auto">This is possibly <a href="https://redmine.named-data.net/issues/2441" target="_blank">https://redmine.named-data.net/issues/2441</a></div><div dir="auto"><br></div><div dir="auto">Yours, Junxiao</div><blockquote class="gmail_quote" style="width:992px;margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_default" style="font-family:tahoma,sans-serif"><div dir="ltr" style="font-family:Arial,Helvetica,sans-serif"><div dir="ltr"><div class="gmail_default" style="font-family:tahoma,sans-serif"><span style="font-size:12.8px"></span></div></div></div></div></div></blockquote>
</div>
</div>