W2H: How to activate the Batch-Queue-Feature in W2H
document, describing the now deprecated configuration until W2H 3.1
Peter Ernst
and Martin Senger
This page describes, what you have to do, if you want to activate the
Batch-Queue-Feature. This feature is deactivated by default.
What does Batch-Queue-Feature mean?
Until now, whenever you press the Run-Button in the
Application-Window
, the job was started
immediately. Now you have the possibility to put this job into a
batch queue.
After activating the Batch-Queue-Feature, you'll have a further
selection of batch queues in the top row of the Application-Window,
where the experienced users may select the appropriate queue. For the
unexperienced users, you gave a default choice, which will be used,
when the user doesn't modify the selection. You also have the
possibility to force users to use a specific batch queue.
This Batch-Queue-Feature has to be activated for each application for
which you want to use it.
But using this is only possible, if your system
offers a queueing-system. Therefore this feature is partly system dependent
and needs you to program two small scripts (must be located in the
same directroy as w2h.com):
- w2h.batch.add: This program puts the jobs into the queue.
- w2h.batch.rm: This program removes a job out of a queue.
How to do those programs will be described later; within this package
there are also 3 examples for the queueing programs qsub,
batch and at. Select one which is appropriate to your
queueing system, rename it to w2h.batch.add
(and a corresponding one to w2h.batch.rm),
put them into the same directory as w2h.com, and change their access
rights to make them executables.
However, batch queues will only be used for those applications, for
which you have modified the according .config-file.
There you have to specify at least a QUEUEDEFAULT.
But let's give you a step-by-step description:
- If you have a queueing system like 'qsub', you can offer your
users quite a list of queues. You can specify a default list of
queues for all applications, though it must be activated for each
individual application. Or you can specify an individual list of
queues for the individual applications. A special is the keyword
none: This means the application is not started in a
batch-queue. You can use it as a QUEUEDEFAULT, too. So
you have two possibilities:
- add a line with the names of the queues you want to offer
for a application into its .config, e.g:
QUEUES = long, verylong
Repeat this for every application for which you want to use batch
queues.
- or simply add a list of queues into Cfg.pl,
e.g.:
$QUEUES = ("veryshort", "short", "long" verylong", "FastA");
This list will be used, whenever there is no QUEUES in
the .config.
The name of the queue will be passed to you by W2H in the
w2h.batch.add-program.
- If you don't already have the QUEUES entry in the
.config-file, of the application, in which you want to use
batch queues, you have to specify at least a QUEUEDEFAULT into that
applications .config, e.g:
QUEUEDEFAULT short
If you already have the QUEUES entry, the first item will be
used as default queue.
- The w2h.batch.add-program has to do the following
things:
- Getting the desired batch queue from the command line
- Putting a call to w2h.com.queue into the batch queue
The arguments to this call are on the command-line, too.
- Write an identifier for this job on STDOUT. Your
w2h.bath.rm program will get this identifier. If there was an
error, write a message to STDOUT.
Please look into the provided examples for details:
- w2h.batch.add.qsub
- w2h.batch.add.batch
- w2h.batch.add.at
- The w2h.batch.rm program is more simple. It gets the
batch-job-ID from the w2h.batch.add program on its
command-line, and it just has to remove this job from the queue
There are examples, too, for this file:
- w2h.batch.rm.qsub
- w2h.batch.rm.batch
- w2h.batch.rm.at
- Finally, you have to activate QUEUES_ENABLED in
Cfg.pl.