Changes between Version 2 and Version 3 of GEC15Agenda/AdvancedGENITopoOmni/Instructions/ClickExampleExperiment


Ignore:
Timestamp:
10/19/12 02:00:02 (12 years ago)
Author:
nriga@bbn.com
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • GEC15Agenda/AdvancedGENITopoOmni/Instructions/ClickExampleExperiment

    v2 v3  
    2727omni.py createsliver -a pg-utah <slicename> <rspec_url>
    2828}}}
    29    i. '''Check the status of your sliver'''
    30    {{{
     29  i. '''Check the status of your sliver'''
     30  {{{
    3131omni.py sliverstatus -a pg-utah <slicename>
    3232}}}
     
    5353Once our sliver is ready we will go ahead and configure our click routers. In this example we have 4 routers, so instead of logging into each one of them and configuring it, we are going to use remote execution and configure them from our VM.
    5454
    55 === 3a. Remote execution ===
    56 In order to figure out how to login
    57 
    58 Create a sliver and add resources. (You changed the slice name, right?)
    59 
    60 {{{
    61 omni.py createsliver -a http://www.emulab.net/protogeni/xmlrpc/am StupidSliceName click-example.rspec
    62 }}}
    63 
    64 Wait until your sliver is ready, typically a few minutes. (You can monitor your sliver with [http://protogeni.net Flack] or use omni's '''sliverstatus''' command as shown below.)
    65 
    66 {{{
    67 omni.py sliverstatus -a http://www.emulab.net/protogeni/xmlrpc/am StupidSliceName
    68 }}}
    69 
    70 When your sliver is ready, run the '''readyToLogin''' script to get login information for your nodes. Use the same aggregate manager and slice name that you used for your '''sliverstatus''' command above.
    71 {{{
    72 readyToLogin.py -a http://www.emulab.net/protogeni/xmlrpc/am StupidSliceName
    73 }}}
    74 
    75 You'll get a big chunk of information, but you're interested in the '''ssh''' command information near the end.
     55=== 3a. Login and remote execution ===
     56Run the `readyToLogin.py` script to get information about logging in to nodes. The script has a lot of output so lets put that in a file so that we can easily search for the information we want.
     57
     58{{{
     59readyToLogin.py -a pg-utah <slicename> > login.out 2>&1
     60}}}
     61
     62You'll get a big chunk of information, but you're interested in the '''ssh configuration info''' information near the end.
    7663
    7764{{{
    7865... <lots of output> ...
    7966================================================================================
    80 Aggregate [http://www.emulab.net/protogeni/xmlrpc/am] has a ProtoGENI sliver.
    81 
    82 
    83 pc278.emulab.net's geni_status is: ready
    84 Login using:
    85         xterm -e ssh -i /Users/mberman/.ssh/id_rsa mberman@pc278.emulab.net &
    86 
    87 pc336.emulab.net's geni_status is: ready
    88 Login using:
    89         xterm -e ssh -i /Users/mberman/.ssh/id_rsa mberman@pc336.emulab.net &
    90 
    91 pc347.emulab.net's geni_status is: ready
    92 Login using:
    93         xterm -e ssh -i /Users/mberman/.ssh/id_rsa mberman@pc347.emulab.net &
    94 
    95 pc358.emulab.net's geni_status is: ready
    96 Login using:
    97         xterm -e ssh -i /Users/mberman/.ssh/id_rsa mberman@pc358.emulab.net &
    98 
    99 pc348.emulab.net's geni_status is: ready
    100 Login using:
    101         xterm -e ssh -i /Users/mberman/.ssh/id_rsa mberman@pc348.emulab.net &
    102 
    103 pc353.emulab.net's geni_status is: ready
    104 Login using:
    105         xterm -e ssh -i /Users/mberman/.ssh/id_rsa mberman@pc353.emulab.net &
    106 
     67SSH CONFIGURATION INFO for User inki
    10768================================================================================
    108 }}}
    109 
    110 The six lines that start with '''xterm -e ssh ...''' contain the information you need to connect to your nodes. There are six nodes in this experiment, and you will want to open a window for each. Copy and paste the commands, '''adding the -A switch to each ssh command''' as shown below. You will get six new terminal windows, one on each node of your experiment. (You should say yes if you are prompted to accept the RSA key of the remote host.)
    111 
    112 {{{
    113 xterm -e ssh -A -i /Users/mberman/.ssh/id_rsa mberman@pc336.emulab.net &
    114 }}}
    115 
    116 The shell prompt in each of your new terminal windows will tell you the host name. The four routers in your experiment are named '''top''', '''left''', '''right''', and '''bottom'''. The two end hosts are named '''hosta''' and '''hostb'''. You may want to rearrange the windows on your screen, putting the router hosts in the locations indicated, with the end hosts off to the side.
    117 
    118 '''Tip''': If you want to login to your hosts from a different host than the one you are running Omni on, take a look [wiki:HowTo/LoginToNodes here] for some tips about how to do this.
     69 
     70Host left
     71  Port 30778
     72  HostName pc403.emulab.net
     73  User inki
     74  IdentityFile /home/geni/.ssh/geni_key
     75
     76Host hostB
     77  Port 30779
     78  HostName pc490.emulab.net
     79  User inki
     80  IdentityFile /home/geni/.ssh/geni_key
     81
     82Host hostA
     83  Port 30778
     84  HostName pc545.emulab.net
     85  User inki
     86  IdentityFile /home/geni/.ssh/geni_key
     87
     88Host bottom
     89  Port 30778
     90  HostName pc490.emulab.net
     91  User inki
     92  IdentityFile /home/geni/.ssh/geni_key
     93 
     94Host right
     95  Port 30778
     96  HostName pc411.emulab.net
     97  User inki
     98  IdentityFile /home/geni/.ssh/geni_key
     99 
     100Host top
     101  Port 30779
     102  HostName pc545.emulab.net
     103  User inki
     104  IdentityFile /home/geni/.ssh/geni_key
     105
     106...<more output>...
     107}}}
     108
     109Copy all the above information and paste it into your `.ssh/config` file, then you can very easily login into your nodes, just by using the nickname (client_id) of the nodes.
     110
     111Your `~/.ssh/config` file should look like
     112{{{
     113IdentityFile /home/geni/.ssh/geni_key
     114Host left
     115  Port 30778
     116  HostName pc403.emulab.net
     117  User inki
     118  IdentityFile /home/geni/.ssh/geni_key
     119 
     120Host hostB
     121  Port 30779
     122  HostName pc490.emulab.net
     123  User inki
     124  IdentityFile /home/geni/.ssh/geni_key
     125
     126Host hostA
     127  Port 30778
     128  HostName pc545.emulab.net
     129  User inki
     130  IdentityFile /home/geni/.ssh/geni_key
     131
     132Host bottom
     133  Port 30778
     134  HostName pc490.emulab.net
     135  User inki
     136  IdentityFile /home/geni/.ssh/geni_key
     137
     138Host right
     139  Port 30778
     140  HostName pc411.emulab.net
     141  User inki
     142  IdentityFile /home/geni/.ssh/geni_key
     143
     144Host top
     145  Port 30779
     146  HostName pc545.emulab.net
     147  User inki
     148  IdentityFile /home/geni/.ssh/geni_key
     149
     150}}}
     151
     152Let's login to our two hosts, the nicknames are `hostA` and `hostB`
     153  i. Open two new terminals
     154  i. In one terminal type
     155  {{{
     156  ssh -A hostA
     157  }}}
     158  and in the other
     159  {{{
     160  ssh -S hostB
     161  }}}
    119162
    120163== Configure your routers ==