Project

General

Profile

Introduction to Moab for users » History » Version 3

Miguel Dias Costa, 29/02/2012 15:49

1 1 Miguel Dias Costa
h1. Introduction to Moab for users
2 1 Miguel Dias Costa
3 2 Miguel Dias Costa
Moab is the workload management system that is used in FEUP's high performance computing clusters.
4 2 Miguel Dias Costa
5 2 Miguel Dias Costa
h2. Getting started
6 2 Miguel Dias Costa
7 2 Miguel Dias Costa
After gaining ssh accesh to a moab frontend, a user can see what resources are available and check the status of the queue by running
8 2 Miguel Dias Costa
9 2 Miguel Dias Costa
<pre>
10 2 Miguel Dias Costa
mshow
11 2 Miguel Dias Costa
</pre>
12 2 Miguel Dias Costa
13 2 Miguel Dias Costa
In order to submit jobs, one needs to create a submit script that defines the requirements and the command to be executed. A simple example to get started would be
14 2 Miguel Dias Costa
15 2 Miguel Dias Costa
h3. Example serial job submission script helloworld.submit
16 2 Miguel Dias Costa
17 2 Miguel Dias Costa
<pre>
18 2 Miguel Dias Costa
#!/bin/bash                                                
19 2 Miguel Dias Costa
#MOAB -l nodes=1:ppn=1                                    
20 2 Miguel Dias Costa
#MOAB -l partition=torque1                                 
21 2 Miguel Dias Costa
#MOAB -j oe                                          
22 2 Miguel Dias Costa
cd $PBS_O_WORKDIR                                    
23 2 Miguel Dias Costa
#!/bin/bash
24 2 Miguel Dias Costa
echo "----------------------"
25 2 Miguel Dias Costa
hostname
26 2 Miguel Dias Costa
echo "----------------------"
27 2 Miguel Dias Costa
date
28 2 Miguel Dias Costa
echo "----------------------"
29 2 Miguel Dias Costa
echo "Sleeping 20s"
30 2 Miguel Dias Costa
sleep 20
31 2 Miguel Dias Costa
echo "----------------------"
32 2 Miguel Dias Costa
echo "Hello World!"
33 2 Miguel Dias Costa
</pre>
34 2 Miguel Dias Costa
35 3 Miguel Dias Costa
h3. Example parallel job submission script helloworld.submit
36 3 Miguel Dias Costa
37 3 Miguel Dias Costa
<pre>
38 3 Miguel Dias Costa
#!/bin/bash                                                
39 3 Miguel Dias Costa
#MOAB -l nodes=2:ppn=2
40 3 Miguel Dias Costa
#MOAB -l partition=torque1                                 
41 3 Miguel Dias Costa
#MOAB -j oe                                          
42 3 Miguel Dias Costa
cd $PBS_O_WORKDIR                                    
43 3 Miguel Dias Costa
mpirun -np 4 -machinefile $PBS_NODEFILE ./command | tee $PBS_JOBID.output
44 3 Miguel Dias Costa
</pre>
45 3 Miguel Dias Costa
46 2 Miguel Dias Costa
After creating this file, the job would be submitted by running
47 2 Miguel Dias Costa
48 2 Miguel Dias Costa
<pre>
49 2 Miguel Dias Costa
msub helloworld.submit
50 2 Miguel Dias Costa
</pre>
51 2 Miguel Dias Costa
52 2 Miguel Dias Costa
h2. Checking status
53 2 Miguel Dias Costa
54 2 Miguel Dias Costa
To see details about the status of each job in the queue, one would run
55 2 Miguel Dias Costa
56 2 Miguel Dias Costa
<pre>
57 2 Miguel Dias Costa
mshow
58 2 Miguel Dias Costa
</pre>
59 2 Miguel Dias Costa
60 2 Miguel Dias Costa
To check the status of a specific job,
61 2 Miguel Dias Costa
62 2 Miguel Dias Costa
<pre>
63 2 Miguel Dias Costa
checkjob jobid
64 2 Miguel Dias Costa
</pre>
65 2 Miguel Dias Costa
66 2 Miguel Dias Costa
To check the status of a specific node,
67 2 Miguel Dias Costa
68 2 Miguel Dias Costa
<pre>
69 2 Miguel Dias Costa
checknode nodeid
70 2 Miguel Dias Costa
</pre>
71 2 Miguel Dias Costa
72 2 Miguel Dias Costa
To cancel a job
73 2 Miguel Dias Costa
74 2 Miguel Dias Costa
<pre>
75 2 Miguel Dias Costa
canceljob jobid
76 2 Miguel Dias Costa
</pre>
77 2 Miguel Dias Costa
78 2 Miguel Dias Costa
h2. More Information
79 2 Miguel Dias Costa
80 2 Miguel Dias Costa
http://www.adaptivecomputing.com/resources/docs/