Presentation is loading. Please wait.

Presentation is loading. Please wait.

Modifying Network Packet Buffering in Network Layer CS518 Final Presentation and Instruction Guide Li Zhang.

Similar presentations


Presentation on theme: "Modifying Network Packet Buffering in Network Layer CS518 Final Presentation and Instruction Guide Li Zhang."— Presentation transcript:

1 Modifying Network Packet Buffering in Network Layer CS518 Final Presentation and Instruction Guide Li Zhang

2 Contents Notations Very Brief Introduction Hardware And Software Preparations Modifying the Code Experiments Design Results and Conclusion References

3 Background Five Network Layers in Linux : 1. MAC and Logical-Link Layer 2. Network Layer 3. Transport Layer 4. Application Layer

4 Traffic Control in Linux and My Goal In the Linux world, the term traffic control represents all the possibilities to influence incoming and outgoing network traffic in one way or another. This project focus on modifying the queuing disciplines in network layer in order to create an bigger size buffer which will drop less packets because of time slots used up. Two reasons to drop packets in network layer: 1. Buffer overflow. 2. Policing mechanism detected violation of a rule For example, packet format fault, firewall blocks.

5 Hardware and Software Preparation Hardware: An x86 networked computer running Windows XP Software: 1. VMware 2. CentOS 5.2 and its applications 3. linux kernel 2.6.26 4. Two tools to monitor network flows: ntop and bing

6 Preparation 1: Create a virtual machine and install CentOS 5.2 Download VMware Server 1.0.3 from http://www.vmware.com/download/server/ Install VMware server and register it online. The registration is free. Create a virtual machine under the guide of video ‘ Create_Virtual_ Machine.avi ’ Download and install CentOS 5.2 in the virtual machine from http://img.cs.montana.edu/linux/centos/5.2/isos/i386/

7 Preparation 2: Recompile the Linux kernel Start Linux and log in as ‘ root ’ Download the kernel code and decompressed it into /usr/src $ cd /tmp $ wget http://www.kernel.org/pub/linux/kernel/v2.6/linux-2.6.26.tar.bz2 $ tar -xjvf linux-2.6.25.tar.bz2 -C /usr/src $ cd /usr/src/linux-2.6.26 Install gcc, a C compiler $ yum install gcc Configure the kernel, do not change anything, just select ‘ exit ’ $ make menuconfig Make and install modules and kernel $ make $ make modules $ make modules_install $ make install

8 Preparation 2-continue Create an initrd image which contains device drivers which needed to loaded $ cd /boot $ mkinitrd -o initrd.img-2.6.26 2.6.26 Modify the grub file 1. Open /boot/grub/menu.lst with text editor 2. Modify the default booting kernel pointing to 2.6.26 3. If there is a line like this ‘ menu hidden ’, delete the whole line Restart Linux Select the kernel 2.6.26 from the boot loader menu

9 Preparation 3: Install ntop and bing Step 1 : Download and install rpmforge-release $ wget http://dag.wieers.com/rpm/packages/rpmforge- release/rpmforge-release-0.3.6-1.el5.rf.i386.rpm $ rpm -Uvh rpmforge-release-0.3.6-1.el5.rf.i386.rpm Step 2: Intsall ntop $yum install rrdtool $yum install ntop Step 3: Install bing $yum install bing

10 Preparation 4: Duplicate Virtual Machine A virtual machine can be duplicated very easily. Duplicate the file folder you created in Preparation 1 and rename it as Linux-modify Use VMware to open the.vmx file in the file folder Linux-modify. Select ‘ Edit virtual machine setting ’ and rename the new machine as ‘ Linux-modify ’ Only modify the kernel in the new machine.

11 Modify the code First double the buffer size by editing the function tbf_change() in netsched/sch_tbf.c. The variable max_size is the max buffer size. The watchdog() function is invoked when the timer for a packet expires. This function will be used in tbf_dequeue() to determine whether the process of transmitting a packet should be interrupted. Modify the condition to invoke the watchdog().

12 Recompile again $ cd /usr/src/linux-2.6.26 $ make menuconfig 1. Select ‘ General setup---  ’ 2. Select ‘ Local version-append to kernel release ’ 3. Enter a name you want, press ‘ OK ’ 4. ‘ Exit ’ twice 5. Watch video ‘ recompile_again_menuconfig.avi ’ Then follow the steps after ‘ make menuconfig ’ described in Preparation 2. Remember using the version name you created. Restart and select the kernel 2.6.26_with_your_name from the boot loader menu

13 Experiments Using bing which is a tool to identify the bandwidth currently available between two computers. 1. Get local host IP address: $ ifconfig 2. Use bing to test the bandwidth betwwen the local host and www.joyo.com $ bing – e 50 – i 1 – s 100 – S 1200 Your_Local_IP www.joyo.com Using ntop to monitor the network in the long term 1. Start ntop and keep the terminal running ntop open $ ntop 2. Open a web browserr, for example Firefox Visit http://localhost:3000/ Watch video ntop_and_bing.avi

14 Results

15 Results-continue

16 References K. Wehrle, F. Pahlke, H. Ritter, D. Muller and M. Bechler, ‘ The Linux Networking architecture ’, Pearson Education Inc, 2005 http://www.cndev.org/forum/msg.aspx?pid=22736 https://www.redhat.com/docs/en- US/Red_Hat_Enterprise_Linux/5.2/pdf/Deployment_G uide/Deployment_Guide.pdf http://gzmaster.blog.51cto.com/299556/77883 http://www.cyberciti.biz/tips/compiling-linux-kernel- 26.html

17 The End Thank you!


Download ppt "Modifying Network Packet Buffering in Network Layer CS518 Final Presentation and Instruction Guide Li Zhang."

Similar presentations


Ads by Google