Modify pending jobs (bmod)

About this task

If your submitted jobs are pending (bjobs shows the job in PEND state), you can modify job submission parameters. You can also modify entire job arrays or individual elements of a job array.

Procedure

  • To replace the job command line, run bmod -Z "new_command".

    For example: bmod -Z "myjob file" 101.

  • To change a specific job parameter, run bmod -b.

    The specified options replace the submitted options.

    For example, to change the start time of job 101 to 2:00 AM, run bmod -b 2:00 101.

  • To reset an option to its default submitted value (undo a bmod), append the n character to the option name and do not include an option value.

    To reset the start time for job 101 back to its default value, run bmod -bn 101.

Modify the service class of a job

About this task

You can attach or detach a service class of a job after the job has been submitted.

Restriction:
You cannot:
  • Use -sla with other bmod options
  • Move job array elements from one service class to another, only entire job arrays
  • Modify the service class of jobs that are already attached to a job group

Procedure

  • Use the -sla option of bmod to modify the service class a job is attached to, or to attach a submitted job to a service class.

    For example, to attach job 2307 to the service class called Vernon, run bmod -sla Vernon 2307.

  • Use bmod -slan to detach a job from a service class.

    For example, to detach job 2307 from the service class called Vernon, run bmod -slan 2307.

Modify a job submitted to a job group

About this task

You can modify your own job groups and job groups that other users create under your job groups. The LSF administrator can modify job groups of all users.

Restriction:

The command bmod -g cannot be combined with other bmod options. It can only operate on pending jobs.

It cannot operate on running or finished jobs.

You cannot move job array elements from one job group to another, only entire job arrays. A job array can only belong to one job group at a time.

You cannot modify the job group of a job that is attached to a service class.

Procedure

To specify a job group path to move a job or a job array from one job group to another, run bmod -g.

For example, to move job 105 to the job group /risk_group/portfolio2/monthly, run bmod -g /risk_group/portfolio2/monthly 105.

Like the bsub -g command, if the job group does not exist, LSF creates it.

Modify the swap limit of a pending job

Before you begin

If a queue swap limit is defined, the value here cannot be greater than the value set for the queue.

Procedure

  • Modify the swap limit:
    bmod -v swap_limit job_id
  • Remove the swap limit:
    bmod -vn job_id

Results

If the job uses more than the new swap limit, the job is killed.