Job spooling directory (JOB_SPOOL_DIR)

The JOB_SPOOL_DIR in lsb.params sets the job spooling directory. If defined, JOB_SPOOL_DIR should be:

  • A shared directory accessible from the master host and the submission host.

  • A valid path up to a maximum length up to 4094 characters on UNIX and Linux or up to 255 characters for Windows.

  • Readable and writable by the job submission user.

Except for bsub -is and bsub -Zs, if JOB_SPOOL_DIR is not accessible or does not exist, output is spooled to the default job output directory .lsbatch.

For bsub -is and bsub -Zs, JOB_SPOOL_DIR must be readable and writable by the job submission user. If the specified directory is not accessible or does not exist, bsub -is and bsub -Zs cannot write to the default directory and the job will fail.

JOB_SPOOL_DIR specified:
  • The job input file for bsub -is is spooled to JOB_SPOOL_DIR/lsf_indir. If the lsf_indir directory does not exist, LSF creates it before spooling the file. LSF removes the spooled file when the job completes.

  • The job command file for bsub -Zs is spooled to JOB_SPOOL_DIR/lsf_cmddir. If the lsf_cmddir directory does not exist, LSF creates it before spooling the file. LSF removes the spooled file when the job completes.

JOB_SPOOL_DIR not specified:
  • The job input file for bsub -is is spooled to LSB_SHAREDIR/cluster_name/lsf_indir. If the lsf_indir directory does not exist, LSF creates it before spooling the file. LSF removes the spooled file when the job completes.

  • The job command file for bsub -Zs is spooled to LSB_SHAREDIR/cluster_name/lsf_cmddir. If the lsf_cmddir directory does not exist, LSF creates it before spooling the file. LSF removes the spooled file when the job completes.

If you want to use job file spooling without specifying JOB_SPOOL_DIR, the LSB_SHAREDIR/cluster_name directory must be readable and writable by all the job submission users. If your site does not permit this, you must manually create lsf_indir and lsf_cmddir directories under LSB_SHAREDIR/cluster_name that are readable and writable by all job submission users.