Software to connect to the remote server:

Software to enable graphics (X-Forwarding):

SFTP Clients for File Transfer:

Connecting to the SCC

Use scc1 or scc2 login node to connect to the Shared Computing Cluster:
ssh username@scc2.bu.edu

An example for user ktrn:

[local prompt] > ssh    ktrn@scc2.bu.edu  # Windows
[local prompt] > ssh -Y ktrn@scc2.bu.edu  # Mac
[local prompt] > ssh -X ktrn@scc2.bu.edu  # Linux



Check if graphics works (X-forwarding is enabled):

[scc2 ~] > xclock &

You should see a pop-up window with clock in it:


If you do not see clock:
Windows: make sure Xserver icon on the op-left side of MobaXterm is green.
Apple OS X: make sure you logout of your computer after you installed xQuartz, start xQuartx (you should see xQuartz icon on the bottom of your screen) and that you use -Y with your ssh command when you login to the SCC

File Transfer

There are a number of ways you can transfer files to the SCC from a local computer and back. See directions on our website:
http://www.bu.edu/tech/support/research/system-usage/getting-started/get-started-file-transfer/

Example of scp command (from a local terminal window). Transfer a file to the home directory on the SCC:

[local prompt] date > date.txt
[local prompt] scp date.txt username@scc2.bu.edu:.


To download a file from a website, use wget command, i.e.:

[scc2 ~] wget http://rcs.bu.edu/classes/DeepLearning/images/scc.jpg



Home Directories

On the SCC, each user has a 10 GB home directory which is backed up nightly and protected by Snapshots. Additional quota is not available for home directories. To check the home directory quota, use the quota -s command:

[scc2 ~] quota -s
Home Directory Usage and Quota:
Name           GB    quota    limit in_doubt    grace |    files    quota    limit in_doubt    grace
ktrn      5.79501     10.0     11.0      0.0     none |   117357   200000   200000        0     none

Home directories are private to the user. The permissions are set that only the owner has permissions to view, modify or execute the files in the home directory. Home directories should NOT be used for the production work. Once quota is reached, your jobs will fail and many programs will not run (or even start).

Project Directories

You can view wich projects you belong to executing command groups. You might belong to one or more SCC projects. The first project on your list is your default project.

[scc2 ~] groups
cs542

When working on the assignments for this class please use cs542 project.

Each SCC project has its project space. Use pquota command to see the directories associated with the project and their sizes:

pquota cs542
                                      quota     quota       usage     usage
project space                          (GB)    (files)       (GB)   (files)
-----------------------------------  ------  ---------  ---------  --------
/project/cs542                            5     163840       1.92        17
/projectnb/cs542                        995   32604160     793.71   5037625

We will be using projectnb partition for the class:

cd /projectnb/cs542    # change directory to the project directory
ls -l                  # check the content of the directory

Each memomber of cs542 class needs to create his/hew own subdirectory and work inside this directory

mkdir koleinik     # create subdirectory koleinik
ls -l              # check what folders are there

cd koleinik        # change current directory to be the one you just created
pwd                # view the current directory path



SCC Text editors

SCC has all standard Linux editors like emacs, vi (vim, gvim) and nano. There is also a note-pad like editor gedit

Software on the SCC

The module package is available on the Shared Computing Cluster, allowing users to access non-standard tools or alternate versions of standard packages. This is also an alternative way to configure your environment as required by certain packages. You can read more about module command usage on our webpage:
http://www.bu.edu/tech/support/research/software-and-programming/software-and-applications/modules/

To view all available modules:

module avail

To list all available version for a particular package:

module avail python



Work with Python

To select a particular version of python:

module load python3/3.6.5

To view which modules are loaded:

module list
Currently Loaded Modulefiles:
  1) R/3.6.0            2) rstudio/1.2.1335

To start Jupyter, please close any firefox browser you have opened locally and then type:

jupyter notebook

To run Jupyter notebook from you local browser, please see “Running Jupyter Notebook” section at the bottom of this page.

SCC has spyder installed as well, but it might be a slow environment to work on the SCC. Another alternative is to write your program in an editor (or simple IDE like geany) and execute your code at the prompt:

# File: hello.py
a = 2+3
print("Hello CS542!\n","a=",a)
module load python3/3.6.5
python hello.py
## Hello CS542!
##  a= 5



Installing Python packages

We have many popular packages installed in the System. If you need some additional package to be added you can ask us to istall it system-wide or you can try to install it into your user evironment. You can see some information about installing Python packages on the SCC on our website:
http://www.bu.edu/tech/support/research/software-and-programming/common-languages/python/install-packages/

SCC Batch System


Running an interactive job

Login nodes are most suitable for code development and debugging. Non-interactive batch processing is an environment for running jobs that take more than a few minutes and which require no interactions between the user and the application software. There are occasions where longer duration jobs that require user interaction may arise or additional resources (like GPUs) are needed. SCC login nodes do not have GPUs. Use qrsh command with appropriate options to start an interactive job.

An example workflow for the interactive job is below. Here we request 1 CPU and 1 GPU with compute capability of at least 3.5 (which is suitable for tensorflow jobs):

qrsh -P cs542 -l gpus=1 -l gpu_c=3.5


cd /projectnb/cs542/koleinik    # change working directory
module load python3/3.6.5         # load all modules (python and possibly tenslorflow)
module load tensorflow/1.13.1
jupyter notebook                # start jupyter in a local firefox browser or other Python environment

Once you finish with running your interactive job, execute exit or logout to free up the resources.

Running a batch job

In any text editor create a file which will submit your code to the batch system. A simple example of a file that submits a python job may look like this:

#!/bin/bash -l

#Specify project
#$ -P cs542

#Request appropriate time (default 12 hours; gpu jobs time limit - 2 days (48 hours), cpu jobs - 30 days (720 hours) )
#$ -l h_rt=12:00:00

#Send an email when the job is done or aborted (by default no email is sent)
#$ -m e

# Give job a name
#$ -N hello

#$ Join output and error streams into one file
#$ -j y


#load appropriate envornment
module load python3/3.6.5


#execute the program
python hello.py



Tensorflow

We have a number of versions available for tensorflow. You can work with either python2 or python3 versions.

module avail tensorflow

----------------------- /share/module.7/machine-learning -----------------------
tensorflow/1.12   tensorflow/1.13.1
If you plan to work with python-3 your module load commands might look like:
module load python3/3.6.5
module load tensorflow/1.13.1
To submit a job that requires a node with a GPU, your submition script might look like:
#!/bin/bash -l

#Specify project
#$ -P cs542

#Request appropriate time (default 12 hours; gpu jobs time limit - 2 days (48 hours), cpu jobs - 30 days (720 hours) )
#$ -l h_rt=12:00:00

#Send an email when the job is done or aborted (by default no email is sent)
#$ -m e

# Give job a name
#$ -N hello

#$ Join output and error streams into one file
#$ -j y



#load appropriate envornment
module load python3/3.6.5
module load tensorflow/1.13.1

#execute the program
python you_code.py



Track SCC job

qstat -u username

You can read more about checking the status of submitted jobs on our website:
http://www.bu.edu/tech/support/research/system-usage/running-jobs/tracking-jobs/

Setup Jupyter Notebook to run in a local browser

Generate the Jupyter configuration file

module load python3/3.6.5
jupyter notebook --generate-config



Use Python to create an encrypted password hash and exit Python:

scc1 % python

Python 3.6.5 (default, May 31 2018, 11:36:25)
[GCC 4.8.5 20150623 (Red Hat 4.8.5-28)] on linux
Type "help", "copyright", "credits" or "license" for more information.

>>> from notebook.auth import passwd; passwd()
Enter password: 
Verify password: 
'sha1:5a40d332c1a5:b62c59587e5cd5a2ab8791492cfcbcb7811ca34a'
>>> exit()



Modify your Jupyter configuration file

Open the Jupyter configuration file ~/.jupyter/jupyter_notebook_config.py in your preferred text editor and edit lines 162 and 217. You will need to first uncomment the lines by removing the preceding “#” symbol and then modify them as follows:

## Line 162:
## The IP address the notebook server will listen on.
c.NotebookApp.ip = '0.0.0.0'
 
## Line 217: 
#  The string should be of the form type:salt:hashed-password.
c.NotebookApp.password = u'sha1:5a40d332c1a5:b62c59587e5cd5a2ab8791492cfcbcb7811ca34a'



Save the configuration file and exit from the editor.

Start interactive job

qrsh -P cs542 -l gpus=1 -l gpu_c=3.5

Please note the login node name from where you submitted your job and the compute node name that your job will be assigned to.

Load modules and start jupyter notebook


#Navigate to your working directory
cd /projectnb/cs542/username

#Load modules
module load python3/3.6.5
module load tensorflow/1.13.1

#Launch Jupyter notebook
jupyter notebook --no-browser
Please note the port that was assigned to you:
[I 13:10:11.680 NotebookApp] The port 8888 is already in use, trying another port.
[I 13:10:11.681 NotebookApp] The port 8889 is already in use, trying another port.
[I 13:10:11.681 NotebookApp] The port 8890 is already in use, trying another port.
[I 13:10:11.681 NotebookApp] The port 8891 is already in use, trying another port.
[I 13:10:11.810 NotebookApp] Serving notebooks from local directory: /project/scv/classes/CS542
[I 13:10:11.811 NotebookApp] 0 active kernels
[I 13:10:11.811 NotebookApp] The Jupyter Notebook is running at:
[I 13:10:11.811 NotebookApp] http://[all ip addresses on your system]:8892/
[I 13:10:11.811 NotebookApp] Use Control-C to stop this server and shut down all kernels (twice to skip confirmation).

Set up tunneling

Open a new local terminal (where you have not logged in to the SCC) and execute

my-PC % ssh koleinik@scc2.bu.edu -L 7777:scc-x06:8892



Note: There are 4 values that you need to adjust in the above example:

  • your user name
  • login node name (if you used scc1.bu.edu to login to the scc, you need to use it instead of scc2.bu.edu)
  • your compute node name (you can find what compute name you were assigned by looking at the prompt where you started your Jupyter notebook or by running qstat -u username command)
  • port number: instead of 8892 number above, use the port number that was assigned to you when you started jupyter notebook
  • for yout local port you can use 7777 (as in example above or some other port that is available on your local machine)

Run Jupyter Notebook in your local browser

Open your local browser and in the address bar type:
localhost:7777 where 7777 is the local port number you used in the tunneling command.

Getting help

Please us at .
Please include the following information in your email: Your class ID (CS542), your user name, your working directory and detailed description of the problem: what script you are running, what error you are getting etc. There is no need to attach your script to your email.

Additional Resources

Our website: http://www.bu.edu/tech/support/research/
Getting started: http://www.bu.edu/tech/support/research/system-usage/getting-started/
ML examples webpage: http://rcs.bu.edu/examples/ML

SCC Cheat Sheet (pdf): http://scv.bu.edu/documents/SCC_CheatSheet.pdf
Linux Cheat Sheet (pdf): http://scv.bu.edu/documents/Linux_SCC_CheatSheet.pdf
Running jobs: http://www.bu.edu/tech/support/research/system-usage/running-jobs/