From 90889b2142b30a53113b6919743447c8f389b525 Mon Sep 17 00:00:00 2001 From: stuebinm Date: Sat, 29 Oct 2022 23:10:57 +0200 Subject: more slurm stuff --- abbenay/hpc.nix | 99 ++++++++++++++++++++++++++++++++++----------------------- 1 file changed, 59 insertions(+), 40 deletions(-) diff --git a/abbenay/hpc.nix b/abbenay/hpc.nix index c29d65c..2bbd2d5 100644 --- a/abbenay/hpc.nix +++ b/abbenay/hpc.nix @@ -12,46 +12,65 @@ clusterName = "abbenay"; - extraConfig = '' -# slurm.conf file generated by configurator.html. -# Put this file on all nodes of your cluster. -# See the slurm.conf man page for more information. -# -SlurmctldHost=abbenay -MpiDefault=none -ReturnToService=1 -# SlurmctldPidFile=/var/run/slurmctld.pid -# SlurmctldPort=6817 -# SlurmdPidFile=/var/run/slurmd.pid -# SlurmdPort=6818 -# SlurmdSpoolDir=/var/spool/slurmd -SwitchType=switch/none -TaskPlugin=task/affinity - -# TIMERS -InactiveLimit=0 -KillWait=30 -MinJobAge=300 -SlurmctldTimeout=120 -SlurmdTimeout=300 -Waittime=0 - -# SCHEDULING -SchedulerType=sched/backfill -SelectType=select/cons_tres - -# LOGGING AND ACCOUNTING -JobAcctGatherFrequency=30 -JobAcctGatherType=jobacct_gather/none -SlurmctldDebug=info -SlurmctldLogFile=/var/log/slurmctld.log -SlurmdDebug=info -SlurmdLogFile=/var/log/slurmd.log - -# COMPUTE NODES -NodeName=abbenay CPUs=2 State=UNKNOWN -PartitionName=debug Nodes=ALL Default=YES MaxTime=INFINITE State=UP -''; + # slurm.conf file generated by configurator.html. + # Put this file on all nodes of your cluster. + # See the slurm.conf man page for more information. + + SlurmctldHost=abbenay + MpiDefault=none + ReturnToService=1 + SwitchType=switch/none + TaskPlugin=task/affinity + + SrunPortRange=60001-63000 + + # TIMERS + InactiveLimit=0 + KillWait=30 + MinJobAge=300 + SlurmctldTimeout=120 + SlurmdTimeout=300 + Waittime=0 + + # SCHEDULING + SchedulerType=sched/backfill + SelectType=select/cons_tres + + # LOGGING AND ACCOUNTING + JobAcctGatherFrequency=30 + JobAcctGatherType=jobacct_gather/linux + AccountingStorageType=accounting_storage/slurmdbd + SlurmctldDebug=info + SlurmctldLogFile=/var/log/slurmctld.log + SlurmdDebug=info + SlurmdLogFile=/var/log/slurmd.log + + # COMPUTE NODES + NodeName=abbenay CPUs=2 State=UNKNOWN + # NodeName=cyberbox CPUs=1 State=UNKNOWN + # [add more nodes here] + PartitionName=debug Nodes=ALL Default=YES MaxTime=INFINITE State=UP + ''; + + dbdserver = { + enable = true; + dbdHost = "abbenay"; + extraConfig = '' + StoragePass=hello + StoragePort = ${builtins.toString (builtins.head config.services.mysql.settings.mysqld.port)} + ''; + }; + }; + + networking.firewall.allowedTCPPorts = [ 6817 6818 ]; + networking.firewall.allowedTCPPortRanges = [ { + from = 60001; + to = 63000; + } ]; + + services.mysql = { + enable = true; + package = pkgs.mariadb; }; } -- cgit v1.2.3