welcome: please sign in

You can't save spelling words.

Clear message
location: Cluster / SGE / howto / basic_usage.html

Status of Grid Engine Resources

qstat

Show job/queue status

no arguments Show currently running/pending jobs

-f Show full listing of all queues

-j Shows detailed information on pending/running job

-U Shows current jobs by user

qhost

Show job/host status

no arguments Show a table of all execution hosts and information about their configuration

-l attr=val Show only certain hosts

-j Shows detailed information on pending/running job

-q Shows detailed information on queues at each host

Sending jobs to Grid Engine

The main submit commands are qsub, qrsh and qtcsh.

See the man pages for submit(1) and qtcsh(1) for more details.

qsub

Submit scripts

Started with no arguments it accepts input from STDIN (^D to send submit input)

-cwd Run the job from the current working directory (Default: Home directory)

-v Pass the variable VAR (-V passes all variables)

-o Redirect standard output (Default: Home directory)

-e Redirect standard error (Default: Home directory)

Example:

qsub -cwd -v SOME_VAR -o /dev/null -e /dev/null myjob.sh

In general, qsub is used for traditional batch submit, that is where I/O is directed to a file. Note that qsub only accepts shell scripts, not executable files.

See the qsub(1) man page for more details.

qrsh

Qrsh acts similar to the rsh command, except that a host name is not given. Instead, a shell script or an executable file is run, potentially on any node in the cluster. I/O is directed back to the submitter's terminal window. By default, if the job cannot be run immediately, qrsh will not queue the job. Using the '-now no' flag to qrsh will allow jobs to queue. Note that I/O can be redirected with the shell redirect operators. For example, to run the uname -a command:

qrsh uname -a

The uname of some machine the scheduler selects in the cluster will then be displayed on the submitting terminal. To redirect the output,

qrsh uname -a > /tmp/myfile

The output from uname will be written to /tmp/myfile on the submitting host. To allow the command to queue:

qrsh -now no uname -a

If a suitable host is not immediately available the command will block until a suitable host is available. At that time, the command output will be displayed on the submitting terminal.

See the qrsh(1) man page for more details.

qtcsh

Grid Engine contains a modified tcsh, qtcsh which will automatically submit jobs listed in a task file to the cluster.

See the qtcsh(1) and qtask(5) man pages for more details.

eciencia: Cluster/SGE/howto/basic_usage.html (last edited 2012-02-20 16:03:34 by marco)