Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Short optionLong optionRequiredDescription

-n

name

Yes

The name of the job.

-a

allocation


The allocation you want to charge the run to.

-q

queue

Default: Development

The queue to submit to, like 'normal' or 'largemem', etc.

-w

wayness


Optional The number of jobs in a job list you want to give to each node. (Default is 12 for Lonestar, 16 for Stampede.)

-N

number of nodes


Optional Specifies a certain number of nodes to use. You probably don't need this option, as the launcher calculates how many nodes you need based on the job list (or Bash command string) you submit. It sometimes comes in handy when writing pipelines.

-t

time

Yes

Time allotment for job, format must be hh:mm:ss.

-e

email


Optional Your email address if you want to receive an email from Lonestar when your job starts and ends.

-l

launcher


Optional Filename of the launcher. (Default is <name>.sge)

-m

modules


Optional String of module management commands. module load launcher is always in the launcher, so there's no need to include that.

-b

Bash commands


Optional String of Bash commands to execute.

-j

Command list


Optional Filename of list of commands to be distributed to nodes.

-s

stdout


Optional Setting this flag outputs the name of the launcher to stdout.

...

Code Block
languagebash
titlehow to make a sample commands file
linenumberstrue
# remember that things after the # sign are ignored by bash 
# lines in blocks like this often will scroll to the right
cds  # move to your scratch directory
mkdir my_first_job  # make a new folder called "my_first_job"
cd my_first_job  # move into the new folder to make it easier to create a file there
nano commands  
 
# the following lines should be typed into the nano editor so they will be saved to the new file "commands"
cat commands > commands.out  # this will print the contents of the file you are currently editing to a new file called commands.out
date > date.out  # this will create a file with todays date on it
pwd > current_directory.out  # this will create a file with the current directory in it
echo "my name is <YOURNAME>" >> name.out  # Note that this time we used the append symbol >> not the write symbol > as we plan to put multiple things into the same file. be sure to replace the <> signs with your name
echo "This is the final result of my first script. It worked how I thought it would, or hopefully have the resources to figure out why it didn't" >> name.out  # this will add another line of text to the name.out file.
# feel free to add up to 7 more lines to your commands file here using the cat/ls/pwd/mkdir/other commands that you know.
# beware using cd commands here as it will change your directory as if you were doing it on an interactive node and may cause you to reference files that don't exist
# write and exit nano now ctrl-o ctrl-x
launcher_creator.py -n "my_first_job" -j commands -t 00:02:00 -a "UT-2015-05-18" # this will create a my_first_job.slurm file that will run for 2 minutes
sbatch my_first_job.slurm  # this will actually submit the job to the Queue Manager and if everything has gone right, it will be added to the development queue.

...