2. Submitting Jobs to the Queues

NQS are submitted using the qsub command:

    qsub [ -q queue-name ] [ flags ] [ script-file ]
If no script-file is specified, then the set of commands to be executed as a batch request is taken directly from the standard input (stdin). In all cases however, the script file is spooled, so that later changes to the file do not affect previously queued batch requests. The choice of queue can affect how soon the job will be run and the maximum CPU-time which can be used --- see the configuration section for details of available queues.

Example scripts for use with Gaussian and Matlab are included below; instructions for use of the NQS with Abaqus are also given.

2.1. Script File Template

The following can be used as a template for NQS submission scripts:

    #!/usr/local/bin/bash

    #QSUB   -r myprog
    #QSUB   -o myoutput.log
    #QSUB   -eo -nr -x

    # Program to run:
    testprog

Qsub Flags

-r assign stated request name to the request;
-o direct the standard output (stdout) to the stated destination;
-eo direct the standard error output (stderr) to the stdout destination;
-nr declare that batch request can not be restartable;
-x export all environment variables with request.

Commonly used qsub flags

In addition to the above flags (switches), NQS provides many flags to qsub command. For more detailed information on the qsub flags, please refer to the qsub man page.

2.2. Simple Examples

Here is a trivial example which is quick to run:

    #!/usr/local/bin/bash

    #QSUB -r quicktest -eo -ke -ko -nr -x -o zaiem.logfile
 
    # Commands to run :
    cd /home/mpciizb/dir-nqs
    banner 'This is a Batch NQS Job'

You might run a programme you have written and compiled like this:

    #!/usr/local/bin/bash

    cd /home/mpciish2/src/lyap_F95
    ./src/a.out 

2.3. Using Matlab with the NQS

Matlab jobs can be run in this manner provided they don't produce any graphical output.

Example 1: Simple Matlab Computations

Create a Matlab batch file, e.g. matlab_example, as follows

    #!/usr/local/bin/bash

    matlab12 -nodisplay -nojvm -nosplash 1> matlab.out1 2>&1 <<EOF

    5+12

    EOF
Then, create an NQS script file that runs the Matlab batch file, e.g. myjob.nqs

    #!/usr/local/bin/bash

    #QSUB -r myprog
    #QSUB -o myoutput.logfile
    #QSUB -eo -nr -x

    # Program to run

    matlab_example
and submit it to one of the NQS queues, e.g.
    qsub -q one_day myjob.nqs

Example 2: running a Matlab script file, <scriptname>.m

Suppose our Matlab script file is called user.m, then a suitable NQS submission script is:

    #!/usr/local/bin/bash

    matlab12 -nodisplay -nojvm -nosplash 1> matlab.out1 2>&1 < user.m
This script file may then be submitted in a similar manner to the previous example. N.B. The Matlab quit command must be put at the end of the script file, in this case, user.m.

2.4. Using Abaqus with the NQS

1. Submitting abaqus jobs to NQS from the command line

To submit an Abaqus job from the command line use the queue= parameter and specify the queue you wish to submit the job to, for example, for Abaqus Version 6.2

     abaqus62 job=<my_input_file>.inp queue=one_day
and for Abaqus 6.3
    abaqus63 job=<my_input_file>.inp queue=one_day
where <my_input_file>.inp is the name of the abaqus input file you wish to run.

2. Submitting abaqus jobs to NQS from within Abaqus CAE, Versions 6.2 and 6.3

You can specify the NQS queue to send the job in Job Manager. Open the Job Module within Abaqus CAE (Module->Job). Choose Job -> Manager, then either Create, to create a new job, or Edit to modify an existing job. Choose the Submission tab and check Queue: under Run Mode. Select the desired queue from the pull-down menu at the side of Queue:. Choose OK when happy with this selection. You may then Submit and Monitor the job, using the Submit and Monitor buttons.

2.5. Using Gaussian with the NQS

...coming...

...previousup (conts)next...



About this document:

Produced from the SGML: /home/isd/public_html/_cosmeric/_nqs_user/_reml_grp/index.reml
On: 17/7/2003 at 18:7:12
Options: reml2 -i noindex -l long -o html -p multiple