• 中国计算机学会会刊
  • 中国科技核心期刊
  • 中文核心期刊

J4 ›› 2011, Vol. 33 ›› Issue (2): 12-16.doi: 10.3969/j.issn.1007130X.2011.

• 论文 • 上一篇    下一篇

基于NS2的网络仿真可视化系统的设计与实现

任炬,邓晓衡,陈志刚   

  1. (中南大学信息科学与工程学院,湖南 长沙 410083)
  • 收稿日期:2010-01-28 修回日期:2010-04-30 出版日期:2011-02-25 发布日期:2011-02-25
  • 通讯作者: 任炬 E-mail:renjufyr@163.com
  • 作者简介:任炬(1987),男,湖南汨罗人,硕士,研究方向为网络仿真技术、J2EE架构技术。邓晓衡(1974),男,湖南衡东人,博士,副教授,研究方向为网络拥塞控制与性能优化。陈志刚(1964),男,湖南益阳人,博士,教授,研究方向为网络与数据库技术。
  • 基金资助:

    国家自然科学基金(60903058);教育部博士点基金新教师基金(200805331109);大学生创新性实验计划项目(LA08050);湖南省普通高校教改研究项目湘教通(2009)140号24

Design and Implementation of a Visual Network Simulation System Based on NS2

REN Ju,DENG Xiaoheng,CHEN Zhigang   

  1. (School of Information Science and Engineering,Central South University,Changsha  410083,China)
  • Received:2010-01-28 Revised:2010-04-30 Online:2011-02-25 Published:2011-02-25

摘要:

在网络模拟领域,NS2一直是应用最广泛的软件,但使用难、缺少远程模拟等缺点也局限了其发展。本文针对这些弱点与不足,提出了基于NS2的远程可视化模拟系统的设计方案并给出了实现方法。系统采用Flex和ActionScript编程语言开发客户端,以组件的形式来开发场景库,以分散式的组件自治模式实现了脚本的自动化生成。然后将脚本传入服务器端,通过远程调用服务器端的NS2子进程执行此脚本,同时整合第三方软件库Gawk和Pnuplot,用以分析模拟结果和实现模拟结果的动画显示和曲线描述,让协议研究人员或学生直观且深入地理解网络中的复杂行为,为用户远程学习计算机网络课程提供了良好的实验平台。

关键词: NS2, 网络模拟, 可视化系统, Flex, 远程调用

Abstract:

NS(Network Simulator) has always been widely used in network simulation. However, some of its shortcomings such as difficulty in use, lack of longrange simulation support have limited its development. This paper proposes a remote visualization simulation system based on NS2 and gives the implementing method. We use Flex and the ActionScript programming language to develop the client program. In addition, we use component technology to develop the library of scenarios and a distributed component autonomy model to realize the automatic generation of the script. Then the system conveys the script to the server and the NS2 child process executes this script by remote calling. Meanwhile, the thirdparty software library Gawk and Pnuplot are integrated to analyze the simulation results and realize the curves description and the animation show of the results, which ensures that protocol researchers can have an intuitive and indepth understanding of the complex network behavior. It provides a good platform for the users who are learning computer network remotely.

Key words: NS2;network simulation;visualization system;Flex;remote call