Versions Compared

Key

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

...

  • wget – retrieves the contents of an Internet URL
  • cp – copies directories or files located on any local file system
  • scp – copies directories or files to/from a remote system
  • rsync – copies directories or files on either local or remote systems

(Read more at about Copying files and directories)

TACC storage areas and Linux commands to access data
(all commands to be executed at TACC except
laptop-to-TACC copies, which must be executed on your laptop)

...

There are 3 local file systems available on any TACC compute cluster (stampede2stampede3, lonestar6, etc.), and your account has a directory in each of the three.

...


HomeWorkScratch
quota10 GB1024 GB = 1 TB2+ PB (basically infinite)none
policybacked upnot backed up,
not purged
not backed up,
purged if not accessed recently (~10 days)
access commandcdcdwcds
environment variable$HOME

$WORK (different sub-directory for each cluster)

$STOCKYARD (root of the shared Work file system)

$SCRATCH
root file system/home/work/scratch
use forSmall files such as scripts that you don't want to lose.Medium-sized files you don't want to copy over all the time. For example, custom programs you install (these can get large), or annotation file used for analysis.Large files accessed from batch jobs. Your starting files will be copied here from somewhere else, and your final results files will be copied elsewhere (e.g. stockyard, corral, your BRCF POD, or your organization's storage area.

...

Code Block
--------------------- Project balances for user abattenh ----------------------
| Name           Avail SUs     Expires | Name           Avail SUs     Expires |
| OTH21095           27688  905  2023-09-302025-01-31 | MCB21106DNAdenovo           3000 1496  20232024-09-30 |
| OTH21164            1010 215  20242025-0503-31 | OTH21180             899996  20242025-03-31 |
------------------------ Disk quotas for user abattenh ------------------------ 
| Disk         Usage (GB)     Limit    %Used   File Usage       Limit   %Used |
| /scratch            0.70       0.0     0.00           567 0           0    0.00 |
| /home1              0.0      11.7     0.0102          232316           0    0.00 |
| /work             169.0    1024.0    16.50        79361     3000000    2.65 |
------------------------------------------------------------------------------- 

...

TACC compute clusters now share a common Work file system called stockyard. So files in your Work area do not have to be copied, for example from to stampede2 stampede3 to ls6 – they can be accessed directly from either cluster.

...

  • $STOCKYARD - This refers to the root of your shared Work area
    • e.g. /work/01063/abattenh
  • $WORK - Refers to a sub-directory of the shared Work area that is different for different clusters, e.g.:
    • /work/01063/abattenh/ls6 on lonestar6
    • /work/01063/abattenh/stampede2stampede3 on stampede2 stampede3

A mechanism is being developed for purchasing larger stockyard allocations (above the 1 TB basic quota) from TACC are in development.

The UT Austin BioInformatics Team, a loose group of bioinformatics researchers, maintains a common directory area on stockyard.

...

corral is a gigantic (multiple PB) storage system (spinning disk) where researchers can store data. UT researchers may request up to 5 TB of corral storage through the normal TACC allocation request process. Additional space on corral can be rented for ~$80~$43/TB/year. A couple of things See https://docs.tacc.utexas.edu/hpc/corral/

A couple of things to keep in mind regarding corral:

...

There is currently no charge for ranch storage. However, since the data is stored on tape it is not immediately available – robots find and mount appropriate tapes when the data is requested, and it can take minutes to hours for the data to appear on disk. The metadata about your data – the directory structures and file names – is always accessible, but the actual data in the files is not on disk until unless "staged". See the ranch user guide for more information: https://wwwdocs.tacc.utexas.edu/user-services/user-guides/ranch-user-guidehpc/ranch/.

Once that data is staged to the ranch disk it can be copied to other places. However, the ranch file system is not mounted as a local file system from the stampede2 stampede3 or ls6 clusters. So remote copy commands are always needed to copy data to and from ranch (e.g. scp, rsync).

...

The rightmost Mounted on column give the top-level access path. Find /home1, /work, and /scratch and note their Size numbers!What do we mean by "hierarchy"? It is like a tree, with the root file system (

Code Block
Filesystem                                           Size  Used Avail Use% Mounted on
devtmpfs                                             126G     0  126G   0% /dev
tmpfs                                                126G   43M  126G   1% /dev/shm
tmpfs                                                126G  4.1G  122G   4% /run
tmpfs                                                126G     0  126G   0% /sys/fs/cgroup
/dev/md127                                           150G   92G   59G  61% /
/dev/sda2                                           1014M  207M  808M  21% /boot
/dev/md126                                           284G   21G  264G   8% /tmp
/dev/md125                                           8.0G  4.3G  3.8G  54% /var
129.114.40.1:/admin                                  3.5T  714G  2.6T  22% /admin
129.114.40.7:/home1                                  7.0T  6.5T  504G  93% /home1
172.29.200.10@o2ib1172:172.29.200.11@o2ib1172:/work  6.8P  2.5P  4.3P  37% /work
129.114.52.169:/corral/main                           38P   21P   18P  55% /corral
tmpfs                                                 26G     0   26G   0% /run/user/891443
tmpfs                                                 26G     0   26G   0% /run/user/881379

What do we mean by "hierarchy"? The file system hierarchy is like a tree, with the root file system (denoted by the leading / ) as the trunk, sub-directories as branches, sub-sub-directories as branches from branches (and so forth), with files as leaves off any branch.

...

The first task is to get this sequencing data to a permanent storage area. This should NOT be your laptop! corral (or stockyard) is a great place for it, a BRCF pod, or a server maintained by your lab or company.

...

  • original – for original sequencing data (compressed FASTQ files)
    • sub-directories named, for example, by year_month.<sequencing run/job or project name>
  • aligned – for alignment data (BAM files, etc)
    • sub-directories named, e.g.,  by year_month.<project_name>
  • analysis – further downstream analysis
    • reasonably named sub-directories, often by project
  • refs – reference genomes and other annotation files used in alignment and analysis
    • sub-directories for different reference genomes and aligners
    • e.g. ucsc/hg38/star, ucsc/sacCer3/bwa, mirbase/v20/bowtie2
  • code – for scripts and programs you and others in your organization write
    • ideally maintained in a version control system such as git, subversion or cvs.
    • can have separate sub-directories for people, or various shared repositories.

...

Well, you don't have a desktop at TACC to "Save as" to, so what to do with a link? The wget program knows how to access web URLs such as http, https and ftp. Anchorwget yeast datawget yeast data

Get ready to run wget from the directory where you want to put the data.

...

Code Block
languagebash
titleGet ready to wget
mkdir -p $SCRATCH/archive/original/20212024.core_ngs
cd $SCRATCH/archive/original/20212024.core_ngs
wget 

Here are two web links:

...

Now press Enter to get the command going. Repeat for the 2nd link. Check that you now see the two files (ls), or tree tree $SCRATCH to see your Scratch directory hierarchy:

...

Code Block
languagebash
titleSingle file copy with cp
mkdir -p $SCRATCH/data/test1
cp $CORENGS/misc/small.fq  $SCRATCH/data/test1/
ls $SCRATCH/data/test1

# or..
cds
mkdir -p data/test1
cd data/test1
cp $CORENGS/misc/small.fq .

# or..
mkdir -p ~/scratch/data/test1   # use the symbolic link in your Home directory
cd ~/scratch/data/test1
cp $CORENGS/misc/small.fq  .
ls

Notice the different ways of referring to a directory (Read more about using Absolute or Relative pathname syntax.)

Now copy an entire directory to your Scratch area. The -r option says recursive.

...

  • -a means "archive mode", which implies the following options (and a few others)
    • -p – preserve file permissions
    • -t – preserve file times
    • -l – copy symbolic links as links
    • -rrecursively copy sub-directories
  • -v means verbose
  • -W means transfer Whole file only
    • Normally the rsync algorithm compares the contents of files that need to be copied and only transfers the different parts.
    • For large files and binary files, figuring out what has changed (diff-ing) can take more time than just copying the whole file.
    • The -W option disables file content comparisons (skips diff-ing).
      • Files are only copied if their modification date is more recent or the file size is different

Since these are all single-character options, they can be combined after one option prefix dash ( - ). You could also use options -ptlrvW, separately, instead of using -a for "archive mode".

Tip
titleAlways add a trailing slash ( / ) after directory names

The trailing slash ( / ) on the source and destination directories are very important for rsync( and for other Linux copy commands also)!

rsync will create the last directory level for you, but earlier levels must already exist.

Let's copy a directory using rsync. We'll also add the -P option to show Progress as the copy progresses.

Code Block
languagebash
titlersync (local directory)
mkdir -p $SCRATCH/data
cds
rsync -avW -avrWP $CORENGS/custom_tracks/ data/custom_tracks/

...

Tip

The bash shell has several convenient line editing features:

  • use the Up arrow to scroll back through the command line history; Down arrow goes forward
  • use Ctrl-a to move the cursor to the beginning start of a line; Ctrl-e to the enduse Backspace to remove text before the cursor; Delete to remove text after the cursore to the end
  • Ctrl-k ("kill") to delete all text on your command line after the cursor
  • Ctrl-y ("yank") to copy the last killed text to where the cursor is

Once the cursor is

See positioned where you want it:

  • Just type in any additional text you want
  • To delete text after the cursor, use:
    • Delete key on Windows
    • Function-Delete keys on Macintosh
  • To delete text before the cursor, use:
    • Backspace key on Windows
    • Delete key on Macintosh

(Read more about Command line history and editing)

Copy from a remote computer - scp or rsync

...

Code Block
titlesingle remote file copy with scp
cat $CORENGS/tacc/dragonfly_access.txt
cds
mkdir -p data/test2
scp -p corengstools@dragonfly.icmb.utexas.edu:~/custom_tracks/progeria_ctcf.vcf.gz ./data/test2/
tree ./data/test2

Notes:

  • The 1st time you access a new host the SSH security prompt will appear
  • You will be prompted for your remote host password
    • for security reasons characters will not be echoed
  • The  -r recursive argument works for scp also, just like for cp
  • The  -p argument says to preserve the file's last modification time
    • otherwise the last modification time of the local copy will be when the copy was done

...