Changes between Version 7 and Version 8 of PlasticSlices/Experiments


Ignore:
Timestamp:
07/08/11 13:21:44 (11 years ago)
Author:
Josh Smift
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • PlasticSlices/Experiments

    v7 v8  
    44
    55In each experiment, it assumes you've already created your slice and all of its slivers, and divided your compute resources into "clients" and "servers" (the meaning of which will vary depending on the particular experiment).
     6
     7There are two kinds of experiments described here:
     8
     9 * "Giga" experiments, which use various methods to send a particular quantity of total data. (1 GB as described below, but it's easy to vary this.)
     10 * "Steady" experiments, which use various methods to send data at a particular rate, either for a set length of time, or indefinitely. (10 Mbits/sec as described below, but it's easy to vary this.)
     11
     12''FIXME: It would be better if we included commands to log output and inspect it later; we just handwave past this for now.''
    613
    714= !GigaPing =
     
    8895Divide that number by the number of host pairs you have (the number of rows in your table); call this number <count>, and use it below when you run the netcat commands.
    8996
    90 Copy the file to each of the servers. (When you run the experiment, you'll download it repeatedly from each of the clients.)
     97Copy the file to each of the servers. (When you run the experiment, you'll download it repeatedly to each of the clients.)
    9198
    9299On each client and server, install netcat:
     
    107114using the "server=<ipaddr>" line from your table, and the <count>, <port>, and <file> values you identified earlier.
    108115
    109 You won't seen any output immediately, but when you start running clients, as each transfer completes, you should see lines on your terminal that look like
     116You won't see any output immediately, but when you start running clients, as each transfer completes, you should see lines on your terminal that look like
    110117
    111118{{{
     
    125132}}}
    126133
    127 You won't seen any output immediately, but as each transfer completes, you should see lines on your terminal that look like
     134You won't see any output immediately, but as each transfer completes, you should see lines on your terminal that look like
    128135
    129136{{{
     
    210217Divide that number by the number of host pairs you have (the number of rows in your table); call this number <count>, and use it below when you run the wget command on the clients.
    211218
    212 Copy the file to each of the servers, and put it into ~/gigaweb/docroot. (When you run the experiment, you'll download it repeatedly from each of the clients.)
     219Copy the file to each of the servers, and put it into ~/gigaweb/docroot. (When you run the experiment, you'll download it repeatedly to each of the clients.)
    213220
    214221== Execution ==
     
    222229}}}
    223230
    224 using the "server=<ipaddr>" line from your table, and the <count>, <port>, and <file> values you identified earlier.
     231using the "server=<ipaddr>" line from your table, and the <port> value you identified earlier.
    225232
    226233That should print a line on your terminal like
     
    480487
    481488No special cleanup is needed.
     489
     490= !SteadyPing =
     491
     492This experiment uses the 'ping' command to send data at 10 Mbits/second via ICMP.
     493
     494== Setup ==
     495
     496Divide the hosts that you want to use into pairs. In each pair, the client is the one that you'll run the 'ping' command on, and the server is the one that you'll ping from the client.
     497
     498Identify the precise IP address on each server that you'll want to ping. Make a table to keep track of which server you'll want to ping from each client, e.g.
     499
     500|| '''client'''                   || '''server'''                   || '''server address''' ||
     501|| ganel.gpolab.bbn.com           || planetlab5.clemson.edu         || server=10.42.17.105  ||
     502|| planetlab4.clemson.edu         || pl5.myplc.grnoc.iu.edu         || server=10.42.17.73   ||
     503|| of-planet1.stanford.edu        || wings-openflow-3.wail.wisc.edu || server=10.42.17.96   ||
     504
     505You'll use the "server=<ipaddr>" parts when you run the experiment.
     506
     507Calculate the interval between ping packets. The formula is:
     508
     509{{{
     510<interval> seconds/packet = 1500 bytes/packet * 8 bits/byte * 1/1024 Kbit/bit * 1/1024 Mbit/Kbit * <hostpairs> * 1/10 seconds/Mbit
     511}}}
     512
     513where <hostpairs> is the number of host pairs you have (the number of rows in your table). Call this number <interval>, and use it below when you run the 'ping' commands.
     514
     515(It's 1/10 seconds per Mbit because you want to calculate an interval expressed in seconds per packet, not packets per second.)
     516
     517== Execution ==
     518
     519On each client, run
     520
     521{{{
     522server=<ipaddr>
     523sudo ping -i <interval> -s $((1500-8-20)) $server
     524}}}
     525
     526using the "server=<ipaddr>" line from your table, and the <interval> value you calculated earlier.
     527
     528That should print many lines on your terminal that look like
     529
     530{{{
     5311480 bytes from <ipaddr>: icmp_seq=44 ttl=64 time=135 ms
     5321480 bytes from <ipaddr>: icmp_seq=49 ttl=64 time=87.7 ms
     5331480 bytes from <ipaddr>: icmp_seq=50 ttl=64 time=77.9 ms
     534}}}
     535
     536and then finish with a section that looks like
     537
     538{{{
     539--- <ipaddr> ping statistics ---
     540<count> packets transmitted, <count> received, 0% packet loss, time 5229ms
     541rtt min/avg/max/mdev = 59.376/70.448/522.011/57.578 ms, pipe 55
     542}}}
     543
     544Copy that final block for your results.
     545
     546== Results ==
     547
     548The results of the experiment are the three-line statistics summary at the end of the output on the client.
     549
     550== Cleanup ==
     551
     552No special cleanup is needed.
     553
     554= !SteadyNetcat =
     555
     556This experiment uses the 'netcat' command to send data via unencrypted TCP. Note that it doesn't allow you to directly control the rate at which data is sent.
     557
     558== Setup ==
     559
     560Divide the hosts that you want to use into pairs. In each pair, you'll run a netcat listener on the server, and make a netcat connection to it from the client.
     561
     562Identify the precise IP address on each server that you'll want to connect to. Make a table to keep track of which server you'll want to connect to from each client, e.g.
     563
     564|| '''client'''                   || '''server'''                   || '''server address''' ||
     565|| ganel.gpolab.bbn.com           || planetlab5.clemson.edu         || server=10.42.17.105  ||
     566|| planetlab4.clemson.edu         || pl5.myplc.grnoc.iu.edu         || server=10.42.17.73   ||
     567|| of-planet1.stanford.edu        || wings-openflow-3.wail.wisc.edu || server=10.42.17.96   ||
     568
     569You'll use the "server=<ipaddr>" parts when you run the experiment.
     570
     571Identify a port that you'd like to use for the connection; call it <port>, and use it below when you run the netcat server and client commands.
     572
     573Identify a file that you'd like to transfer from the servers to the clients; call it <file>.
     574
     575Copy the file to each of the servers. (When you run the experiment, you'll download it repeatedly to each of the clients.)
     576
     577On each client and server, install netcat:
     578
     579{{{
     580sudo yum install nc
     581}}}
     582
     583== Execution ==
     584
     585On each server, run
     586
     587{{{
     588server=<ipaddr>
     589while true ; do nc -l $server <port> < <file> ; done
     590}}}
     591
     592using the "server=<ipaddr>" line from your table, and the <port>, and <file> values you identified earlier.
     593
     594You won't see any output in the server window.
     595
     596On each client, run
     597
     598{{{
     599server=<ipaddr>
     600rm -rf ~/steadynetcat
     601mkdir ~/steadynetcat
     602cd ~/steadynetcat
     603while true ; do nc $server <port> > <file> ; echo -n "$(date "+%F %T")  " ; md5sum <file> ; rm <file> ; done
     604}}}
     605
     606You won't see any output immediately, but as each transfer completes, you should see lines on your terminal that look like
     607
     608{{{
     6092011-06-29 11:20:46  d4fcf71833327fbfef98be09deef8bfb  substrate.doc
     610}}}
     611
     612and the md5sum checksum of the file and the filename.
     613
     614Leave it running for a while; when you're done, hit ctrl-c on the client, and then on the server, to kill the netcat processes.
     615
     616== Results ==
     617
     618Compare the md5sum checkums; they should all be the same.
     619
     620== Cleanup ==
     621
     622On each client, remove the steadynetcat directory:
     623
     624{{{
     625cd
     626rm -rf ~/steadynetcat
     627}}}
     628
     629= !SteadyWeb =
     630
     631This experiment uses the HTTPS protocol to send data via encrypted TCP. Note that it doesn't allow you to directly control the rate at which data is sent.
     632
     633== Setup ==
     634
     635Divide the hosts that you want to use into pairs. In each pair, you'll run an HTTPS server on the server, and run wget on the client to fetch files from it.
     636
     637Identify the precise IP address on each server that you'll want to connect to. Make a table to keep track of which server you'll want to connect to from each client, e.g.
     638
     639|| '''client'''                   || '''server'''                   || '''server address''' ||
     640|| ganel.gpolab.bbn.com           || planetlab5.clemson.edu         || server=10.42.17.105  ||
     641|| planetlab4.clemson.edu         || pl5.myplc.grnoc.iu.edu         || server=10.42.17.73   ||
     642|| of-planet1.stanford.edu        || wings-openflow-3.wail.wisc.edu || server=10.42.17.96   ||
     643
     644You'll use the "server=<ipaddr>" parts when you run the experiment.
     645
     646Identify a port that you'd like to use for the connection; call it <port>, and use it below when you run the netcat server and client commands.
     647
     648On each server, install an HTTPS server. One way is to install pyOpenSSL, the 'patch' program, and use the Python server at http://code.activestate.com/recipes/442473-simple-http-server-supporting-ssl-secure-communica/, with a patch to allow you to bind to an address and port specified on the command line:
     649
     650{{{
     651sudo yum install pyOpenSSL patch
     652rm -rf ~/steadyweb
     653mkdir -p ~/steadyweb/docroot
     654cd ~/steadyweb
     655wget http://code.activestate.com/recipes/442473-simple-http-server-supporting-ssl-secure-communica/download/1/ -O httpsd.py
     656wget http://groups.geni.net/geni/attachment/wiki/PlasticSlices/Experiments/httpsd.py.patch?format=raw -O httpsd.py.patch
     657patch httpsd.py httpsd.py.patch
     658rm httpsd.py.patch
     659}}}
     660
     661On each server, generate a self-signed SSL key:
     662
     663{{{
     664openssl genrsa -passout pass:localhost -des3 -rand /dev/urandom -out localhost.localdomain.key 1024
     665openssl req -subj /CN=localhost.localdomain -passin pass:localhost -new -key localhost.localdomain.key -out localhost.localdomain.csr
     666openssl x509 -passin pass:localhost -req -days 3650 -in localhost.localdomain.csr -signkey localhost.localdomain.key -out localhost.localdomain.crt
     667openssl rsa -passin pass:localhost -in localhost.localdomain.key -out decrypted.localhost.localdomain.key
     668mv decrypted.localhost.localdomain.key localhost.localdomain.key
     669cat localhost.localdomain.key localhost.localdomain.crt > localhost.localdomain.pem
     670rm localhost.localdomain.key localhost.localdomain.crt localhost.localdomain.csr
     671}}}
     672
     673Identify a file that you'd like to transfer from the servers to the clients; call it <file>.
     674
     675Copy the file to each of the servers, and put it into ~/steadyweb/docroot. (When you run the experiment, you'll download it repeatedly to each of the clients.)
     676
     677== Execution ==
     678
     679On each server, run
     680
     681{{{
     682server=<ipaddr>
     683cd ~/steadyweb/docroot
     684python ../httpsd.py $server <port>
     685}}}
     686
     687using the "server=<ipaddr>" line from your table, and <port> value you identified earlier.
     688
     689That should print a line on your terminal like
     690
     691{{{
     692Serving HTTPS on <ipaddr> port <port> ...
     693}}}
     694
     695immediately, and then lines like
     696
     697{{{
     698<ipaddr> - - [17/May/2011 19:53:21] "GET / HTTP/1.1" 200 -
     699}}}
     700
     701for each client connection when clients connect.
     702
     703On each client, run
     704
     705{{{
     706server=<ipaddr>
     707rm -rf ~/steadyweb
     708mkdir ~/steadyweb
     709cd ~/steadyweb
     710while true ; do wget --no-check-certificate https://$server:<port>/<file> -O <file> ; echo -n "$(date "+%F %T")  " ; md5sum <file> ; rm <file> ; done
     711}}}
     712
     713You'll see output typical of wget as each transfer runs, and an md5sum checksum line.
     714
     715Leave it running for a while; when you're done, hit ctrl-c on the client, and then on the server, to kill the netcat processes.
     716
     717== Results ==
     718
     719Compare the md5sum checkums; they should all be the same.
     720
     721== Cleanup ==
     722
     723On each client, remove the steadyweb directory:
     724
     725{{{
     726cd
     727rm -rf ~/steadyweb
     728}}}
     729
     730= SteadyPerfTCP =
     731
     732This experiment uses the iperf command to send 1 GB of data via TCP, measuring performance throughout the transfer.
     733
     734== Setup ==
     735
     736Divide the hosts that you want to use into pairs. In each pair, you'll run an iperf listener on the server, and make an iperf connection to it from the client.
     737
     738Identify the precise IP address on each server that you'll want to connect to. Make a table to keep track of which server you'll want to connect to from each client, e.g.
     739
     740|| '''client'''                   || '''server'''                   || '''server address''' ||
     741|| ganel.gpolab.bbn.com           || planetlab5.clemson.edu         || server=10.42.17.105  ||
     742|| planetlab4.clemson.edu         || pl5.myplc.grnoc.iu.edu         || server=10.42.17.73   ||
     743|| of-planet1.stanford.edu        || wings-openflow-3.wail.wisc.edu || server=10.42.17.96   ||
     744
     745You'll use the "server=<ipaddr>" parts when you run the experiment.
     746
     747Identify a port that you'd like to use for the connection; call it <port>, and use it below when you run the iperf server and client commands.
     748
     749Decide how long (in seconds) you'd like to transfer data for; call that <time>, and use it below when you run the iperf server and client commands.
     750
     751On each client and server, install iperf:
     752
     753{{{
     754sudo yum -y install iperf
     755}}}
     756
     757== Execution ==
     758
     759On each server, run
     760
     761{{{
     762server=<ipaddr>
     763nice -n 19 iperf -B $server -p <port> -s -i 1
     764}}}
     765
     766using the "server=<ipaddr>" line from your table, and the <port> value you identified earlier. That should print a few lines on your terminal immediately, including ones like
     767
     768{{{
     769Server listening on TCP port <port>
     770Binding to local address <ipaddr>
     771}}}
     772
     773and then more lines once a client connects.
     774
     775On each client, run
     776
     777{{{
     778server=<ipaddr>
     779nice -n 19 iperf -c $server -p <port> -t 86400
     780}}}
     781
     782using the "server=<ipaddr>" line from your table, and the <port> and <time> values you identified earlier. That should print a few lines on your terminal immediately, including ones like
     783
     784{{{
     785Client connecting to <ipaddr>, TCP port <port>
     786------------------------------------------------------------
     787[  3] local 10.42.17.51 port 40997 connected with <ipaddr> port <port>
     788}}}
     789
     790The client IP address and port will be different, of course.
     791
     792The server will then start to print lines like
     793
     794{{{
     795[  4] local <ipaddr> port <port> connected with 10.42.17.51 port 40997
     796[  4]  0.0- 1.0 sec    359 KBytes  2.94 Mbits/sec
     797[  4]  1.0- 2.0 sec    498 KBytes  4.08 Mbits/sec
     798}}}
     799
     800When the transfer finishes, the client will print lines like
     801
     802{{{
     803[ ID] Interval       Transfer     Bandwidth
     804[  3]  0.0- 2.2 sec  1.00 MBytes  3.79 Mbits/sec
     805}}}
     806
     807Copy that final block for your results.
     808
     809After the time you specified has passed, the client will exit; on the server, hit ctrl-c to kill the iperf server process.
     810
     811== Results ==
     812
     813The results of the experiment are the statistics summary at the end of the output on the client.
     814
     815== Cleanup ==
     816
     817No special cleanup is needed.
     818
     819= SteadyPerfUDP =
     820
     821This experiment uses the iperf command to send 1 GB of data via UDP, measuring performance throughout the transfer.
     822
     823== Setup ==
     824
     825Divide the hosts that you want to use into pairs. In each pair, you'll run an iperf listener on the server, and make an iperf connection to it from the client.
     826
     827Identify the precise IP address on each server that you'll want to connect to. Make a table to keep track of which server you'll want to connect to from each client, e.g.
     828
     829|| '''client'''                   || '''server'''                   || '''server address''' ||
     830|| ganel.gpolab.bbn.com           || planetlab5.clemson.edu         || server=10.42.17.105  ||
     831|| planetlab4.clemson.edu         || pl5.myplc.grnoc.iu.edu         || server=10.42.17.73   ||
     832|| of-planet1.stanford.edu        || wings-openflow-3.wail.wisc.edu || server=10.42.17.96   ||
     833
     834You'll use the "server=<ipaddr>" parts when you run the experiment.
     835
     836Identify a port that you'd like to use for the connection; call it <port>, and use it below when you run the iperf server and client commands.
     837
     838Divide 1000 by the number of host pairs you have (the number of rows in your table); call this number <size>, and use it below when you run the iperf client command. (This is how much data (in megabytes) each client will send to the server.)
     839
     840Decide how fast you'd like to send data (in megabits per second); call this number <rate>, and use it below when you run the iperf client command.
     841
     842On each client and server, install iperf:
     843
     844{{{
     845sudo yum -y install iperf
     846}}}
     847
     848== Execution ==
     849
     850On each server, run
     851
     852{{{
     853server=<ipaddr>
     854nice -n 19 iperf -u -B $server -p <port> -s -i 1
     855}}}
     856
     857using the "server=<ipaddr>" line from your table, and the <port> value you identified earlier. That should print a few lines on your terminal immediately, including ones like
     858
     859{{{
     860Server listening on UDP port <port>
     861Binding to local address <ipaddr>
     862}}}
     863
     864and then more lines once a client connects.
     865
     866On each client, run
     867
     868{{{
     869server=<ipaddr>
     870nice -n 19 iperf -u -c $server -p <port> -n <size>M -b <rate>M
     871}}}
     872
     873using the "server=<ipaddr>" line from your table, and the <port>, <size>, and <rate> values you identified earlier. That should print a few lines on your terminal immediately, including ones like
     874
     875{{{
     876Client connecting to <ipaddr>, UDP port <port>
     877------------------------------------------------------------
     878[  3] local 10.42.17.51 port 40997 connected with <ipaddr> port <port>
     879}}}
     880
     881The client IP address and port will be different, of course.
     882
     883The server will then start to print lines like
     884
     885{{{
     886[  4] local <ipaddr> port <port> connected with 10.42.17.51 port 40997
     887[  4]  0.0- 1.0 sec    359 KBytes  2.94 Mbits/sec
     888[  4]  1.0- 2.0 sec    498 KBytes  4.08 Mbits/sec
     889}}}
     890
     891When the transfer finishes, the client will print lines like
     892
     893{{{
     894[ ID] Interval       Transfer     Bandwidth
     895[  3]  0.0-79.8 sec   954 MBytes   100 Mbits/sec
     896[  3] Sent 680273 datagrams
     897[  3] Server Report:
     898[  3]  0.0-79.1 sec   881 MBytes  93.4 Mbits/sec   0.040 ms 52088/680272 (7.7%)
     899[  3]  0.0-79.1 sec  256 datagrams received out-of-order
     900}}}
     901
     902Copy that final block for your results.
     903
     904After the time you specified has passed, the client will exit; on the server, hit ctrl-c to kill the iperf server process.
     905
     906== Results ==
     907
     908The results of the experiment are the statistics summary at the end of the output on the client.
     909
     910== Cleanup ==
     911
     912No special cleanup is needed.