Please Enter a Search Term
 
"Building a Healthy Tomorrow"  TM
AdmissionsCommunicationsDivision/DisciplineEducationFaculty/StaffLeadershipResearchStudents
Center for Health Informatics and Analytics

How to submit jobs and navigate around LSF

The following guide describes how to submit jobs and navigate around to CHIA’s file management system (LSF) using the Linux Terminal Window. If you would prefer to use a graphical interface for this, please view the guide titled "How to Use PAC web interface":

Linux Terminal Window

1.       Open terminal window

2.       Type ssh username@chia-sched1.med.mun.ca

3.       Enter your password as prompted

4.       The following are the main job submission and control commands you need to know for using LSF in command:
a.       bsub [options] command [cmdargs]  (common bsub options are –J to name the job, -q to submit job to specified               queue, -n for number of CPUs needed for the job,-cwd dir-path specifies the current working directory for the job, -i            filename to use standard file as   standard input for job,  -I submits an interactive batch. All options associated with            bsub can be viewed by typing man bsub on the command line.)
b.      bjobs [-a][-J jobname][-u usergroup|-u all][...] jobID
c.      bhist [-a][-J jobname][-u usergroup|-u all][...] jobID
d.      bbot/btop [jobID | "jobID[index_list]“] [position]
e.      bkill [-J jobname] [-m] [-u ] [-q] [-s signalvalue]
f.       bmod [bsub_options] jobID
g.      bpeek [-f] jobID
h.      bstop/bresume jobID
i.       bswitch destination_queue jobID

5.       The following example submits a job called ‘jobname’ to the normal queue using 4 CPUs in the current working directory of           jobname. /my_job_launcher.sh:

           bsub -J `jobname` -q normal -n 4 -cwd `jobname` ./my_job_launcher.sh

6.       Once a job has been created you should see something like this:
Job <4>, Job Name </gpfs/home/msturge/regression/chip1>, User <msturge>
Project <default>, Status <RUN>, Queue <normal>,
Command <./my_job_launcher.sh>

Thu Mar 1 17:48:43: Submitted from host <chia-sched1>,
CWD </gpfs/home/msturge/regression/chip1>;

Thu Mar 1 17:51:55: Started on <chia-sched1>,
Execution Home </home/msturge>,
Execution CWD </gpfs/home/msturge/regression/chip1> ;
Thu Mar 1 17:52:12: Resource usage collected.
MEM: 2 Mbytes; SWAP: 5 Mbyt
7.       To terminate a job type bkill. To terminate all jobs of the current user: bkill –b 0

8.       The bjobs command displays information about pending, running and suspended jobs. To view all jobs use bjobs –a. To                see pending jobs type bjobs –p. For running jobs use bsub –r. To see jobs for a specific use type bjobs –u user_name. 
Further information on options for the bsub command can be viewed by typing
man bjobs on command line interface.

9.       An example of the type of information displayed from the command bjobs –u all –a:

JOBID USER STAT QUEUE FROM_HOST EXEC_HOST JOB_NAME SUBMIT_TIME
1233 test1 DONE normal mac1 mainmac testjob Feb 27 10:00
1234 test1 RUN priority mac1 mainmac logger Feb 27 10:00
1235 test2 PEND normal win2   ranalysis Feb 27 10:03
1236 test PEND night win2   jobname Feb 27 10:06
               
10       To get more detailed information on any of the listed commands from #4, type man command.

 
Copyright © 2017 Memorial University of Newfoundland.   Newfoundland and Labrador, Canada.