SOCIS2017

From Nsnam
Revision as of 17:24, 16 August 2017 by Pasquimp (Talk | contribs)

Jump to: navigation, search

Main Page - Current Development - Developer FAQ - Tools - Related Projects - Project Ideas - Summer Projects

Installation - Troubleshooting - User FAQ - HOWTOs - Samples - Models - Education - Contributed Code - Papers

Return to Summer Projects page.

Project overview

  • Project name: High Performance Emulation of Real Devices in ns-3
  • Abstract: The goal of the project is the improvement of the emulation performance of the simulator. The project introduces a device in ns-3 that uses the netmap primitives to process the incoming and outgoing traffic. netmap is a fast packets processing that bypass the host networking stack and gains direct access to network device. Also, the project introduces a flow control mechanism between the traffic control of ns-3 and the device ring. Finally, the project introduces a performance evaluation of the introduced device in ns-3 in emulation scenarios on real device. The project enables a more accurate evaluation of high level protocols, e.g., Deley Tolerant Networking protocols (DTN), and of the scheduling algorithms in emulated scenarios.
  • About me: I am a PhD student in Information Technology and Electrical Engineering at University of Naples Federico II

Approach

In the first step, the project introduces netmap in ns-3 to gain direct access to network device. netmap allows to bypass the host networking stack and to map the device memory in user space area. This step includes the integration of the netmap headers in ns-3 and the introduction of a new device, i.e., NetmapNetDevice, in the fd-net-device module. Also, the emu-fd-net-device-helper will be extended with the introduction of a new function to set the emulation in netmap mode. This step includes functional testing of the new device by ping a real host connected back-to-back through ethernet.

In the second step, the project introduces a realistic flow control mechanism between the traffic control of ns-3 and the real device ring. Also, the project will introduce support for Byte Queue Limit (BQL) in the new device. The flow control and BQL will be fundamental to keep a backlog in traffic-control where we will evaluate the presence of backlog and the effectiveness of the Active Queue Management algorithms as consequence of the presence of such mechanisms. The support for flow control and BQL will be tested by ping a real host connected back-to-back through ethernet and with presence of traffic load (to saturate the transmission ring capacity).

In the final step, the project will introduce further optimization to gain the performance improvement on real device emulation scenarios. The performance bottleneck will be evaluated with profiler and we expect to improve the incoming phase, e.g., by removing the dynamic memory allocation, and the outgoing phase, e.g., with the transfer of batch of packets to the new device. The final step perform a benchmark of the new device by comparison of the new device with the FdNetDevice in emulation mode in a back-to-back through ethernet scenario of two ns-3 nodes.

Deliverables

By the end of the project, the following will be delivered to the ns-3 fd-net-device module

  • the NetmapNetDevice to send and receive packet using the netmap primitives on an emulated real device and its support for flow control and BQL
  • EmuFdNetDeviceHelper extension to provide helper functions useful to set the netmap emulation mode
  • functional testing of the new device by ping a real host connected back-to-back through ethernet with or without presence of traffic load
  • benchmark of the new device: comparison of the new device with the FdNetDevice in standard emulation mode in a real scenario of back-to-back through ethernet of two ns-3 nodes; performance evaluation in term of throughput, rtt, qdisc backlog and dropping.

Due to the short timespan of SOCIS 2017, there will be a single deliverable at the end of the project. However, the developed code and documentation is available at https://github.com/pasquimp/ns-3-dev-git/commits/socis. Anyone is encouraged to comment the code and leave feedbacks.

Finally, to improve the organization of the coding period it has been divided in three phases. Each phase includes test, documentation and gathering of comments from the community. The milestones expected at the end of each phase are

Phase 1

  • netmap integration into ns-3
  • new device and its helper that uses netmap primitives
  • functional testing with the ping example of a real host connected back-to-back through ethernet

Phase 2

  • support for flow control and BQL
  • functional testing with a ping example with presence of UDP traffic load
  • introduction of a example to assess the performance parameters in a back-to-back through ethernet scenario of two ns-3 nodes with UDP and TCP traffic load

Phase 3

  • further optimizations
  • benchmark of the new device with the introduced example, i.e., comparison of the performance parameters of the new device and the FdNetDevice in emulation mode in a back-to-back through ethernet scenarios of two ns-3 nodes
  • refinement of the whole project

Weekly Reports

Below the detailed report of the activity

Community Bonding Period (July 3-July 16)

During the community bonding period, I communicated with the mentor to refine the project and its schedule. Also, during this period I improved my knowledge of the fd-net-device module and of netmap.

Week 1 (July 17-July 23)

During the first week, I have implemented the extensions in the fd-net-device module and its helpers to support the netmap emulation mode. More specifically, I have

  • inserted the check for the netmap installation in the fd-net-device module wscript;
  • implemented the requested changes in the FdNetDevice to support its specializations;
  • introduced the new device as derived class of the FdNetDevice class;
  • introduced an helper function in the EmuFdNetDeviceHelper to set the netmap emulation mode;
  • implemented an extension of the raw socket creator to open a netmap fd.

Week 2 (June 24-July 30)

I started the implementation of the methods of the new device. I have

  • implemented the method to switch the emulated interface in netmap mode;
  • implemented a write method to copy a packet in the netmap transmission ring;
  • introduced an example to ping a real host through a real interface in netmap emulated mode.

Week 3 (July 31-August 6)

I implemented the read method of the new device and tested the new device in a back-to-back through ethernet scenario with the introduced ping-example. More specifically, I have

  • implemented the read method of the new device;
  • tested the new device in a back-to-back through ethernet with the ping example;
  • added traffic load to the ping example to support future test;
  • provided an initial version of a wiki on how to install netmap and how to use the netmap emulation features in ns-3.

Week 4 (August 7-August 13)

I started the implementation of the flow control support of the new device. I have

  • introduced the support for flow control in the new device;
  • extended the ping example to support the sampling of the backlog in the queue disc of the ns-3 traffic-control;
  • performed a test of the flow control (with the ping example on 100 Mbps back-to-back ethernet) and observed the presence of backlog in the queue disc.

Week 5 (August 14-August 20)

Week 6 (August 21-August 27)

Week 7 (August 28-September 3)

Wrapping Up (September 4-September 17)