http://ndnsim.net/1.0/getting-started.html
sudo apt-get update
sudo apt-get uprade
参考Yogy的Kali Linux下常用软件安装及配置
安装
wudanye@wubuntu:~$ sudo apt-get install build-esscential
wudanye@wubuntu:~$ sudo apt-get install aptitude
依赖(wudanye@wubuntu:~$sudo apt-get install libpython2.7-stdlib
)
- 安装依赖库
wudanye@wubuntu:~$ sudo aptitude install libboost-all-dev
sudo apt-get install python-dev python-pygraphviz python-kiwi python-pygoocanvas python-gnome2 python-rsvg ipython
- 下载ndnSIM源代码
安装
wudanye@wubuntu:~$ sudo apt-get install git
wudanye@wubuntu:~$ sudo apt-get install vim
wudanye@wubuntu:~/Workspace$ mkdir ndnSIM
下载ns-3:
wudanye@wubuntu:~/Workspace/ndnSIM$ git clone -b ndnSIM-v1 git://github.com/cawka/ns-3-dev-ndnSIM ns-3
下载ndnSIM
wudanye@wubuntu:~/Workspace/ndnSIM$ git config --global url."https://".insteadOf git://
wudanye@wubuntu:~/Workspace/ndnSIM$ git clone -b master-v1 git://github.com/named-data/ndnSIM.git ns-3/src/ndnSIM
如果不下载ns-3,直接复制的情况下,需要在ns-3下:
wudanye@wubuntu:~/Workspace/ndnSIM/ns-3$ sudo chmod -R 777 *
配置pybindgen:
wudanye@wubuntu:~/Workspace/ndnSIM$ git clone git://github.com/cawka/pybindgen.git pybindgen
??(wudanye@wubuntu:~/Workspace/ndnSIM$ git clone -b master-v1 git://github.com:named-data/ndnSIM.git ns-3/src/ndnSIM)
- 编译运行
wudanye@wubuntu:~/Workspace/ndnSIM/ns-3$./waf configure --enable-tests --enable-examples
wudanye@wubuntu:~/Workspace/ndnSIM/ns-3$./waf --run=ndn-simple --vis
wudanye@wubuntu:~/Workspace/ndnSIM/ns-3$./waf --run=ndn-tree-cs-tracers
Eclipse
1.安装
wudanye@wubuntu:~$ sudo apt-get install eclipse eclipse-cdt eclipse-cdt-pkg-config
2.配置
新建ns-3项目
New -- C++ Project
Project name: ndnSIM
Location: /home/wudanye/Workspace/ndnSIM/ns-3
配置waf编译器
Project->properties->C/C++build
Builder Settings:
Build command: ${workspace_loc:/ndnSIM}/waf
Build directory: ${workspace_loc:/ndnSIM}/build
Behaviour:
Build(Incremental Build): all --> build
备选
Project->properties->C/C++build->Environment->Add
Name: LANG
Value: zh_CN.UTF-8:en_US
Name:LC_ALL
Value: en_US
Very Important:
配置调试器
Run->Debug Configurations->C/C++application->ndnSIM Debug
C/C++ Application:
/home/wudanye/workspace/ndnSIM/ns-3/src/ndnSIM/examples/ndn-tree-cs-tracers.cc
Project:
ndnSIM
Environment->New:
Variable: LD_LIBRARY_PATH
Value: ${workspace_loc:/ndnSIM}/build
写在最后。
sudo passwd root
su root
su
logout (?)
IPV4
10.21.5.60
255.255.0.0
10.21.0.254
DNS
159.226.39.1
159.226.8.6
登录 159.226.39.22
ubuntu系统安装 逻辑分区
ext4 /
交换分区 小5G
ext4 /home