For Application Users

From PRAGMAgridWIKI

Jump to: navigation, search

This page is a guide for MPICH-GX application users. At the front node, pluto, of testbed, you could submit a job to the resources. We provide two kinds of CLI(command line interface) tools: grasprun and gxrun.

1. grasprun
the client tool for job submission, monitoring and control via GRASP. GRASP is service packages for job submission, meta scheduling, and resource allocation. Currently, GRASP is implemented in Globus Toolkit 3.x.

2. gxrun
the simple client tool for job submission of the MPICH-GX applications.

Here we provide three kinds of scenarios using above two tools. First one is the job submission to the manually selected resources via grasprun. Second one is the job submission to the automatically selected resources by a meta-scheduler via grasprun. Last one is the job submission to the manually selected resources via gxrun.

1st scenario via grasprun

1. Proxy creation
After logged in the pluto, you have to create a user proxy.

$ grid-proxy-init

2. Compile a program

$ cd /home/cicese/gx-test
$ mpicc -o cpi cpi.c

3. Create a JRDL file
A job should be decribed to the JRDL file. The JRDL is the extension of RSL, the language of Globus Toolkit 3.x.

$ vi cpi.xml
 <?xml version="1.0" encoding="UTF-8"?>
 <jrdl xmlns="http://www.moredream.org/namespaces/2003/09/jrdl">
   <job>
      <!-- executable attribute -->
      <executable>
         <path>
            <!-- for the automatically staging to the compute resources -->
            <substitutionRef name="GLOBUSRUN_GASS_URL"/>
            <!-- local full path of executable -->
            <stringElement value="/home/cicese/gx-test/cpi"/>
         </path>
      </executable>

      <!-- environment attribute -->
      <environment>
         <hashtable>
            <entry name="LD_LIBRARY_PATH">
               <substitutionRef name="GLOBUS_LOCATION"/>
               <stringElement value="/lib"/>
            </entry>
         </hashtable>
      </environment>

      <!-- job type attribute -->
      <jobType>
         <enumeration>
            <enumerationValue>
               <xmpi/>
            </enumerationValue>
         </enumeration>
      </jobType>

      <!-- attributes regarding resources -->
      <subjob>
         <resourceManagerContact>
            <string>
               <stringElement value="http://vega01.gridcenter.or.kr:8080"/>
            </string>
         </resourceManagerContact>
         <jobManagerType>
            <enumeration>
               <enumerationValue><pbs/></enumerationValue>
            </enumeration>
         </jobManagerType>
         <count>
            <integer value="2"/>
         </count>
      </subjob>
      <subjob>
         <resourceManagerContact>
            <string>
               <stringElement value="http://eros01.gridcenter.or.kr:8080"/>
            </string>
         </resourceManagerContact>
         <jobManagerType>
            <enumeration>
               <enumerationValue><pbs/></enumerationValue>
            </enumeration>
         </jobManagerType>
         <count>
            <integer value="2"/>
         </count>
      </subjob>
   </job>
  </jrdl>

4. Submitting the job

$ grasprun -file ./cpi.xml

2nd scenario via grasprun

Submitting the job into the resources selected by meta-scheduler.

1. Proxy creation
After logged in the pluto, you have to create a user proxy.

$ grid-proxy-init

2. Compile a program

$ cd /home/cicese/gx-test
$ mpicc -o cpi cpi.c

3. Create a JRDL file
A job should be decribed to the JRDL file. The JRDL is the extension of RSL, the language of Globus Toolkit 3.x.

$ vi cpi.xml
 <?xml version="1.0" encoding="UTF-8"?>
 <jrdl xmlns="http://www.moredream.org/namespaces/2003/09/jrdl">
   <job>
      <!-- executable attribute -->
      <executable>
         <path>
            <!-- for the automatically staging to the compute resources -->
            <substitutionRef name="GLOBUSRUN_GASS_URL"/>
            <!-- local full path of executable -->
            <stringElement value="/home/cicese/gx-test/cpi"/>
         </path>
      </executable>

      <!-- environment attribute -->
      <environment>
         <hashtable>
            <entry name="LD_LIBRARY_PATH">
               <substitutionRef name="GLOBUS_LOCATION"/>
               <stringElement value="/lib"/>
            </entry>
         </hashtable>
      </environment>

      <!-- job type attribute -->
      <jobType>
         <enumeration>
            <enumerationValue>
               <xmpi/>
            </enumerationValue>
         </enumeration>
      </jobType>

      <!-- requirements attributes for selecting resources -->
      <resource>
        <count>
          <integer value="4"/>
        </count>
        <operatingSystem>
           <name>
              <string>
                 <stringElement value="Linux"/>
              </string>
           </name>
        </operatingSystem>
        <schedulingPlugin>
           <string>
              <stringElement value="MPIPlugin"/>
           </string>
        </schedulingPlugin>
      </resource>
   </job>
  </jrdl>

4. Querying the job (Optional)
This step is a test procedure. Before submitting the actual resources, using resource requirements in JRDL, it finds proper resources to query to the meta-scheduler.

$ grasprun -file ./cpi.xml -test

5. Submitting the job

$ grasprun -file ./cpi.xml
Personal tools