Commit b9b3284f authored by Francois Ledoyen's avatar Francois Ledoyen
Browse files

add slurm real time debugging

parent e1a826a9
Loading
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
label: "Utilisation HPC"
label: "HPC guide"
icon: ":computer:"

src/hpc_guide/slurm.md

0 → 100644
+40 −0
Original line number Diff line number Diff line
---
order: 1
---

# SLURM guide

## Debug in Real-time on SLURM

### Problem

Debugging a code by submitting jobs to a supercomputer is an inefficient
process. It goes something like this :

1. Submit job and wait in queue.
1. Check for errors/change code.
1. Repeat endlessly until your code works.

### Solution

Fortunately, there’s a better way, you can debug in real-time like so:

1. Request a debugging or interactive node and wait in queue :

   ```sh
   srun --partition=<name> --nodes=<nnodes> --gres=gpu:<ngpus> --time=<time> --pty bash -i
   ```

1. This is how it looks once the interactive job starts :

   ```sh
   srun: job 12345 queued and waiting for resources
   srun: job 12345 has been allocated resources
   ```

1. Check for errors/change code continuously until code is fixed or node has
   timed out.

### Sources

- [HPC-UiT Services User Documentation](https://hpc-uit.readthedocs.io/en/latest/jobs/interactive.html#starting-an-interactive-job)

src/utilisation_hpc/slurm.md

deleted100644 → 0
+0 −3
Original line number Diff line number Diff line
---
label: "Slurm"
---
Loading