<html><head><meta http-equiv="Content-Type" content="text/html charset=GB2312"><base href="x-msg://125/"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div>Hi Nilicy,</div><div><br></div><div>There is one important problem in your code, which probably is the reason of the problem: you should not call ndnStackHelper.Install (...) or ndnStackHelper.InstallAll ()  before all nodes and all links before nodes are actually created.</div><div><br></div><div>The reason for this restriction is that the Install method besides installing the stack creates necessary NDN faces based on the available NetDevices on the node.  If you call Install and then add new NetDevice (connect LANs), this NetDevice will not have a corresponding ndn::NetDeviceFace and thus NDN will not be aware of the available link.  If you really want to connect after calling Install, you will need to manually create faces and install faces in corresponding ndn::L3Protocols.</div><div><br></div><div>As for the other question about selective route calculation.  As it stands right now, CalculateRoutes does the job only for all available nodes. However, you can extend the ndn::GlobalRoutingHelper with another method that accept Node and/or NodeContainer parameter and calculates routes only for the requested nodes.  If you make this change, I will gladly push it to the main branch of ndnSIM, as it could be useful for others too.</div><div><br></div><div>---</div><div>Alex</div><div><br></div><br><div><div>On Apr 16, 2013, at 3:04 AM, youshou_wy <<a href="mailto:youshou_wy@126.com">youshou_wy@126.com</a>> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="line-height: 1.5; font-family: Î¢ÈíÑźÚ; color: rgb(0, 0, 128); font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; margin: 10px; "><div>Hi  Alex,</div><div> </div><div>I send you my  scenario , and i guess you maybe don't  the action  of <span style="font-style: italic; ">  1.txt   ,<span class="Apple-converted-space"> </span><span style="font-style: normal; font-weight: normal; ">let me explain it.</span></span></div><div><span style="font-style: italic; "><span style="font-style: normal; font-weight: normal; "></span></span> </div><div><span style="font-style: italic; "><span style="font-style: normal; font-weight: normal; ">I  Reload<span style="font-style: italic; "><span class="Apple-converted-space"> </span>ForwardingStrategy::DidCreatePitEntry   in  ndn-ForwardingStrategy.cc  <span class="Apple-converted-space"> </span><span style="font-style: normal; ">and  make some changes .  when a node receive a interest packet ,fisrt it will check  CS ,second check PIT and last check  FIB , if the node don't find entry about the interest ,the interest will be drop .  In my<span class="Apple-converted-space"> </span><em>ForwardingStrategy.cc ,<span class="Apple-converted-space"> </span><span style="font-style: normal; ">wnen  node don't   find entry i</span></em></span></span></span></span><span style="font-style: italic; "><span style="font-style: normal; font-weight: normal; "><span style="font-style: italic; "><span style="font-style: normal; "><em><span style="font-style: normal; ">n FIB, it will check the<span class="Apple-converted-space"> </span><span style="font-style: italic; ">1.txt .<span style="font-style: normal; "><span class="Apple-converted-space"> </span>In other words,<span class="Apple-converted-space"> </span><span style="font-style: italic; ">1.txt  store some  route   entrys.</span></span></span></span></em></span></span></span></span></div><div><span style="font-style: italic; "><span style="font-style: normal; font-weight: normal; "><span style="font-style: italic; "></span></span></span> </div><div><span style="font-style: italic; "><span style="font-style: normal; font-weight: normal; "><span style="font-style: italic; "><span style="font-style: normal; "><em><span style="font-style: normal; "><span style="font-style: italic; "><span style="font-style: normal; "><span style="font-style: italic; "><span style="font-style: normal; ">So  when  i simulation in ndnSIM ,</span><span class="Apple-converted-space"> </span><span style="font-style: normal; ">I  wanna use   </span>ndn::GlobalRoutingHelper::CalculateRoutes ()  to <span class="Apple-converted-space"> </span><span style="font-style: normal; ">add  some  FIB  entry   about  the  LAN  itself<span style="font-style: normal; ">,</span></span><span style="font-style: normal; ">  if   cosumer2 (belong to LAN2)  request a rouses comes form  LAN1, it must find <span style="font-style: italic; "><span class="Apple-converted-space"> </span>1.txt.</span></span></span></span></span></span></em></span></span></span></span></div><div><span style="font-style: italic; "><span style="font-style: normal; font-weight: normal; "><span style="font-style: italic; "></span></span></span> </div><div><span style="font-style: italic; ">But maybe   ndn::GlobalRoutingHelper::CalculateRoutes ()   only  Calculate  all   the   nodes   routes    ,How to use  it to Calculate  some  nodes  routes?</span></div><div> </div><hr align="left" size="1" style="width: 210px; height: 1px; "><div><span>youshou_wy</span></div><div> </div><div style="border-width: 1pt medium medium; border-style: solid none none; padding: 3pt 0cm 0cm; border-top-color: rgb(181, 196, 223); "><div style="padding: 8px; background-color: rgb(239, 239, 239); font-size: 12px; "><div><b>From:</b> <a href="mailto:alexander.afanasyev@ucla.edu">Alex Afanasyev</a></div><div><b>Date:</b> 2013-04-16 02:03</div><div><b>To:</b> <a href="mailto:youshou_wy@126.com">youshou_wy</a></div><div><b>CC:</b> <a href="mailto:ndnsim@lists.cs.ucla.edu">ndnsim@lists.cs.ucla.edu</a></div><div><b>Subject:</b> Re: How to simulation two or three LNA in ndnSIM?</div></div></div><div><div>Hi Nilicy,</div><div> </div><div>ndn::GlobalRoutingHelper should not have any problems in creating valid FIB entries from one LAN to another.  You can either send me your scenario, so I can check what is wrong, or you can use this scenario (<a href="http://pastebin.com/Hz3uE73m">http://pastebin.com/Hz3uE73m</a>) that I just created as a base point.  (This scenario creates the same topology as you explained, but using PointToPointGridHelper.)</div><div> </div><div>I'm a little bit confused about Add method that you have used.  If you're referring to Add on a NodeContainer, then it doesn't really do anything good to you, since NodeContainer is just a container and doesn't create any links.  To create links within a LAN, as well as between LANs, you need to use, for example, PointToPointHelper::Install method (check line 82 in the example I linked).</div><div> </div><div>---</div><div>Alex</div><div> </div><div>On Apr 15, 2013, at 2:37 AM, youshou_wy <<a href="mailto:youshou_wy@126.com">youshou_wy@126.com</a>> wrote:</div><div> </div><div>> Hi  Alex,  </div><div>> I  wanna simulation two LAN in ndnSIM ,  i set  two NodeContainer to creating nodes, like is:</div><div>>               NodeContainer node1;</div><div>>               NodeContainer node2; </div><div>>         node1 contains the nodes of first LAN ,node2 contains the nodes of second LAN. I use Add(node1,node2) to create the WAN .  But when i use ndn::GlobalRoutingHelper to Generate each routes of every LAN ,it can't work .</div><div>>         In other word , if i can create a network like is:</div><div>>          </div><div>> (consumer1) -- ( ) ----- ( )</div><div>>     |           |         |</div><div>>    ( ) ------- ( ) ----- ( )</div><div>>     |           |         |</div><div>>    ( ) ------- ( ) -- (producer1)    LAN1</div><div>>                 |</div><div>>                 |</div><div>>                 |</div><div>>  </div><div>> (consumer2) -- ( ) ----- ( )</div><div>>     |           |         |</div><div>>    ( ) ------- ( ) ----- ( )</div><div>>     |           |         |</div><div>>    ( ) ------- ( ) -- (producer2)     LAN2</div><div>>     </div><div>>    I guess i can generation each LAN ,but if i must Manually add routes in each LAN?    </div><div>>         Thanks</div><div>>  </div><div>> Nilicy</div><div> </div></div><span><ndn-grid-v2.cc></span><span><1.txt></span><span><topo-grid-lan1.txt></span><span><topo-grid-lan2.txt></span></div></blockquote></div><br></body></html>