[slurm-users] Does latest slurm version still work on CentOS 6?

215 views
Skip to first unread message

Colas Rivière

unread,
Feb 11, 2019, 11:27:33 AM2/11/19
to slurm...@schedmd.com
Hello,

I'm trying to update slurm to the latest stable version 18.08.5-2. Our
cluster uses CentOS 6.8 and updating it tricky because of Lustre support.
According to https://slurm.schedmd.com/platforms.html, CentOS 6 is still
supported.

However, `yum-builddep slurm-18.08.5-2/slurm.spec` fails, because
`slurm.spec` contains `BuildRequires: systemd` which is not available on
CentOS 6 (at least on my 6.8 apparently).

Does slurm 18.08 work on mode recent versions of CentOS 6? Am I missing
something, or is the platforms page out of date?

Thanks,
Cola

Michael Robbert

unread,
Feb 11, 2019, 11:35:01 AM2/11/19
to slurm...@lists.schedmd.com
Cola,

You need to use the legacy spec file from the contribs directory:

ls -l slurm-18.08.5/contribs/slurm.spec-legacy
-rw-r--r-- 1 mrobbert mrobbert 38574 Jan 30 11:59
slurm-18.08.5/contribs/slurm.spec-legacy

Mike

Prentice Bisbal

unread,
Feb 11, 2019, 11:55:07 AM2/11/19
to slurm...@lists.schedmd.com
Also, make sure no 3rd party packages installed software that installs
files in the systemd directories. The legacy spec file still checks for
systemd files to be present:

if [ -d /usr/lib/systemd/system ]; then
   install -D -m644 etc/slurmctld.service
$RPM_BUILD_ROOT/usr/lib/systemd/system/slurmctld.service
   install -D -m644 etc/slurmd.service
$RPM_BUILD_ROOT/usr/lib/systemd/system/slurmd.service
   install -D -m644 etc/slurmdbd.service
$RPM_BUILD_ROOT/usr/lib/systemd/system/slurmdbd.service
   %if %{slurm_with cray}
      install -D -m644 contribs/cray/slurmsmwd/slurmsmwd.service
%{buildroot}/%{_unitdir}/slurmsmwd.service
   %endif
elif [ -d /etc/init.d ]; then
   install -D -m755 etc/init.d.slurm $RPM_BUILD_ROOT/etc/init.d/slurm
   install -D -m755 etc/init.d.slurmdbd $RPM_BUILD_ROOT/etc/init.d/slurmdbd
   mkdir -p "$RPM_BUILD_ROOT/usr/sbin"
   ln -s ../../etc/init.d/slurm $RPM_BUILD_ROOT/usr/sbin/rcslurm
   ln -s ../../etc/init.d/slurmdbd $RPM_BUILD_ROOT/usr/sbin/rcslurmdbd
fi

At my site, we are using a software package that supports both RHEL6 and
RHEL7 using the same RPM, so they install the startup files for both
systemd and SysV Init at the same time. This will result in
/usr/lib/systemd/system existing on RHEL6 systems. Yes, this a bad
practice that could be fixed with a conditional somewhere in the RPM
post-install script, or just maintaining two different RPMS for each
RHEL major version #, but it's a commercial packag, and this is what I'm
stuck with.  As a result, when I build Slurm using the legacy spec file,
it will still build the systemd unit files and not the SysV  init
scripts. If you're in the same situation, the easiest way to fix it is
to edit that conditional and comment out some of the lines, like this:

#if [ -d /usr/lib/systemd/system ]; then
#   install -D -m644 etc/slurmctld.service
$RPM_BUILD_ROOT/usr/lib/systemd/system/slurmctld.service
#   install -D -m644 etc/slurmd.service
$RPM_BUILD_ROOT/usr/lib/systemd/system/slurmd.service
#   install -D -m644 etc/slurmdbd.service
$RPM_BUILD_ROOT/usr/lib/systemd/system/slurmdbd.service
#   %if %{slurm_with cray}
#      install -D -m644 contribs/cray/slurmsmwd/slurmsmwd.service
%{buildroot}/%{_unitdir}/slurmsmwd.service
#   %endif
#elif [ -d /etc/init.d ]; then
   install -D -m755 etc/init.d.slurm $RPM_BUILD_ROOT/etc/init.d/slurm
   install -D -m755 etc/init.d.slurmdbd $RPM_BUILD_ROOT/etc/init.d/slurmdbd
   mkdir -p "$RPM_BUILD_ROOT/usr/sbin"
   ln -s ../../etc/init.d/slurm $RPM_BUILD_ROOT/usr/sbin/rcslurm
   ln -s ../../etc/init.d/slurmdbd $RPM_BUILD_ROOT/usr/sbin/rcslurmdbd
#fi

It would be great is schedmd could modify the legacy spec file to have a
--without-systemd option for this somewhat rare case, or check for the
existence of the systemd RPMs instead of just the existence of systemd
unit files for this conditional.

Jason Bacon

unread,
Feb 11, 2019, 12:45:03 PM2/11/19
to Slurm User Community List, Colas Rivière, slurm...@schedmd.com
We install via pkgsrc and the 18.08 package (currently in pkgsrc-wip)
builds fine on CentOS 6 and CentOS 7.

Cheers,

    JB

--
Earth is a beta site.


Colas Rivière

unread,
Feb 12, 2019, 10:29:37 AM2/12/19
to slurm...@lists.schedmd.com
Thank you everyone, I successfully updated slurm using slurm.spec-legacy.

Cheers,
Colas
Reply all
Reply to author
Forward
0 new messages