Apollo Logo Apollo Logo

Apollo HPC Cluster - Quickstart Guide

HPC Network at DST-FIST Sponsored AI & DS Lab

Department of Computer Science and Engineering, Jadavpur University, India

🔧 View Maintenance Guide QR Code

Accessing the Cluster

The cluster may be accessed by connecting to the master node via Secure Shell (SSH).

The IP address of the master node is 172.24.56.211.

This IP address should be accessible from certain designated locations within the CSE department. To connect:

$ ssh <username>@172.24.56.211

Using SLURM

Here’s a quick overview of common SLURM commands. For detailed usage, refer to the official SLURM docs or use the man pages.

Scheduling Jobs

Monitoring Jobs

squeue: Monitor running or queued jobs

$ squeue [options]

Cancelling Jobs

scancel: Cancel jobs

$ scancel [options] job-id

Managing SLURM Configuration

scontrol: View or modify SLURM config (admin use only)

Important: Most scontrol commands require admin privileges. Contact your system admin before using them.

Example: Running a Python Program

This example walks through running a basic Python project on the cluster.

Step 1: Navigate to Working Directory

$ cd /apollo/<username>
$ mkdir <project-name>
$ cd <project-name>

Step 2: Create Virtual Environment

$ python3 -m venv myenv

Step 3: Activate Virtual Environment

$ source myenv/bin/activate

Step 4: Install Required Python Packages

Using requirements.txt:

$ pip install -r requirements.txt

Or manually:

$ pip install <package-1> <package-2> ...

Step 5: Write SLURM Job Script

Create a file named job.sh:

#!/bin/bash
#SBATCH --job-name=my_python_job
#SBATCH --output=output.log
#SBATCH --error=error.log
#SBATCH --time=01:00:00
#SBATCH --nodes=1
#SBATCH --ntasks=1
#SBATCH --cpus-per-task=4
#SBATCH --gpus-per-node=1
#SBATCH --mem=4G

cd /apollo/<username>/<project-name>
source myenv/bin/activate
python main.py

Step 6: Submit the Job

$ sbatch job.sh

Step 7: Monitor the Job

$ squeue -u <username>

Step 8: View Output

$ cat output.log
$ cat error.log