Skip to content
thornenj edited this page Apr 25, 2016 · 14 revisions

For this example, we will be using the master node as host for the job scheduling services of SLURM.

Install some dependencies

[root@master work_slurm]# losf addpkg rpm-build readline-devel openssl-devel munge-devel munge-libs pam-devel munge perl-ExtUtils-MakeMaker
[root@master work_slurm]# update

Download and build SLURM

[root@master work_slurm]# wget http://www.schedmd.com/download/latest/slurm-14.11.0.tar.bz2
[root@master work_slurm]# rpmbuild -ta slurm-14.11.0.tar.bz2

Install the slurm RPMS using losf

[root@master x86_64]# cd ~/rpmbuild/RPMS/x86_64/
[root@master x86_64]# for rpm in $(ls ./); do losf addrpm $rpm; done
[root@master x86_64]# update

Create the munge key and test to see if slurm service starts

[root@master x86_64]# create-munge-key 
[root@master x86_64]# service munge restart

Configure slurm, where it lives in losf

cp /etc/slurm/slurm.conf.example /admin/losf/config/const_files/discovery/master/slurm.conf
vim /admin/losf/config/const_files/discovery/master/slurm.conf #change at least ClusterName= and ControlMachine=
#(control machine should be ping-able)

In /admin/losf/config/config.[cluster name], tell losf to sync files

[ConfigFiles]
# SLURM
/etc/slurm/slurm.conf           = yes
/etc/munge/munge.key            = yes

In /admin/losf/config/config.[cluster name], start services

[Services]
munge           = on
slurmctld       = on

Scheduling jobs on clusters requires that system clocks are synchronised - this optional step for setting up ntp is strongly recommended

losf addpkg ntp

In /admin/losf/config/config.[cluster name] append ntp to the list of services

[Services]
munge           = on
slurmctld       = on
ntpd            = on

Update to implement both changes

update