Migrating from Slurm#

Spur is drop-in compatible with Slurm’s command-line interface, REST API, and C FFI. Most Slurm workloads move over unchanged. This page covers what works as-is, where the configuration model differs, and the behavioral differences a Slurm user should know about before switching.

What Works Unchanged#

The following work without modification:

  • Commands — sbatch, srun, salloc, squeue, sinfo, sacct, scancel, scontrol, and sacctmgr (via the symlinks described in Slurm Compatibility).

  • Job script directives — #SBATCH directives in batch scripts are parsed the same way. #PBS directives are also converted on a best-effort basis.

  • Environment variables — Spur sets a SLURM_* twin for every SPUR_* variable it injects into a job, so Slurm-aware software (MPI launchers, training frameworks) sees the SLURM_* names it expects.

  • REST API and C FFI — the REST surface and the FFI library remain Slurm-compatible.

Configuration Differences#

Slurm’s slurm.conf and slurmdbd.conf are replaced by a single TOML file, spur.conf (default location /etc/spur/spur.conf). Key differences:

  • One config file, one set of daemons. There is no slurmdbd and no slurmrestd — accounting and the REST API are served by the controller (spurctld). Accounting storage is configured under [accounting] in spur.conf rather than in a separate slurmdbd.conf.

  • Raft-based state. Controller state is replicated through Raft and persists across restarts, so there is no StateSaveLocation handling to manage separately.

  • Built-in high availability. HA is provided by Raft (openraft) and is always on — even a single controller runs a one-member cluster. There is no separate backup-controller configuration; add controllers to the Raft cluster instead.

See Configuration Reference (spur.conf) for the full spur.conf reference.

Behavioral Differences and Current Limitations#

The commands below accept Slurm syntax, but the following differences apply. Flags noted as “accepted for compatibility” parse without error but have no effect yet.

Area

Difference

Partitions

Defined in spur.conf; there is no runtime scontrol create/update/delete partition. Edit the config and reload the controller to change a partition.

--noconvert

Accepted for compatibility on squeue, sinfo, sacct, sstat, sshare, and sreport. Spur already reports raw values where applicable (sinfo’s memory columns are MB integers; squeue has no memory column yet), so there is nothing to suppress. sstat still prints MemAlloc with an M suffix whether or not the flag is passed.

sacct --jobs

Accepted for compatibility; the job-id filter is not yet applied server-side.

sacct ReqMem

The ReqMem format field has no value yet and renders empty.

sstat

Per-process Ave* and Max* metrics (for example AveRSS, MaxVMSize) show N/A.

sprio

The FAIRSHARE column is a placeholder and does not yet reflect usage.

sacctmgr -p/-P

Delimited output covers show account, show qos, and show txn; for show user, show association, and show tres it errors instead of printing a table no script can parse. -n works for every entity.

scancel arrays

Array-element syntax (123_4) is not yet supported client-side; cancel by plain job id.

scontrol show

Output is always the multi-line Key=Value block; there is no --oneliner. Unset diagnostic fields print as (null) rather than being omitted — notably NodeList=(null) on a pending job, where earlier Spur releases omitted the line. Note that ReqNodeList, ExcNodeList, and SchedNodeList all contain the literal NodeList=, and ReqNodeList is printed first: a script matching NodeList= without anchoring the field name will now read the requested list instead of the allocated one. Match ^\s*NodeList= (or an equivalent boundary) instead. ReqTRES omits Slurm’s billing= component, as Spur computes no TRES billing weights. MinCPUsNode is the per-node CPU floor implied by the task layout, which can read higher than Slurm’s pn_min_cpus for an uneven split such as -N2 -n7. A pending job now reports the scheduler’s projected StartTime (and an EndTime derived from it) where earlier releases printed N/A, so a script treating StartTime != N/A as “the job has started” needs to check JobState instead.

scontrol show assoc_mgr

Caps print as Limit(Consumed) with N for no limit, as in Slurm, and an OverLimit field names caps already exceeded. Filters to one user (users=<name> or a bare name); Slurm’s accounts=, qos= and flags= selectors are not accepted (an unknown <key>= errors rather than being read as a username). As in Slurm, an unprivileged caller is scoped to their own associations and administrators see every scope. Users are listed on their own lines under a scope rather than nested in a User Limits= field, and an account’s group figures are stated once for the account instead of repeated per association row. Fairshare and priority internals Slurm prints (SharesRaw, UsageRaw, Lft-Rgt, GrpTRESMins) are not included.

sshare/sreport usage units

sshare RawUsage and CPURawUsage report cpu-seconds, matching Slurm. Prior Spur releases displayed cpu-hours under the same column names. sreport columns are likewise cpu-seconds. Scripts parsing sshare --parsable output will see values 3600× larger than before. Upgrade spurctld and spur-cli together to avoid a mixed-unit window.

QOS GrpWall

Enforced at scheduling admission only: an over-budget QOS stops admitting jobs, and running jobs are never killed where Slurm cancels them. Consumption is a trailing window (grp_wall_window_days under [accounting]) rather than decayed usage, and the cap exists on a QOS only, not on an association. See Group wall-clock budgets (GrpWall).

Accounting and QOS Mapping#

Accounting entities map directly from Slurm:

  • sacctmgr add account, sacctmgr add user, and sacctmgr add qos work as in Slurm, following the same cluster → account → user → association → QOS ordering.

  • The [accounting] require_qos setting is the equivalent of Slurm’s AccountingStorageEnforce=qos.

  • The [accounting] require_association setting is the equivalent of Slurm’s AccountingStorageEnforce=associations.

  • The default_qos setting is the equivalent of Slurm’s fallback QOS.

See Accounting, Accounts, Users, and QOS for the accounting concept guide.

Tip

Before migrating a production workload, test the golden path on a small cluster first: submit a job (sbatch), check the queue (squeue), cancel a job (scancel), and review accounting history (sacct).

See Also#