Frequently Asked Question

How to submit batch jobs to VSC?
Last Updated 4 years ago

1. Introduction

This is a short introduction of how to submit batch jobs to the Vienna Scientific Cluster from an EODC Virtual Machine. For more detailed information please refer to the official documentation here.
If you don't yet have access to the Vienna Scientific Cluster contact our support team.
You can read more on how to access the VSC in our guide here.

2. Submit Batch Jobs via Submission Script

Users submit jobs, which are scheduled and allocated resources (CPU time, memory, etc.) by the resource manager. A job consists in two parts: resource requests and job steps. Resource requests consist in a number of CPUs, computing expected duration, amounts of RAM or disk space, etc. Job steps describe tasks that must be done, software which must be run.
In order to submit batch jobs you will have to write a "Submission Script" which is handled by a resource manager called "Slurm".

A submission script is a shell script, e.g. a Bash script, whose comments, if they are prefixed with SBATCH, are understood by Slurm as parameters describing resource requests and other submissions options. You can get the complete list of parameters from the sbatch manpage man sbatch. In order to submit a job to the VSC over your EODC virtual machine it is crucial to add the SBATCH comment #SBATCH --licenses="gpfs@eodc" to your submission script.

For instance, the following script, hypothetically named submit.sh, would request one CPU for 10 minutes, along with 100 MB of RAM, in the default queue. When started, the job would run a first job steps run hostname, which will launch the UNIX command hostname on the node on which the requested CPU was allocated. Then, a second job step will start the sleep command. Note that the --job-name parameter allows giving a meaningful name to the job and the --output parameter defines the file to which the output of the job must be sent.

Important: Do not forget to add the SBATCH comment #SBATCH --licenses="gpfs@eodc" as shown in the example below.

2.1 Example

#!/bin/bash
#
#SBATCH --licenses="gpfs@eodc"
#SBATCH --job-name=test
#SBATCH --output=res.txt
#
#SBATCH --ntasks=1
#SBATCH --time=10:00
#SBATCH --mem-per-cpu=100
srun hostname
srun sleep 60
This website relies on temporary cookies to function, but no personal data is ever stored in the cookies. For further information see our

privacy policy.

Accept

Loading ...