Version 12 (modified by 9 years ago) (diff) | ,
---|
Module A: Run your first experiment (a.k.a. Implement a Learning Switch)
1. Design the Experiment
|
2. Establish the Environment
2.1 Pre-work: Ensure SSH keys are setup
Verify that you have at least one public key associated with your account. To do that, after you login to the portal check under your Profile, under the SSH keys
tab. If you do not have SSH keys associated yet, please follow the instructions on that tab of the Portal.
2.2 Configure Omni
|
Figure 2-1 Click on the Configure omni tab under Profile. |
- Click on the `Download your omni data` button under step 2.
Figure 2-2 Download your omni data under step 2.
- If this is the first time you try to access your GENI certificate you will have to generate one. Click on the `generate a certificate` link.
Figure 2-3 Click on Generate a certificate.
- Unless you really understand how SSL certificates work, choose the simple option. Click on the `Generate Combined Certificate and Key File` button and then click on `Close`. You will be taken back to the download page with the warning. Reload the page to enable the download button.
Figure 2-4 Click on Generate Combined Certificate and Key File.
- If you are a member of more than one project, select which project you would like to be the default one for running experiments in GENI. You can always change the project that is used by the `-r` command line option of Omni. Then click on `Download your omni data`.
Figure 2-5 Click on Download your omni data.
|
3. Obtain Resources
3.1 Create a slice
Create a slice using omni
and the slice name of your choice. From now on that slice name will be referred to as SLICENAME
.
$ omni createslice SLICENAME
3.2. Load a simple topology in Jacks
For this exercise, we will edit an existing RSpec file. Start by loading this predefined topology into Jacks.
|
Figure 3-1 Import an RSpec into Jacks. |
|
3.3. Modify the RSpec to automatically install and execute LabWiki software
For this experiment, we need to install the following software on the nodes:
- The GIMI software (gimidev.tar.gz)
When the nodes start up, we need the following scripts to be executed:
- Script that sets up the GIMI software (gimibot.sh)
We automate the installation and running of the software using install and execute scripts in the RSpec.
|
Figure 3-2 Edit the nodes |
|
Figure 3-3 Specify the install and execute scripts |
|
|
3.4. Export the modified request RSpec
Now we will pull back some of the covers and inspect exactly what Jacks has been doing for us when preparing the RSpecs for the experiments we design. Each node and link has a corresponding element in the RSpec, and the details of the component configuration (such as the install and execute services we requested above) are specified with attributes, or sometimes child elements, within those portions of the document.
|
Figure 3-4 View and save the final request RSpec |
|
3.5. Instantiate the new experiment using Omni
For this step, we'll change the approach a bit and switch to a new client tool, the command line Omni client.
From a terminal, please enter the command:
$ omni -a AM_NICKNAME createsliver SLICENAME RSPEC_FILE
where AM_NICKNAME
is the nickname for your assigned aggregate manager and SLICENAME
is the name of the slice you created earlier (both of these are given on your worksheet). RSPEC_FILE
should be replaced with the filename of the RSpec you saved in step 3.4.
If all is well, Omni should give you a number of informational messages, such as:
INFO:omni:Loading config file /home/geni/.gcf/omni_config
It should quickly proceed to the point where it makes the request to the remote manager:
INFO:omni:Creating sliver(s) from rspec file /home/geni/Downloads/experiments.rspec for slice ...
This step can sometimes be time-consuming, so please be patient. If it succeeds, within a couple of minutes Omni should report:
INFO:omni: Completed createsliver:
and your resource reservation is complete!
4 Wait for resources to be ready
You can tell whether your nodes are ready by using a script built on omni
called readyToLogin
.
-
Please use the command:
readyToLogin --useSliceAggregates SLICENAME
where (as before) SLICENAME is your slice name (found on your worksheet). --useSliceAggregates will query the GENI Clearinghouse for the aggregates where you have resources on this slice.
- If it reports that the sliver is not yet ready (for example, it might say that the status is "changing"), then wait a minute
or two and try again. Once everything is complete, readyToLogin
will give output that should look something like this:
... nodea's geni_status is: ready User example logs in to nodea using: ssh -p 34106 -i /Users/example/.ssh/geni_key_portal example@pc2.instageni.illinois.edu switch's geni_status is: ready User example logs in to switch using: ssh -p 34110 -i /Users/example/.ssh/geni_key_portal example@pc2.instageni.illinois.edu nodeb's geni_status is: ready User example logs in to nodeb using: ssh -p 34107 -i /Users/example/.ssh/geni_key_portal example@pc2.instageni.illinois.edu nodec's geni_status is: ready User example logs in to nodec using: ssh -p 34108 -i /Users/example/.ssh/geni_key_portal example@pc2.instageni.illinois.edu noded's geni_status is: ready User example logs in to noded using: ssh -p 34109 -i /Users/example/.ssh/geni_key_portal example@pc2.instageni.illinois.edu ...