Changes between Version 59 and Version 60 of NikySandbox/SIGSCETutorial


Ignore:
Timestamp:
02/21/13 09:01:04 (7 years ago)
Author:
nriga@bbn.com
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • NikySandbox/SIGSCETutorial

    v59 v60  
    88Make sure that you have access to your email.
    99
    10 = 1.  Create a GENI account =
    11 {{{
    12 #!html
    13 <table border="0">
    14    
    15       <tr>
    16        <td >
    17          <ol>
    18             <li> Go to <a href="https://panther.gpolab.bbn.com"> https://panther.gpolab.bbn.com </a> and press the <b> Use GENI </b> button</li>
    19             <li> From the Drop Down menu select your institutions. If you got an account through the GENI Identity Provider, please select <b>GENI Project Office</b>
    20                   <br/><b>NOTE</b>: Make sure that you <b>do not</b> choose the GENI Project Office (internal) <br/><b>Tip</b> Start typing the name of your institution and see the list become smaller.
    21             </li>
    22             <li> You will be transferred in the Login Page of your institution. Fill in your username and password </li>
    23             <li> <FONT COLOR="red">Complete the form that appears after you have successfully logged in and press <b>Continue</b></font></li>
    24             <li> <FONT COLOR="red">You will be transferred to an <b>Activation Page</b>. Make sure both checkboxes are checked and then press <b>Activate</b></font> </li>
    25           </ol>
    26        </td>
    27          <td>
     10This tutorial has two parts:
     11Part 1[wiki:NikySandbox/SIGSCE/SetupAccount Setup your GENI account and your GENI Project]
    2812
    29         <a href="https://panther.gpolab.bbn.com">
    30         <!--img border="0" src="http://groups.geni.net/geni/attachment/wiki/GENIExperimenter/Graphics/use-geni.png?format=raw" alt="Login to GENI"  height="120" title="Use GENI" />  </a>
    31 
    32         <br/--><img border="0" src="http://groups.geni.net/geni/attachment/wiki/GENIExperimenter/Graphics/login_to_portal.png?format=raw" alt="Use GENI"  height="120" title="Login to GENI" /> </a>
    33        </td>
    34     </tr>
    35  </table>
    36 }}}
    37 
    38 Congratulations, you have successfully created a GENI account.
    39 
    40 = 2. Create a GENI Project =
    41 A GENI account has no priviledges outside of a Project, i.e. as long as you are not a member of a GENI Project you can not use any GENI resources. In GENI only Project Leads can create Projects. Any faculty member, or a person in a corresponding position in industry, can request to become a Project Lead and thus have the capability of creating GENI Projects.
    42 {{{
    43 #!html
    44 <table border="0">
    45    
    46       <tr>
    47         <td>
    48 
    49         <img border="0" src="http://groups.geni.net/geni/attachment/wiki/GENIExperimenter/Graphics/new-project.png?format=raw" alt="Create a GENI Project"  height="150" title="Create a GENI Project" /> </a>
    50        </td>
    51        <td >
    52          <ol>
    53             <li> In the first page of the portal, press the button <b>Ask to be a Project Lead</b></li>
    54            <li> <FONT COLOR="red"> In the <i>Modify Account</i> page that showed up, fill in your telephone number; this is necessary for people that want to become Project Leads. Also check the box at the bottom of the page that says <b>Make me a 'Project Lead' </b> and press the <b>Modify Account</b> button.</font></li>
    55             <li> Wait until you receive an email that your request has been approved.</b>
    56             </li>
    57             <li> In the ''Projects'' tab click the <b>Create New Project</b> button</li>
    58             <li> Fill in the form as shown in the picture on the left;
    59                    Use your <b>own initials</b> and complete the <b>expiration field</b></li>
    60            
    61             <li> <FONT COLOR="red">Press the <b>Create Project</b> button</font> </li>
    62           </ol>
    63        </td>
    64        
    65     </tr>
    66  </table>
    67 }}}
    68 
    69 Congratulations you have created a project
    70 
    71 = 3. Invite people to join your project =
    72 When you create a new project for your class, you would want to add the TA and the students in your class.
    73 {{{
    74 #!html
    75 <table border="0">
    76    
    77       <tr>
    78         <td>
    79 
    80         <img border="0" src="http://groups.geni.net/geni/attachment/wiki/GENIExperimenter/Graphics/invite-members-portal.png?format=raw" alt="Create a GENI Project"  height="150" title="Create a GENI Project" /> </a>
    81        </td>
    82        <td >
    83          <ol>
    84             <li> Choose one person from the room to be your TA and one to be your student and write down their email addresses. </li>
    85            <li> From the <i>Project</i> page press the button <b>Invite New Project Members</b></li>
    86             <li> <FONT COLOR="red">Fill in the form using both email addresses and press the <b>Invite</b> button</font>
    87             </li>
    88             <li> Check your email, you might have an invitation from another user</li>
    89             <li>Follow the instructions about joining their project.</li>
    90            
    91             <li>Check your email for the request that someone joined your project and follow the instructions to add them to your project. Add your TA as an <b>Admin</b> and your student as a <b>Member</b>. This way the TA can Invite more people and/or approve join requests. </li>
    92           </ol>
    93        </td>
    94        
    95     </tr>
    96  </table>
    97 }}}
    98 
    99 Congratulations, you added your collaborators to your project!
    100 
    101 = 4. Join an existing project =
    102 [EXTRA STEP JUST FOR SCALING ITS GOING TO BE REMOVED FOR SIGSCE]
    103   a. Go to the Projects Tab
    104   b. Press the '''Join the Project''' button
    105   c.  [[Color(#FFFFFF, #FF0000, From the list of projects find the one named 'tutorial' and press '''Join''')]]
    106 
    107 = 5. Create an experiment =
    108 Now that your project is all setup, you are ready to run your first GENI experiment. For the purpose of this tutorial we are going to use a sample assignment that compares a UDP based transfer protocol with a TCP one. 
    109 
    110 {{{
    111 #!html
    112 <table border="0">
    113    
    114       <tr>
    115         <td>
    116 
    117         <img border="0" src="http://groups.geni.net/geni/attachment/wiki/GENIExperimenter/Graphics/add-resources-portal.png?format=raw" alt="Create a GENI Project"  height="120" title="Create a GENI Project" /> </a>
    118        </td>
    119        <td >
    120          <ol>
    121             <li> Go to the <i>Home</i> tab. </li>
    122            <li> In the project that '''you''' created press the <b>Create Slice</b> button</li>
    123             <li> <FONT COLOR="red">As a slice name use <code>udt</code>, you can leave the description empty and press <b>Create Slice</b></font>
    124             </li>
    125             <li> Select <b>Add Resources</b></li>
    126             <li>Since this if the first time you are trying to reserve resources, you should see a warning on the top about not having an SSH key in your account. Access to compute resources in GENI is provide through ssh key pairs and thus the portal needs a public key to upload to compute resources. For the purposes of the tutorial we will have the portal creating an SSH key pair for you. However, if you prefer to use your personal public key you can choose to upload it. Click on the <b>Generate and Download SSH Keypair</b> button.</li>
    127            
    128             <li>Press the <b>Download Private Key</b> button</li>
    129             <li> Open a terminal and execute <code>ssh-add ~/Downloads/id_geni_ssh_rsa</code> </li>
    130             <li> <FONT COLOR="red">Go to the <i>Slices</i> tab and press again on the <b>Add Resources</b> button. This time there should be no warning. Complete the form as as shown in the picture on the left and press the <b>Reserve Resources</b> button </font></li>
    131 <li> While we wait for our resources to get ready, lets look at another tool that is integrated with the portal. <FONT COLOR="red">Go to the <i>Slices</i> tab and press the <b>Launch Flack</b> button.</li>
    132 
    133           </ol>
    134        </td>
    135        
    136     </tr>
    137  </table>
    138 }}}
    139 
    140 = 6. Run your experiment =
    141 Once your resources are ready, your slice in Flack will be green. Once this is done we can now continue to the interesting part of running through the sample assignment. For this we will need to know how to transfer files with UDT, with FTP and how to change the link parameters between the link that connects the two hosts. Follow these instructions that will guide you through doing this with your nodes:
    142 
    143 === 6a. File Transfer Using UDT ===
    144 
    145 Follow these steps to perform a file transfer using UDT.
    146 
    147  * Log into pc1 and pc2 in separate windows.
    148 
    149  * On pc1, start a UDT file transfer server, using this command:
    150 {{{
    151 % pc1:~% /local/udt4/app/sendfile
    152 server is ready at port: 9000
    153 }}}
    154 
    155  * On pc2, start a UDT file transfer client, using this command:
    156 {{{
    157 pc2:~% /local/udt4/app/recvfile pc1 9000 /local/datafiles/sm.10M /dev/null
    158 }}}
    159 You should see output like the following in your pc1 window, showing the results of the file transfer. Note the transfer rate.
    160 {{{
    161 new connection: 192.168.2.2:55839
    162 speed = 7.14472Mbits/sec
    163 }}}
    164 
    165  * There are three data files available for transfer tests: '''/local/datafiles/sm.10M''' is 10MB, '''/local/datafiles/med.100M''' is 100MB, and '''/local/datafiles/lg.1G''' is 1000MB. Leave your transfer server running on pc1, and try transferring each of these files in turn by typing the appropriate commands on pc2. Keep track of the transfer rates in each case.
    166 
    167  * You can leave your UDT server running or stop it with ctrl-C.
    168 
    169 === 6b. File Transfer Using FTP ===
    170 
    171 Follow these steps to perform a file transfer using FTP.
    172 
    173  * For a TCP-based (FTP) transfer, there's already a FTP server running on pc1. Log into pc2, and start an ftp client:
    174 
    175 (You type ''ftp pc1'', the user name ''anonymous'', and any password you want, although your e-mail address is traditional.)
    176 
    177 {{{
    178 pc2:~% ftp pc1
    179 Connected to PC1-lan1.
    180 220 (vsFTPd 2.3.2)
    181 Name (pc1:mberman): anonymous
    182 331 Please specify the password.
    183 Password:
    184 230 Login successful.
    185 Remote system type is UNIX.
    186 Using binary mode to transfer files.
    187 ftp>
    188 }}}
    189 
    190  * Still on pc2, request a file transfer. Note the reported file size, transfer time, and transfer rate.
    191 
    192 {{{
    193 ftp> get med.100M /dev/null
    194 local: /dev/null remote: med.100M
    195 200 PORT command successful. Consider using PASV.
    196 150 Opening BINARY mode data connection for med.100M (104857600 bytes).
    197 226 Transfer complete.
    198 104857600 bytes received in 8.91 secs (11491.9 kB/s)
    199 }}}
    200 
    201  * You can perform additional transfers with additional get commands. When you're done, exit the ftp client with the quit command.
    202 
    203 === 6c. Viewing and Adjusting link characteristics ===
    204 
    205 In this experiment, you'll be changing the characteristics of the link and measuring how they affect UDT and TCP performance.
    206 
    207  * Log into your delay node as you do with any other node. Then, on your delay node, use this command:
    208 {{{
    209 %sudo ipfw pipe show
    210 }}}
    211 
    212 You'll get something like this:
    213 {{{
    214 60111: 100.000 Mbit/s    1 ms   50 sl. 1 queues (1 buckets) droptail
    215     mask: 0x00 0x00000000/0x0000 -> 0x00000000/0x0000
    216 BKT Prot ___Source IP/port____ ____Dest. IP/port____ Tot_pkt/bytes Pkt/Byte Drp
    217   0 ip    207.167.175.72/0       195.123.216.8/6        7     1060  0    0   0
    218 60121: 100.000 Mbit/s    1 ms   50 sl. 1 queues (1 buckets) droptail
    219     mask: 0x00 0x00000000/0x0000 -> 0x00000000/0x0000
    220 BKT Prot ___Source IP/port____ ____Dest. IP/port____ Tot_pkt/bytes Pkt/Byte Drp
    221   0 ip   207.167.176.224/0         195.124.8.8/6        8     1138  0    0   0
    222 }}}
    223 
    224 This information shows the internal configuration of the "pipes" used to emulate network characteristics.
    225 (Your output may look different, depending on the version of ipfw installed on your delay node.
    226 In any case, the information you need is on the first line of output for each pipe.)
    227 
    228 You'll want to make note of the two pipe numbers, one for each direction of traffic along your link.
    229 In the example above, they are 60111 and 60121.
    230 
    231 There are three link characteristics we'll manipulate in this experiment: bandwidth, delay, and packet loss rate.
    232 You'll find their values listed in the ipfw output above.
    233 The link bandwidth appears on the first line immediately after the pipe number. It's 100Mbps in the example shown above.
    234 The next value shown is the delay, 1 ms in the example above.
    235 The packet loss rate (PLR) is omitted if it's zero, as shown above. If non-zero, you'll see something like '''plr 0.000100'''
    236 immediately after the "50 sl." on the first output line.
    237 
    238 It is possible to adjust the parameters of the two directions of your link separately, to emulate asymmetric links.
    239 In this experiment, however, we are looking at symmetric links, so we'll always change the settings on both pipes together.
    240 
    241 Here are the command sequences you'll need to change your link parameters.
    242 In each case, you'll need to provide the correct pipe numbers, if they're different from the example.
    243 
    244  * To change bandwidth (100M means 100Mbits/s):
    245 {{{
    246 sudo ipfw pipe 60111 config bw 100M
    247 sudo ipfw pipe 60121 config bw 100M
    248 }}}
    249 
    250  * Request a bandwidth of zero to use the full capacity of the link (unlimited):
    251 {{{
    252 sudo ipfw pipe 60111 config bw 0
    253 sudo ipfw pipe 60121 config bw 0
    254 }}}
    255 
    256  * To change link delay (delays are measured in ms):
    257 {{{
    258 sudo ipfw pipe 60111 config delay 10
    259 sudo ipfw pipe 60121 config delay 10
    260 }}}
    261 
    262  * To change packet loss rate (rate is a probability, so 0.001 means 0.1% packet loss):
    263 {{{
    264 sudo ipfw pipe 60111 config plr .0001
    265 sudo ipfw pipe 60121 config plr .0001
    266 }}}
    267 
    268  * You can combine settings for bandwidth, delay, and loss by specifying more than one in a single ipfw command. We'll use this form in the procedure below.
    269 
    270 == Experiment Procedure ==
    271 
    272  * Set your link parameters to use maximum bandwidth, no delay, no packet loss:
    273 
    274 {{{
    275 sudo ipfw pipe 60111 config bw 0 delay 0 plr 0
    276 sudo ipfw pipe 60121 config bw 0 delay 0 plr 0
    277 }}}
    278 
    279  * Verify with
    280 
    281 {{{
    282 sudo ipfw pipe show
    283 60111: unlimited    0 ms   50 sl. 1 queues (1 buckets) droptail
    284     mask: 0x00 0x00000000/0x0000 -> 0x00000000/0x0000
    285 BKT Prot ___Source IP/port____ ____Dest. IP/port____ Tot_pkt/bytes Pkt/Byte Drp
    286   0 ip    207.167.175.72/0       195.123.216.8/6        7     1060  0    0   0
    287 60121: unlimited    0 ms   50 sl. 1 queues (1 buckets) droptail
    288     mask: 0x00 0x00000000/0x0000 -> 0x00000000/0x0000
    289 BKT Prot ___Source IP/port____ ____Dest. IP/port____ Tot_pkt/bytes Pkt/Byte Drp
    290   0 ip   207.167.176.224/0         195.124.8.8/6        8     1138  0    0   0
    291 }}}
    292 
    293 Note that bandwidth is set to ''unlimited'', delay to ''0 ms'', and no PLR is shown.
    294 
    295  * Using this initial setting, try a few UDT transfers, including the larger files. Now try FTP transfers. Record the transfer sizes and rates.
    296 
    297  * Now change the link parameters to reduce the available bandwidth to 10Mbps:
    298 
    299 {{{
    300 sudo ipfw pipe 60111 config bw 10M delay 0 plr 0
    301 sudo ipfw pipe 60121 config bw 10M delay 0 plr 0
    302 }}}
    303 
    304  * Repeat your file transfers with the new settings. As before, note the transfer sizes and rates, as well as the link settings.
    305 
    306  * Continue with additional trials, varying each of the three link parameters over a range sufficient to observe meaningful performance differences. Record your data.
    307 
    308 
    309 = 7. Delete your experiment =
    310 When we are done with our experiment it is always good to clean up and release our resources so other people can use them.
    311   a. Go back to the portal and press on the '''Slices''' tab
    312   b. In your slice press the '''Release Resources''' button
    313 
    314 Congratulations you have successfully completed your first GENI assignment!
    315 
    316 
    317  
     13Part 2[wiki:NikySandbox/SIGSCE/RunSampleAssignment Run through a sample assignment]