User Tools

Site Tools


guides:slurm:basics

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
guides:slurm:basics [16.10.2020 10:47]
Juha Kekäläinen
guides:slurm:basics [27.11.2023 12:40] (current)
Administrator
Line 35: Line 35:
 #SBATCH --mem=2000 # Reserve 2 GB RAM for the job #SBATCH --mem=2000 # Reserve 2 GB RAM for the job
 #SBATCH --partition serial # Partition to submit #SBATCH --partition serial # Partition to submit
-module load matlab/R2018b # load modules+ 
 +module load matlab/R2022b # load modules
  
 matlab -nodisplay < matlab.m # Execute the script matlab -nodisplay < matlab.m # Execute the script
Line 47: Line 48:
 ``` ```
 **[sbatch](https://slurm.schedmd.com/sbatch.html)** command submits the job to the job queue and executes the **[bash script](https://en.wikipedia.org/wiki/Bash_(Unix_shell)**.  **[sbatch](https://slurm.schedmd.com/sbatch.html)** command submits the job to the job queue and executes the **[bash script](https://en.wikipedia.org/wiki/Bash_(Unix_shell)**. 
 +
 +Here is an another example on how to analyze variants.
 +
 +```
 +#!/bin/bash
 +#SBATCH --ntasks 1          # Number of task
 +#SBATCH --time 00:30:00     # Runtime 30min
 +#SBATCH --mem 2000          # Reserve 2 GB RAM for the job
 +#SBATCH --partition serial  # Partition to submit
 +
 +module load bcftools # load modules
 +
 +# filter variants and calculate stats
 +bcftools filter --include'%QUAL>20' calls.vcf.gz | bcftools stats --output calls_filtered.stats 
 +```
 +
 +Submit the job to computing queue with the **[sbatch](https://slurm.schedmd.com/sbatch.html)** command.
 +
 +```
 +sbatch variants.sbatch
 +```
  
  
Line 83: Line 105:
 ``` ```
 scontrol show job <jobid> scontrol show job <jobid>
-``` 
- 
-#### Extend runtime of given jobid 
- 
-``` 
-scontrol update jobid=<job_id> TimeLimit=<new_timelimit> 
 ``` ```
  
guides/slurm/basics.1602834429.txt.gz · Last modified: 16.10.2020 10:47 by Juha Kekäläinen