[ndnSIM] question for topology

Alex Afanasyev alexander.afanasyev at ucla.edu
Tue Mar 5 18:59:54 PST 2013


Hi Aaron,

Sorry, you are not the first one who gets confused with my template.  I hope a corrected README file is more clear.

In any case,  you need to clone ndnSIM-sample-topologies into a separate location, not related to ns-3.  Let's say you start from scratch, then you can do the following:

mkdir ns-dev
cd ns-dev

git clone git://github.com/cawka/ns-3-dev-ndnSIM.git -b ns-3.16-ndnSIM ns-3
git clone git://github.com/NDN-Routing/ndnSIM.git -b v0.2.6 ns-3/src/ndnSIM

git clone git://github.com/cawka/ndnSIM-sample-topologies.git ndnSIM-sample-topologies

cd ns-3
./waf configure
./waf install

cd ../ndnSIM-sample-topologies
(there are some tricks to compile ndnSIM-sample-topologies, but README talks about them)


As for the usage, you can create your scenario similar to http://ndnsim.net/examples.html#node-grid-example-using-topology-plugin, but instead of  
topologyReader.SetFileName ("src/ndnSIM/examples/topologies/topo-grid-3x3.txt");
write something like
topologyReader.SetFileName ("topologies/bw-delay-rand-1/1221.r0-conv-annotated.txt");  // you also need to adjust other parts of the scenario

(or you can just copy .txt files to your preferred location)

Btw. This template can be used for all your custom simulations.  Just put any scenario that you're working on in scenarios/ folder and all of them will be automatically compiled when you do ./waf and you can run.

---
Alex


On Mar 5, 2013, at 6:36 PM, aaronishere <aaronishere at qq.com> wrote:

> Hi, Alex and Chengyu
> I download the  ndnSIM-sample-topologies under the ..ns3/src but when ./waf configue, it showed like below:
> Traceback (most recent call last):
>   File "/home/ndnSIM/ns-3/.waf-1.6.11-30618c54883417962c38f5d395f83584/waflib/Scripting.py", line 97, in waf_entry_point
>     run_commands()
>   File "/home/ndnSIM/ns-3/.waf-1.6.11-30618c54883417962c38f5d395f83584/waflib/Scripting.py", line 146, in run_commands
>     parse_options()
>   File "/home/ndnSIM/ns-3/.waf-1.6.11-30618c54883417962c38f5d395f83584/waflib/Scripting.py", line 125, in parse_options
>     Context.create_context('options').execute()
>   File "/home/ndnSIM/ns-3/.waf-1.6.11-30618c54883417962c38f5d395f83584/waflib/Options.py", line 133, in execute
>     super(OptionsContext,self).execute()
>   File "/home/ndnSIM/ns-3/.waf-1.6.11-30618c54883417962c38f5d395f83584/waflib/Context.py", line 87, in execute
>     self.recurse([os.path.dirname(g_module.root_path)])
>   File "/home/ndnSIM/ns-3/.waf-1.6.11-30618c54883417962c38f5d395f83584/waflib/Context.py", line 128, in recurse
>     user_function(self)
>   File "/home/ndnSIM/ns-3/wscript", line 218, in options
>     opt.sub_options('src')
>   File "/home/ndnSIM/ns-3/.waf-1.6.11-30618c54883417962c38f5d395f83584/waflib/Context.py", line 128, in recurse
>     user_function(self)
>   File "/home/ndnSIM/ns-3/src/wscript", line 51, in options
>     opt.sub_options(module, mandatory=False)
>   File "/home/ndnSIM/ns-3/.waf-1.6.11-30618c54883417962c38f5d395f83584/waflib/Context.py", line 128, in recurse
>     user_function(self)
>   File "/home/ndnSIM/ns-3/src/ndnSIM-sample-topologies/wscript", line 26, in options
>     opt.load("compiler_c compiler_cxx boost ns3")
>   File "/home/ndnSIM/ns-3/.waf-1.6.11-30618c54883417962c38f5d395f83584/waflib/Context.py", line 81, in load
>     module=load_tool(t,path)
>   File "/home/ndnSIM/ns-3/.waf-1.6.11-30618c54883417962c38f5d395f83584/waflib/extras/compat15.py", line 77, in load_tool
>     ret=eld(*k,**kw)
>   File "/home/ndnSIM/ns-3/.waf-1.6.11-30618c54883417962c38f5d395f83584/waflib/Context.py", line 296, in load_tool
>     __import__(d)
> ImportError: No module named ns3
>  
> I'm new in ns3 and is there some guidelines for how to use this topology?
>  
> Thanks a lot !
>   
> Aaron
>  
> From: Alex Afanasyev
> Date: 2013-03-06 09:06
> To: Chengyu Fan
> CC: aaronishere; ndnsim
> Subject: Re: [ndnSIM] question for topology
> Hi all,
> 
> You can also checkout the repository that I just created http://github.com/cawka/ndnSIM-sample-topologies, which can be used as a base for topology generation using rocketfuel-maps-cch-to-annotaded tool.
> 
> I also put a sample for converted topologies (with graphviz-generated topology visualizations) here: https://github.com/cawka/ndnSIM-sample-topologies/tree/master/topologies/bw-delay-rand-1   But you need to double check if the parameters used in the rocketfuel-maps-cch-to-annotaded tool are good for your simulations.
> 
> ---
> Alex
> 
> On Mar 5, 2013, at 9:47 AM, Chengyu Fan <chengyu at cs.colostate.edu> wrote:
> 
>> You can find an example in the src directory:
>> 
>> src/ndnSIM/tools/rocketfuel-maps-cch-to-annotaded.cc
>> 
>> Thanks,
>> Chengyu
>> 
>> On Tue, Mar 5, 2013 at 8:41 AM, aaronishere <aaronishere at qq.com> wrote:
>> Hi, Alex
>>  
>> The topology in the example is a little simple, is there more complex topology available? And I found that in the ../plugins/topology there's rocketfuel-map/weights, how to use it? Thanks !  
>>  
>> Aaron -
>> 
>> _______________________________________________
>> ndnSIM mailing list
>> ndnSIM at lists.cs.ucla.edu
>> http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim
>> 
>> 
>> _______________________________________________
>> ndnSIM mailing list
>> ndnSIM at lists.cs.ucla.edu
>> http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim
> 
> _______________________________________________
> 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: <http://www.lists.cs.ucla.edu/pipermail/ndnsim/attachments/20130305/e9cc0de1/attachment.html>


More information about the ndnSIM mailing list