Debugging a code by submitting jobs to a supercomputer is an inefficient process. It goes something like this:
- Submit job and wait in queue
- Check for errors/change code
- (repeat endlessly until your code works)
Debugging in Real-Time:
- Request a debugging or interactive node and wait in queue
- Check for errors/change code continuously until code is fixed or node has timed out
Example (using Summit supercomputer at University of Colorado Boulder):
- Log into terminal (PuTTY, Cygwin, etc.)
- Navigate to directory where the file to be debugged is located using ‘cd’ command
- Load SLURM
- $module load slurm
- Enter the ‘sinteractive’ command
- $sinteractive
-
Wait in line for permission to use the node (you will have a high priority with a debugging QOS so it shouldn’t take long)
-
Once you are granted permission, the node is yours! Now you can debug to your hearts content (or until you run out of time).