150 likes | 434 Views
NCTUns Emulation. 指導教授:潘仁義 報告者:李詩涵、蕭惠陽. Kernel Re-entering Simulation Methodology. Tunnel 網路介面是實現 Kernel Re-entering Simulation Methodology 的關鍵技術 Tunnel Pseudo network interface A corresponding device special file in the /dev directory. Kernel Re-entering Simulation Methodology.
E N D
NCTUns Emulation 指導教授:潘仁義 報告者:李詩涵、蕭惠陽
Kernel Re-entering Simulation Methodology • Tunnel網路介面是實現Kernel Re-entering Simulation Methodology的關鍵技術 • Tunnel • Pseudo network interface • A corresponding device special file in the /dev directory
Kernel Re-entering Simulation Methodology • Simulation Time= Link Propagation Time + Packet transmission Time
Emulator Architecture • External host • 指在NCTUns GUI裡的Emulation host • External machine • 指欲emulation的真實機器,有可能是PC、PDA、IPCAM…等。
Example 1 • 實驗環境 • Fedora 9 • NCTUns 5.0
設定Machine IP • 在Linux設定實體IP • 設定Nctuns External host IP
Run NCTUns - ifup tun1~tun4 • #ifconfig • tun1=1.0.1.1 • tun2=1.0.1.2 • tun3=1.0.2.1 • tun4=1.0.2.2 • eth0= 192.168.1.100
Run NCTUns-route add • #route -n
Run NCTUns • Tun1=n1 • Tun2=n2(left) • Tun3=n2(right) • Tun4=n4
Simulator turned into network emulator • First, virtual clock與real time同步 • Second, 在真實世界中,新增system routing table • 為了傳packet至simulation machine -------------------emulation 開始------------------------- • Third, packet-filtering rules need to be installed Addthe system routing table on the simulation machine • 為了允許在真實世界中incoming packet可被抓取至simulation network • Finally, the headers of the captured packets need to be translated • they can be forwarded between the simulated network and the real-world devices.
Kernel Emulation Module • External Machine - TCP Sender
Kernel Module(Emulation Module) • Filter packet, capture packet • Simulation start: emulation module被加載到Kernel,它會自動讀取配置文件,該文件包含了所有的過濾規則。 • During simulation: emulation module 解讀所有packet header,為了把external machinepacket作傳或收。
Kernel Emulation Module • External Machine - TCP Receiver
參考資料 • NCTUNS TOOL FOR INNOVATIVE NETWORKEMULATIONS • http://nsl.csie.nctu.edu.tw/NovaNCTUnsEmulationNew2009.pdf • The GUI User Manual for theNCTUns 6.0 Network Simulatorand Emulator(Ch7 Emulation) • http://nsl10.csie.nctu.edu.tw/support/documentation/GUIManual.pdf • The Protocol Developer Manual forthe NCTUns 6.0 Network Simulatorand Emulator • http://nsl10.cs.nctu.edu.tw/support/documentation/DeveloperManual.pdf