From anilj.mailing at gmail.com Tue Dec 1 19:50:18 2015 From: anilj.mailing at gmail.com (Anil Jangam) Date: Tue, 1 Dec 2015 19:50:18 -0800 Subject: [ndnSIM] CryptoPP is present, but is not usable. In-Reply-To: References: Message-ID: Thanks Spyros for the reply. Curious to know what is the difference between the ndn-cxx (its main source) and the one which is part of ndnSIM? This is the question from my below post, which I believe is not answered yet. When we configure/compile ndnSIM one of the prerequisite is ndn-cxx otherwise configure script fails. So my question is: do we install ndn-cxx from its main source or do we install it from the version which is part of ndnSIM source? When I install ndn-cxx it from the main source its compile goes through fine. However, when I try to compile and install ndn-cxx from the ndnSIM sources, I hit the error I reported in this thread. Can you please comment? /anil. On Mon, Nov 30, 2015 at 9:53 AM, Spyridon (Spyros) Mastorakis < mastorakis at cs.ucla.edu> wrote: > Hi Anil, > > there was another thread about this issue. You may want to take a look at > it: > > http://www.lists.cs.ucla.edu/pipermail/ndnsim/2015-November/002208.html > > Hope that this helps! > > Spyridon (Spyros) Mastorakis > Personal Website: http://cs.ucla.edu/~mastorakis/ > Internet Research Laboratory > Computer Science Department > UCLA > > > > > On Nov 30, 2015, at 9:44 AM, Anil Jangam wrote: > > Hi, > > Before we compile ndnSIM 2.1, do we have to install the ndn-cxx from it > sources or should we be installing it from the sources provided under > ndnSIM, which I think is slightly modified version? If I just do not > install it, ndnSIM configure obviously gives configure error (Checking for > 'libndn-cxx' : not found). > > When I try to configure and install ndn-cxx which is included in ndnSIM, I > hit the following error. > > Checking for 'sqlite3' : yes > hecking Crypto++ lib : 563 > Checking if CryptoPP library works : no > Checking if CryptoPP library works : no > CryptoPP is present, but is not usable > (complete log in > /home/anilj1/sandbox/ndnSIM/ns-3/src/ndnSIM/ndn-cxx/build/config.log) > > As can be seen I have already compiled and installed the latest version > (5.6.3) of the cryptopp from its source. (Got the reference from here: > http://redmine.named-data.net/issues/1700) but it is not helping. > > This redmine change is about an year old. However is there any change made > in recent past to ndnSIM in this regard? > > /anil. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From tk.kt0518 at gmail.com Tue Dec 1 21:37:43 2015 From: tk.kt0518 at gmail.com (=?UTF-8?B?5Yqg6Jek5bCt5b2m?=) Date: Wed, 2 Dec 2015 14:37:43 +0900 Subject: [ndnSIM] A Question on per fib rate limit Message-ID: Dear all, I'm trying to use per fib limit, limit rate and nack over ndnSIM 1.0, but I have some problems. The level "m_bucket" for perFibLimit dose not decrease, so the leaky bucket becomes full. The scenario and the topology I used are followings. I'm very happy if someone help me. By the way, my plan is to implement the stateful fowarding. Does anyone know there is a program code for it. // ndn-simple.cpp #include "ns3/core-module.h" #include "ns3/network-module.h" #include "ns3/ndnSIM-module.h" // for ndn::L3AggregateTracer #include // for ndn::L3RateTracer #include using namespace ns3; int main(int argc, char* argv[]) { // Read optional command-line parameters (e.g., enable visualizer with ./waf --run=<> --visualize CommandLine cmd; cmd.Parse(argc, argv); // Read Topology from file AnnotatedTopologyReader reader ; reader.SetFileName("scratch/topology.txt"); reader.Read (); // Install NDN stack ndn::StackHelper ndnHelper; ndnHelper.SetForwardingStrategy ("ns3::ndn::fw::BestRoute"); // Install PerFibLimit ndnHelper.SetForwardingStrategy ("ns3::ndn::fw::BestRoute::PerOutFaceLimits::PerFibLimits", "Limit", "ns3::ndn::Limits::Rate"); ndnHelper.EnableLimits (true, Seconds(0.1), 0, 1250); ndnHelper.SetForwardingStrategy ("ns3::ndn::fw::BestRoute::PerOutFaceLimits::PerFibLimits", "EnableNACKs", "true"); ndnHelper.InstallAll (); // Installing global routing interface on all nodes ndn::GlobalRoutingHelper ndnGlobalRoutingHelper; ndnGlobalRoutingHelper.InstallAll (); // Installing applications // Getting containers for consumer/producer Ptr producer1 = Names::Find ("server1"); Ptr producer2 = Names::Find ("server2"); Ptr consumer1 = Names::Find ("client1"); Ptr consumer2 = Names::Find ("client2"); // Consumer window ndn::AppHelper consumerHelper ("ns3::ndn::ConsumerWindow"); // Consumer std::string prefix1 = "/root"; consumerHelper.SetPrefix(prefix1); consumerHelper.SetAttribute ("Size", StringValue ("2.0")); consumerHelper.Install(consumer1); std::string prefix2 = "/prefix"; consumerHelper.SetPrefix(prefix2); consumerHelper.SetAttribute ("Size", StringValue ("2.0")); consumerHelper.Install(consumer2); // Producer ndn::AppHelper producerHelper("ns3::ndn::Producer"); producerHelper.SetPrefix(prefix1); producerHelper.SetAttribute("PayloadSize", StringValue("1250")); producerHelper.Install(producer1); // last node // Producer will reply to all requests starting with /prefix producerHelper.SetPrefix(prefix2); producerHelper.SetAttribute("PayloadSize", StringValue("1250")); producerHelper.Install(producer2); // Add prefix origins to ndn::GlobalRouter ndnGlobalRoutingHelper.AddOrigins (prefix1, producer1); ndnGlobalRoutingHelper.AddOrigins (prefix2, producer2); // Calculate and install FIBs ndn::GlobalRoutingHelper::CalculateRoutes (); Simulator::Stop(Seconds(10.0)); ndn::L3RateTracer::InstallAll("test.txt", Seconds(0.5)); Simulator::Run(); Simulator::Destroy(); return 0; } topology.txt router #name city latitude longitude client1 unknown 28.8967 135 client2 unknown 35.41 135 server1 unknown 28.8967 140 server2 unknown 35.41 140 clientProvider unknown 30.1 137 serverProvider unknown 30.1 139 link #x y capacity(kbps) OSPF Delay MaxPackets client1 clientProvider 10Mbps 1 50ms 200 client2 clientProvider 10Mbps 1 50ms 200 server1 serverProvider 10Mbps 2 20ms 20 server2 serverProvider 10Mbps 2 20ms 20 clientProvider serverProvider 1Mbps 1 30ms 20 -------------- next part -------------- An HTML attachment was scrubbed... URL: From aa at CS.UCLA.EDU Wed Dec 2 15:17:02 2015 From: aa at CS.UCLA.EDU (Alex Afanasyev) Date: Wed, 2 Dec 2015 15:17:02 -0800 Subject: [ndnSIM] CryptoPP is present, but is not usable. In-Reply-To: References: Message-ID: <2AAD6B70-B8E7-4DCA-AB75-83775CF045CA@cs.ucla.edu> > On Dec 1, 2015, at 7:50 PM, Anil Jangam wrote: > > Thanks Spyros for the reply. > > Curious to know what is the difference between the ndn-cxx (its main source) and the one which is part of ndnSIM? This is the question from my below post, which I believe is not answered yet. > > When we configure/compile ndnSIM one of the prerequisite is ndn-cxx otherwise configure script fails. So my question is: do we install ndn-cxx from its main source or do we install it from the version which is part of ndnSIM source? > > When I install ndn-cxx it from the main source its compile goes through fine. However, when I try to compile and install ndn-cxx from the ndnSIM sources, I hit the error I reported in this thread. > > Can you please comment? Hi Anil, ndnSIM bundles (as a submodule) a specific version of ndn-cxx. This is to ensure that ndnSIM can be compiled even there are changes of the mainstream library. The actual bundled code is almost exactly the same as the mainstream, there is a very minor change and it is just not the most recent version. Same applies to the bundled NFD source code. It is a fixed version of NFD codebase with a few minor modifications. Installation of a stand-alone ndn-cxx/NFD will not have any effect on ndnSIM 2.1+. --- Alex > > /anil. > > > On Mon, Nov 30, 2015 at 9:53 AM, Spyridon (Spyros) Mastorakis > wrote: > Hi Anil, > > there was another thread about this issue. You may want to take a look at it: > > http://www.lists.cs.ucla.edu/pipermail/ndnsim/2015-November/002208.html > > Hope that this helps! > > Spyridon (Spyros) Mastorakis > Personal Website: http://cs.ucla.edu/~mastorakis/ > Internet Research Laboratory > Computer Science Department > UCLA > > > > >> On Nov 30, 2015, at 9:44 AM, Anil Jangam > wrote: >> >> Hi, >> >> Before we compile ndnSIM 2.1, do we have to install the ndn-cxx from it sources or should we be installing it from the sources provided under ndnSIM, which I think is slightly modified version? If I just do not install it, ndnSIM configure obviously gives configure error (Checking for 'libndn-cxx' : not found). >> >> When I try to configure and install ndn-cxx which is included in ndnSIM, I hit the following error. >> >> Checking for 'sqlite3' : yes >> hecking Crypto++ lib : 563 >> Checking if CryptoPP library works : no >> Checking if CryptoPP library works : no >> CryptoPP is present, but is not usable >> (complete log in /home/anilj1/sandbox/ndnSIM/ns-3/src/ndnSIM/ndn-cxx/build/config.log) >> >> As can be seen I have already compiled and installed the latest version (5.6.3) of the cryptopp from its source. (Got the reference from here: http://redmine.named-data.net/issues/1700 ) but it is not helping. >> >> This redmine change is about an year old. However is there any change made in recent past to ndnSIM in this regard? >> >> /anil. > > _______________________________________________ > ndnSIM mailing list > ndnSIM at lists.cs.ucla.edu > http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 841 bytes Desc: Message signed with OpenPGP using GPGMail URL: From rozhnova.natalya at gmail.com Thu Dec 3 09:35:24 2015 From: rozhnova.natalya at gmail.com (Natalya Rozhnova) Date: Thu, 3 Dec 2015 18:35:24 +0100 Subject: [ndnSIM] interface management Message-ID: Hi all, I would ask a question about the interface state management. Is there in ndnSIM 2.1 something that do the following: when interface goes physically down (say nomore channel or link or something else on physical layer) -> remove the corresponding face from FIB? How (and where) could I check it ? I would need this information in NFD forwarder. BTW I found the similar functionnality in FaceTable but didn't really get how the information about the interface is checked... Could anybody please explain it to me in more details? I also found the function to check whether a face isUp() but it always returns true... thanks in advance, Natalya -------------- next part -------------- An HTML attachment was scrubbed... URL: From anilj.mailing at gmail.com Thu Dec 3 10:24:38 2015 From: anilj.mailing at gmail.com (Anil Jangam) Date: Thu, 3 Dec 2015 10:24:38 -0800 Subject: [ndnSIM] ndn-cxx or ndnSIM/ndn-cxx? Message-ID: Thanks Alex for your comments. So in this regard, is it proposed to remove the ndnSIM's dependency on ndn-cxx since configure fails if no ndn-cxx libraries are found. So your last statement isn't completely true OR it would justify the above proposed removal. /anil. On Wed, Dec 2, 2015 at 3:17 PM, Alex Afanasyev wrote: > > On Dec 1, 2015, at 7:50 PM, Anil Jangam wrote: > > Thanks Spyros for the reply. > > Curious to know what is the difference between the ndn-cxx (its main > source) and the one which is part of ndnSIM? This is the question from my > below post, which I believe is not answered yet. > > When we configure/compile ndnSIM one of the prerequisite is ndn-cxx > otherwise configure script fails. So my question is: do we install ndn-cxx > from its main source or do we install it from the version which is part of > ndnSIM source? > > When I install ndn-cxx it from the main source its compile goes through > fine. However, when I try to compile and install ndn-cxx from the ndnSIM > sources, I hit the error I reported in this thread. > > > Can you please comment? > > > Hi Anil, > > ndnSIM bundles (as a submodule) a specific version of ndn-cxx. This is to > ensure that ndnSIM can be compiled even there are changes of the mainstream > library. The actual bundled code is almost exactly the same as the > mainstream, there is a very minor change and it is just not the most recent > version. > > Same applies to the bundled NFD source code. It is a fixed version of NFD > codebase with a few minor modifications. > > Installation of a stand-alone ndn-cxx/NFD will not have any effect on > ndnSIM 2.1+. > > --- > Alex > > > /anil. > > > On Mon, Nov 30, 2015 at 9:53 AM, Spyridon (Spyros) Mastorakis < > mastorakis at cs.ucla.edu> wrote: > >> Hi Anil, >> >> there was another thread about this issue. You may want to take a look at >> it: >> >> http://www.lists.cs.ucla.edu/pipermail/ndnsim/2015-November/002208.html >> >> Hope that this helps! >> >> Spyridon (Spyros) Mastorakis >> Personal Website: http://cs.ucla.edu/~mastorakis/ >> Internet Research Laboratory >> Computer Science Department >> UCLA >> >> >> >> >> On Nov 30, 2015, at 9:44 AM, Anil Jangam wrote: >> >> Hi, >> >> Before we compile ndnSIM 2.1, do we have to install the ndn-cxx from it >> sources or should we be installing it from the sources provided under >> ndnSIM, which I think is slightly modified version? If I just do not >> install it, ndnSIM configure obviously gives configure error (Checking for >> 'libndn-cxx' : not found). >> >> When I try to configure and install ndn-cxx which is included in ndnSIM, >> I hit the following error. >> >> Checking for 'sqlite3' : yes >> hecking Crypto++ lib : 563 >> Checking if CryptoPP library works : no >> Checking if CryptoPP library works : no >> CryptoPP is present, but is not usable >> (complete log in >> /home/anilj1/sandbox/ndnSIM/ns-3/src/ndnSIM/ndn-cxx/build/config.log) >> >> As can be seen I have already compiled and installed the latest version >> (5.6.3) of the cryptopp from its source. (Got the reference from here: >> http://redmine.named-data.net/issues/1700) but it is not helping. >> >> This redmine change is about an year old. However is there any change >> made in recent past to ndnSIM in this regard? >> >> /anil. >> >> > _______________________________________________ > ndnSIM mailing list > ndnSIM at lists.cs.ucla.edu > http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From aa at CS.UCLA.EDU Thu Dec 3 12:40:12 2015 From: aa at CS.UCLA.EDU (Alex Afanasyev) Date: Thu, 3 Dec 2015 12:40:12 -0800 Subject: [ndnSIM] ndn-cxx or ndnSIM/ndn-cxx? In-Reply-To: References: Message-ID: Hi Anil, I may have misread your original question. You don't need to install ndn-cxx bundled with ndnSIM. You just need to configure ns-3/ndnSIM as you would normally do. All necessary detection for dependencies derived from ndn-cxx is done as part of normal configure and build procedure. So. The steps, as per ndnsim.net are just: cd ./waf configure ...any-configure-flags-you're-using... ./waf > On Dec 3, 2015, at 10:24 AM, Anil Jangam wrote: > > Thanks Alex for your comments. > > So in this regard, is it proposed to remove the ndnSIM's dependency on ndn-cxx since configure fails if no ndn-cxx libraries are found. So your last statement isn't completely true OR it would justify the above proposed removal. > > /anil. > > On Wed, Dec 2, 2015 at 3:17 PM, Alex Afanasyev > wrote: > >> On Dec 1, 2015, at 7:50 PM, Anil Jangam > wrote: >> >> Thanks Spyros for the reply. >> >> Curious to know what is the difference between the ndn-cxx (its main source) and the one which is part of ndnSIM? This is the question from my below post, which I believe is not answered yet. >> >> When we configure/compile ndnSIM one of the prerequisite is ndn-cxx otherwise configure script fails. So my question is: do we install ndn-cxx from its main source or do we install it from the version which is part of ndnSIM source? >> >> When I install ndn-cxx it from the main source its compile goes through fine. However, when I try to compile and install ndn-cxx from the ndnSIM sources, I hit the error I reported in this thread. >> >> Can you please comment? > > Hi Anil, > > ndnSIM bundles (as a submodule) a specific version of ndn-cxx. This is to ensure that ndnSIM can be compiled even there are changes of the mainstream library. The actual bundled code is almost exactly the same as the mainstream, there is a very minor change and it is just not the most recent version. > > Same applies to the bundled NFD source code. It is a fixed version of NFD codebase with a few minor modifications. > > Installation of a stand-alone ndn-cxx/NFD will not have any effect on ndnSIM 2.1+. > > --- > Alex > >> >> /anil. >> >> >> On Mon, Nov 30, 2015 at 9:53 AM, Spyridon (Spyros) Mastorakis > wrote: >> Hi Anil, >> >> there was another thread about this issue. You may want to take a look at it: >> >> http://www.lists.cs.ucla.edu/pipermail/ndnsim/2015-November/002208.html >> >> Hope that this helps! >> >> Spyridon (Spyros) Mastorakis >> Personal Website: http://cs.ucla.edu/~mastorakis/ >> Internet Research Laboratory >> Computer Science Department >> UCLA >> >> >> >> >>> On Nov 30, 2015, at 9:44 AM, Anil Jangam > wrote: >>> >>> Hi, >>> >>> Before we compile ndnSIM 2.1, do we have to install the ndn-cxx from it sources or should we be installing it from the sources provided under ndnSIM, which I think is slightly modified version? If I just do not install it, ndnSIM configure obviously gives configure error (Checking for 'libndn-cxx' : not found). >>> >>> When I try to configure and install ndn-cxx which is included in ndnSIM, I hit the following error. >>> >>> Checking for 'sqlite3' : yes >>> hecking Crypto++ lib : 563 >>> Checking if CryptoPP library works : no >>> Checking if CryptoPP library works : no >>> CryptoPP is present, but is not usable >>> (complete log in /home/anilj1/sandbox/ndnSIM/ns-3/src/ndnSIM/ndn-cxx/build/config.log) >>> >>> As can be seen I have already compiled and installed the latest version (5.6.3) of the cryptopp from its source. (Got the reference from here: http://redmine.named-data.net/issues/1700 ) but it is not helping. >>> >>> This redmine change is about an year old. However is there any change made in recent past to ndnSIM in this regard? >>> >>> /anil. >> >> _______________________________________________ >> ndnSIM mailing list >> ndnSIM at lists.cs.ucla.edu >> http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim > > -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 841 bytes Desc: Message signed with OpenPGP using GPGMail URL: From aa at CS.UCLA.EDU Thu Dec 3 12:44:10 2015 From: aa at CS.UCLA.EDU (Alex Afanasyev) Date: Thu, 3 Dec 2015 12:44:10 -0800 Subject: [ndnSIM] interface management In-Reply-To: References: Message-ID: <515F9CD3-C708-467B-9A31-980E0865363A@cs.ucla.edu> Hi Natalya, NS-3, as I remember, doesn't provide a mechanism to remove channel/netdevice. As such, there is no corresponding part in ndnSIM. At the same time, the FaceTable code you found is to support tcp/udp faces of NFD, which can go up and down any time. Unfortunately, due to lack of manpower, we are still lagging behind implementation of IP-overlay faces in ndnSIM that would have functionality you need. It would be terrific if you or somebody else on the list helped with this implementation. --- Alex > On Dec 3, 2015, at 9:35 AM, Natalya Rozhnova wrote: > > Hi all, > > I would ask a question about the interface state management. > Is there in ndnSIM 2.1 something that do the following: > when interface goes physically down (say nomore channel or link or something else on physical layer) -> remove the corresponding face from FIB? > > How (and where) could I check it ? I would need this information in NFD forwarder. > > BTW I found the similar functionnality in FaceTable but didn't really get how the information about the interface is checked... Could anybody please explain it to me in more details? > I also found the function to check whether a face isUp() but it always returns true... > > thanks in advance, > Natalya > -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 841 bytes Desc: Message signed with OpenPGP using GPGMail URL: From NourElHouda.BenYoussef at oxia-group.com Thu Dec 3 03:13:43 2015 From: NourElHouda.BenYoussef at oxia-group.com (Nour El Houda Ben Youssef) Date: Thu, 3 Dec 2015 11:13:43 +0000 Subject: [ndnSIM] CalculateRoutes In-Reply-To: <505FD4B9-96EF-4EC0-8227-3C397E2A8125@ucla.edu> References: <712FE4E7257849499414892DD92704BC5FC71FA3@INFRAEX01.oxia.corp> <0DBC83D9-593C-466A-8AA7-2B80DF021BBC@ucla.edu> <712FE4E7257849499414892DD92704BC5FC72FCB@INFRAEX01.oxia.corp> <703EF5C8-C54C-40CF-AF7A-B4910CBF29EB@ucla.edu> <712FE4E7257849499414892DD92704BC5FC74025@INFRAEX01.oxia.corp> <712FE4E7257849499414892DD92704BC5FC740A8@INFRAEX01.oxia.corp> <505FD4B9-96EF-4EC0-8227-3C397E2A8125@ucla.edu> Message-ID: <712FE4E7257849499414892DD92704BC73233BFE@INFRAEX02.oxia.corp> Dear Alex I'm planning on comparing different forwarding strategies in a PLC topology built using the ns-3 PLC module To do so I change the forwarding strategy in each scenario and then run the simulation and collect delay using ndnSim application tracers If I work with defaultroutes does this mean that I'm not using the forwording starategy ? I doubted this because I'm having the same results with all the forwarding strategies ! I tried to use calculate routes to populate the FIB's but all the nodes are unreachable!!! Does this mean that there is a problem with the PLC_channel ?! Please help De : Alexander Afanasyev [mailto:cawka1 at gmail.com] De la part de Alex Afanasyev Envoy? : jeudi 17 juillet 2014 20:43 ? : Nour El Houda Ben Youssef Objet : Re: Using AddNetDeviceFaceCreateCallback Somehow, plc network device or channel don't support working with multiple protocols. If you check NetDeviceFace::Send, you'll see that Send operation specifies "L3Protocol::ETHERNET_FRAME_TYPE" as a protocol number. During registering ndn protocol, NetDeviceFace::RegisterProtocolHandlers, the same protocol was specified. Somehow, inside PLC module when packet arrives, it does not carry the proper protocol number and without the hack I suggested, NS-3 cannot properly dispatch packets to ndnSIM. --- Alex On Jul 17, 2014, at 12:56 AM, Nour El Houda Ben Youssef > wrote: Dear Alex I'm really thankful, I don't know by which miracle but the maneuver worked just fine I would like thought to understand what was the meaning of the changes that you recommended Best regards De : Alexander Afanasyev [mailto:cawka1 at gmail.com] De la part de Alex Afanasyev Envoy? : mercredi 16 juillet 2014 06:13 ? : Nour El Houda Ben Youssef Objet : Re: Using AddNetDeviceFaceCreateCallback You can try to replace L3Protocol::ETHERNET_FRAME_TYPE with 0 in ndn-net-device-face.cc (you may also set promisc mode to false). Two days ago I was observing a similar behavior as you described with lr-wpan module and the hack solved the problem. --- Alex On Jul 15, 2014, at 8:21 PM, Nour El Houda Ben Youssef > wrote: Well frankly it wasn't without difficulties especially that I'm new with ns3, but using this link was very helpful :https://github.com/jvaubourg/plc There was also need to disable python bindings before building the module and then I regenerated, using the semi-automatic way, all python bindings for plc Unfortunately I thought this was the hardest part but then I wasn't able to deploy ndn over a PLC topology :( After running few examples I noticed that interests are being sent then received at PLC_netdevice level but not reaching higher layers I think perhaps the problem is caused by PLC_mac I hope you build PLC module and then figure out the problem ! Best regards De : Alexander Afanasyev [mailto:cawka1 at gmail.com] De la part de Alex Afanasyev Envoy? : mardi 15 juillet 2014 18:33 ? : Nour El Houda Ben Youssef Objet : Re: Using AddNetDeviceFaceCreateCallback Ehm.. How did you manage to compile plc module in the first place? It seem to me that it works only with older version (ns-3.16), while the current ndnSIM was just rebased on top of ns-3.20... Even after I fixed the problems with wscript, I still cannot build the code due to some errors... --- Alex On Jul 15, 2014, at 12:33 AM, Nour El Houda Ben Youssef > wrote: Thank you for your quick answer Actually I do not need a particular initialization but ndn did not work over a PLC netdevice. I'm sure PLC netdevice works fine since I used it with Internet stack but when I try to deploy ndn stack over it interests are being sent but not received :( So I guessed it should need a customized callback The PLC module that I'm using can be found in: https://github.com/ns3-plc-module You can also find attached my script deploying ndn avec PLC Your help is really appreciated Best regards De : Alexander Afanasyev [mailto:cawka1 at gmail.com] De la part de Alex Afanasyev Envoy? : lundi 14 juillet 2014 18:39 ? : Nour El Houda Ben Youssef Objet : Re: Using AddNetDeviceFaceCreateCallback Hi, Technically, there is a default callback that should work with any class based on NetDevice. The callback is needed when you need to do custom initialization of the face (=creating custom version of ndn::Face for the netdevice). The example I have is here: https://github.com/cawka/ndnSIM-nom-rapid-car2car/blob/master/scenarios/car-relay.cc#L44 --- Alex On Jul 14, 2014, at 3:23 AM, Nour El Houda Ben Youssef > wrote: Dear Alexander I'm having trouble using ndnSim over a power line communication netdevice I would like to ask if there is any example showing me how to define a new NetDeviceFace Callback Best regards Nour El Houda Ben Youssef Koubaa Doctorante Mobidoc - OXIA/SAGE Mast?re nouvelle g?n?ration des syst?mes d'informations - FST Ing?nieur G?nie Logiciel - INSAT > -------------- next part -------------- An HTML attachment was scrubbed... URL: From rozhnova.natalya at gmail.com Fri Dec 4 09:32:57 2015 From: rozhnova.natalya at gmail.com (Natalya Rozhnova) Date: Fri, 4 Dec 2015 18:32:57 +0100 Subject: [ndnSIM] interface management In-Reply-To: <515F9CD3-C708-467B-9A31-980E0865363A@cs.ucla.edu> References: <515F9CD3-C708-467B-9A31-980E0865363A@cs.ucla.edu> Message-ID: Thanks Alex for you reply. Ok, let's see what we can do with it Best, Natalya 2015-12-03 21:44 GMT+01:00 Alex Afanasyev : > Hi Natalya, > > NS-3, as I remember, doesn't provide a mechanism to remove > channel/netdevice. As such, there is no corresponding part in ndnSIM. > > At the same time, the FaceTable code you found is to support tcp/udp faces > of NFD, which can go up and down any time. Unfortunately, due to lack of > manpower, we are still lagging behind implementation of IP-overlay faces in > ndnSIM that would have functionality you need. It would be terrific if you > or somebody else on the list helped with this implementation. > > --- > Alex > > > On Dec 3, 2015, at 9:35 AM, Natalya Rozhnova > wrote: > > > > Hi all, > > > > I would ask a question about the interface state management. > > Is there in ndnSIM 2.1 something that do the following: > > when interface goes physically down (say nomore channel or link or > something else on physical layer) -> remove the corresponding face from FIB? > > > > How (and where) could I check it ? I would need this information in NFD > forwarder. > > > > BTW I found the similar functionnality in FaceTable but didn't really > get how the information about the interface is checked... Could anybody > please explain it to me in more details? > > I also found the function to check whether a face isUp() but it always > returns true... > > > > thanks in advance, > > Natalya > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From z.rezaiefar at yahoo.com Mon Dec 7 15:14:46 2015 From: z.rezaiefar at yahoo.com (Zeinab) Date: Tue, 8 Dec 2015 08:14:46 +0900 Subject: [ndnSIM] Packet delivery in ndn Message-ID: <2169223E-F422-4572-BC4E-6D8A3F1F919E@yahoo.com> > Hello every one, > I am wondering if ndn does not use any information of users for sending Interest message, how this network deliver data to the user. Moreover, I would like to say that the Data message is passed the reverse path that interest message is received and each router saves the interface from where it receives this interest message. any how, if more than one user is connected to one interface ( for example in wireless network), the router broadcasts data message to all of them? if this can be happened, how they can control behavior of user and block the malicious user ? > Any help will be appreciated > thanks in advance > best regards -------------- next part -------------- An HTML attachment was scrubbed... URL: From aa at CS.UCLA.EDU Mon Dec 7 18:23:55 2015 From: aa at CS.UCLA.EDU (Alex Afanasyev) Date: Mon, 7 Dec 2015 18:23:55 -0800 Subject: [ndnSIM] Packet delivery in ndn In-Reply-To: <2169223E-F422-4572-BC4E-6D8A3F1F919E@yahoo.com> References: <2169223E-F422-4572-BC4E-6D8A3F1F919E@yahoo.com> Message-ID: > On Dec 7, 2015, at 3:14 PM, Zeinab wrote: > > Hello every one, > I am wondering if ndn does not use any information of users for sending Interest message, how this network deliver data to the user. Moreover, I would like to say that the Data message is passed the reverse path that interest message is received and each router saves the interface from where it receives this interest message. any how, if more than one user is connected to one interface ( for example in wireless network), the router broadcasts data message to all of them? if this can be happened, how they can control behavior of user and block the malicious user ? > Any help will be appreciated > thanks in advance > best regards Hi Zeinab, I don't have a single answer to your question. NFD support multiple modes of the forwarding data back, depending on how exactly users deliver interest packets to the router. Specifically, which face has been used: if interest was sent/received using multicast face, then the data packet is multicasted back too. If individual users send interest packets using unicast faces (e.g., UdpFace), then answer is unicasted to each requester. We also have in works modification to the multicast face, which would optionally allow unicasting of data packets (by recording and then using lower layer addressing). This could also include the option to ignore specific senders (or whitelist specific senders), though this may not be a very reliable mechanism. The default behavior in ndnSIM to use NetDeviceFace, which effectively is a multicast face. If in your simulation scenario you're using wireless network, then the response is multicasted/broadcasted. --- Alex -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 841 bytes Desc: Message signed with OpenPGP using GPGMail URL: From z.rezaiefar at yahoo.com Tue Dec 8 00:34:16 2015 From: z.rezaiefar at yahoo.com (Zeinab Rezaiefar) Date: Tue, 8 Dec 2015 08:34:16 +0000 (UTC) Subject: [ndnSIM] Packet delivery in ndn In-Reply-To: References: Message-ID: <182632647.17188066.1449563656392.JavaMail.yahoo@mail.yahoo.com> Hello Alex,I would like to say thanks for your guiding. actually my current scenario is wired but I want that each node can consider credibility for each neighbor ( the nodes which send message to it directly). for this reason, I consider credibility for each face that packet received from it . I am wondering that with consider credibility for each face , it can be equal to each neighbor.?however, I?have not?changed??NetDeviceFace . I should change default to consider unicast? if I should change , how can I change it.I am looking forward to hearing youthanks in advancebest regards On Tuesday, December 8, 2015 11:23 AM, Alex Afanasyev wrote: On Dec 7, 2015, at 3:14 PM, Zeinab wrote: Hello every one, I am wondering if ndn does not use any information of users for sending Interest message, how this network deliver data to the user. ?Moreover, I would like to say that the Data message is passed the reverse path that interest message is received and each router saves the interface from where it receives this interest message. any how, if more than one user is connected to one interface ( for example in wireless network), the router broadcasts data message to all of them? if this can be happened, how they can control behavior of user and block the malicious user ? Any help will be appreciated? thanks in advance best regards Hi Zeinab, I don't have a single answer to your question. ?NFD support multiple modes of the forwarding data back, depending on how exactly users deliver interest packets to the router. ?Specifically, which face has been used: if interest was sent/received using multicast face, then the data packet is multicasted back too. ?If individual users send interest packets using unicast faces (e.g., UdpFace), then answer is unicasted to each requester. ?We also have in works modification to the multicast face, which would optionally allow unicasting of data packets (by recording and then using lower layer addressing). ?This could also include the option to ignore specific senders (or whitelist specific senders), though this may not be a very reliable mechanism. The default behavior in ndnSIM to use NetDeviceFace, which effectively is a multicast face. ?If in your simulation scenario you're using wireless network, then the response is multicasted/broadcasted. ---Alex -------------- next part -------------- An HTML attachment was scrubbed... URL: From rozhnova.natalya at gmail.com Tue Dec 8 01:32:48 2015 From: rozhnova.natalya at gmail.com (Natalya Rozhnova) Date: Tue, 8 Dec 2015 10:32:48 +0100 Subject: [ndnSIM] NetDeviceFace Message-ID: Hi all, I wonder what the class NetDeviceFace is used for in ndnSIM/NFD? I thought it links NetDevice and Face objects but practically it is never called (when I try to print anything in the constructor of NetDeviceFace, it does not, so I suppose that it's never created)... Could anybody please clarify this point to me? thanks in advance, Best, Natalya -------------- next part -------------- An HTML attachment was scrubbed... URL: From rozhnova.natalya at gmail.com Tue Dec 8 01:53:37 2015 From: rozhnova.natalya at gmail.com (Natalya Rozhnova) Date: Tue, 8 Dec 2015 10:53:37 +0100 Subject: [ndnSIM] NetDeviceFace In-Reply-To: References: Message-ID: I'm sorry, I were using the NS_LOG to print the info but didn't connect to the right one. :) But I still would like to know a little more details about NetDeviceFace and who and why call it? Thanks, Natalya 2015-12-08 10:32 GMT+01:00 Natalya Rozhnova : > Hi all, > > I wonder what the class NetDeviceFace is used for in ndnSIM/NFD? > I thought it links NetDevice and Face objects but practically it is never > called (when I try to print anything in the constructor of NetDeviceFace, > it does not, so I suppose that it's never created)... > > Could anybody please clarify this point to me? > > thanks in advance, > Best, > Natalya > -------------- next part -------------- An HTML attachment was scrubbed... URL: From rozhnova.natalya at gmail.com Thu Dec 10 03:02:26 2015 From: rozhnova.natalya at gmail.com (Natalya Rozhnova) Date: Thu, 10 Dec 2015 12:02:26 +0100 Subject: [ndnSIM] Delete a pitEntry (not so easy as it seems to be) Message-ID: Hi all, It's me again. :) The task I want to perform is to iterate in the Pit in order to find some interesting entries and delete them. I just discovered that the Pit iterators return const nfd::pit::Entry& but the function erase takes shared_ptr as parameter. I can't create the shared_ptr with make_shared because the class is protected by "noncopyable". So I can't delete the entries I want by iterating in the pit... Is there any other way to do it? Thanks in advance. Best, Natalya -------------- next part -------------- An HTML attachment was scrubbed... URL: From shijunxiao at email.arizona.EDU Thu Dec 10 08:40:41 2015 From: shijunxiao at email.arizona.EDU (Junxiao Shi) Date: Thu, 10 Dec 2015 09:40:41 -0700 Subject: [ndnSIM] Delete a pitEntry (not so easy as it seems to be) In-Reply-To: References: Message-ID: Hi Natalya You may invoke Pit::insert again with the same Interest, which would return the same entry as a shared_ptr. Then you can erase this entry. Yours, Junxiao On Thu, Dec 10, 2015 at 4:02 AM, Natalya Rozhnova < rozhnova.natalya at gmail.com> wrote: > Hi all, > > It's me again. :) > The task I want to perform is to iterate in the Pit in order to find some > interesting entries and delete them. > I just discovered that the Pit iterators return const nfd::pit::Entry& but > the function erase takes shared_ptr as parameter. I can't > create the shared_ptr with make_shared because the class is protected by > "noncopyable". So I can't delete the entries I want by iterating in the > pit... > Is there any other way to do it? > > Thanks in advance. > Best, > Natalya > > _______________________________________________ > ndnSIM mailing list > ndnSIM at lists.cs.ucla.edu > http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From carlzu8 at gmail.com Thu Dec 10 09:51:45 2015 From: carlzu8 at gmail.com (Carl Zu) Date: Thu, 10 Dec 2015 18:51:45 +0100 Subject: [ndnSIM] know about all the faces of a node Message-ID: Hi, I know that we can know about the upstream faces for some prefix by calling "fibEntry->getNextHops ()". However imagine I would like to know about all the faces of a node without looking up the FIB. I even do not care about any particular prefixes...Just would like to know all the faces of a node. How I can do that ? Thanks in advance. Regards, C -------------- next part -------------- An HTML attachment was scrubbed... URL: From shijunxiao at email.arizona.EDU Thu Dec 10 13:31:16 2015 From: shijunxiao at email.arizona.EDU (Junxiao Shi) Date: Thu, 10 Dec 2015 14:31:16 -0700 Subject: [ndnSIM] know about all the faces of a node In-Reply-To: References: Message-ID: Hi Carl You may use the FaceTable. It's accessible at Strategy::getFaceTable and Forwarder::getFaceTable. Yours, Junxiao On Thu, Dec 10, 2015 at 10:51 AM, Carl Zu wrote: > Hi, > > I know that we can know about the upstream faces for some prefix by > calling "fibEntry->getNextHops ()". However imagine I would like to know > about all the faces of a node without looking up the FIB. I even do not > care about any particular prefixes...Just would like to know all the faces > of a node. How I can do that ? > > Thanks in advance. > > Regards, > C > > _______________________________________________ > ndnSIM mailing list > ndnSIM at lists.cs.ucla.edu > http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From mastorakis at CS.UCLA.EDU Thu Dec 10 15:32:19 2015 From: mastorakis at CS.UCLA.EDU (Spyridon (Spyros) Mastorakis) Date: Thu, 10 Dec 2015 15:32:19 -0800 Subject: [ndnSIM] [Ndn-interest] CalculateRoutes In-Reply-To: <712FE4E7257849499414892DD92704BC73233BFE@INFRAEX02.oxia.corp> References: <712FE4E7257849499414892DD92704BC5FC71FA3@INFRAEX01.oxia.corp> <0DBC83D9-593C-466A-8AA7-2B80DF021BBC@ucla.edu> <712FE4E7257849499414892DD92704BC5FC72FCB@INFRAEX01.oxia.corp> <703EF5C8-C54C-40CF-AF7A-B4910CBF29EB@ucla.edu> <712FE4E7257849499414892DD92704BC5FC74025@INFRAEX01.oxia.corp> <712FE4E7257849499414892DD92704BC5FC740A8@INFRAEX01.oxia.corp> <505FD4B9-96EF-4EC0-8227-3C397E2A8125@ucla.edu> <712FE4E7257849499414892DD92704BC73233BFE@INFRAEX02.oxia.corp> Message-ID: <0CA9CE3C-13BB-48C9-BB46-AD7B50ECFA73@cs.ucla.edu> Hi, if you work with default routes, FIB entries containing the ?/? prefix would be added for each created face. The forwarding strategy module would still be used, but depending on the simulation scenario, it may not be effective. Hope that this helps. Spyridon (Spyros) Mastorakis Personal Website: http://cs.ucla.edu/~mastorakis/ Internet Research Laboratory Computer Science Department UCLA > On Dec 3, 2015, at 3:13 AM, Nour El Houda Ben Youssef wrote: > > Dear Alex > > I?m planning on comparing different forwarding strategies in a PLC topology built using the ns-3 PLC module > > To do so I change the forwarding strategy in each scenario and then run the simulation and collect delay using ndnSim application tracers > > If I work with defaultroutes does this mean that I?m not using the forwording starategy ? > > I doubted this because I?m having the same results with all the forwarding strategies ! > > I tried to use calculate routes to populate the FIB?s but all the nodes are unreachable!!! > > Does this mean that there is a problem with the PLC_channel ?! > > > Please help > > > De : Alexander Afanasyev [mailto:cawka1 at gmail.com ] De la part de Alex Afanasyev > Envoy? : jeudi 17 juillet 2014 20:43 > ? : Nour El Houda Ben Youssef > Objet : Re: Using AddNetDeviceFaceCreateCallback > > Somehow, plc network device or channel don't support working with multiple protocols. If you check NetDeviceFace::Send, you'll see that Send operation specifies "L3Protocol::ETHERNET_FRAME_TYPE" as a protocol number. During registering ndn protocol, NetDeviceFace::RegisterProtocolHandlers, the same protocol was specified. Somehow, inside PLC module when packet arrives, it does not carry the proper protocol number and without the hack I suggested, NS-3 cannot properly dispatch packets to ndnSIM. > > --- > Alex > > On Jul 17, 2014, at 12:56 AM, Nour El Houda Ben Youssef > wrote: > > > Dear Alex > I?m really thankful, I don?t know by which miracle but the maneuver worked just fine > I would like thought to understand what was the meaning of the changes that you recommended > > Best regards > > > De : Alexander Afanasyev [mailto:cawka1 at gmail.com ] De la part de Alex Afanasyev > Envoy? : mercredi 16 juillet 2014 06:13 > ? : Nour El Houda Ben Youssef > Objet : Re: Using AddNetDeviceFaceCreateCallback > > You can try to replace L3Protocol::ETHERNET_FRAME_TYPE with 0 in ndn-net-device-face.cc (you may also set promisc mode to false). > > Two days ago I was observing a similar behavior as you described with lr-wpan module and the hack solved the problem. > > --- > Alex > > On Jul 15, 2014, at 8:21 PM, Nour El Houda Ben Youssef > wrote: > > > > Well frankly it wasn?t without difficulties especially that I?m new with ns3, but using this link was very helpful :https://github.com/jvaubourg/plc > There was also need to disable python bindings before building the module and then I regenerated, using the semi-automatic way, all python bindings for plc > > Unfortunately I thought this was the hardest part but then I wasn?t able to deploy ndn over a PLC topology L > After running few examples I noticed that interests are being sent then received at PLC_netdevice level but not reaching higher layers > I think perhaps the problem is caused by PLC_mac > I hope you build PLC module and then figure out the problem ! > > Best regards > > > De : Alexander Afanasyev [mailto:cawka1 at gmail.com ] De la part de Alex Afanasyev > Envoy? : mardi 15 juillet 2014 18:33 > ? : Nour El Houda Ben Youssef > Objet : Re: Using AddNetDeviceFaceCreateCallback > > Ehm.. How did you manage to compile plc module in the first place? It seem to me that it works only with older version (ns-3.16), while the current ndnSIM was just rebased on top of ns-3.20... > > Even after I fixed the problems with wscript, I still cannot build the code due to some errors... > > --- > Alex > > On Jul 15, 2014, at 12:33 AM, Nour El Houda Ben Youssef > wrote: > > > > > Thank you for your quick answer > Actually I do not need a particular initialization but ndn did not work over a PLC netdevice. I?m sure PLC netdevice works fine since I used it with Internet stack but when I try to deploy ndn stack over it interests are being sent but not received L So I guessed it should need a customized callback > The PLC module that I?m using can be found in: https://github.com/ns3-plc-module > You can also find attached my script deploying ndn avec PLC > > Your help is really appreciated > Best regards > > De : Alexander Afanasyev [mailto:cawka1 at gmail.com ] De la part de Alex Afanasyev > Envoy? : lundi 14 juillet 2014 18:39 > ? : Nour El Houda Ben Youssef > Objet : Re: Using AddNetDeviceFaceCreateCallback > > Hi, > > Technically, there is a default callback that should work with any class based on NetDevice. > > The callback is needed when you need to do custom initialization of the face (=creating custom version of ndn::Face for the netdevice). The example I have is here: https://github.com/cawka/ndnSIM-nom-rapid-car2car/blob/master/scenarios/car-relay.cc#L44 > > --- > Alex > > On Jul 14, 2014, at 3:23 AM, Nour El Houda Ben Youssef > wrote: > > > > > > Dear Alexander > I?m having trouble using ndnSim over a power line communication netdevice > > I would like to ask if there is any example showing me how to define a new NetDeviceFace Callback > > Best regards > > Nour El Houda Ben Youssef Koubaa > Doctorante Mobidoc - OXIA/SAGE > Mast?re nouvelle g?n?ration des syst?mes d'informations - FST > Ing?nieur G?nie Logiciel - INSAT > > > > > _______________________________________________ > Ndn-interest mailing list > Ndn-interest at lists.cs.ucla.edu > http://www.lists.cs.ucla.edu/mailman/listinfo/ndn-interest -------------- next part -------------- An HTML attachment was scrubbed... URL: From mastorakis at CS.UCLA.EDU Thu Dec 10 15:40:21 2015 From: mastorakis at CS.UCLA.EDU (Spyridon (Spyros) Mastorakis) Date: Thu, 10 Dec 2015 15:40:21 -0800 Subject: [ndnSIM] NetDeviceFace In-Reply-To: References: Message-ID: <19450670-5C7C-4232-91C1-D520371721B2@cs.ucla.edu> Hi Natalya, NetDeviceFace objects are created by the Stack Helper: https://github.com/named-data-ndnSIM/ndnSIM/blob/master/helper/ndn-stack-helper.cpp#L282 A NetDeviceFace is the way that simulated nodes communicate with each other. A NetDeviceFace is associated with a NetDevice object. This object is used by NS3, so that each simulated node communicates with another node. Spyridon (Spyros) Mastorakis Personal Website: http://cs.ucla.edu/~mastorakis/ Internet Research Laboratory Computer Science Department UCLA > On Dec 8, 2015, at 1:53 AM, Natalya Rozhnova wrote: > > I'm sorry, I were using the NS_LOG to print the info but didn't connect to the right one. :) > But I still would like to know a little more details about NetDeviceFace and who and why call it? > > Thanks, > Natalya > > 2015-12-08 10:32 GMT+01:00 Natalya Rozhnova >: > Hi all, > > I wonder what the class NetDeviceFace is used for in ndnSIM/NFD? > I thought it links NetDevice and Face objects but practically it is never called (when I try to print anything in the constructor of NetDeviceFace, it does not, so I suppose that it's never created)... > > Could anybody please clarify this point to me? > > thanks in advance, > Best, > Natalya > > _______________________________________________ > ndnSIM mailing list > ndnSIM at lists.cs.ucla.edu > http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim -------------- next part -------------- An HTML attachment was scrubbed... URL: From aa at CS.UCLA.EDU Thu Dec 10 15:45:08 2015 From: aa at CS.UCLA.EDU (Alex Afanasyev) Date: Thu, 10 Dec 2015 15:45:08 -0800 Subject: [ndnSIM] Delete a pitEntry (not so easy as it seems to be) In-Reply-To: References: Message-ID: <1342E58F-5093-4CE8-BD43-5D3CFB7DECCD@cs.ucla.edu> Hi Natalya, This seem to be a deficiency in the current interface that we should fix asap. As an immediate workaround, which could be faster then what Junxiao suggested, but not future-safe code: auto pitIterator = pit.begin(); // ... shared_ptr pitEntry = pitIterator.operator->(); pit.erase(pitEntry); --- Alex > On Dec 10, 2015, at 8:40 AM, Junxiao Shi wrote: > > Hi Natalya > > You may invoke Pit::insert again with the same Interest, which would return the same entry as a shared_ptr. > Then you can erase this entry. > > Yours, Junxiao > > On Thu, Dec 10, 2015 at 4:02 AM, Natalya Rozhnova > wrote: > Hi all, > > It's me again. :) > The task I want to perform is to iterate in the Pit in order to find some interesting entries and delete them. > I just discovered that the Pit iterators return const nfd::pit::Entry& but the function erase takes shared_ptr as parameter. I can't create the shared_ptr with make_shared because the class is protected by "noncopyable". So I can't delete the entries I want by iterating in the pit... > Is there any other way to do it? > > Thanks in advance. > Best, > Natalya -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 841 bytes Desc: Message signed with OpenPGP using GPGMail URL: From aa at CS.UCLA.EDU Thu Dec 10 15:55:46 2015 From: aa at CS.UCLA.EDU (Alex Afanasyev) Date: Thu, 10 Dec 2015 15:55:46 -0800 Subject: [ndnSIM] NetDeviceFace In-Reply-To: References: Message-ID: > On Dec 8, 2015, at 1:32 AM, Natalya Rozhnova wrote: > > Hi all, > > I wonder what the class NetDeviceFace is used for in ndnSIM/NFD? > I thought it links NetDevice and Face objects but practically it is never called (when I try to print anything in the constructor of NetDeviceFace, it does not, so I suppose that it's never created)... I think there is a small confusion here. NetDeviceFace instance is a face object, which happens to communicate to external nodes using send/receive functionality of NS-3's NetDevice. As of now (this will not be true in the next version of NFD), there is no just Face object. Each face is instance of a specific type of the face: one that works using NetDevice, one that works for the NS-3 applications, (in future) using UDP socket simulation, etc. I guess after you have corrected NS_LOG to include ndn.NetDeviceFace, you saw more messages: - an instance of NetDeviceFace is created by ndn::StackHelper for each corresponding NetDevice found on nodes - when FIB is configured to send interests through the face, you will see logs for each send and receive call. --- Alex > > Could anybody please clarify this point to me? > > thanks in advance, > Best, > Natalya -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 841 bytes Desc: Message signed with OpenPGP using GPGMail URL: From rozhnova.natalya at gmail.com Fri Dec 11 06:07:32 2015 From: rozhnova.natalya at gmail.com (Natalya Rozhnova) Date: Fri, 11 Dec 2015 15:07:32 +0100 Subject: [ndnSIM] Delete a pitEntry (not so easy as it seems to be) In-Reply-To: <1342E58F-5093-4CE8-BD43-5D3CFB7DECCD@cs.ucla.edu> References: <1342E58F-5093-4CE8-BD43-5D3CFB7DECCD@cs.ucla.edu> Message-ID: Hi Alex, Junxiao, Thank you very much for your replies. Indeed, Alex's solution seems to be much faster than re-insert a pit entry. Anyway, thanks to you two for the support! Best, Natalya 2015-12-11 0:45 GMT+01:00 Alex Afanasyev : > Hi Natalya, > > This seem to be a deficiency in the current interface that we should fix > asap. > > As an immediate workaround, which could be faster then what Junxiao > suggested, but not future-safe code: > > auto pitIterator = pit.begin(); > // ... > shared_ptr pitEntry = pitIterator.operator->(); > pit.erase(pitEntry); > > --- > Alex > > On Dec 10, 2015, at 8:40 AM, Junxiao Shi > wrote: > > Hi Natalya > > You may invoke Pit::insert again with the same Interest, which would > return the same entry as a shared_ptr. > Then you can erase this entry. > > Yours, Junxiao > > On Thu, Dec 10, 2015 at 4:02 AM, Natalya Rozhnova < > rozhnova.natalya at gmail.com> wrote: > >> Hi all, >> >> It's me again. :) >> The task I want to perform is to iterate in the Pit in order to find some >> interesting entries and delete them. >> I just discovered that the Pit iterators return const nfd::pit::Entry& >> but the function erase takes shared_ptr as parameter. I can't >> create the shared_ptr with make_shared because the class is protected by >> "noncopyable". So I can't delete the entries I want by iterating in the >> pit... >> Is there any other way to do it? >> >> Thanks in advance. >> Best, >> Natalya >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From anilj.mailing at gmail.com Sat Dec 19 14:43:44 2015 From: anilj.mailing at gmail.com (Anil Jangam) Date: Sat, 19 Dec 2015 14:43:44 -0800 Subject: [ndnSIM] Conversion from ns3::Application to specific application type. Message-ID: Hi, In a scenario where an application instance is installed on the nodes, what is the way to retrieve that application instance from the node? In my requirement, I want to set some parameters into my application object, which is not possible at the time it is installed on the node. Perhaps they all do not use the parametrized constructor (I am talking about the classes in ns-3/src/ndnSIM/apps path). In an example below: 80 ndn::AppHelper consumerHelper("ns3::ndn::ConsumerCbr"); 83 consumerHelper.Install(consumerNodes); I want to retrieve back the instance of "ns3::ndn::ConsumerCbr" from the consumerNodes object. I checked the API in bit details, the ndn-app-helper has this code: 119 Ptr app = m_factory.Create(); 120 node->AddApplication(app); The node interface also provides an API GetApplication, but it returns Application instance: 160 Ptr 161 Node::GetApplication (uint32_t index) const How to convert it from ns3::Application to ns3::ndn::ConsumerCbr? Perhaps this is simple type casting operation, but just want to confirm it. Any other suggestion to achieve the same (i.e. updating the application instance installed on the node) is also fine with me. /anil. -------------- next part -------------- An HTML attachment was scrubbed... URL: From shijunxiao at email.arizona.edu Sat Dec 19 15:00:49 2015 From: shijunxiao at email.arizona.edu (Junxiao Shi) Date: Sat, 19 Dec 2015 16:00:49 -0700 Subject: [ndnSIM] Conversion from ns3::Application to specific application type. In-Reply-To: References: Message-ID: Hi Anil To get Ptr from Ptr, you may use type-casting or ->GetObject(). The proper way to set a parameter onto an application object is through ns-3 attributes. See ns-3 Manual < https://www.nsnam.org/docs/release/3.24/manual/html/index.html> "Object Model" and "Configuration and Attributes" section for more information. Yours, Junxiao On Dec 19, 2015 3:45 PM, "Anil Jangam" wrote: > Hi, > > In a scenario where an application instance is installed on the nodes, > what is the way to retrieve that application instance from the node? > > In my requirement, I want to set some parameters into my application > object, which is not possible at the time it is installed on the node. > Perhaps they all do not use the parametrized constructor (I am talking > about the classes in ns-3/src/ndnSIM/apps path). > > In an example below: > 80 ndn::AppHelper consumerHelper("ns3::ndn::ConsumerCbr"); > 83 consumerHelper.Install(consumerNodes); > > I want to retrieve back the instance of "ns3::ndn::ConsumerCbr" from the > consumerNodes object. > > I checked the API in bit details, the ndn-app-helper has this code: > 119 Ptr app = m_factory.Create(); > 120 node->AddApplication(app); > > The node interface also provides an API GetApplication, but it returns > Application instance: > 160 Ptr > 161 Node::GetApplication (uint32_t index) const > > How to convert it from ns3::Application to ns3::ndn::ConsumerCbr? Perhaps > this is simple type casting operation, but just want to confirm it. > > Any other suggestion to achieve the same (i.e. updating the application > instance installed on the node) is also fine with me. > > /anil. > > > > _______________________________________________ > ndnSIM mailing list > ndnSIM at lists.cs.ucla.edu > http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From anilj.mailing at gmail.com Sat Dec 19 18:12:30 2015 From: anilj.mailing at gmail.com (Anil Jangam) Date: Sat, 19 Dec 2015 18:12:30 -0800 Subject: [ndnSIM] Conversion from ns3::Application to specific application type. In-Reply-To: References: Message-ID: Thanks Junxiao, I did not understand how Application object is installed using AddApplication() in the Install() method of AppHelper and yet it can be retrieved by node->GetObject(). This API is not symmetric but it working! ->GetObject(), I think is typically used when the object is added to the node by aggregate() function, isn't it? Since the install uses AddApplication() I think we can use GetApplication() to get reference to installed application. My type casting is failing at compile time. error: invalid conversion from ?ns3::Application*? to ?ns3::ndn::NlsrApp*? [-fpermissive] The corresponding line is. So what kind of type casting required here? Ptr nlsrApp = (Ptr) (*i)->GetApplication(0); AFA setting attributes is concerned, I do not know how it works. I want to set the config object into the application used inside the application's logic. To give an analogy, I am trying to set the configuration object inside the app::RealApp. I have exact same implementation as given here: http://ndnsim.net/2.1/guide-to-simulate-real-apps.html (Read from : How to simulate real applications...) /anil. On Sat, Dec 19, 2015 at 3:00 PM, Junxiao Shi wrote: > Hi Anil > > To get Ptr from Ptr, you may use type-casting or > ->GetObject(). > > The proper way to set a parameter onto an application object is through > ns-3 attributes. > > See ns-3 Manual < > https://www.nsnam.org/docs/release/3.24/manual/html/index.html> "Object > Model" and "Configuration and Attributes" section for more information. > > Yours, Junxiao > On Dec 19, 2015 3:45 PM, "Anil Jangam" wrote: > >> Hi, >> >> In a scenario where an application instance is installed on the nodes, >> what is the way to retrieve that application instance from the node? >> >> In my requirement, I want to set some parameters into my application >> object, which is not possible at the time it is installed on the node. >> Perhaps they all do not use the parametrized constructor (I am talking >> about the classes in ns-3/src/ndnSIM/apps path). >> >> In an example below: >> 80 ndn::AppHelper consumerHelper("ns3::ndn::ConsumerCbr"); >> 83 consumerHelper.Install(consumerNodes); >> >> I want to retrieve back the instance of "ns3::ndn::ConsumerCbr" from the >> consumerNodes object. >> >> I checked the API in bit details, the ndn-app-helper has this code: >> 119 Ptr app = m_factory.Create(); >> 120 node->AddApplication(app); >> >> The node interface also provides an API GetApplication, but it returns >> Application instance: >> 160 Ptr >> 161 Node::GetApplication (uint32_t index) const >> >> How to convert it from ns3::Application to ns3::ndn::ConsumerCbr? Perhaps >> this is simple type casting operation, but just want to confirm it. >> >> Any other suggestion to achieve the same (i.e. updating the application >> instance installed on the node) is also fine with me. >> >> /anil. >> >> >> >> _______________________________________________ >> ndnSIM mailing list >> ndnSIM at lists.cs.ucla.edu >> http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim >> >> -------------- next part -------------- An HTML attachment was scrubbed... URL: From anilj.mailing at gmail.com Sat Dec 26 00:27:13 2015 From: anilj.mailing at gmail.com (Anil Jangam) Date: Sat, 26 Dec 2015 00:27:13 -0800 Subject: [ndnSIM] Conversion from ns3::Application to specific application type. In-Reply-To: References: Message-ID: This the correct way to get the reference to the installed application instance. Ptr nlsrApp = (*i)->GetApplication(0)->GetObject (); Also thanks to this "ns3-users" post, where I get the answer from. https://groups.google.com/forum/#!topic/ns-3-users/nvCaq98lRBY /anil. On Sat, Dec 19, 2015 at 6:12 PM, Anil Jangam wrote: > Thanks Junxiao, > > I did not understand how Application object is installed using > AddApplication() in the Install() method of AppHelper and yet it can be > retrieved by node->GetObject(). This API is not symmetric but > it working! > > ->GetObject(), I think is typically used when the object is > added to the node by aggregate() function, isn't it? > > Since the install uses AddApplication() I think we can use > GetApplication() to get reference to installed application. My type casting > is failing at compile time. > > error: invalid conversion from ?ns3::Application*? to ?ns3::ndn::NlsrApp*? > [-fpermissive] > > The corresponding line is. So what kind of type casting required here? > Ptr nlsrApp = (Ptr) (*i)->GetApplication(0); > > AFA setting attributes is concerned, I do not know how it works. I want to > set the config object into the application used inside the application's > logic. To give an analogy, I am trying to set the configuration object > inside the app::RealApp. > I have exact same implementation as given here: > http://ndnsim.net/2.1/guide-to-simulate-real-apps.html (Read from : How > to simulate real applications...) > > /anil. > > > > On Sat, Dec 19, 2015 at 3:00 PM, Junxiao Shi > wrote: > >> Hi Anil >> >> To get Ptr from Ptr, you may use type-casting >> or ->GetObject(). >> >> The proper way to set a parameter onto an application object is through >> ns-3 attributes. >> >> See ns-3 Manual < >> https://www.nsnam.org/docs/release/3.24/manual/html/index.html> "Object >> Model" and "Configuration and Attributes" section for more information. >> >> Yours, Junxiao >> On Dec 19, 2015 3:45 PM, "Anil Jangam" wrote: >> >>> Hi, >>> >>> In a scenario where an application instance is installed on the nodes, >>> what is the way to retrieve that application instance from the node? >>> >>> In my requirement, I want to set some parameters into my application >>> object, which is not possible at the time it is installed on the node. >>> Perhaps they all do not use the parametrized constructor (I am talking >>> about the classes in ns-3/src/ndnSIM/apps path). >>> >>> In an example below: >>> 80 ndn::AppHelper consumerHelper("ns3::ndn::ConsumerCbr"); >>> 83 consumerHelper.Install(consumerNodes); >>> >>> I want to retrieve back the instance of "ns3::ndn::ConsumerCbr" from the >>> consumerNodes object. >>> >>> I checked the API in bit details, the ndn-app-helper has this code: >>> 119 Ptr app = m_factory.Create(); >>> 120 node->AddApplication(app); >>> >>> The node interface also provides an API GetApplication, but it returns >>> Application instance: >>> 160 Ptr >>> 161 Node::GetApplication (uint32_t index) const >>> >>> How to convert it from ns3::Application to ns3::ndn::ConsumerCbr? >>> Perhaps this is simple type casting operation, but just want to confirm it. >>> >>> Any other suggestion to achieve the same (i.e. updating the application >>> instance installed on the node) is also fine with me. >>> >>> /anil. >>> >>> >>> >>> _______________________________________________ >>> ndnSIM mailing list >>> ndnSIM at lists.cs.ucla.edu >>> http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim >>> >>> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From sarantarnoi at gmail.com Mon Dec 28 01:05:22 2015 From: sarantarnoi at gmail.com (Saran Tarnoi) Date: Mon, 28 Dec 2015 18:05:22 +0900 Subject: [ndnSIM] How to get node id in lru-policy.hpp Message-ID: Dear All, I would like to get node id (or the node name) while being in lru-policy.hpp for logging purpose. I am using ndnSIM-2.0. A solution found at http://www.lists.cs.ucla.edu/pipermail/ndnsim/2014-May/001307.html did not work. I have no idea how I can get a pointer to Node from here. Could you give me some pieces of advice? Thanks a lot in advance for your help. -- Best regards, Saran Tarnoi -------------- next part -------------- An HTML attachment was scrubbed... URL: From aa at CS.UCLA.EDU Mon Dec 28 09:01:51 2015 From: aa at CS.UCLA.EDU (Alex Afanasyev) Date: Mon, 28 Dec 2015 09:01:51 -0800 Subject: [ndnSIM] How to get node id in lru-policy.hpp In-Reply-To: References: Message-ID: <4CFB43EA-22EB-46C3-BE44-A3055B7F5632@cs.ucla.edu> Hi Saran, The solution you found is getting access to nodeId from the ndnSIM 1.0 strategy. For the caching policy, you can do the following: item->payload()->GetContentStore()->GetObject()->GetId() You can also use the following (cheaty) solution that can work in most of the places: Simulator::GetContext(); // context ID == nodeId -- Alex > On Dec 28, 2015, at 1:05 AM, Saran Tarnoi wrote: > > Dear All, > > I would like to get node id (or the node name) while being in lru-policy.hpp for logging purpose. > I am using ndnSIM-2.0. A solution found at http://www.lists.cs.ucla.edu/pipermail/ndnsim/2014-May/001307.html did not work. I have no idea how I can get a pointer to Node from here. > > Could you give me some pieces of advice? > > Thanks a lot in advance for your help. > > -- > Best regards, > Saran Tarnoi -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 841 bytes Desc: Message signed with OpenPGP using GPGMail URL: From anilj.mailing at gmail.com Mon Dec 28 11:23:12 2015 From: anilj.mailing at gmail.com (Anil Jangam) Date: Mon, 28 Dec 2015 11:23:12 -0800 Subject: [ndnSIM] Failed to register prefix in local hub's daemon Message-ID: Hi, I am testing a scenario of NLSR simulation and hitting an exception in ndnSIM. I searched for the error in the past learned that I need to start the NFD and NRD processes, but that suggestion was in case of real applications. What is the cause of this in the simulation setup? Am I missing any environment setup, which is leading to this error? 4.227s ndn-cxx.Face:expressInterest(): >> Interest: /ndn/NLSR/sync/00 4.227s ndn-cxx.Face:expressInterest(): >> Interest: /ndn/NLSR/sync/00 4.227s ndn-cxx.Face:expressInterest(): >> Interest: /ndn/NLSR/sync/00 8.487s ndn-cxx.Face:expressInterest(): >> Interest: /ndn/NLSR/sync/00 8.487s ndn-cxx.Face:expressInterest(): >> Interest: /ndn/NLSR/sync/00 8.487s ndn-cxx.Face:expressInterest(): >> Interest: /ndn/NLSR/sync/00 10s HelloProtocol:scheduleInterest(): Scheduling HELLO Interests in 5 seconds 10s HelloProtocol:scheduleInterest(): Scheduling HELLO Interests in 5 seconds 10s HelloProtocol:scheduleInterest(): Scheduling HELLO Interests in 5 seconds ERROR: Failed to register prefix in local hub's daemon terminate called after throwing an instance of 'nlsr::Nlsr::Error' what(): Error: Prefix registration failed Program received signal SIGABRT, Aborted. 0x00007fffe99cccc9 in __GI_raise (sig=sig at entry=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:56 56 ../nptl/sysdeps/unix/sysv/linux/raise.c: No such file or directory. /anil. -------------- next part -------------- An HTML attachment was scrubbed... URL: From aa at CS.UCLA.EDU Mon Dec 28 12:06:08 2015 From: aa at CS.UCLA.EDU (Alex Afanasyev) Date: Mon, 28 Dec 2015 12:06:08 -0800 Subject: [ndnSIM] Failed to register prefix in local hub's daemon In-Reply-To: References: Message-ID: Most likely you're starting your NLSR application at time moment 0. You need to schedule the start at a later time moment (say, 1second). Otherwise, ndn::Face::registerPrefix() will always fail. --- Alex > On Dec 28, 2015, at 11:23 AM, Anil Jangam wrote: > > Hi, > > I am testing a scenario of NLSR simulation and hitting an exception in ndnSIM. I searched for the error in the past learned that I need to start the NFD and NRD processes, but that suggestion was in case of real applications. What is the cause of this in the simulation setup? > > Am I missing any environment setup, which is leading to this error? > > 4.227s ndn-cxx.Face:expressInterest(): >> Interest: /ndn/NLSR/sync/00 > 4.227s ndn-cxx.Face:expressInterest(): >> Interest: /ndn/NLSR/sync/00 > 4.227s ndn-cxx.Face:expressInterest(): >> Interest: /ndn/NLSR/sync/00 > 8.487s ndn-cxx.Face:expressInterest(): >> Interest: /ndn/NLSR/sync/00 > 8.487s ndn-cxx.Face:expressInterest(): >> Interest: /ndn/NLSR/sync/00 > 8.487s ndn-cxx.Face:expressInterest(): >> Interest: /ndn/NLSR/sync/00 > 10s HelloProtocol:scheduleInterest(): Scheduling HELLO Interests in 5 seconds > 10s HelloProtocol:scheduleInterest(): Scheduling HELLO Interests in 5 seconds > 10s HelloProtocol:scheduleInterest(): Scheduling HELLO Interests in 5 seconds > ERROR: Failed to register prefix in local hub's daemon > terminate called after throwing an instance of 'nlsr::Nlsr::Error' > what(): Error: Prefix registration failed > > Program received signal SIGABRT, Aborted. > 0x00007fffe99cccc9 in __GI_raise (sig=sig at entry=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:56 > 56 ../nptl/sysdeps/unix/sysv/linux/raise.c: No such file or directory. > > /anil. -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 841 bytes Desc: Message signed with OpenPGP using GPGMail URL: From anilj.mailing at gmail.com Mon Dec 28 12:49:45 2015 From: anilj.mailing at gmail.com (Anil Jangam) Date: Mon, 28 Dec 2015 12:49:45 -0800 Subject: [ndnSIM] Failed to register prefix in local hub's daemon In-Reply-To: References: Message-ID: Thanks Alex. It worked! 68 nlsrApp->SetStartTime(Seconds (1.0)); Proceeding with next set of debugging. :) /anil. On Mon, Dec 28, 2015 at 12:06 PM, Alex Afanasyev wrote: > Most likely you're starting your NLSR application at time moment 0. You > need to schedule the start at a later time moment (say, 1second). > Otherwise, ndn::Face::registerPrefix() will always fail. > > --- > Alex > > > On Dec 28, 2015, at 11:23 AM, Anil Jangam > wrote: > > > > Hi, > > > > I am testing a scenario of NLSR simulation and hitting an exception in > ndnSIM. I searched for the error in the past learned that I need to start > the NFD and NRD processes, but that suggestion was in case of real > applications. What is the cause of this in the simulation setup? > > > > Am I missing any environment setup, which is leading to this error? > > > > 4.227s ndn-cxx.Face:expressInterest(): >> Interest: /ndn/NLSR/sync/00 > > 4.227s ndn-cxx.Face:expressInterest(): >> Interest: /ndn/NLSR/sync/00 > > 4.227s ndn-cxx.Face:expressInterest(): >> Interest: /ndn/NLSR/sync/00 > > 8.487s ndn-cxx.Face:expressInterest(): >> Interest: /ndn/NLSR/sync/00 > > 8.487s ndn-cxx.Face:expressInterest(): >> Interest: /ndn/NLSR/sync/00 > > 8.487s ndn-cxx.Face:expressInterest(): >> Interest: /ndn/NLSR/sync/00 > > 10s HelloProtocol:scheduleInterest(): Scheduling HELLO Interests in 5 > seconds > > 10s HelloProtocol:scheduleInterest(): Scheduling HELLO Interests in 5 > seconds > > 10s HelloProtocol:scheduleInterest(): Scheduling HELLO Interests in 5 > seconds > > ERROR: Failed to register prefix in local hub's daemon > > terminate called after throwing an instance of 'nlsr::Nlsr::Error' > > what(): Error: Prefix registration failed > > > > Program received signal SIGABRT, Aborted. > > 0x00007fffe99cccc9 in __GI_raise (sig=sig at entry=6) at > ../nptl/sysdeps/unix/sysv/linux/raise.c:56 > > 56 ../nptl/sysdeps/unix/sysv/linux/raise.c: No such file or directory. > > > > /anil. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From sarantarnoi at gmail.com Mon Dec 28 19:46:41 2015 From: sarantarnoi at gmail.com (Saran Tarnoi) Date: Tue, 29 Dec 2015 12:46:41 +0900 Subject: [ndnSIM] How to get node id in lru-policy.hpp In-Reply-To: <4CFB43EA-22EB-46C3-BE44-A3055B7F5632@cs.ucla.edu> References: <4CFB43EA-22EB-46C3-BE44-A3055B7F5632@cs.ucla.edu> Message-ID: Hi Alex, Thanks a lot for your help. However, I cannot get the first solution to work. I got this log: ../src/ndnSIM/model/cs/../../utils/trie/lru-policy.hpp:81:72: error: ?Node? was not declared in this scope ../src/ndnSIM/model/cs/../../utils/trie/lru-policy.hpp:81:78: error: expected primary-expression before ?)? token After including "ns3/node.h", I still got the following errors: ../src/ndnSIM/model/cs/../../utils/trie/lru-policy.hpp:82:76: error: expected primary-expression before ?>? token ../src/ndnSIM/model/cs/../../utils/trie/lru-policy.hpp:82:78: error: expected primary-expression before ?)? token I do not know why GetObject() failed here. Using GetObject() did not help either. The compiler did not get it. Did I miss something? The second solution (Simulator::GetContext()) works well. Regards, Saran Tarnoi 2015-12-29 2:01 GMT+09:00 Alex Afanasyev : > Hi Saran, > > The solution you found is getting access to nodeId from the ndnSIM 1.0 > strategy. For the caching policy, you can do the following: > > item->payload()->GetContentStore()->GetObject()->GetId() > > You can also use the following (cheaty) solution that can work in most of > the places: > > Simulator::GetContext(); // context ID == nodeId > > -- > Alex > > On Dec 28, 2015, at 1:05 AM, Saran Tarnoi wrote: > > Dear All, > > I would like to get node id (or the node name) while being in > lru-policy.hpp for logging purpose. > I am using ndnSIM-2.0. A solution found at > http://www.lists.cs.ucla.edu/pipermail/ndnsim/2014-May/001307.html did > not work. I have no idea how I can get a pointer to Node from here. > > Could you give me some pieces of advice? > > Thanks a lot in advance for your help. > > -- > Best regards, > Saran Tarnoi > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From aa at CS.UCLA.EDU Tue Dec 29 00:14:58 2015 From: aa at CS.UCLA.EDU (Alex Afanasyev) Date: Tue, 29 Dec 2015 00:14:58 -0800 Subject: [ndnSIM] How to get node id in lru-policy.hpp In-Reply-To: References: <4CFB43EA-22EB-46C3-BE44-A3055B7F5632@cs.ucla.edu> Message-ID: You may needed to include header file, use full namespace, and add additional C++ syntax sugar needed, given lru-policy is a template class. I checked and the following should work, but I would still recommend the simpler Simulator::GetContext() method. item->payload()->GetContentStore()->template GetObject()->GetId(); --- Alex > On Dec 28, 2015, at 7:46 PM, Saran Tarnoi wrote: > > Hi Alex, > > Thanks a lot for your help. However, I cannot get the first solution to work. > I got this log: > ../src/ndnSIM/model/cs/../../utils/trie/lru-policy.hpp:81:72: error: ?Node? was not declared in this scope > ../src/ndnSIM/model/cs/../../utils/trie/lru-policy.hpp:81:78: error: expected primary-expression before ?)? token > > After including "ns3/node.h", I still got the following errors: > ../src/ndnSIM/model/cs/../../utils/trie/lru-policy.hpp:82:76: error: expected primary-expression before ?>? token > ../src/ndnSIM/model/cs/../../utils/trie/lru-policy.hpp:82:78: error: expected primary-expression before ?)? token > > I do not know why GetObject() failed here. Using GetObject() did not help either. The compiler did not get it. > Did I miss something? > > The second solution (Simulator::GetContext()) works well. > > Regards, > Saran Tarnoi > > > 2015-12-29 2:01 GMT+09:00 Alex Afanasyev >: > Hi Saran, > > The solution you found is getting access to nodeId from the ndnSIM 1.0 strategy. For the caching policy, you can do the following: > > item->payload()->GetContentStore()->GetObject()->GetId() > > You can also use the following (cheaty) solution that can work in most of the places: > > Simulator::GetContext(); // context ID == nodeId > > -- > Alex > >> On Dec 28, 2015, at 1:05 AM, Saran Tarnoi > wrote: >> >> Dear All, >> >> I would like to get node id (or the node name) while being in lru-policy.hpp for logging purpose. >> I am using ndnSIM-2.0. A solution found at http://www.lists.cs.ucla.edu/pipermail/ndnsim/2014-May/001307.html did not work. I have no idea how I can get a pointer to Node from here. >> >> Could you give me some pieces of advice? >> >> Thanks a lot in advance for your help. >> >> -- >> Best regards, >> Saran Tarnoi -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 841 bytes Desc: Message signed with OpenPGP using GPGMail URL: From sarantarnoi at gmail.com Tue Dec 29 00:48:02 2015 From: sarantarnoi at gmail.com (Saran Tarnoi) Date: Tue, 29 Dec 2015 17:48:02 +0900 Subject: [ndnSIM] How to get node id in lru-policy.hpp In-Reply-To: References: <4CFB43EA-22EB-46C3-BE44-A3055B7F5632@cs.ucla.edu> Message-ID: Hi Alex, Your solution works well. Putting template before GetObject() solves the whole problem. Anyway, I will follow you advice and use Simulator::GetContext() method. Thank you so much. Best regards, Saran Tarnoi 2015-12-29 17:14 GMT+09:00 Alex Afanasyev : > You may needed to include header file, use full namespace, > and add additional C++ syntax sugar needed, given lru-policy is a template > class. I checked and the following should work, but I would still > recommend the simpler Simulator::GetContext() method. > > item->payload()->GetContentStore()->template > GetObject()->GetId(); > > --- > Alex > > On Dec 28, 2015, at 7:46 PM, Saran Tarnoi wrote: > > Hi Alex, > > Thanks a lot for your help. However, I cannot get the first solution to > work. > I got this log: > ../src/ndnSIM/model/cs/../../utils/trie/lru-policy.hpp:81:72: error: > ?Node? was not declared in this scope > ../src/ndnSIM/model/cs/../../utils/trie/lru-policy.hpp:81:78: error: > expected primary-expression before ?)? token > > After including "ns3/node.h", I still got the following errors: > ../src/ndnSIM/model/cs/../../utils/trie/lru-policy.hpp:82:76: error: > expected primary-expression before ?>? token > ../src/ndnSIM/model/cs/../../utils/trie/lru-policy.hpp:82:78: error: > expected primary-expression before ?)? token > > I do not know why GetObject() failed here. Using > GetObject() did not help either. The compiler did not get it. > Did I miss something? > > The second solution (Simulator::GetContext()) works well. > > Regards, > Saran Tarnoi > > > 2015-12-29 2:01 GMT+09:00 Alex Afanasyev : > >> Hi Saran, >> >> The solution you found is getting access to nodeId from the ndnSIM 1.0 >> strategy. For the caching policy, you can do the following: >> >> item->payload()->GetContentStore()->GetObject()->GetId() >> >> You can also use the following (cheaty) solution that can work in most of >> the places: >> >> Simulator::GetContext(); // context ID == nodeId >> >> -- >> Alex >> >> On Dec 28, 2015, at 1:05 AM, Saran Tarnoi wrote: >> >> Dear All, >> >> I would like to get node id (or the node name) while being in >> lru-policy.hpp for logging purpose. >> I am using ndnSIM-2.0. A solution found at >> http://www.lists.cs.ucla.edu/pipermail/ndnsim/2014-May/001307.html did >> not work. I have no idea how I can get a pointer to Node from here. >> >> Could you give me some pieces of advice? >> >> Thanks a lot in advance for your help. >> >> -- >> Best regards, >> Saran Tarnoi >> >> > -- Regards, Saran Tarnoi Graduate Student Department of Informatics The Graduate University for Advanced Studies (Sokendai) Tokyo, Japan -------------- next part -------------- An HTML attachment was scrubbed... URL: From anilj.mailing at gmail.com Tue Dec 29 23:14:20 2015 From: anilj.mailing at gmail.com (Anil Jangam) Date: Tue, 29 Dec 2015 23:14:20 -0800 Subject: [ndnSIM] Node adjacency matrix in ndnSIM, how? Message-ID: Hi (Alex, Spyros), In all ndnSIM examples, the interconnection links between nodes is specified as: # srcNode dstNode bandwidth metric delay queue Node0 Node1 1Mbps 1 10ms ns3::RedQueue,MeanPktSize=100 Node0 Node3 1Mbps 1 10ms ns3::RedQueue,MeanPktSize=100 In all these configs, is the adjacency between the two nodes and all the link characteristics defined as bidirectional by default? Is it a ndnSIM requirement to specify the links parameters as defined in all the examples or it is specific to application? Can we define the links and their parameters in each direction and how does ndnSIM would behave in such case? For example, how to achieve this: # srcNode dstNode bandwidth metric delay queue Node0 Node1 1Mbps 1 10ms ns3::RedQueue,MeanPktSize=100 Node1 Node0 2Mbps 1 20ms ns3::RedQueue,MeanPktSize=200 Node0 Node3 1Mbps 1 10ms ns3::RedQueue,MeanPktSize=100 Node3 Node0 2Mbps 1 20ms ns3::RedQueue,MeanPktSize=200 My application scenario, each node define its own adjacency matrix and link parameters (i.e. application specific configuration), thus takes care of creating and initializing the faces in each direction explicitly. While I believe in real set up it would fine; however, in case of ndnSIM I am not sure how it is going to behave. Can you please elaborate? /anil. -------------- next part -------------- An HTML attachment was scrubbed... URL: From aa at CS.UCLA.EDU Thu Dec 31 17:41:07 2015 From: aa at CS.UCLA.EDU (Alex Afanasyev) Date: Thu, 31 Dec 2015 17:41:07 -0800 Subject: [ndnSIM] Node adjacency matrix in ndnSIM, how? In-Reply-To: References: Message-ID: <397B7717-60DA-4AFE-A7BA-A11A135638E1@cs.ucla.edu> Hi Anil, The format you showed is just one of the ways how to setup network environment for the simulation, so there are no ndnSIM requirements here. You can try to update util/topology/annotated-topology-reader.cpp to match your needs. Alternatively, you can define a separate configuration file that defines individual link properties, and apply those properties after the link is created. You can use something like in the following snippet to find specific PointToPointNetDevice to set parameters, using two node names: std::string node1 = ...; std::string node2 = ...; Ptr node = Names::Find(node1); Ptr otherNode = Names::Find(node2); for (uint32_t deviceId = 0; deviceId < node->GetNDevices(); deviceId++) { Ptr netDevice = DynamicCast(node->GetDevice(deviceId)); if (netDevice == 0) continue; Ptr channel = netDevice->GetChannel(); if (channel == 0) continue; if (channel->GetDevice(0)->GetNode() == otherNode) { || channel->GetDevice(1)->GetNode() == otherNode) { // apply parameters on channel->GetDevice(0) or channel->GetDevice(1) return; } } --- Alex > On Dec 29, 2015, at 11:14 PM, Anil Jangam wrote: > > Hi (Alex, Spyros), > > In all ndnSIM examples, the interconnection links between nodes is specified as: > > # srcNode dstNode bandwidth metric delay queue > Node0 Node1 1Mbps 1 10ms ns3::RedQueue,MeanPktSize=100 > Node0 Node3 1Mbps 1 10ms ns3::RedQueue,MeanPktSize=100 > > In all these configs, is the adjacency between the two nodes and all the link characteristics defined as bidirectional by default? Is it a ndnSIM requirement to specify the links parameters as defined in all the examples or it is specific to application? > > Can we define the links and their parameters in each direction and how does ndnSIM would behave in such case? For example, how to achieve this: > > # srcNode dstNode bandwidth metric delay queue > Node0 Node1 1Mbps 1 10ms ns3::RedQueue,MeanPktSize=100 > Node1 Node0 2Mbps 1 20ms ns3::RedQueue,MeanPktSize=200 > Node0 Node3 1Mbps 1 10ms ns3::RedQueue,MeanPktSize=100 > Node3 Node0 2Mbps 1 20ms ns3::RedQueue,MeanPktSize=200 > > My application scenario, each node define its own adjacency matrix and link parameters (i.e. application specific configuration), thus takes care of creating and initializing the faces in each direction explicitly. While I believe in real set up it would fine; however, in case of ndnSIM I am not sure how it is going to behave. > > Can you please elaborate? > > /anil. > -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 841 bytes Desc: Message signed with OpenPGP using GPGMail URL: From makelangelo2011 at hotmail.com Thu Dec 31 20:50:28 2015 From: makelangelo2011 at hotmail.com (makel angelo) Date: Fri, 1 Jan 2016 04:50:28 +0000 Subject: [ndnSIM] Vanet via Named Data Networking Message-ID: Hi (Alex, Spyros), First of all happy new year. i am trying to run a simulation using ndnSim but i have a lot of question i hope you can answer me . First i tried to run a simulation available on the web published in 2013 but i am having some difficulties .First do i need to make changes to the code if the version of ndnSim i am working on is different than the one the code was developed under ? when using the code i noticed that there is a file called ndn-v2v-net-device-face.cc and it's header .h.I think all the errors i am facing is due to this file .it's normal since this file call for other file such as ndn-net-device-face also ndn-header-helper .while searching for those file i could not find those file under ns3/build/ns3 i could not find the file with extension ndn-net-device-face.h instead i found ndn-net-device-face.hpp.but when changing the call in ndn-v2v-net-device-face the compile says that the file ndn-net-device-face.hpp is not found.Well i think i missing something here could you please try to explain for me? -------------- next part -------------- An HTML attachment was scrubbed... URL: