<!--
  User's Guide  Chapter
  $Header$

  <chapter>
    <title>Title of the chapter</title>
    <filename>Filename of the chapter</filename>
    <shortname>Shortname for the chapter</shortname>
    <stylesheet>stylesheet filename (optional)</stylesheet>
    <scripts>script filename (optional)</scripts>
    <contents>
      <section>
        <title>Heading of the section</title>
        <tag>Tag used to reference (optional)</tag>
        <updated>Date last updated</updated>
        <contents>
          Contents of the section.
          May include either HTML within paragraphs ("p")
          or more section's
        </contents>
      </section>
    </contents>
  </chapter>

-->

<chapter>
  <title>DSMT User's Guide</title>
  <filename>DSMTGuide.php</filename>
  <stylesheet>docs.css</stylesheet>
  <shortname>DSMTGuide</shortname>
  <contents>
    <section>
      <title>Overview</title>
      <tag>overview</tag>
      <contents>
        Access to the Distributed Service Management Toolkit (DSMT) is provided
        by the <i>dsmtc</i> command line interface.  In order to create a managed
        slice, your application must be packaged as an RPM
      </contents>
    </section>
    <section>
      <title>Quick Start</title>
      <tag>quickstart</tag>
      <contents>
        <p>To create a managed slice from scratch:</p>
        <pre>$ dsmtc create --slice <i>slicename</i></pre>
        <p>To start managing an existing slice:</p>
        <pre>$ dsmtc manage --slice <i>slicename</i></pre>
        <p>To set a node (distribution) plan for a slice</p>
        <pre>$ dsmtc setplan --slice <i>slicename</i> --plan <i>planname [key=value]*</i></pre>
        <p>To set an agent (management) plan for a slice</p>
        <pre>$ dsmt setagent --slice <i>slicename</i> --agent <i>agentname [key=value]*</i></pre>
      </contents>
    </section>
    <section>
      <title>Authentication</title>
      <tag>authentication</tag>
      <contents>
        <p>PlanetLab uses two methods of authentication:
        </p>
        <ul>
          <li>Password authentication - for operations on the PlanetLab Central database</li>
          <li>SSH authentication - for logging into a slice</li>
        </ul>
        <p>
          The toolkit uses your PlanetLab account Id (email address) to authenticate
          with PLC, whilst authentication with the management service utilizes your
          ssh key.
        </p>
      </contents>
    </section>
    <section>
      <title>Slice Creation</title>
      <tag>slicecreation</tag>
      <contents>
        Slice creation can only be performed by users with the PlanetLab role of 'pi' or
        'admin'.  The toolkit provides support for creation of managed or un-managed slices.
        <section>
          <title>Managed Slice Creation</title>
          <tag>managedslicecreation</tag>
          <contents>
            <p>The dsmtc create command will perform all necessary steps to create
               a create a slice with PlanetLab and establish management on that slice.</p>
            <pre>$ dsmtc create --slice <i>slicename</i> \
            [ --agent <i>agentname [key=value]*</i> ] \
            [ --plan <i>planname [key=value]*</i> ] \
            [ --user user.name@some.domain ] \
            [ --node planetlab.node.name ] </pre>
          </contents>
        </section>
        <section>
          <title>Unmanaged Slice Creation</title>
          <tag>unmanagedslicecreation</tag>
          <contents>
            <p>First create the node with PlanetLab central</p>
            <pre>$ dsmtc plc create --slice idsl_test1</pre>
            <p>Then add any users (including yourself)</p>
            <pre>$ dsmtc plc addusers --user paul.brett@intel.com --slice idsl_test1</pre>
            <p>Now add the nodes you wish to use</p>
            <pre>$ dsmtc plc addnodes --node planetlab1.nbgisp.com --node planetlab3.nbgisp.com --slice idsl_test1</pre>
            <p>Set the instantiation method</p>
            <pre>$ dsmtc plc setInstantiationMethod --method plc --slice idsl_test1</pre>
            <p>And finally start the slice</p>
            <pre>$ dsmtc plc start --slice idsl_test1</pre>
          </contents>
        </section>
      </contents>
    </section>
    <section>
      <title>Package Management</title>
      <tag>packagemanagement</tag>
      <contents>
        <p>Package management is currently in development.  Currently developers
           must login to alpha and upload rpms into the correct yum repository.
           In the near future, a 'depot' interface will be provided with the
           following commands:
        </p>
        <p>To copy a file from your desktop to the depot:</p>
        <pre>$ dsmtc depot put <i>filename</i></pre>
        <p>To copy a file from the depot to your desktop:</p>
        <pre>$ dsmtc depot get <i>filename</i></pre>
        <p>To list the files in the depot:</p>
        <pre>$ dsmtc depot ls</pre>
        <p>To remove a file from the depot:</p>
        <pre>$ dsmtc depot rm <i>filename</i></pre>
        <p>To create any required indexes on the directory (e.g. run yum-arch):</p>
        <pre>$ dsmtc depot index</pre>
      </contents>
    </section>
    <section>
      <title>Node Management</title>
      <tag>nodemanagement</tag>
      <contents>
        <p>Node assignment for managed slices can either be performed manually by the user
           or by using a deploymment plan.
        </p>
        <section>
          <title>Manual deployment</title>
          <tag>manualdeployment</tag>
          <contents>
            <p>When no deployment plan has been specified with the <i>--plan</i> option,
               the management service will maintain your application on all nodes currently
               assigned to the slice.  This list of nodes can be maintained by using the 
               PlanetLab web interface or the <i>dsmtc plc</i> sub-commands:
            </p>
            <p>To list the currently assigned nodes:</p>
            <pre>$ dsmtc plc listnodes --slice idsl_jpet1
planetlab2.pop-mg.rnp.br
planetlab1.pop-ce.rnp.br
planetlab2.pop-rj.rnp.br
planetlab2.pop-rs.rnp.br</pre>
            <p>To add nodes</p>
            <pre>$ dsmtc plc addnodes --node planetlab1.nbgisp.com --node planetlab3.nbgisp.com</pre>
            <p>To delete nodes</p>
            <pre>$ dsmtc plc delnodes --node planetlab1.pop-ce.rnp.br --node planetlab2.pop-rj.rnp.br</pre>
          </contents>
        </section>
        <section>
          <title>Built-in Deployment plans</title>
          <tag>builtindeploymentplans</tag>
          <contents>
            <p>Deployment plans provide a managed set of nodes upon which to install
               your application.  In general, deployment plans attempt to find sets of 
               nodes which match your requirements whilst minimizing the number of 
               changes to the node set during the evaluation of each step of the plan.
            </p>
            <p>You can query for a list of deployment plans for your slice using:</p>
            <pre>$ dsmtc plan ls
# name                        attributes
all_nodes
failed                        penalty=86400 running=14400 request=900 install=14400
geographical_filter   maxlat=90.0 minlat=-90.0 parent= maxlng=180.0 minlng=-180.0
hostname_filter       parent= prefix= suffix=
intersection                  right= left=
limit                         parent= count=0
manual
minus                         right= left=
n_per_site                    parent= count=0
no_nodes
plc
sword                         refresh=0 query=
union                         right= left= </pre>
            <p>A detailed description for each deployment plan, including the nodeset to 
               which it would currently evaluate is available utilizing the <i>get</i>
               command, e.g.
            </p>
            <pre>$ dsmtc plan get --plan all_nodes</pre>
            <p>New plans can be established based on existing plans using the <i>set</i>
               command.</p>
            <pre>$ dsmtc plan set --plan newplan --base existingplan key1=value1 key2=value2 ...</pre>
            <p>Unused user defined plans can be removed from a slice using the <i>rm</i> command.</p>
            <pre>$ dsmtc plan rm --plan oldplan</pre>
            <section>
              <title>All Nodes</title>
              <tag>all_nodes</tag>
              <contents>
                <p>The all nodes deployment plan provides a set of all the live nodes in
                   the PlanetLab database (i.e. all nodes listed in sites.xml</p>
                <pre>$ dsmtc plan get --plan all_nodes
# name                        attributes  description
all_nodes                              All bootable nodes according to the PLC database
# nodelist
[planet1.cs.ucsb.edu, planet1.scs.cs.nyu.edu, planet2.scs.cs.nyu.edu, planetlab-1.stanford
.edu, ricepl-1.cs.rice.edu, planet1.cc.gt.atl.ga.us, planetlab1.arizona-gigapop.net, plane
tlab2.arizona-gigapop.net, pl1.cs.utk.edu, pl2.cs.utk.edu, planetlab1.diku.dk, ... ] </pre>
              </contents>
            </section>
            <section>
              <title>Failed Nodes</title>
              <tag>failed</tag>
              <contents>
                <p>The failed nodes deployment plan provides a set of nodes upon which
                   the installation of this slice has been recently attempted, but has
                   failed.  This plan is usually combined with the 'minus' plan to
                   remove failed nodes from a compond deployment plan.
                </p>
                <pre>$ dsmtc plan get --plan failed
# name                        attributes  description
failed                        penalty=86400 running=14400 request=900 install=14400  Set
of nodes which have failed to install
# nodelist
[planetlab3.nbgisp.com, planet2.ottawa.canet4.nodes.planet-lab.org, planetlab8.nbgisp.com,
planetlab7.nbgisp.com, planetlab2.nbgisp.com, mycroft.nbgisp.com] </pre>
               <p>The failed nodes deployment plan can be tuned in order to establish the
                  timeouts required for each of the states.  All timeout parameters are
                  specified in seconds.
               </p>
               <p>
                 <ul>
                   <li><b>request</b></li> timeout is the period of time between the node
                       being selected into the deployment set, and the node being assigned
                       by PLC
                   <li><b>install</b></li> timeout is the period between the sliver being
                       requested with PLC, and the sliver completing installation
                   <li><b>running</b></li> timeout is the period between successive heartbeats
                       being recieved by the container manager
                   <li><b>penalty</b></li> is the period of time this node will remain in
                       the failed node set
                 </ul>
               </p>
               <p>Example:</p>
               <pre>$ dsmtc plan set --plan good_nodes --base minus left=all_nodes right=failed
$ dsmtc plan set --plan 10_good_nodes --base limit count=10 parent=good_nodes
$ dsmtc plan get --plan 10_good_nodes
# name                        attributes  description
10_good_nodes                 parent=good_nodes count=10  At most 'count' nodes
# nodelist
[planet1.cs.ucsb.edu, planet1.scs.cs.nyu.edu, planet2.scs.cs.nyu.edu, planetlab-1.stanford
.edu, ricepl-1.cs.rice.edu, planet1.cc.gt.atl.ga.us, planetlab1.arizona-gigapop.net, plane
tlab2.arizona-gigapop.net, pl1.cs.utk.edu, pl2.cs.utk.edu] </pre>
              </contents>
            </section>
            <section>
              <title>Geographical filtering of nodes</title>
              <tag>geographical_filter</tag>
              <contents>
                  <p>The geographical filtered nodes plan allows nodes to be filtered based on
                     site latitude/longitude from the PlanetLab database.  Sites in the database
                     without valid lat/long data will be ommitted.
                </p>
                <pre>$ dsmtc plan get --plan geographical_filter
# name                        attributes  description
geographical_filter   maxlat=90.0 minlat=-90.0 parent= maxlng=180.0 minlng=-180.0
All nodes within the bounding box set with min/max lat/lng
# nodelist
[] </pre>
                <p>Examples:</p>
                <pre>$ dsmtc plan set --base geographical_filter --plan north_american_nodes \
                 minlat=0 maxlat=90 minlng=-150 maxlng=-55 parent=all_nodes
$ dsmtc plan set --base geographical_filter --plan european_nodes \
                 minlat=40 maxlat=90 minlng=-10 maxlng=60 parent=all_nodes
$ dsmtc plan set --base geographical_filter --plan south_american_nodes \
                 minlat=-90 maxlat=0 minlng=-90 maxlng=-30 parent=all_nodes
$ dsmtc plan set --base geographical_filter --plan australian_nodes \
                 minlat=-90 maxlat=0 minlng=105 maxlng=160 parent=all_nodes </pre>
              </contents>
            </section>
            <section>
              <title>Hostname filtering of nodes</title>
              <tag>hostname_filter</tag>
              <contents>
                <p>The hostname filtered plan allows filters nodes based on the prefix and/or
                    suffix of the hostname
                </p>
                <pre>$ dsmtc plan get --plan hostname_filter
# name                        attributes  description
hostname_filter       parent= prefix= suffix=  All nodes starting with 'prefix' an
d ending with 'suffix'
# nodelist
[] </pre>
                <p>Examples:</p>
                <pre>$ dsmtc plan set --plan internet2_nodes suffix=internet2.planet-lab.org \
                 --base hostname_filter parent=all_nodes
$ dsmtc plan set --plan canet4_nodes suffix=canet4.nodes.planet-lab.org \
                 --base hostname_filter parent=all_nodes </pre>
              </contents>
            </section>
            <section>
              <title>Set intersection</title>
              <tag>intersection</tag>
              <contents>
                <p>The intersection operation provides the ability to specify the overlap
                   between two different node plans.
                </p>
                <pre>$ dsmtc plan get --plan intersection
# name                        attributes  description
intersection                  right= left=  All nodes in both the 'left' and 'right' plans
# nodelist
[] </pre>
                <p>Example:</p>
                <pre>$ dsmtc plan set --plan com_nodes --base hostname_filter suffix=.com
plan set --plan european_com_nodes --base intersection left=com_nodes right=european_nodes
plan get --plan european_com_nodes
# name                        attributes  description                           
european_com_nodes            right=european_nodes left=com_nodes  All nodes in both the '
left' and 'right' plans 
# nodelist                                                                      
[pli1-br-2.hpl.hp.com, pli1-br-3.hpl.hp.com, pli1-br-1.hpl.hp.com, pli2-br-2.hpl.hp.com, p
li2-br-1.hpl.hp.com, pli1-tlnx.hpl.hp.com, planetlab1.rdfrancetelecom.com, planetlab2.rdfr
ancetelecom.com] </pre>
              </contents>
            </section>
            <section>
              <title>Limiting node set</title>
              <tag>limit</tag>
              <contents>
                <p>Providing an upper bound on the number of nodes in a set can be accomplised
                   with the limit operation.  
                </p>
                <pre>$ dsmtc plan get --plan limit
# name                        attributes  description
limit                         parent= count=0  At most 'count' nodes
# nodelist
[] </pre>
                <p>Example:</p>
                <pre>$ dsmtc plan set --plan good_nodes --base minus left=all_nodes right=failed
$ dsmtc plan set --plan 10_good_nodes --base limit count=10 parent=good_nodes
$ dsmtc plan get --plan 10_good_nodes
# name                        attributes  description
10_good_nodes                 parent=good_nodes count=10  At most 'count' nodes
# nodelist
[planet1.cs.ucsb.edu, planet1.scs.cs.nyu.edu, planet2.scs.cs.nyu.edu, planetlab-1.stanford
.edu, ricepl-1.cs.rice.edu, planet1.cc.gt.atl.ga.us, planetlab1.arizona-gigapop.net, plane
tlab2.arizona-gigapop.net, pl1.cs.utk.edu, pl2.cs.utk.edu] </pre>
                <p><b>Important</b> : Limit should almost always be used at the outermost
                   level of your node plan.  The following plan is not equivalent:
                </p>
                <pre>$ dsmtc plan set --plan 10_nodes --base limit count=10 parent=all_nodes
$ dsmtc plan set --plan good_10_nodes --base minus left=10_nodes right=failed </pre>
              </contents>
            </section>
            <section>
              <title>Manual control of nodes</title>
              <tag>manual</tag>
              <contents>
                <p>The manual control plan allows for user selection of the node set.
                </p>
                <pre>$ # name                        attributes  description
manual                        nodes=      Manual control - provide a white space separated
list of nodes
# nodelist
[] </pre>
              <p>Example:</p>
              <pre>$ dsmtc plan set --plan mynodes --base manual nodes=@nodes.txt
$ dsmtc plan get mynodes
Error: Unrecognized command line option mynodes
dsmtc paul.brett@intel.com [pi] idsl_pfb_test_1> plan get --plan mynodes
# name                        attributes  description                           
mynodes                       nodes=planetlab3.nbgisp.complanetlab1.nbgisp.com  Manual con
trol - provide a white space separated list of nodes 
# nodelist                                                                      
[planetlab3.nbgisp.com, planetlab1.nbgisp.com]</pre>
              </contents>
            </section>
            <section>
              <title>Set minus</title>
              <tag>minus</tag>
              <contents>
                <p>The minus plan allows nodes from one plan to be excluded from 
                   another plan.
                </p>
                <pre>$ dsmtc plan get --plan minus
# name                        attributes  description
minus                         right= left=  All nodes in the 'left' plan, but not in the '
right' plan
# nodelist
[] </pre>
              <p>Example:</p>
              <pre>$ dsmtc plan set --plan internet2_nodes suffix=internet2.planet-lab.org \
                 --base hostname_filter parent=all_nodes
$ dsmtc plan set --plan not_i2_nodes --base minus left=all_nodes right=internet2_nodes
$ dsmtc plan set --plan canet4_nodes suffix=canet4.nodes.planet-lab.org \
                 --base hostname_filter parent=all_nodes
$ dsmtc plan set --plan i1_nodes --base minus left=not_i2_nodes right=canet4_nodes
$ dsmtc plan get --plan i1_nodes
# name                        attributes  description                           
i1_nodes                      right=canet4_nodes left=not_i2_nodes  All nodes in the 'left
' plan, but not in the 'right' plan 
# nodelist                                                                      
[planet1.cs.ucsb.edu, planet1.scs.cs.nyu.edu, planet2.scs.cs.nyu.edu, planetlab-1.stanford
.edu, ricepl-1.cs.rice.edu, planet1.cc.gt.atl.ga.us, planetlab1.arizona-gigapop.net, ... ]</pre>
              </contents>
            </section>
            <section>
              <title>Selecting every site</title>
              <tag>n_per_site</tag>
              <contents>
                <p>A common requirement on PlanetLab is to run an experiment or service at
                   a group of sites, which requires a single instance to be assigned once 
                   per site.  This can be achieved with the n_per_site plan.
                </p>
                <pre>$ dsmtc plan get --plan n_per_site
# name                        attributes  description
n_per_site                    parent= count=0  At most 'count' nodes per site
# nodelist
[]</pre>
                <p>Example:</p>
                <pre>$ dsmtc plan set --plan i2_1_per_site --base n_per_site count=1 parent=internet2_nodes
$ dsmtc plan get --plan i2_1_per_site
# name                        attributes  description                           
i2_1_per_site                 parent=internet2_nodes count=1  At most 'count' nodes per site        
# nodelist                                                                      
[planetlab1.nycm.internet2.planet-lab.org, planetlab1.ipls.internet2.planet-lab.org, plane
tlab2.sttl.internet2.planet-lab.org, planetlab1.chin.internet2.planet-lab.org, ... ] </pre>
              </contents>
            </section>
            <section>
              <title>Empty nodeset</title>
              <tag>no_nodes</tag>
              <contents>
                <p>The empty node set provides a mechanism for a slice to be removed from
                   all nodes without deleting the slice from PlanetLab.
                </p>
                <pre>$ dsmtc plan get --plan no_nodes
# name                        attributes  description
no_nodes                                  No nodes
# nodelist
[] </pre>
              </contents>
            </section>
            <section>
              <title>PLC Controlled</title>
              <tag>plc</tag>
              <contents>
                <p>The PLC controlled site plan disables node management within DSMT. The
                   nodelist of current nodes in the slice will be downloaded from PLC, and
                   any changes made at PLC (via either the web interface, or dsmtc's plc 
                   sub-menu will be honored.
                </p>
                <pre>$ dsmtc plan get --plan plc
# name                        attributes  description
plc                                       PLC Controlled - use plc add/del nodes
# nodelist
[planetlab3.nbgisp.com, planetlab1.nbgisp.com, planet1.ottawa.canet4.nodes.planet-lab.org,
planetlab8.nbgisp.com, planetlab7.nbgisp.com, planetlab4.nbgisp.com, ... ]</pre>
              </contents>
            </section>
            <section>
              <title>Sword selected</title>
              <tag>sword</tag>
              <contents>
                <p>The Sword plan generates queries to David Oppenheimer 's Scalable 
                   Wide-Area Resource Discovery tool to perform node selection.
                </p>
                <pre>$ dsmtc plan get --plan sword
# name                        attributes  description                           
sword                         refresh=0 query=  Query using Scalable Wide-Area Resource Di
scovery (http://www.swordrd.org/ 
# nodelist                                                                      
[]</pre>
                <p>Example:</p>
                <pre>$ dsmtc plan set --plan sword_20 --base sword query=@sword.txt refresh=3600
$ dsmtc plan get --plan sword_20
# name                        attributes  description                           
sword_20                      refresh=3600 query=&lt;request&gt;
   &lt;group&gt;
      &lt;name&gt;LowLoad&lt;/name&gt;
      &lt;numhosts&gt;20&lt;/numhosts&gt;
      &lt;num_machines&gt;all&lt;/num_machines&gt;
      &lt;load_one&gt;0.0,0.0,5.0,5.0,0.0&lt;/load_one&gt;
   &lt;/group&gt;
&lt;/request&gt;  Query using Scalable Wide-Area Resource Discovery (http://www.swordrd.org/ 
# nodelist                                                                      
[planet3.pittsburgh.intel-research.net, planetlab3.xeno.cl.cam.ac.uk, ... ]</pre>
              </contents>
            </section>
            <section>
              <title>Set union</title>
              <tag>union</tag>
              <contents>
                <p>The union operation provides the ability to specify the combination 
                   of two different node plans.
                </p>
                <pre>$ plan get --plan union 
# name                        attributes  description                           
union                         right= left=  All nodes in either the 'left' or 'right' plan 
# nodelist                                                                      
[] </pre>
                <p>Example:</p>
                <pre>$ plan set --plan berkeley_edu_nodes --base hostname_filter \
         suffix=berkeley.edu
$ dsmtc plan set --plan berkeley_intel_nodes --base hostname_filter \
         suffix=berkeley.intel-research.net
$ dsmtc plan set --plan berkeley_nodes --base union left=berkeley_edu_nodes \
         right=berkeley_intel_nodes
$ dsmtc plan get --plan berkeley_nodes
# name                        attributes  description                           
berkeley_nodes                right=berkeley_intel_nodes left=berkeley_edu_nodes  All node
s in either the 'left' or 'right' plan 
# nodelist                                                                      
[planetlab4.millennium.berkeley.edu, planetlab12.millennium.berkeley.edu, planetlab5.mille
nnium.berkeley.edu, ... planet1.berkeley.intel-research.net]</pre>
              </contents>
            </section>
            <p>A deployment plan can be established on your managed slice using the
               setplan command
            </p>
            <pre>$ dsmtc setplan --plan internet2_nodes --slice idsl_jpet1</pre>
          </contents>
        </section>
       <section>
         <title>Custom deployment plans</title>
         <tag>customplans</tag>
         <contents>
           <p>The built-in deployment plans can be composed together to provide fine
              grained control over the placement of an application.  To illustrate
              plan composition, we will construct a deployment plan for a distributed
              service with the following requirements:
              <ul>
                <li>The service requires a presence in europe, north america, south america
                    and australia</li>
                <li>In each geography, four working nodes are required.  For redundancy, 
                     none of the node in a geography may be at the same site.</li>
                <li>The nodes must not be hosted by Internet2 or Canarie.</li>
                <li>If the node is down for more than one hour, it should be replaced with
                    another node.  Installation time for any node should be limited to a
                    maximum of 4 hours.</li>
              </ul>
           </p>
           <p>Create a list of nodes which meet the installation and service uptime 
              requirements.
           </p>
           <pre>$ dsmtc plan set --plan badnodes --base failed running=3600 install=14400</pre>
           <p>And exclude these nodes from the available node list</p>
           <pre>$ dsmtc plan set --plan nobadnodes --base minus left=all_nodes right=badnodes</pre>
           <p>Create a list of internet2 and canarie nodes, and exclude them from the available nodes</p>
           <pre>$ dsmtc plan set --plan internet2_nodes \
                 --base hostname_filter suffix=internet2.planet-lab.org parent=all_nodes
$ dsmtc plan set --plan canet4_nodes \
                 --base hostname_filter parent=all_nodes suffix=canet4.nodes.planet-lab.org 
$ dsmtc plan set --plan nobad_noi2_nodes --base minus left=nobadnodes right=internet2_nodes
$ dsmtc plan set --plan good_nodes --base minus left=nobad_noi2_nodes right=canet4_nodes</pre>
            <p>Create node groups for each of the geographies</p>
            <pre>$ dsmtc plan set --base geographical_filter --plan north_american_nodes \
                 minlat=0 maxlat=90 minlng=-150 maxlng=-55 parent=good_nodes
$ dsmtc plan set --base geographical_filter --plan european_nodes \
                 minlat=40 maxlat=90 minlng=-10 maxlng=60 parent=good_nodes
$ dsmts plan set --base geographical_filter --plan south_american_nodes \
                 minlat=-90 maxlat=0 minlng=-90 maxlng=-30 parent=good_nodes
$ dsmtc plan set --base geographical_filter --plan australian_nodes \
                 minlat=-90 maxlat=0 minlng=105 maxlng=160 parent=good_nodes</pre>
           <p>Limit each geography to four nodes</p>
           <pre>$ dsmtc plan set --plan north_american_four --base limit parent=north_american_nodes count=4
$ dsmtc plan set --plan european_four --base limit parent=european_nodes count=4
$ dsmtc plan set --plan south_american_four --base limit parent=south_american_nodes count=4
$ dsmtc plan set --plan australian_four --base limit parent=australian_nodes count=4</pre>
           <p>Join the regions together</p>
           <pre>$ dsmtc plan set --plan american_eight --base union left=north_american_four right=south_american_four
$ dsmtc plan set --plan nonamerican_eight --base union left=european_four right=australian_four 
$ dsmtc plan set --plan appnodes --base union left=american_eight right=nonamerican_eight</pre>
           <p>And finally, activate the plan</p>
           <pre>$dsmtc setplan --plan appnodes</pre>

         </contents>
       </section>
      </contents>
    </section>
    <section>
      <title>Files</title>
      <tag>Files</tag>
      <contents>
        <section>
          <title>.slices</title>
          <tag>slices</tag>
          <contents>
            <p>
            The $HOME/.slices file contains configuration information required to
            authenticate the the PlanetLab central API.  This configuration file
            can be shared with the plslice command (part of the pldeploy package),
            and has the following format:
            </p>
            <pre>
slice: <i>slicename</i>
account: <i>email address</i>
password: <i>plain text password</i>
server: <i>url to PLC API</i>
role: <i>PLC role name</i></pre>
            All items are optional, and can alternativly be specified on the command
            line.
          </contents>
        </section>
        <section>
          <title>ssh identity</title>
          <tag>ssh</tag>
          <contents>
            Authentication with DSMT currently uses the ssh key uploaded into
            PlanetLab.  Your key will be searched for in the following locations
            <pre>
$HOME/.ssh/id_rsa
$HOME/.ssh/id_dsa
$HOME/.ssh/identity</pre>
            The dsmtc client includes an inbuilt ssh client, and does not currently recognize
            options in the $HOME/.ssh/config file.  Proxies are also currently
            not supported.
          </contents>
        </section>
      </contents>
    </section>
  </contents>
</chapter>
<!-- vim: tabstop=2 shiftwidth=2 autoindent expandtab
-->

