Changes between Version 1 and Version 2 of GENIExperimenter/Tutorials/GettingStarted_PartII_ccn/Procedure/Execute


Ignore:
Timestamp:
06/18/14 23:32:02 (10 years ago)
Author:
Vic Thomas
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • GENIExperimenter/Tutorials/GettingStarted_PartII_ccn/Procedure/Execute

    v1 v2  
    2626    Please use the command:
    2727<pre>
    28 readyToLogin --no-keys -a AM_NICKNAME SLICENAME
     28readyToLogin -a AM_NICKNAME SLICENAME
    2929<pre>
    3030where (as before) <tt>AM_NICKNAME</tt> and <tt>SLICENAME</tt> are your aggregate
    3131manager nickname and your slice name (both found on your worksheet).
    3232  </li>
    33   <li>If it reports that the sliver is not yet ready (for example, it might say that the status is "changing"), then please wait a minute
     33  <li>If it reports that the sliver is not yet ready (for example, it might say that the status is "changing"), then wait a minute
    3434or two and try again.  Once everything is complete, <tt>readyToLogin</tt>
    3535will give output that should look something like this:
    3636<pre>
    3737...
    38 server's geni_status is: ready (am_status:ready)
    39 User example logs in to server using:
    40         ssh -p 32768 example@pc1.utah.geniracks.net
    41 User example logs in to client using:
    42         ssh -p 32769 example@pc1.utah.geniracks.net
     38rschr's geni_status is: ready (am_status:ready)
     39User example logs in to rschr using:
     40        ssh  -p 32768 -i /Users/example/.ssh/geni_key_portal example@pc1.utah.geniracks.net
     41User example logs in to collar using:
     42        ssh -p 32769 -i /Users/example/.ssh/geni_key_portal example@pc1.utah.geniracks.net
    4343...
    4444</pre>
    45 
    46 <table border="0" cellpadding="0" cellspacing="0"><tr><td><img src="http://groups.geni.net/geni/attachment/wiki/GENIExperimenter/Tutorials/Graphics/warning-icon-hi.png?format=raw" width='50' height='50' /></td><td>If you didn't previously complete the Flack tutorial (or are not running an <tt>ssh</tt> agent), then your <tt>ssh</tt> client might
    47 not be set up to log in with above commands.  Try re-running <tt>readyToLogin</tt> without the <tt>--no-keys</tt> option, and it will give you one or
    48 more <tt>ssh</tt> commands to choose from (which should work, although might require the key passphrase).</td></tr></table>
    4945
    5046  </li>
     
    5248}}}
    5349
    54 == 5 Browse server webpage and log in to client node ==
     50== 5 Trying out the CCN protocol ==
    5551
    5652The `install` and `execute` services requested in our RSpec have
    57 already started, and the apache webserver has started on the server and measurements are now being collected.
     53already started, and nodes in our experiment should be running the CCN (Content Centric Networking) protocol.  Our experiment consists of:
     54   * A data source (node {{{dsrc1}}} that holds precipitation data from the US National Oceanic and Atmospheric Administration (NOAA).
     55   * A researcher node {{{rsrchr}}} that gets data from the data source
     56   * A collaborator node {{{collab}} that gets data from the researcher
    5857
    59 {{{
    60 #!html
    61 <table>
    62 <tr><td>
    63 <ol type='a'>
    64 <li>
    65 Enter the hostname of the server node in your browser.  It should bring up a webpage of statistics from your experiment similar to that shown in the figure.
    66 </li>
    67 </ol>
    68 </td>
    69         <td>
    70         <img
    71       src="http://groups.geni.net/geni/attachment/wiki/GENIEducation/SampleAssignments/UnderstandAMAPI/Graphics/webserver_v1.png?format=raw"
    72       alt="Enter the hostname in your browser to see statistics"  width="300"
    73       title="Enter the hostname in your browser to see statistics" /> </a>
    74          <br/>
    75          <b>Figure 5-1</b> Enter the hostname of the <i>server</i> node in your browser to see statistics</i>
    76        </td>
    77 </tr>
    78 </table>
    79 <table>
    80 <tr>
    81 <td>
    82 <ol type='a' start='2'>
    83   <li>Find the <code>ssh</code> commands for your client in your <code>readyToLogin</code> output.  Copy and paste those <code>ssh</code> commands directly into your terminal
    84 to log in.  You should see a shell prompt
    85 from the remote end:
    86 <pre>
    87      [example@client ~]$
    88 </pre>
     58Key features of the CCN protocol include:
     59   * Data is accessed by name.  In our case we use a program called client to get precipitation data by date range (e.g. precipitation between 1901/01/01 and 1901/01/02).
     60   * All nodes cache data for a certain period of time.   When a node receives a request for data, it checks its local cache.  If the data is in it's cache, it returns that data.  Otherwise, it forwards it on to its neighbor.
    8961
    90 <table id="Table_01" border="0" cellpadding="5" cellspacing="0">
    91         <tr>
    92                 <td>
    93                         <img src="http://trac.gpolab.bbn.com/gcf/raw-attachment/wiki/Graphics/4NotesIcon_512x512.png" width="50" height="50" alt="Note">
    94                </td>
    95 <td>
    96 While you're welcome to inspect either
    97 the client or server, for the purpose of this experiment the <tt>client</tt> host is the one
    98 running the <tt>iperf</tt> tests and collecting all the logs.
    99 </td>
    100         </tr>
    101 </table>
    102 </li>
    103 <li>
     62We verify this caching behavior by:
     63   * Logging into the researcher node and using the client program to get precipitation data for a certain date range.  The client displays how long it took to get the data.
     64   * Retrieving the same data again and noting how we get it much faster since it comes out of a cache.
     65   * Requesting data for different date range and see how long it took to retrieve the data.
     66   * Requesting the data again and noting it is retrieved much faster.
    10467
    105 Look in the <code>/local</code> directory to see the install scripts and other files from the Archive you specified in your RSpec:
    106 <pre>
    107 cd /local
    108 ls
    109 </pre>
    110 </li>
    111 <li>
    112 Look for the <code>iperf</code> and <code>wget</code> processes started by your install scripts:
    113 <pre>
    114 ps ax
    115 </pre>
     68If you have time, you can repeat the above steps on the collaborator node.
    11669
    117 <table id="Table_03" border="0" cellpadding="5" cellspacing="0">
    118         <tr>
    119                 <td>
    120                         <img src="http://groups.geni.net/geni/attachment/wiki/GENIExperimenter/Tutorials/Graphics/Symbols-Tips-icon.png?format=raw" width="50" height="50" alt="Tip">
    121                </td>
    122                <td>
    123 If you do not see the proper files and processes, please double-check the <code>RSpec</code> you used in the previous step.
    124         </tr>
    125 </table>
     70Note: There is an optional portion to this exercise that uses the GENI Desktop to visualize traffic on the links in our network.  There you can visualize which data requests went all the way to the data source (node {{{dsrc1}}}) and which data requests were fulfilled from a node's cache.
    12671
    127 </li>
    128 </ol>
    129        </td>
    130 
    131       </tr>
    132 <tr><td>
    133 </td></tr>
    134 </table>
    135 }}}
     72=== 5.1 Run the CCN application ===
     73 1. Log into the node {{{rsrchr}}} using the {{{ssh}}} command returned by {{{readyToLogin}}}.
     74 2. Once you are logged in, ask for precipitation data from 1 Jan 1902 to 2 Jan 1902:
     75     {{{
     76        /opt/ccnx-atmos/client.py
     77        Start Date in YYYY/MM/DD? 1902/01/01
     78        End Date in YYYY/MM/DD? 1902/01/02
     79     }}}
     80 3. You should see output that looks like:
     81     {{{
     82     Asking for /ndn/colostate.edu/netsec/pr_1902/01/01/00, Saving to pr_1902_01_01.tmp.nc
     83     Time for pr_1902_01_01.tmp.nc 1.09802699089=
     84     Asking for /ndn/colostate.edu/netsec/pr_1902/01/02/00, Saving to pr_1902_01_02.tmp.nc
     85     Time for pr_1902_01_02.tmp.nc 4.65998315811=
     86      Joining files..
     87     Concat + write time 0.0735998153687
     88     Wrote to pr_1902_1_1_1902_1_2.nc
     89     }}}
     90     Note that it took about 1.1 and 4.7 seconds respectively to retrieve data for Jan 1 and Jan 2
     914. Run the client again and request the same data.  This time your output should look like:
     92    {{{
     93    Asking for /ndn/colostate.edu/netsec/pr_1902/01/01/00, Saving to pr_1902_01_01.tmp.nc
     94    Time for pr_1902_01_01.tmp.nc 0.0423700809479=
     95    Asking for /ndn/colostate.edu/netsec/pr_1902/01/02/00, Saving to pr_1902_01_02.tmp.nc
     96    Time for pr_1902_01_02.tmp.nc 0.0388598442078=
     97    Joining files..
     98    Concat + write time 0.0237510204315
     99    Wrote to pr_1902_1_1_1902_1_2.nc
     100    }}}
     101    Notice how much faster the data was retrieved this time.
     1025. If time permits, log into the collaborator node {{{collar}}} and run queries from there.  Notice different data retrieval times depending on whether the data came from the datasource, cache at {{{rsrchr}}} or the local cache.
    136103
    137104
     105=== 5.2 (Optional) Visualize experiment data flows ===
     106    To use the GENI Desktop to v
    138107
    139 The client machine is saving all the test results in the `/tmp/iperf-logs`
    140 directory.  Files with timestamps in the names will gradually appear
    141 there (there are 100 tests overall, and it may take 20 minutes for all
    142 of them to complete if you want to wait for them). 
    143 
    144 Each log file corresponds to one test with some number of simultaneous
    145 TCP connections over the VLAN link you requested between the two hosts.
    146 Later tests gradually include more concurrent connections, so the
    147 throughput of each individual connection will decrease, but the
    148 aggregate throughput (the `[SUM]` line at the end of each file)
    149 should remain approximately consistent.
    150 
    151 
    152 
    153 == 6.  Analyze Experiment ==
    154 
    155 For a real experiment, of course, this step would be the most important
    156 and collection, analysis and archival of the results would be critical,
    157 but for now, play around as necessary to satisfy your curiosity and
    158 then continue.
    159108
    160109----
    161110
    162 = [wiki:GENIEducation/SampleAssignments/UnderstandAMAPI/Procedure Introduction] =
    163 = [wiki:GENIEducation/SampleAssignments/UnderstandAMAPI/Procedure/Finish Next:  Finish] =
     111= [wiki:GENIExperimenter/Tutorials/GettingStarted_PartII_ccn/Procedure/Setup Setup] =
     112= [wiki:GENIExperimenter/Tutorials/GettingStarted_PartII_ccn/Procedure/Finish Next:  Finish] =