Computer NetworksHomework 1Graded out of 36 pointsIn this homework, we will analyze the relationship between traffic load, delay, throughput, andpacket loss. We will utilize mininet, a network emulation tool to create a network topology andiperf to generate traffic on that network topology.1. Network topologymininet will emulate the following network topology:The hosts h1 through h6 are connected to the packet switches s1 and s2 as shown. Allcommunications links have a transmission rate of 1 Gbps, except for the s1-s2 link., which has arate to 0.5 Gbps.2. Traffic ScenariosYou will use a tool called “iperf” to generate traffic flows. Each iperf flow has a client (sender ofthe traffic) and a server (recipient of the traffic). Note that “client” and “server” in the iperfterminology are distinct from the client and server in a client-server application architecture, aslearned in class. You will generate two concurrent flows:Flow F1: Client is h1, server is h2Flow F3: Client is h3, server is h4The traffic intensity (called “bandwidth” in iperf) of each flow is a settable parameter in iperf,expressed in Mbps. The traffic intensity is defined as the rate at which the client is sending data,which is not necessarily the same as the rate at which the server is receiving data. You will runperformance tests for various traffic intensity values and s1’s buffer size values. 3. What to measureThe flows F1 and F3 share the same buffer at s1, and that buffer may be congested if thecombined incoming traffic intensity of F1 and F3 exceeds the rate of link s1-s2. We want tomeasure the queuing delay at that buffer, and the percentage of packets lost as a result of thatbuffer being full.To perform the measurements, we will use “Ping” between h5 and h6. Ping is a networkingutility used to test the reachability of a host on an Internet Protocol (IP) network. The Pingprotocol allows a client machine to send a packet of data to a remote server machine, and havethe remote server return the data back to the client unchanged (an action referred to as echoing).Among other uses, the Ping protocol allows a client to determine round-trip times (RTT) to theserver. The Ping client also measures packet losses. A packet is considered lost if no echo isreceived within a certain time. Ping’s contribution to the traffic load is negligible. h5 and h6 willbe the Ping client and Ping server respectively. Note that “client” and “server” in the Pingterminology are distinct from the client and server in a client-server application architecture, aslearned in class.Another metric is the throughput of F1 and F3. iperf will generate reports on the throughput(referred to as “bandwidth” in the report) seen at the h2 and h4 servers (how many bits reachedthe server per second).4. StepsIntall and set up mininet, puTTY (refer to “mininet-info” posted under “General info and tools”for details).If you are not familiar with mininet, you may want to try some examples in the mininetwalkthrough: http://mininet.org/walkthrough/, but this is not requiredStart the VM Virtual Box VM and login to mininet. It is recommended to ssh into mininet.User name is mininet, password is mininetCopy the provided Python script “topo1.py” into your mininet VM. To do that, first copy the filesinto your local machine, then transfer from your local machine to the mininet VM, by followingthe instructions in “mininet-info”.Once logged in to your mininet VM, follow the step by step instructions in “mininet-info” to installthe “progress” module into the mininet VM, then run the script by typing “sudo –E pythontopo1.py”. The “progress” module will allow the script to display a progress bar when it isrunning. It is not critical to have the “progress” module, you can skip installing it if you havetrouble. Without the progress bar, you just need to patiently wait for the script to complete.The script will generate the network topology and automatically run the performance tests forconfiguration x, for x = 0 to 5.Each performance test does 代寫Computer Networks作業(yè)、Python編程設(shè)計(jì)作業(yè)調(diào)試、Python語(yǔ)言作業(yè)代做 代做R語(yǔ)言編程|代做the following (the size of s1’s buffer is a parameter set to 500, 500,500, 5000, 5000 packets for x = 0, 1, 2, 3, 4, 5 respectively)? Setup h2 as an iperf server. h2 is now ready to receive iperf traffic from a client? Setup h4 as an iperf server. h4 is now ready to receive iperf traffic from a client? Start the iperf traffic for flow F1. The traffic is sent by client h1 towards server h2,for a duration of 60 seconds. The traffic intensity is a parameter, set to 0 Mbps,100 Mbps, 200 Mbps, 300 Mbps, 200 Mbps and 300 Mbps for x =0, 1, 2, 3, 4, 5respectively. The output is redirected to the file i1_x.out? Start the iperf traffic for flow F3. The traffic is sent by client h3 towards server h4,for a duration of 60 seconds. The traffic intensity is a parameter, set to 0 Mbps,100 Mbps, 200 Mbps, 300 Mbps, 200 Mbps and 300 Mbps for x =0, 1, 2, 3, 4, 5respectively. The output is redirected to the file i3_x.out? Launch ping from h5 to h6, for a count of 650 pings, spaced apart by 0.1 secondsWhen the script execution is completed, you will get the $ prompt.Now open the output files i1_x.out, i3_x.out, p_x.out, for x = 0 to 5, by typing cat (Alternatively, you can transfer the output files to your local machine, following the stepsdescribed in “mininet-info”, and read the files on your local machine).In the “i1_x.out” file you will find a Server Report which contains a “Bandwidth” value. That is thethroughput observed at h2. Similarly in the “i3_x.out” file, there is the throughput observed at h4.In the p_x.out file, you will find the ping statistics: rtt min, rtt avg, rtt max, % of packets lost. rtt isnot the queuing delay, but it is a related measure which is good enough for the purpose ofanalyzing the delay trends.5. What to turn inYou should turn in a Word document or similar that contains table 1 below. Fill in the yellowcells with your results, and answer the following questions for the various cases (6 points each):Q1. From what you learned in the lectures, do you expect a relationship between the ping lossand the traffic intensity for a given buffer capacity (for example, decrease or increase withtraffic intensity)? Answer yes or no, and justify your answer. Now analyze the reported data forthe various configurations. Does the data match the relationship you expected? Same questionfor the relationship between the ping avg RTT and the traffic intensity.Q2. From what you learned in the lectures, do you expect a relationship between the ping lossand the buffer capacity (for example, decrease or increase with buffer capacity)? Answer yes orno, and justify your answer. Now analyze the reported data for the various configurations. Doesthe data match the relationship you expected? Same question for the relationship between theping avg RTT and the buffer capacity.Q3. Is the observed throughput at the server h2 the same as the F1 traffic intensity? If theanswer is no, explain why.Q4. Is the observed throughput at the server h4 the same as the F3 traffic intensity? If theanswer is no, explain why.Q5. Is there a relationship between the RTT/loss % and the throughputs observed at theservers? If so, what is that relationship? Can you explain?Q6. Regarding the individual ping RTT values, do you see any significant differences betweenthe first pings and the last pings within the same ping session? If your answer is yes, can youexplain why?You should also turn in the *.out files generated by the script.Note: The expected ping RTT values should not exceed a few hundreds of msec in the worstcase. If you obtain numbers which seem out of whack, please rerun the mininet simulation.Mininet sometimes gives incorrect results. If you still see numbers which seem out of whackafter a few reruns, please contact the TA for help.6. ResourcesIf you are interested to learn more about ping and iperf, here are some links:a. pinghttps://en.wikipedia.org/wiki/Ping_(networking_utility)b. iperfhttps://www.es.net/assets/Uploads/201007-JTIperf.pdfhttps://en.wikipedia.org/wiki/Iperf轉(zhuǎn)自:http://www.3zuoye.com/contents/3/4803.html
講解:Computer Networks、Python、PythonR|SPSS
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請(qǐng)聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時(shí)請(qǐng)結(jié)合常識(shí)與多方信息審慎甄別。
平臺(tái)聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點(diǎn),簡(jiǎn)書(shū)系信息發(fā)布平臺(tái),僅提供信息存儲(chǔ)服務(wù)。
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時(shí)請(qǐng)結(jié)合常識(shí)與多方信息審慎甄別。
平臺(tái)聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點(diǎn),簡(jiǎn)書(shū)系信息發(fā)布平臺(tái),僅提供信息存儲(chǔ)服務(wù)。
相關(guān)閱讀更多精彩內(nèi)容
- Computer NetworksHomework 1Graded out of 36 pointsIn this...
- Computer NetworksHomework 1Graded out of 36 pointsIn this...
- Computer NetworksHomework 1Graded out of 36 pointsIn this...
- 你的記憶中一定有某些時(shí)刻難以忘卻,歷久彌新!一定有一些味道無(wú)論你身處何方總會(huì)一遍遍想起,不能忘卻!這種...
- 一日,玉皇大帝坐在凌霄殿大殿上對(duì)文曲星君道:“文曲星,二十一世紀(jì)是個(gè)和平的世紀(jì),是個(gè)知識(shí)文化爆炸的時(shí)代,也正是人類...