Computer Science 335
Parallel Processing and High Performance Computing

Fall 2021, Siena College

Lab 2: Stampede2 Setup
Due: 1:20 PM, Monday, September 27, 2021

In this very brief lab, you will set up and experiment with your account on Stampede2 at the Texas Advanced Computing Center.

You must work individually on this lab.

Getting Set Up

You can find the link to follow to set up your GitHub repository stampede2-lab-yourgitname for this Lab in Canvas.

Git and noreaster

Before moving on to stampede2, make sure you are set up to run C programs and can interact with git and GitHub on noreaster. Some of you have already done parts of this configuration. Skip any setup steps you've done previously.

Log into your account on noreaster.teresco.org with Secure Shell. From Windows, one way to do this is to use PuTTY. From a Mac, a Windows Git Bash window, or a Unix/Linux system, you can use the ssh command in a terminal window. Once successfully connected, you should see a prompt that looks something like this:

[jcool@noreaster]$

Next, create a directory for your work for this course. If you want to name it "parallel", use the command:

mkdir parallel

Then change your working directory to that new directory:

cd parallel

Recent changes to GitHub's authentication now require that you create a Personal Access Token (PAT) to be able to use the git command line tool to interact with your repositories on GitHub. If you have not already done so, follow the instructions here to create a PAT to use with noreaster. Set an expiration date after the end of this semester, and under "Select Scopes", make sure you select "repo", "workflow", and "admin:org". Copy and save your PAT somewhere safe and secure in case you need it again later.

Before you interact with a repository from the command line on noreaster, you will need to store this PAT using gh (GitHub's excellent command-line utility) so the git command can use it to authenticate you to GitHub from noreaster. There are different ways to do this, but the following instructions should get the job done:

Run the command:

gh auth login

and choose the responses as shown here:

From here, you should be able to clone your repository for this lab using the usual procedure (git clone URL, where the URL is copied and pasted from the repository page on GitHub).

Also issue these commands to set your username and email address to be used with Git:

git config --global user.name "jcool"
git config --global user.email "jcool@teresco.org"

Of course you will replace jcool's info with your own.

Complete these brief tasks on noreaster, then add, commit, and push the files produces to GitHub.

First, compile and run lab2.c. Redirect the output of this program to a file n1.txt.

Output Capture: n1.txt for 2 point(s)

Modify the program to print a second line "Edited on noreaster". Put your name in the banner comment while you're in there. Recompile.

Redirect the output of the modified version of program to a file n2.txt.

Output Capture: n2.txt for 2 point(s)

Make sure the modified lab2.c and your two output files are on GitHub.

Stampede2 Basics

This section is new for everyone.

  1. Log into Stampede2 by following the directions on the XSEDE Single Sign On Hub page. This will include installing the Duo app on some device. Once you are able to connect to the login.xsede.org site, you will use gsissh to connect to stampede2.
  2. Clone your repository for this lab onto stampede2. Use your existing or a new GitHub access token when prompted for a password.
  3. Issue these commands to set your username and email address to be used with Git:
    git config --global user.name "jcool"
    git config --global user.email "jcool@teresco.org"
    
  4. Make sure you can compile and run the lab2.c program.
  5. If you prefer to have a different editor (like Emacs or nano) than vi be launched when git needs to you edit something like a commit message, you can edit the file .bashrc in your home directory to include the line
    export EDITOR=emacs
    

    near the end of the file. The next time you log in, your default editor would be Emacs (or nano, if you set it to nano instead).

Run the command uname -a and redirect the output to a file stampede2.txt in your repository.

Output Capture: stampede2.txt for 2 point(s)

Compile lab2.c if you have not already done so. Redirect the output of this program to a file s1.txt.

Output Capture: s1.txt for 2 point(s)

Modify the program to print a second line "Edited on stampede2". Recompile. Redirect the output of the modified version of program to a file s2.txt.

Output Capture: s2.txt for 2 point(s)

Make sure the modified lab2.c and your two output files are on GitHub.

Submission

Commit and push!

Grading

This assignment will be graded out of 15 points.

Feature

Value Score
n1.txt 2
noreaster printout in lab2.c 2
n2.txt 2
Successful stampede2 login 1
stampede2.txt 2
s1.txt 2
stampede2 printout in lab2.c 2
s2.txt 2
Total 15