ishan747 / slurm-accounting-fix

To fix jobs accumulating runtime infinitely because they do not have end times.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Problem

Runaway jobs that have an end times of 0 which add up compute hours that are altering the accounting info within slurmDB which produces inaccurate accounting data.

slurm-accounting-fix

To fix jobs accumulating runtime infinitely because they do not have end times.

Note: First create a back up of your slurm accounting database and work in a local test environment.

Steps to Restore the slurmDB

mysql -u root

create database slurm_acct_db;

mysql slurm_acct_db -u root < <path to your DB dumpfile>

Note: Before using this script you need to have an input file which is generated by running the following command sacct -o jobid,state,totalcpu,timelimit,start,end,resvcpuraw --accounts 'username' > inputfile

Usage

./slurm-acct-db-patch inputfile

=======

Usage

./slurm-acct-db-patch filename user

About

To fix jobs accumulating runtime infinitely because they do not have end times.


Languages

Language:Shell 100.0%