Size of job email
Some batch jobs can create large amounts of output. To prevent large job output files from interfering with your mail system, you can use the LSB_MAILSIZE_LIMIT parameter in lsf.conf to limit the size of the email containing the job output information.
By default, LSB_MAILSIZE_LIMIT is not enabled: no limit is set on size of batch job output email.
If the size of the job output email exceeds LSB_MAILSIZE_LIMIT, the output is saved to a file under JOB_SPOOL_DIR, or the default job output directory if JOB_SPOOL_DIR is undefined. The email informs users where the job output is located.
If the -o or -oo option of bsub is used, the size of the job output is not checked against LSB_MAILSIZE_LIMIT.
LSB_MAILSIZE environment variable
LSF sets LSB_MAILSIZE to the approximate size in KB of the email containing job output information, allowing a custom mail program to intercept output that is larger than desired. If you use the LSB_MAILPROG parameter to specify the custom mail program that can make use of the LSB_MAILSIZE environment variable, it is not necessary to configure LSB_MAILSIZE_LIMIT.
LSB_MAILSIZE is not recognized by the LSF default mail program. To prevent large job output files from interfering with your mail system, use LSB_MAILSIZE_LIMIT to explicitly set the maximum size in KB of the email containing the job information.
LSB_MAILSIZE values
- A positive integer: if the output is being sent by email, LSB_MAILSIZE is set to the estimated mail size in KB.
- -1:if the output fails or cannot be read, LSB_MAILSIZE is set to -1, and the output is sent by email using LSB_MAILPROG if specified in lsf.conf.
- Undefined: If you use the output or error options (-o, -oo, -e, or -eo) of bsub, the output is redirected to an output file. Because the output is not sent by email in this case, LSB_MAILSIZE is not used and LSB_MAILPROG is not called.
If the -N option is used with the output or error options of bsub, LSB_MAILSIZE is not set.