Versions Compared

Key

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

...

Where is the real script?
Code Block
languagebash
titleReal location of launcher_creator.py
ls -l ~/local/bin
Expand
title


# this will tell you the real location of the launcher_creator.py
/work2
 script is
# /work/projects/BioITeam/common/bin/launcher_creator.py


Warning
title$PATH caveat

Remember that the order of locations in the $PATH environment variable is the order in which the locations will be searched.

...

Job Execution

Job execution is controlled by the SLURM batch system on both stampede2 and ls6.

...

Code Block
Project simple.
Using job file simple.cmds.
Using normaldevelopment queue.
For 00:01:00 time.
Using OTH21164 allocation.
Not sending start/stop email.
Launcher successfully created. Type "sbatch simple.slurm" to queue your job.

...

Notice in my queue status, where the STATE is Running, there is only one node assigned. Why is this, since there were 8 tasks?

...

But here's a cute trick for viewing the contents all your output files at once, using the cat command and filename wildcarding.

Code Block
languagebash
titleMulti-character filename wildcarding
cat cmd*.log

The cat command actually takes can take a list of one or more files (if you're giving it files rather than standard input – more on this shortly) and outputs the concatenation of them to standard output. The asterisk ( * ) in cmd*.log is a multi-character wildcard that matches any filename starting with cmd then ending with .log. So it would match cmd_hello_world.log.

You can also specify single-character matches inside brackets ( [ ] ) in either of the ways below, this time using the ls command so you can better see what is matching:

...

Code Block
languagebash
titleAn echo commandA simple.cmds task line
sleep 5; echo "Command 3 `date`" > cmd3.log 2>&1

...

There's still more to learn from one of our simple tasks, something called output redirection:

...

languagebash

...

.

...

Every command and Unix program has three "built-in" streams: standard input, standard output and standard error, each with a name, a number, and a redirection syntax.

...

Normally echo writes its string to standard output, but it could encounter an error and write an error message to standard error. We want both standard output and standard error for each task stored in a log file named for the command number.

Code Block
languagebash
titleA simple.cmds task line
sleep 5; echo "Command 3 `date`" > cmd3.log 2>&1

So in the above example the first '>' says to redirect the standard output of the echo command to the cmd3.log file. The '2>&1' part says to redirect standard error to the same place. Technically, it says to redirect standard error (built-in Linux stream 2) to the same place as standard output (built-in Linux stream 1); and since standard output is going to cmd3.log, any standard error will go there also. (Read more about Standard streams and redirection)

...

Code Block
languagebash
titleCopy wayness commands
# If $CORENGS is not defined:
export CORENGS=/work/projects/BioITeam/projects/courses/Core_NGS_Tools

cds
mkdir -p core_ngs/slurm/wayness
cd core_ngs/slurm/wayness
cp ~$CORENGS/CoreNGS/tacc/wayness.cmds .

Exercise: How many tasks are specified in the wayness.cmds file?

...

Code Block
languagebash
titleRelative path exercise
# navigate through the symbolic link in your Home directory
cd ~scratch/core_ngs/slurm/simple 
ls ../wayness
ls ../..
ls -l ~/.bashrc

And read (Read more about Absolute and relative pathname syntax)

Interactive sessions (idev)

...

  • the hostname command on a login node will return a login server name like login3.ls6.tacc.utexas.edu
    • while in an idev session hostname returns a compute node name like c303-006.ls6.tacc.utexas.edu
  • you cannot submit a batch job from inside an idev session, only from a login node
  • your idev session will end when the requested time has expired
    • or you can just type exit to return to a login node session

...