Summary and Setup

The Unix shell has been around longer than most of its users have been alive. It has survived because it’s a powerful tool that allows users to perform complex and powerful tasks, often with just a few keystrokes or lines of code. It helps users automate repetitive tasks and easily combine smaller tasks into larger, more powerful workflows.

Use of the shell is fundamental to a wide range of advanced computing tasks, including high-performance computing. These lessons will introduce you to this powerful tool.

Prerequisite

Prerequisites

This lesson guides you through the basics of file systems and the shell. If you have stored files on a computer at all and recognize the word “file” and either “directory” or “folder” (two common words for the same thing), you’re ready for this lesson.

Setup

Logging into Rivanna/Afton

To log into the Rivanna or Afton HPC cluster, start by visiting the HPC Login Instructions page:
https://www.rc.virginia.edu/userinfo/hpc/login/

Follow the instructions for Secure Shell Access (SSH) based on your operating system:

  • Windows: Install the recommended SSH client, MobaXterm, by clicking the Install MobaXterm button under the Windows section of the page and following the instructions.
  • macOS: Open the Terminal application, located in the Utilities folder.
    • On macOS Mojave and earlier, the default shell is Bash.
    • On macOS Catalina and later, the default shell is Zsh. To temporarily switch to Bash, open Terminal, type bash, and press Return.
  • Linux: Most Linux systems use Bash as the default shell. Open a terminal using the Applications menu or search bar (look for Terminal, Konsole, or xterm). If your system defaults to another shell, you can switch by typing bash and pressing Return.

Once you have a terminal open, connect to the HPC cluster by typing:

BASH

ssh -Y uva_compute_id@login.hpc.virginia.edu

Replace uva_compute_id with your UVA computing ID. You will then be prompted to enter your UVA NetBadge password.

Data Access for This Lesson

Before we start, let’s make sure you are in your home directory. In the terminal, type:

BASH

cd

and press Return.

The data for this lesson is stored in the folder:

BASH

/standard/bims6000/shell-lesson-data

Let’s copy this folder into your home directory so you can work with your own copy. Run the following command:

BASH

cp -r /standard/bims6000/shell-lesson-data .

Don’t worry about the details of this command yet. We will explain how it works later in the lesson.