Changes between Version 43 and Version 44 of GENIExperimenter/Tutorials/GENIExperimentEngine/Execute


Ignore:
Timestamp:
03/18/15 18:10:50 (9 years ago)
Author:
acb@cs.princeton.edu
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • GENIExperimenter/Tutorials/GENIExperimentEngine/Execute

    v43 v44  
    3232You will use Ansible to do this. 
    3333
    34 == 1. Create an Ansible playbook to install the software you'll need ==
    35 
    36 First you will write a playbook to install the software you'll need on all the nodes.  Below is a skeleton Ansible file that you use ([attachment:software-install.yaml download]).  You will need to fill in the bits marked `# INSERT ARGUMENTS HERE` based on the instructions in the following section.  If you get stuck at any point, you can take a look at this [attachment:software-install-solution.yaml solution].
    37 
    38 {{{
    39 #!python
    40 ---
    41 - hosts: nodes
    42   remote_user: root
    43   tasks:
    44   - name: Update apt cache
    45     apt: # INSERT ARGUMENTS HERE
    46 
    47   - name: Install dnsutils (for dig)
    48     apt: # INSERT ARGUMENTS HERE
    49 
    50   - name: Install geoip-bin (for geoiplookup)
    51     apt: # INSERT ARGUMENTS HERE
    52 }}}
    53 
    54 Run this playbook on all the nodes in your slice.  You'll only need to do this step once.
    55 
    56 -----
    57 
    58 == 2. Create an Ansible playbook to download a parameterized URL from each node ==
     34== 1. Create an Ansible playbook to download a parameterized URL from each node ==
    5935
    6036To solve the problems of this tutorial, you need to collect several pieces of information on each node: the container name, the IP of the host (i.e., the VM hosting the container), the IP of the container, and the latitude and longitude of the host.  Three of these (the slice name, container name, and local IP) can be found from Ansible variables.  Running a {{{setup}}} command, as on the previous page, will show you the Ansible variables.  Note that {{{setup}}} is run automatically by Ansible, so when executing a playbook on a node that information is available.  Look through the output from {{{setup}}}, and you can identify
    6137the variables you'll need.  You then need to fetch a custom URL containing this information from each host.   
    6238
    63 Below is a skeleton Ansible file that you use ([attachment:gee-tutorial.yaml download]).  You will need to fill in the bits marked `# INSERT ARGUMENTS HERE` based on the instructions in the following section.  If you get stuck at any point, you can take a look at this [attachment:gee-tutorial-solution.yaml solution] -- but don't give up too easily!
     39Below is a [attachment:gee-tutorial.yaml skeleton Ansible playbook] that you can use.  You will need to fill in the bits marked `# INSERT ARGUMENTS HERE` based on the instructions in the following section.  If you get stuck at any point, you can take a look at this [attachment:gee-tutorial-solution.yaml solution] -- but don't give up too easily!
    6440
    6541{{{
     
    182158----
    183159
    184 == 3. Run the playbook ==
     160== 2. Run the playbook ==
    185161
    186 Once you have finished with Step 2, run your playbook against all the nodes in your slicelet! 
     162Once you have finished with Step 1, run your playbook against all the nodes in your slicelet! 
    187163
    188164----
    189165
    190 == 4. Verify that your playbook worked as expected ==
     166== 3. Verify that your playbook worked as expected ==
    191167
    192168Once you have completed the tutorial, you can check where you’ve said hello from at: