Table of Contents

NAME

bhist - display the history of batch jobs in the lsbatch system

SYNOPSIS

bhist [ -h ] [ -V ] [ -b ] [ -l ] [ -a ] [ -d ] [ -p ] [ -s ] [ -r ] [ -f logfile_name ] [ -N host_spec ]
[ -C time0, time1 ] [ -S time0, time1 ] [ -D time0, time1 ] [ -q queue_name ] [ -m host_name ] [ -u user_name | -u all ] [ -J job_name] [ -n num_logfiles] [ jobId ... ]

DESCRIPTION

Display the history of one or more batch jobs specified by the options. If no option is specified, then the default is to display information about all the unfinished (that is, pending, running and suspended) jobs submitted by the user who invoked this command. If the -d or -a option is specified, then jobs that have finished can be displayed.

OPTIONS

-h Print command usage to stderr and exit.

-V Print LSF release version to stderr and exit.

-b Display the job history in a brief format. For the default, see -l.

-l Display the job history in a (long) multi-line format for each job, which gives detailed information about the job. If neither -l nor -b is present, the default is to display the fields in SUMMARY only (see below).

-a Display both finished and unfinished jobs. This option overrides -d, -p, -s, and -r. If neither -a nor -d is present, then finished jobs are not displayed.

-d Display only the finished jobs.

-p Display only the pending jobs.

-s Display only the suspended jobs, showing the reason why each job was suspended (if option -l or -b specified).

-r Display only the running jobs.

-f logfile_name
Specify the file name of the event log file. Either an absolute or a relative path name may be specified. The default is to use the event log file currently used by the lsbatch system: $(LSB_SHAREDIR)/<clustername>/logdir/lsb.events (see lsb.events(5) ). Option -f is useful for off-line analysis.

-n num_logfiles
Specify the number of event log files that bhist searches. The most recent num_logfiles log files are searched. The default is 1; i.e., the current event log file,
$(LSB_SHAREDIR)/<clustername>/logdir/lsb.events (see lsb.events(5) ) is searched. If num_logfiles is 2, bhist searches event log files lsb.events and lsb.events.1; If num_logfiles is 3, bhist searches lsb.events, lsb.events.1, and lsb.events.2; and so on. If num_logfiles is 0, all the event log files in $(LSB_SHAREDIR)/<clustername>/logdir are searched.

-N host_spec
Display the CPU time by a normalized value. host_spec is either a host name, or a host model name defined in LSF, or a CPU factor (use lsinfo(1) to get host model and CPU factor information). If bhist is used off line, i.e., without LIM, the only legal usage for host_spec is a CPU factor. The appropriate CPU scaling factor for the specified host_spec is used to normalize the actual CPU time consumed by the job.

-C time0, time1
Consider only those jobs whose completion or exit times were within the time interval time0, time1 (see TIME FORMAT below). The default is to consider all jobs that were completed or exited between the timestamp of the first event and the timestamp of the last event in the event file.

-S time0, time1
Consider only those jobs whose submission times were within the time interval time0, time1 (see TIME FORMAT below). The default is to consider all jobs that were submitted between the timestamp of the first event and the timestamp of the last event in the event file.

-D time0, time1
Consider only those jobs whose dispatch times were within the time interval time0, time1 (see TIME FORMAT below). The default is to consider all jobs that were dispatched between the timestamp of the first event and the timestamp of the last event in the event file.

-q queue_name
Display jobs submitted to the specified queue queue_name only. The default is to consider all queues.

-m host_name
Display jobs dispatched to the specified host host_name only. The default is to consider all hosts.

-u user_name | -u all
Display jobs that have been submitted by the user specified by user_name, or by all users (if the reserved user name all is specified). The default is to display the jobs submitted by the user who invoked this command.

-J job_name
Display the jobs that have the specified job_name.

jobId ...
Display the specified job(s) only. This option overrides all other options except -N, -h and -V. When it is used with -J, only those jobs listed here that have the specified job_name are displayed.

SUMMARY

Statistics of the amounts of time that job has spent in various states:

PEND The total waiting time excluding user suspended time before the job is dispatched

PSUSP
The total user suspended time of a pending job

RUN The total run time of the job

USUSP
The total user suspended time after the job is dispatched

SSUSP
The total system suspended time after the job is dispatched

UNKWN
The total unknown time of the job (job status becomes unknown if slave batch daemon (sbatchd) on the execution host is temporarily unreachable).

TOTAL
The total time that the job has spent in all states; for a finished job, it is the turnaround time (that is, the time interval from job submission to job completion).

TIME FORMAT

The «time0, time1» in options of -C, -S and -D must conform to the following:

time_form = ptime,ptime | ptime, | ,ptime | itime

ptime
= day | /day | month/ | year/month/day | year/month/day/ | hour: | month/day | year/month/day/hour: | year/month/day/hour:minute | day/hour: | month/day/hour: | day/hour:minute | hour:minute | month/day/hour:minute | . | .-itime
itime
= ptime day, month, hour, minute = two digits

where `ptime' stands for a specific point of time, `itime' stands for a specific interval of time, and `.' stands for the current month/day/hour:minute.

Keeping the following rules in mind will help you to specify the time freely:

- year must be 4 digits and followed by a /
- month must be followed by a / - day must be preceded by a / - hour must be followed by a : - minute must be preceded by a : - The / before day can be omitted when day stands alone or when day is followed by /hour: - No spaces are allowed in time format, that is, the time must be a single string.

The above time format is designed for easy and flexible time specification.

See the following examples:

Suppose the current time is Mar 9 17:06:30 1994.

1,8
from Mar 1 00:00:00 1994 to Mar 8 23:59:00 1994; ,4 or ,/4 from the time when first job was logged to Mar 4 23:59:00 1994;
6 or /6
from Mar 6 00:00:00 1994 to Mar 6 23:59:00 1994;
2/
from Feb 1 00:00:00 1994 to Feb 28 23:59:00 1994;
12:
from Mar 9 12:00:00 1994 to Mar 9 12:59:00 1994;
2/1
from Feb 1 00:00:00 1994 to Feb 1 23:59:00 1994;
2/1,
from Feb 1 00:00:00 to the current time;
,. or ,
from the time when first job was logged to the current time;
,.-2
from the time when first job was logged to Mar 7 17:06:30 1994;
,.-2/
from the time when first job was logged to Jan 9 17:06:30 1994;
,2/10:
from the time when first job was logged to Mar 2 10:59:00 1994;
1993/11/25,1994/1/25
from Nov 25 00:00:00 1993 to Jan 25 23:59:00 1994;

SEE ALSO

lsb.events(5) , bsub(1) , bjobs(1) , lsinfo(1)


Table of Contents