25.06.2015 Views

Administering Platform LSF - SAS

Administering Platform LSF - SAS

Administering Platform LSF - SAS

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Configuring Job Control Actions<br />

Example<br />

The following defines a night queue that will kill jobs if the run window closes.<br />

Begin Queue<br />

NAME<br />

= night<br />

RUN_WINDOW = 20:00-08:00<br />

TERMINATE_WHEN = WINDOW<br />

JOB_CONTROLS = TERMINATE[ kill -KILL $LSB_JOBPIDS;<br />

echo "job $LSB_JOBID killed by queue run window" |<br />

mail $USER ]<br />

End Queue<br />

LSB_SIGSTOP parameter (lsf.conf)<br />

Use LSB_SIGSTOP to configure the SIGSTOP signal sent by the default<br />

SUSPEND action.<br />

If LSB_SIGSTOP is set to anything other than SIGSTOP, the SIGTSTP signal that<br />

is normally sent by the SUSPEND action is not sent. For example, if<br />

LSB_SIGSTOP=SIGKILL, the three default signals sent by the TERMINATE<br />

action (SIGINT, SIGTERM, and SIGKILL) are sent 10 seconds apart.<br />

See the <strong>Platform</strong> <strong>LSF</strong> Reference for information about the lsf.conf file.<br />

Avoiding signal and action deadlock<br />

Do not configure a job control to contain the signal or command that is the<br />

same as the action associated with that job control. This will cause a deadlock<br />

between the signal and the action.<br />

For example, the bkill command uses the TERMINATE action, so a deadlock<br />

results when the TERMINATE action itself contains the bkill command.<br />

Any of the following job control specifications will cause a deadlock:<br />

◆ JOB_CONTROLS=TERMINATE[bkill]<br />

◆ JOB_CONTROLS=TERMINATE[brequeue]<br />

◆ JOB_CONTROLS=RESUME[bresume]<br />

◆ JOB_CONTROLS=SUSPEND[bstop]<br />

394<br />

<strong>Administering</strong> <strong>Platform</strong> <strong>LSF</strong>

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!