wiki:GENIExperimenter/ExperimentExample

Version 11 (modified by Aaron Helsinger, 13 years ago) (diff)

--

GENI Experiment Example 1

This page illustrates an operational example for the GENI Experimenter How-to page capturing the actions required to run an experiment using multiple resource aggregates and with user credentials from the GPO ProtoGENI Clearinghouse pgeni.gpolab.bbn.com. Details on how credentials are set up can be found in the GENI Credentials section of the main GENI Experimenter page. In this experiment, a total of 5 nodes are requested, with 2 nodes from the Emulab (PG) aggregate and 3 nodes from the PlanetLab (PL) aggregate.

This page does not cover the installation of the OMNI client, as it is well documented, please see the following pages to get the GCF package and to install it.

Omni Configuration

For GENI Experiment Example defined above, the following omni_config settings were used:

[omni]
default_cf = pgeni
users = lnevers

# ---------- Users ----------
[lnevers]
urn = urn:publicid:IDN+pgeni.gpolab.bbn.com+user+lnevers
keys = ~/.ssh/id_rsa.pub

# ---------- Frameworks ----------
[pgeni]
type = pg
ch = https://www.emulab.net:443/protogeni/xmlrpc/ch
sa = https://www.pgeni.gpolab.bbn.com:443/protogeni/xmlrpc/sa
cert = ~/.ssl/encrypted-cleartext.pem
key = ~/.ssl/encrypted-cleartext.pem
verbose=false

[emulab]
type = pg
ch = https://www.emulab.net:443/protogeni/xmlrpc/ch
sa = https://www.emulab.net:443/protogeni/xmlrpc/sa
cert = ~/.ssl/encrypted-cleartext.pem
key = ~/.ssl/encrypted-cleartext.pem

[plc]
type=sfa
authority=plc.bbn
user=plc.bbn.lnevers
cert=~/.gcf/plc.bbn.lnevers.gid
key=~/.gcf/lnevers.pkey
registry=http://www.planet-lab.org:12345
slicemgr=http://www.planet-lab.org:12347

The above configuration is specific to the experiment captured in this page. Note, the pgeni framework definition includes the Utah Emulab clearinghouse, which is the only clearinghouse for ProtoGENI aggregates. For additional configuration details please see the Omni page for more details. The omni_configuration parameters shown define the following:

Parameter Use
default_cf Default Clearinghouse and credentials used if not specified on the command line.
users users setting used when reserving slices.
urn The username URN, see how to determine your URN
keys A comma separated list of public ssh key files to be uploaded to the Clearinghouse
type Clearinghouse/credentials type "pg" indicates ProtoGENI, see the Omni page.
ch ProtoGENI Clearinghouse URL.
sa Slice Authority URL.
cert Location of your SSL encrypted certificate (contains both a certificate and a key).
key Location of your SSL encrypted key (contains both a certificate and a key).

List available resources

With the GPO Protogeni setting defined as shown in the omni_config above, you can get a list of available resources from each of the other 2 aggregates.

Note: These instructions use Omni 1.3 options. Starting with Omni 1.3, 'native' format RSpecs are the default, and 'omnispecs' are deprecated though still available. Additionally, verbose output like the Advertisement RSpec from List Resources is saved to a file using the -o option. Finally, these instructions show the use of the -t option to request RSpecs in a particular format. For earlier versions of omni, you should (a) include the -n argument, (b) re-direct output to a file (>) instead of the -o option, and (c) use PG V0.2 RSpecs at Emulab and SFA format RSpecs at PlanetLab.

Getting a list of resources from the Emulab Protogeni aggregate in ProtoGENI RSpec V2 format:

$  src/omni.py -a https://www.emulab.net/protogeni/xmlrpc/am -o -t ProtoGENI 2 listresources 
INFO:omni:Loading config file omni_config
INFO:omni:Using control framework pgeni
INFO:omni:Saving output to a file.
INFO:omni:Listed resources on 1 out of 1 possible aggregates.
INFO:omni:Writing to 'rspec-www-emulab-net-protogeni.xml'
INFO:omni: ------------------------------------------------------------
INFO:omni: Completed listresources:

  Options as run:
		aggregate: https://www.emulab.net/protogeni/xmlrpc/am
		configfile: omni_config
		framework: pgeni
		native: True
		output: True
		rspectype: ('ProtoGENI', '2')

  Args: listresources

  Result Summary: Retrieved resources from 1 aggregates.
Wrote rspecs from 1 aggregates to 1 files. 
INFO:omni: ============================================================

The resulting file (named rspec-www-emulab-net-protogeni.xml as the output describes) looks like this in part:

<?xml version="1.0" ?>
<!-- Resources at AM:
        URN: unspecified_AM_URN
        URL: https://www.emulab.net/protogeni/xmlrpc/am
 -->
<rspec expires="2011-06-16T13:34:00Z" generated="2011-06-16T13:34:00Z" type="advertisement" xmlns="http://www.protogeni.net/resources/rspec/2" xmlns:emulab="http://www.protogeni.net/resources/rspec/ext/emulab/1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.protogeni.net/resources/rspec/2 http://www.protogeni.net/resources/rspec/2/ad.xsd http://www.protogeni.net/resources/rspec/ext/emulab/1 http://www.protogeni.net/resources/rspec/ext/emulab/1/ptop_extension.xsd">  
  <node component_id="urn:publicid:IDN+emulab.net+node+cisco3" component_manager

Getting a list of resources from the PlanetLab Princeton aggregate in its default format (SFA):

$  src/omni.py -o -a http://www.planet-lab.org:12346 listresources
INFO:omni:Loading config file omni_config
INFO:omni:Using control framework pgeni
INFO:omni:Saving output to a file.
INFO:omni:Listed resources on 1 out of 1 possible aggregates.
INFO:omni:Writing to 'rspec-www-planet-lab-org.xml'
INFO:omni: ------------------------------------------------------------
INFO:omni: Completed listresources:

  Options as run:
		aggregate: https://www.planet-lab.org:12346
		configfile: omni_config
		framework: pgeni
		native: True
		output: True

  Args: listresources

  Result Summary: Retrieved resources from 1 aggregates.
Wrote rspecs from 1 aggregates to 1 files. 
INFO:omni: ============================================================

This output file (rspec-www-planet-lab-org.xml) begins:

<?xml version="1.0" ?>
<!-- Resources at AM:
        URN: unspecified_AM_URN
        URL: https://www.planet-lab.org:12346
 -->
<RSpec expires="2011-06-16T14:37:07Z" generated="2011-06-16T13:37:07Z" type="SFA">  
    <network name="plc">    

You may use the output of these two listresources commands to generate rspecs to request resources. The above listresources commands use the default native rspec format rather than the deprecated omnispec format. Note that with native RSpecs, the -a flag or the aggregates entry in your omni_config is required to specify an aggregate manager.

If you are planning to use MyPLC resources, you may query a MyPLC installation to get a list of available resources as follows:

$ ./src/omni.py -a http://myplc.gpolab.bbn.com:12346 -o listresources
INFO:omni:Loading config file omni_config
INFO:omni:Using control framework pgeni
INFO:omni:Saving output to a file.
INFO:omni:Listed resources on 1 out of 1 possible aggregates.
INFO:omni:Writing to 'rspec-myplc-gpolab-bbn-com.xml'
INFO:omni: ------------------------------------------------------------
INFO:omni: Completed listresources:

  Options as run:
		aggregate: http://myplc.gpolab.bbn.com:12346
		configfile: omni_config
		framework: pgeni
		native: True
		output: True

  Args: listresources

  Result Summary: Retrieved resources from 1 aggregates.
Wrote rspecs from 1 aggregates to 1 files. 
INFO:omni: ============================================================

If you are planning to use University of Kentucky Emulab resources, you can query just this installation (instead of all PG aggregates, as we did in the example above) to get a list of available resources. Note the example below was collected with GPO pgeni.gpolab.bbn.com credentials:

$ src/omni.py -a https://www.uky.emulab.net/protogeni/xmlrpc/am -o listresources 
INFO:omni:Loading config file omni_config
INFO:omni:Using control framework pgeni
INFO:omni:Saving output to a file.
INFO:omni:Listed resources on 1 out of 1 possible aggregates.
INFO:omni:Writing to 'rspec-www-uky-emulab-net-protogeni.xml'
INFO:omni: ------------------------------------------------------------
INFO:omni: Completed listresources:

  Options as run:
		aggregate: https://www.uky.emulab.net/protogeni/xmlrpc/am
		configfile: omni_config
		framework: pgeni
		native: True
		output: True

  Args: listresources

  Result Summary: Retrieved resources from 1 aggregates.
Wrote rspecs from 1 aggregates to 1 files. 
INFO:omni: ============================================================

Create a slice

Since the omni_config specifies using the credentials and the Clearinghouse for the GPO Protogeni, your slice will be created in the pgeni.gpolab.bbn.com namespace. For this example a slice named lnevers_slice is created; you should choose a slice name that is meaningful to you. To avoid confusion, avoid creating a slice with the same name as your username (ie if your username is lnevers, don't name your slice lnevers too).

$ ./src/omni.py createslice lnevers_slice
INFO:omni:Loading config file omni_config
INFO:omni:Using control framework pgeni
INFO:omni:Created slice with Name lnevers_slice, URN urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice, Expiration 2011-06-16 19:46:49
INFO:omni: ------------------------------------------------------------
INFO:omni: Completed createslice:

  Options as run:
		configfile: omni_config
		framework: pgeni
		native: True

  Args: createslice lnevers_slice

  Result Summary: Created slice with Name lnevers_slice, URN urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice, Expiration 2011-06-16 19:46:49
 
INFO:omni: ============================================================

Renew your slice

Note in the above output that our new slice expires soon. Your resource reservations will not be longer then your slice life, and will go away when the reservation expires. For your experiment be sure to renew your slice for the duration of your experiment. Here we only slightly extend the slice lifetime.

$ ./src/omni.py renewslice lnevers_slice 20110618
INFO:omni:Loading config file omni_config
INFO:omni:Using control framework pgeni
INFO:omni.protogeni:Requesting new slice expiration '2011-06-18T00:00:00'
INFO:omni:Slice lnevers_slice now expires at 2011-06-18 00:00:00 UTC
INFO:omni:Slice urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice expires on 2011-06-18 00:00:00 UTC
INFO:omni: ------------------------------------------------------------
INFO:omni: Completed renewslice:

  Options as run:
		configfile: omni_config
		framework: pgeni
		native: True

  Args: renewslice lnevers_slice 20110618

  Result Summary: Slice lnevers_slice now expires at 2011-06-18 00:00:00 UTC
Slice urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice expires on 2011-06-18 00:00:00 UTC 
INFO:omni: ============================================================

Add Emulab PG resources to GPO PG slice

To request two Emulab ProtoGENI nodes, the following rspec named emulab.rspec was used for this example; your rspec will be specific to your experiment requirements:

<?xml version="1.0" ?>
<!-- Resources at AM:
        URN: unspecified_AM_URN
        URL: https://www.emulab.net/protogeni/xmlrpc/am
 -->
<rspec type="request" xmlns="http://www.protogeni.net/resources/rspec/2" xmlns:emulab="http://www.protogeni.net/resources/rspec/ext/emulab/1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.protogeni.net/resources/rspec/2 http://www.protogeni.net/resources/rspec/2/request.xsd http://www.protogeni.net/resources/rspec/ext/emulab/1 http://www.protogeni.net/resources/rspec/ext/emulab/1/ptop_extension.xsd">
  <node client_id="geni1"
        exclusive="true">
    <sliver_type name="raw-pc" />
  </node>
  <node client_id="geni2"
        exclusive="true">
    <sliver_type name="raw-pc" />
  </node>
</rspec>

To request two Protogeni nodes, a sliver was created within the Emulab Protogeni aggregate with the rspec above using the following command. Note the use of the -o argument, which saves the manifest RSpec to a file. The manifest contains your new host's IP address and login information.

$ ./src/omni.py -a https://www.emulab.net/protogeni/xmlrpc/am -o createsliver lnevers_slice emulab.rspec 
INFO:omni:Loading config file omni_config
INFO:omni:Using control framework pgeni
INFO:omni:Slice urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice expires within 1 day on 2011-06-16 19:46:49 UTC
INFO:omni:Creating sliver(s) from rspec file emulab.rspec for slice urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice
INFO:omni:Writing result of createsliver for slice: lnevers_slice at AM: https://www.emulab.net/protogeni/xmlrpc/am to file lnevers_slice-manifest-rspec-www-emulab-net-protogeni.xml
INFO:omni:Writing to 'lnevers_slice-manifest-rspec-www-emulab-net-protogeni.xml'
INFO:omni: ------------------------------------------------------------
INFO:omni: Completed createsliver:

  Options as run:
		aggregate: https://www.emulab.net/protogeni/xmlrpc/am
		configfile: omni_config
		framework: pgeni
		native: True
		output: True

  Args: createsliver lnevers_slice emulab.rspec

  Result Summary: Slice urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice expires within 1 day(s) on 2011-06-16 19:46:49 UTC
Reserved resources on https://www.emulab.net/protogeni/xmlrpc/am. 
   Saved createsliver results to lnevers_slice-manifest-rspec-www-emulab-net-protogeni.xml.  
INFO:omni: ============================================================

The manifest RSpec - the result of your reservation - looks like this:

<?xml version="1.0" ?>
<!-- Reserved resources for:
        Slice: lnevers_slice
        At AM:
        URL: http://www.emulab.net/protogeni/xmlrpc/am
 -->
<rspec type="manifest" xmlns="http://www.protogeni.net/resources/rspec/2" xmlns:
emulab="http://www.protogeni.net/resources/rspec/ext/emulab/1" xmlns:xsi="http:/
/www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.protogeni.ne
t/resources/rspec/2 http://www.protogeni.net/resources/rspec/2/manifest.xsd http
://www.protogeni.net/resources/rspec/ext/emulab/1 http://www.protogeni.net/resou
rces/rspec/ext/emulab/1/ptop_extension.xsd">  
    <node client_id="geni1" component_id="urn:publicid:IDN+emulab.net+node+pc141
" component_manager_id="urn:publicid:IDN+emulab.net+authority+cm" exclusive="tru
e" sliver_id="urn:publicid:IDN+emulab.net+sliver+39860" xmlns:emulab="http://www
.protogeni.net/resources/rspec/ext/emulab/1">    
        <sliver_type name="raw"/>    
      <emulab:vnode name="pc141"/>    <services>      <login authentication="ssh
-keys" hostname="pc141.emulab.net" port="22" username="lnevers"/>    </services
>  </node>  
    <node client_id="geni2" component_id="urn:publicid:IDN+emulab.net+node+pc139
" component_manager_id="urn:publicid:IDN+emulab.net+authority+cm" exclusive="tru
e" sliver_id="urn:publicid:IDN+emulab.net+sliver+39861" xmlns:emulab="http://www
.protogeni.net/resources/rspec/ext/emulab/1">    
        <sliver_type name="raw"/>    
      <emulab:vnode name="pc139"/>    <services>      <login authentication="ssh
-keys" hostname="pc139.emulab.net" port="22" username="lnevers"/>    </services
>  </node>  
</rspec>

Add PlanetLab resources to GPO PG slice

To request three Planetlab nodes, the following rspec named planet.rspec was used for this example; your rspec will be specific to your experiment requirements.

This example uses ProtoGENI V2 RSpec format. Standard SFA formats are also acceptable. To generate the ProtoGENI V2 request from the Advertisement:

  • Change the rspec headers to specify that this is a request, using the headers shown below
  • Pull out only the nodes you wish to reserve - ensure they say available now="true"
  • For each node
    • Add an attribute client_id with a nickname
    • Remove the available sub-element
    • Add the sub-element <sliver_type name="plab-vnode"/>
<?xml version="1.0" ?>
<!-- Resources at AM:
        URN: unspecified_AM_URN
        URL: http://www.planet-lab.org:12346
 -->
<rspec type="request"
       xmlns="http://www.protogeni.net/resources/rspec/2"
       xmlns:emulab="http://www.protogeni.net/resources/rspec/ext/emulab/1"
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xsi:schemaLocation="http://www.protogeni.net/resources/rspec/2
       http://www.protogeni.net/resources/rspec/2/request.xsd
       http://www.protogeni.net/resources/rspec/ext/emulab/1
       http://www.protogeni.net/resources/rspec/ext/emulab/1/ptop_extension.xsd">
  <node
    component_id="urn:publicid:IDN+plc:rit+node+planet2.cs.rit.edu"
    component_manager_id="urn:publicid:IDN+plc+authority+am"
    component_name="planet2.cs.rit.edu" exclusive="false" 
    client_id="ritpl2">    
      <hardware_type name="plab-pc"/>    
      <hardware_type name="pc"/>    
      <location country="us" latitude="43.0844" longitude="-77.6799"/>    
      <sliver_type name="plab-vnode"/>    
  </node>  
  <node
    component_id="urn:publicid:IDN+plc:williams+node+planetlab3.williams.edu"
    component_manager_id="urn:publicid:IDN+plc+authority+am"
    component_name="planetlab3.williams.edu" exclusive="false" 
    client_id="williamspl3">    
      <hardware_type name="plab-pc"/>    
      <hardware_type name="pc"/>    
      <location country="us" latitude="42.71" longitude="-73.2"/>    
      <sliver_type name="plab-vnode"/>    
  </node>  
  <node
    component_id="urn:publicid:IDN+plc:bbn+node+plnode-03.gpolab.bbn.com"
    component_manager_id="urn:publicid:IDN+plc+authority+am"
    component_name="plnode-03.gpolab.bbn.com" exclusive="false" 
    client_id="gpopl3">    
      <hardware_type name="plab-pc"/>    
      <hardware_type name="pc"/>    
      <location country="us" latitude="42.3907" longitude="-71.1478"/>    
      <sliver_type name="plab-vnode"/>    
  </node>  
</rspec>

To request the three Planetlab nodes, a sliver was created within Planetlab with the rspec above using the following command:

$ ./src/omni.py -a http://www.planet-lab.org:12346 -o createsliver lnevers_slice planet.rspec
INFO:omni:Loading config file omni_config
INFO:omni:Using control framework pgeni
INFO:omni:Slice urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice expires on 2011-06-18 00:00:00 UTC
INFO:omni:Creating sliver(s) from rspec file planet.rspec for slice urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice
INFO:omni:Writing result of createsliver for slice: lnevers_slice at AM: https://www.planet-lab.org:12346 to file lnevers_slice-manifest-rspec-www-planet-lab-org.xml
INFO:omni:Writing to 'lnevers_slice-manifest-rspec-www-planet-lab-org.xml'
INFO:omni: ------------------------------------------------------------
INFO:omni: Completed createsliver:

  Options as run:
		aggregate: https://www.planet-lab.org:12346
		configfile: omni_config
		framework: pgeni
		native: True
		output: True

  Args: createsliver lnevers_slice planet.rspec

  Result Summary: Slice urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice expires on 2011-06-18 00:00:00 UTC
Reserved resources on https://www.planet-lab.org:12346. 
   Saved createsliver results to lnevers_slice-manifest-rspec-www-planet-lab-org.xml.  
INFO:omni: ============================================================

The resulting manifest RSpec is this:

<?xml version="1.0" ?>
<!-- Reserved resources for:
        Slice: lnevers_slice
        At AM:
        URL: https://www.planet-lab.org:12346
 -->
<rspec expires="2011-06-16T15:52:23Z" generated="2011-06-16T14:52:23Z" type="man
ifest" xmlns="http://www.protogeni.net/resources/rspec/2" xmlns:xsi="http://www.
w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.protogeni.net/res
ources/rspec/2 http://www.protogeni.net/resources/rspec/2/manifest.xsd">  
    <node client_id="planetlab3.williams.edu" component_id="urn:publicid:IDN+plc
:williams+node+planetlab3.williams.edu" component_manager_id="urn:publicid:IDN+p
lc+authority+am" component_name="planetlab3.williams.edu" exclusive="false" sliv
er_id="urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice">    
        <hardware_type name="plab-pc"/>    
        <hardware_type name="pc"/>    
        <location country="us" latitude="42.71" longitude="-73.2"/>    
        <sliver_type name="plab-vnode"/>    
    </node>  
    <node client_id="plnode-03.gpolab.bbn.com" component_id="urn:publicid:IDN+pl
c:bbn+node+plnode-03.gpolab.bbn.com" component_manager_id="urn:publicid:IDN+plc+
authority+am" component_name="plnode-03.gpolab.bbn.com" exclusive="false" sliver
_id="urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice">    
        <hardware_type name="plab-pc"/>    
        <hardware_type name="pc"/>    
        <location country="us" latitude="42.3907" longitude="-71.1478"/>    
        <sliver_type name="plab-vnode"/>    
    </node>  
    <node client_id="planet2.cs.rit.edu" component_id="urn:publicid:IDN+plc:rit+
node+planet2.cs.rit.edu" component_manager_id="urn:publicid:IDN+plc+authority+am
" component_name="planet2.cs.rit.edu" exclusive="false" sliver_id="urn:publicid:
IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice">    
        <hardware_type name="plab-pc"/>    
        <hardware_type name="pc"/>    
        <location country="us" latitude="43.0844" longitude="-77.6799"/>    
        <sliver_type name="plab-vnode"/>    
    </node>  
</rspec>

Note that your login for your nodes is available by running sliverstatus.

As part of the createsliver operation for PL nodes, Omni uploads the user SSH keys based on the [users] section of the omni_config. If you have problems in setting up your slice, contact us at help@geni.net.

Checking sliver resource status

Once you have requested the resources you may check the sliver status for PG and PL nodes. As you review the results, note the expiration time to make sure that it meets your experiment running time requirement. To get sliverstatus for the example experiment on this page the following command was issued for the PG resources:

$ ./src/omni.py -a https://www.emulab.net/protogeni/xmlrpc/am sliverstatus lnevers_slice
INFO:omni:Loading config file omni_config
INFO:omni:Using control framework pgeni
INFO:omni:Slice urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice expires on 2011-06-18 00:00:00 UTC
INFO:omni:Status of Slice urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice:
INFO:omni:Sliver status for Slice urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice at AM URL https://www.emulab.net/protogeni/xmlrpc/am
INFO:omni:{'geni_resources': [{'geni_error': '',
                     'geni_status': 'ready',
                     'geni_urn': 'urn:publicid:IDN+emulab.net+sliver+39860',
                     'pg_manifest': {'attributes': {'client_id': 'geni1',
                                                    'component_id': 'urn:publicid:IDN+emulab.net+node+pc141',
                                                    'component_manager_id': 'urn:publicid:IDN+emulab.net+authority+cm',
                                                    'exclusive': 'true',
                                                    'sliver_id': 'urn:publicid:IDN+emulab.net+sliver+39860',
                                                    'xmlns': 'http://www.protogeni.net/resources/rspec/2',
                                                    'xmlns:emulab': 'http://www.protogeni.net/resources/rspec/ext/emulab/1'},
                                     'children': [{'attributes': {'name': 'raw'},
                                                   'children': [],
                                                   'name': 'sliver_type'},
                                                  {'attributes': {'name': 'pc141'},
                                                   'children': [],
                                                   'name': 'emulab:vnode'},
                                                  {'attributes': {},
                                                   'children': [{'attributes': {'authentication': 'ssh-keys',
                                                                                'hostname': 'pc141.emulab.net',
                                                                                'port': 22,
                                                                                'username': 'lnevers'},
                                                                 'children': [],
                                                                 'name': 'login'}],
                                                   'name': 'services'}],
                                     'name': 'node'},
                     'pg_status': 'ready'},
                    {'geni_error': '',
                     'geni_status': 'ready',
                     'geni_urn': 'urn:publicid:IDN+emulab.net+sliver+39861',
                     'pg_manifest': {'attributes': {'client_id': 'geni2',
                                                    'component_id': 'urn:publicid:IDN+emulab.net+node+pc139',
                                                    'component_manager_id': 'urn:publicid:IDN+emulab.net+authority+cm',
                                                    'exclusive': 'true',
                                                    'sliver_id': 'urn:publicid:IDN+emulab.net+sliver+39861',
                                                    'xmlns': 'http://www.protogeni.net/resources/rspec/2',
                                                    'xmlns:emulab': 'http://www.protogeni.net/resources/rspec/ext/emulab/1'},
                                     'children': [{'attributes': {'name': 'raw'},
                                                   'children': [],
                                                   'name': 'sliver_type'},
                                                  {'attributes': {'name': 'pc139'},
                                                   'children': [],
                                                   'name': 'emulab:vnode'},
                                                  {'attributes': {},
                                                   'children': [{'attributes': {'authentication': 'ssh-keys',
                                                                                'hostname': 'pc139.emulab.net',
                                                                                'port': 22,
                                                                                'username': 'lnevers'},
                                                                 'children': [],
                                                                 'name': 'login'}],
                                                   'name': 'services'}],
                                     'name': 'node'},
                     'pg_status': 'ready'}],
 'geni_status': 'ready',
 'geni_urn': 'urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice',
 'pg_expires': '2011-06-17 18:00:00',
 'pg_status': 'ready'}
INFO:omni: ------------------------------------------------------------
INFO:omni: Completed sliverstatus:

  Options as run:
		aggregate: https://www.emulab.net/protogeni/xmlrpc/am
		configfile: omni_config
		framework: pgeni
		native: True

  Args: sliverstatus ahtest_slice

  Result Summary: Slice urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice expires on 2011-06-18 00:00:00 UTC
Returned status of slivers on 1 of 1 possible aggregates. 
INFO:omni: ============================================================

To check the sliverstatus for PL resources, but this time saving the status output to a file, the following command was issued:

$ ./src/omni.py -a http://www.planet-lab.org:12346 -o sliverstatus lnevers_slice
INFO:omni:Loading config file omni_config
INFO:omni:Using control framework pgeni
INFO:omni:Slice urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice expires on 2011-06-18 00:00:00 UTC
INFO:omni:Status of Slice urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice:
INFO:omni:Writing to 'lnevers_slice-sliverstatus-www-planet-lab-org.json'
INFO:omni:Sliver status for Slice urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice at AM URL https://www.planet-lab.org:12346
INFO:omni: ------------------------------------------------------------
INFO:omni: Completed sliverstatus:

  Options as run:
		aggregate: https://www.planet-lab.org:12346
		configfile: omni_config
		framework: pgeni
		native: True
		output: True

  Args: sliverstatus ahtest_slice

  Result Summary: Slice urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice expires on 2011-06-18 00:00:00 UTC
Returned status of slivers on 1 of 1 possible aggregates. 
INFO:omni: ============================================================

And the saved status is:

{'geni_resources': [{'geni_error': '',
                     'geni_status': 'ready',
                     'geni_urn': 'urn:publicid:IDN+plc:williams+node+planetlab3.wi
lliams.edu',
                     'pl_boot_state': 'boot',
                     'pl_hostname': 'planetlab3.williams.edu',
                     'pl_last_contact': 'Thu Jun 16 10:50:38 2011'},
                    {'geni_error': '',
                     'geni_status': 'ready',
                     'geni_urn': 'urn:publicid:IDN+plc:bbn+node+plnode-03.gpolab.b
bn.com',
                     'pl_boot_state': 'boot',
                     'pl_hostname': 'plnode-03.gpolab.bbn.com',
                     'pl_last_contact': 'Thu Jun 16 11:00:21 2011'},
                    {'geni_error': '',
                     'geni_status': 'ready',
                     'geni_urn': 'urn:publicid:IDN+plc:rit+node+planet2.cs.rit.edu
',
                     'pl_boot_state': 'boot',
                     'pl_hostname': 'planet2.cs.rit.edu',
                     'pl_last_contact': 'Thu Jun 16 10:54:26 2011'}],
 'geni_status': 'ready',
 'geni_urn': 'urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice',
 'pl_expires': 'Thu Jun 30 10:52:22 2011',
 'pl_login': 'pgenigpolabbbncom_lnevers_slice'}

A lot of very useful information is reported for the sliverstatus output including which hosts are assigned to you and for how long. For PlanetLab, notice the value in the 'pl_login' field, which is the login to be used to access the nodes. For a slice across multiple aggregates, you should pay close attention to the expiration time for each aggregate sliver (pg_expires & pl_expires). Note that slice expiration time is also available in the output of many commands.

Also note that by using the aggregates option in your omni_config, you can configure Omni to talk to all the aggregates in your experiment, and only those aggregates. Then sliverstatus will get full status for you in a single call.

For this example the pg_expires is 2011-06-17 18:00:00 while the pl_expires is Thu Jun 30 10:52:22 2011. Make sure that each expiration time meets your requirements for your experiment's duration. If you need to extend the expiration, you can use the Omni renewslice to expand the time for your slice as described above. Then use renewsliver to extend each sliver. The following command is issued to modify the expiration time for the ProtoGENI resources:

$ ./src/omni.py -a https://www.emulab.net/protogeni/xmlrpc/am renewsliver lnevers_slice 20110618
INFO:omni:Loading config file omni_config
INFO:omni:Using control framework pgeni
INFO:omni:Slice urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice expires on 2011-06-18 00:00:00 UTC
INFO:omni:Renewing Sliver urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice until 2011-06-18 00:00:00 UTC
INFO:omni:Renewed sliver urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice at unspecified_AM_URN (https://www.emulab.net/protogeni/xmlrpc/am) until 2011-06-18T00:00:00 UTC
INFO:omni: ------------------------------------------------------------
INFO:omni: Completed renewsliver:

  Options as run:
		aggregate: https://www.emulab.net/protogeni/xmlrpc/am
		configfile: omni_config
		framework: pgeni
		native: True

  Args: renewsliver lnevers_slice 20110618

  Result Summary: Slice urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice expires on 2011-06-18 00:00:00 UTC
Renewed sliver urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice at unspecified_AM_URN (https://www.emulab.net/protogeni/xmlrpc/am) until 2011-06-18T00:00:00 UTC
 
INFO:omni: ============================================================

Check status again and you will notice that the pg_expires has been modified:

$ ./src/omni.py -a https://www.emulab.net/protogeni/xmlrpc/am sliverstatus lnevers_slice
INFO:omni:Loading config file omni_config
INFO:omni:Using control framework pgeni

.....

 'geni_status': 'ready',
 'geni_urn': 'urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice',
 'pg_expires': '2011-06-17 18:00:00',
 'pg_status': 'ready'}
INFO:omni: ------------------------------------------------------------
INFO:omni: Completed sliverstatus:

  Options as run:
		aggregate: https://www.emulab.net/protogeni/xmlrpc/am
		configfile: omni_config
		framework: pgeni
		native: True

  Args: sliverstatus lnevers_slice

  Result Summary: Slice urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice expires on 2011-06-18 00:00:00 UTC
Returned status of slivers on 1 of 1 possible aggregates. 
INFO:omni: ============================================================

Find Slivers and List Resources in your Slice

If at any point you forget what you have reserved in your slice, or lose the manifest RSpec that you saved earlier, you can retrieve it. By calling listresources with your slice name as an argument, you get your manifest RSpec again.

Run:

$ ./src/omni.py -a https://www.emulab.net/protogeni/xmlrpc/am -o -t ProtoGENI 2 listresources lnevers_slice
INFO:omni:Loading config file omni_config
INFO:omni:Using control framework pgeni
INFO:omni:Saving output to a file.
INFO:omni:Gathering resources reserved for slice lnevers_slice..
INFO:omni:Listed resources on 1 out of 1 possible aggregates.
INFO:omni:Writing to 'lnevers_slice-rspec-www-emulab-net.xml'
INFO:omni: ------------------------------------------------------------
INFO:omni: Completed listresources:

  Options as run:
		aggregate: http://www.emulab.net/protogeni/xmlrpc/am
		native: True
		output: True

  Args: listresources ahtest

  Result Summary: Retrieved resources for slice lnevers_slice from 1 aggregates.
Wrote rspecs from 1 aggregates to 1 files. 
INFO:omni: ============================================================

The result will be a file (lnevers_slice-rspec-www-emulab-net.xml) of the resources in your slice at that aggregate.

Verify Resources and run your Experiment

Once you have the sliverstatus, you have enough information to access the hosts allocated for your experiment. Simply SSH into one of the hosts and ping any of the other hosts in your experiment. Notice that the pl_login is being used to get access. Now verify that there is connectivity between your allocated resources. In this example experiment, one of the PlanetLab resources allocated is used to ping a !ProtoGENI resource that is also part of the experiment:

$ ssh pgenigpolabbbncom_lneversslice@plnode-03.gpolab.bbn.com
Last login: Mon Mar  7 18:20:48 2011 from sendaria.gpolab.bbn.com
[pgenigpolabbbncom_lneversslice@plnode-03 ~]$ ping pc203.emulab.net -c 3
PING pc203.emulab.net (155.98.39.3) 56(84) bytes of data.
64 bytes from pc203.emulab.net (155.98.39.3): icmp_seq=1 ttl=44 time=116 ms
64 bytes from pc203.emulab.net (155.98.39.3): icmp_seq=2 ttl=44 time=116 ms
64 bytes from pc203.emulab.net (155.98.39.3): icmp_seq=3 ttl=44 time=116 ms

--- pc203.emulab.net ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2001ms
rtt min/avg/max/mdev = 116.385/116.595/116.997/0.398 ms
[pgenigpolabbbncom_lneversslice@plnode-03 ~]$ 

Once you have verified connectivity between these hosts that have been allocated to you, you may start your experiment.

Delete sliver resources

When the experiment is completed you should release the resources by deleting the resource sliver for each of the Resource Aggregates used in the Experiment. In the example experiment used in this page, the ProtoGENI sliver was deleted as follows:

$ ./src/omni.py -a https://www.emulab.net/protogeni/xmlrpc/am deletesliver lnevers_slice
INFO:omni:Loading config file omni_config
INFO:omni:Using control framework pgeni
INFO:omni:Deleted sliver urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice on unspecified_AM_URN at https://www.emulab.net/protogeni/xmlrpc/am
INFO:omni: ------------------------------------------------------------
INFO:omni: Completed deletesliver:

  Options as run:
		aggregate: https://www.emulab.net/protogeni/xmlrpc/am
		configfile: omni_config
		framework: pgeni
		native: True

  Args: deletesliver lnevers_slice

  Result Summary: Deleted sliver urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice on unspecified_AM_URN at https://www.emulab.net/protogeni/xmlrpc/am 
INFO:omni: ============================================================

Also the Planetlab sliver was deleted as follows:

$ ./src/omni.py -a http://www.planet-lab.org:12346 deletesliver lnevers_slice
INFO:omni:Loading config file omni_config
INFO:omni:Using control framework pgeni
INFO:omni:Deleted sliver urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice on unspecified_AM_URN at https://www.planet-lab.org:12346
INFO:omni: ------------------------------------------------------------
INFO:omni: Completed deletesliver:

  Options as run:
		aggregate: https://www.planet-lab.org:12346
		configfile: omni_config
		framework: pgeni
		native: True

  Args: deletesliver lnevers_slice

  Result Summary: Deleted sliver urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice on unspecified_AM_URN at https://www.planet-lab.org:12346 
INFO:omni: ============================================================

List your Slices

You are responsible for remembering your slices, and what resources you have.

If, as here, you use Protogeni as your Clearinghouse, you can use an Omni command to listmyslices. Then for each, you can use listresources to see what you have reserved at various aggregates.

For example:

$ ./src/omni.py listmyslices lnevers
INFO:omni:Loading config file omni_config
INFO:omni:Using control framework pgeni
INFO:omni:User 'lnevers' has slices: 
	urn:publicid:IDN+pgeni.gpolab.bbn.com+slice+lnevers_slice
INFO:omni: ------------------------------------------------------------
INFO:omni: Completed listmyslices:

  Options as run:
		configfile: omni_config
		framework: pgeni
		native: True

  Args: listmyslices lnevers

  Result Summary: Found 1 slices for user 'lnevers'.
 
INFO:omni: ============================================================

Then, to see what resources you have in this slice at Planetlab:

$ ./src/omni.py -f pgeni -a http://www.planet-lab.org:12346 -t Protogeni 2 listresources lnevers_slice
INFO:omni:Loading config file omni_config
INFO:omni:Using control framework pgeni
INFO:omni:Gathering resources reserved for slice lnevers_slice..
INFO:omni:Listed resources on 1 out of 1 possible aggregates.
INFO:omni:<?xml version="1.0" ?>
INFO:omni:<!-- Resources for:
	Slice: lnevers_slice
	at AM:
	URN: unspecified_AM_URN
	URL: http://www.planet-lab.org:12346
 -->
INFO:omni:<rspec expires="2011-06-16T16:31:00Z" generated="2011-06-16T15:31:00Z" type="manifest" xmlns="http://www.protogeni.net/resources/rspec/2" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.protogeni.net/resources/rspec/2 http://www.protogeni.net/resources/rspec/2/manifest.xsd"/>
INFO:omni: ------------------------------------------------------------
INFO:omni: Completed listresources:

  Options as run:
		aggregate: http://www.planet-lab.org:12346
		configfile: omni_config
		framework: pgeni
		native: True
		rspectype: ('Protogeni', '2')

  Args: listresources lnevers_slice

  Result Summary: Retrieved resources for slice lnevers_slice from 1 aggregates.
Wrote rspecs from 1 aggregates. 
INFO:omni: ============================================================

The results above show that the returned RSpec contains no nodes - as expected, since we had already deleted our sliver there.

Happy Experimenting!


Email us with any questions and feedback on this page!

Attachments (1)

Download all attachments as: .zip