From db5c1785040bd9888510869ff033eedaa516822f Mon Sep 17 00:00:00 2001 From: Philip Kovacs Date: Oct 25 2017 21:57:09 +0000 Subject: Version bump, patches adjusted. --- diff --git a/slurm.spec b/slurm.spec index 58da823..a7c0642 100644 --- a/slurm.spec +++ b/slurm.spec @@ -25,8 +25,8 @@ # slurm-torque Name: slurm -Version: 17.02.7 -Release: 4%{?dist} +Version: 17.02.8 +Release: 1%{?dist} Summary: Simple Linux Utility for Resource Management License: GPLv2 and BSD URL: https://slurm.schedmd.com/ @@ -37,19 +37,19 @@ Source3: slurm-sview.desktop Source4: slurm-128x128.png Source5: slurm_setuser.in -# upstream bugs #4094, #4095, #4101, #4113 -Patch0: slurm_opts_restrict.patch -Patch1: slurm_salloc_setgroups.patch -Patch2: slurm_format_truncation.patch +# upstream bug #3942 +Patch0: slurm_ac_header_major.patch # build-related patches -Patch3: slurm_perlapi_rpaths.patch -Patch4: slurm_html_doc_path.patch -Patch5: slurm_doc_fix.patch +Patch1: slurm_perlapi_rpaths.patch +Patch2: slurm_html_doc_path.patch +Patch3: slurm_doc_fix.patch # Fedora-related patches -Patch6: slurm_service_files.patch +Patch4: slurm_service_files.patch +BuildRequires: autoconf +BuildRequires: automake BuildRequires: pkgconfig(gtk+-2.0) BuildRequires: hdf5-devel BuildRequires: pkgconfig(hwloc) @@ -219,8 +219,6 @@ Torque wrapper scripts used for helping migrate from Torque/PBS to Slurm. %patch2 -p1 %patch3 -p1 %patch4 -p1 -%patch5 -p1 -%patch6 -p1 cp %SOURCE1 etc/slurm.conf cp %SOURCE1 etc/slurm.conf.example cp %SOURCE2 etc/slurmdbd.conf @@ -233,6 +231,9 @@ mkdir -p extras cp %SOURCE5 extras/slurm_setuser.in %build +%{__aclocal} -I auxdir +%{__autoconf} +%{__automake} --no-force # upstream bug #2443. need to force lazy linkage since plugins contain # undefined symbols not used in every context, i.e. slurmctld vs slurmd. CFLAGS="$RPM_OPT_FLAGS -Wl,-z,lazy" @@ -266,11 +267,11 @@ s|^dir_tmpfiles_d=.*|dir_tmpfiles_d="%{_tmpfilesdir}"|g;' \ extras/slurm_setuser.in > extras/slurm_setuser # build base packages -%make_build V=0 +%make_build V=1 # build contribs packages # INSTALLDIRS=vendor so perlapi goes to vendor_perl directory -PERL_MM_PARAMS="INSTALLDIRS=vendor" %make_build contrib V=0 +PERL_MM_PARAMS="INSTALLDIRS=vendor" %make_build contrib V=1 %check %{__make} check @@ -749,6 +750,9 @@ fi %systemd_postun_with_restart slurmdbd.service %changelog +* Wed Oct 25 2017 Philip Kovacs - 17.02.8-1 +- Version bump, patches adjusted. + * Thu Oct 5 2017 Philip Kovacs - 17.02.7-4 - Patch changes per resolution of upstream bug #4101: - salloc/sbatch/srun: must be root to use --uid/--gid options. diff --git a/slurm_ac_header_major.patch b/slurm_ac_header_major.patch new file mode 100644 index 0000000..f9050f1 --- /dev/null +++ b/slurm_ac_header_major.patch @@ -0,0 +1,16 @@ +--- slurm-17.02.8/configure.ac.old 2017-10-25 14:35:36.325236357 -0400 ++++ slurm-17.02.8/configure.ac 2017-10-25 15:24:41.023876115 -0400 +@@ -124,7 +124,13 @@ + AC_HEADER_SYS_WAIT + AC_HEADER_TIME + AC_HEADER_STDC ++ ++dnl Workaround for transition of autoconf/glibc issues in deprecation of the ++dnl definitions major, minor, makedev by sys/types.h vs sys/sysmacros.h ++old_CFLAGS=$CFLAGS ++CFLAGS="$CFLAGS -Werror" + AC_HEADER_MAJOR ++CFLAGS=$old_CFLAGS + + dnl Checks for structures. + dnl diff --git a/slurm_doc_fix.patch b/slurm_doc_fix.patch index 8cd7936..41c2754 100644 --- a/slurm_doc_fix.patch +++ b/slurm_doc_fix.patch @@ -1,5 +1,5 @@ ---- slurm-17.02.6/doc/man/man5/burst_buffer.conf.5.orig 2017-08-15 23:22:24.333180212 -0400 -+++ slurm-17.02.6/doc/man/man5/burst_buffer.conf.5 2017-08-15 23:23:45.224298397 -0400 +--- slurm-17.02.8/doc/man/man5/burst_buffer.conf.5.old 2017-08-15 23:22:24.333180212 -0400 ++++ slurm-17.02.8/doc/man/man5/burst_buffer.conf.5 2017-08-15 23:23:45.224298397 -0400 @@ -31,18 +31,18 @@ \fBAllowUsers\fR Comma separated list of user names and/or IDs permitted to use burst buffers. diff --git a/slurm_format_truncation.patch b/slurm_format_truncation.patch deleted file mode 100644 index 8107e97..0000000 --- a/slurm_format_truncation.patch +++ /dev/null @@ -1,44 +0,0 @@ ---- slurm-17.02.7/src/plugins/node_features/knl_generic/node_features_knl_generic.c 2017-08-15 14:37:07.000000000 -0400 -+++ slurm-17.02.7/src/plugins/node_features/knl_generic/node_features_knl_generic.c.new 2017-08-21 01:35:38.352301060 -0400 -@@ -1607,7 +1607,7 @@ - // insmod /home/tim/kmod/xppsl-addons/zonesort_module.ko - struct stat sb; - int buf_len, fd, i, len; -- char buf[8]; -+ char buf[16]; - - if (stat(ZONE_SORT_PATH, &sb) == -1) - (void) system(MODPROBE_PATH " zonesort_module"); ---- slurm-17.02.7/src/plugins/select/bluegene/bg_core.c 2017-07-21 11:17:53.000000000 -0400 -+++ slurm-17.02.7/src/plugins/select/bluegene/bg_core.c.new 2017-08-21 01:39:35.896506235 -0400 -@@ -701,7 +701,7 @@ - */ - extern const char *bg_err_str(int inx) - { -- static char tmp_char[10]; -+ static char tmp_char[32]; - - switch (inx) { - case SLURM_SUCCESS: ---- slurm-17.02.7/src/plugins/task/affinity/cpuset.c 2017-07-21 11:17:53.000000000 -0400 -+++ slurm-17.02.7/src/plugins/task/affinity/cpuset.c.new 2017-08-21 01:42:53.872712983 -0400 -@@ -354,7 +354,7 @@ - int slurm_set_memset(char *path, nodemask_t *new_mask) - { - char file_path[PATH_MAX]; -- char mstr[1 + CPU_SETSIZE * 4], tmp[10]; -+ char mstr[1 + CPU_SETSIZE * 4], tmp[16]; - int fd, i, max_node; - ssize_t rc; - ---- slurm-17.02.7/src/slurmd/slurmd/read_proc.c 2017-07-21 11:17:53.000000000 -0400 -+++ slurm-17.02.7/src/slurmd/slurmd/read_proc.c.new 2017-08-26 00:27:38.036289952 -0400 -@@ -233,7 +233,7 @@ - DIR *proc_fs; - struct dirent *proc_ent; - int proc_fd, proc_stat_size, found, n; -- char proc_name[22], *proc_stat; -+ char proc_name[272], *proc_stat; - struct stat buffer; - int uid, session; - long resident_set_size; diff --git a/slurm_html_doc_path.patch b/slurm_html_doc_path.patch index 263439a..fc147f9 100644 --- a/slurm_html_doc_path.patch +++ b/slurm_html_doc_path.patch @@ -1,11 +1,9 @@ ---- slurm-17.02.7/doc/html/Makefile.in 2017-08-14 13:48:43.000000000 -0400 -+++ slurm-17.02.7/doc/html/Makefile.in.new 2017-08-24 07:58:01.242452059 -0400 -@@ -417,7 +417,7 @@ - host_cpu = @host_cpu@ - host_os = @host_os@ - host_vendor = @host_vendor@ +--- slurm-17.02.8/doc/html/Makefile.am.old 2017-10-25 15:55:38.622808585 -0400 ++++ slurm-17.02.8/doc/html/Makefile.am 2017-10-25 15:56:07.236582868 -0400 +@@ -1,5 +1,5 @@ + -htmldir = ${datadir}/doc/${PACKAGE}-${SLURM_VERSION_STRING}/html +htmldir = ${datadir}/doc/${PACKAGE}/html - includedir = @includedir@ - infodir = @infodir@ - install_sh = @install_sh@ + + generated_html = \ + accounting.html \ diff --git a/slurm_opts_restrict.patch b/slurm_opts_restrict.patch deleted file mode 100644 index ddf6bed..0000000 --- a/slurm_opts_restrict.patch +++ /dev/null @@ -1,72 +0,0 @@ ---- slurm-17.02.7/src/salloc/opt.c.old 2017-10-05 13:33:36.300529834 -0400 -+++ slurm-17.02.7/src/salloc/opt.c 2017-10-05 13:37:02.093162798 -0400 -@@ -1054,6 +1054,10 @@ - } - break; - case LONG_OPT_UID: -+ if (getuid() != 0) { -+ error("--uid only permitted by root user"); -+ exit(error_exit); -+ } - if (opt.euid != (uid_t) -1) { - error("duplicate --uid option"); - exit(error_exit); -@@ -1064,6 +1068,10 @@ - } - break; - case LONG_OPT_GID: -+ if (getuid() != 0) { -+ error("--gid only permitted by root user"); -+ exit(error_exit); -+ } - if (opt.egid != (gid_t) -1) { - error("duplicate --gid option"); - exit(error_exit); ---- slurm-17.02.7/src/sbatch/opt.c.old 2017-10-05 13:39:04.067419821 -0400 -+++ slurm-17.02.7/src/sbatch/opt.c 2017-10-05 13:41:20.388042002 -0400 -@@ -1621,6 +1621,10 @@ - opt.jobid_set = true; - break; - case LONG_OPT_UID: -+ if (getuid() != 0) { -+ error("--uid only permitted by root user"); -+ exit(error_exit); -+ } - if (opt.euid != (uid_t) -1) { - error("duplicate --uid option"); - exit(error_exit); -@@ -1631,6 +1635,10 @@ - } - break; - case LONG_OPT_GID: -+ if (getuid() != 0) { -+ error("--gid only permitted by root user"); -+ exit(error_exit); -+ } - if (opt.egid != (gid_t) -1) { - error("duplicate --gid option"); - exit(error_exit); ---- slurm-17.02.7/src/srun/libsrun/opt.c.old 2017-10-05 13:42:57.195643601 -0400 -+++ slurm-17.02.7/src/srun/libsrun/opt.c 2017-10-05 13:44:34.753262251 -0400 -@@ -1450,6 +1450,10 @@ - _get_int(optarg, "max-exit-timeout", true); - break; - case LONG_OPT_UID: -+ if (getuid() != 0) { -+ error("--uid only permitted by root user"); -+ exit(error_exit); -+ } - if (opt.euid != (uid_t) -1) { - error("duplicate --uid option"); - exit(error_exit); -@@ -1460,6 +1464,10 @@ - } - break; - case LONG_OPT_GID: -+ if (getuid() != 0) { -+ error("--gid only permitted by root user"); -+ exit(error_exit); -+ } - if (opt.egid != (gid_t) -1) { - error("duplicate --gid option"); - exit(error_exit); diff --git a/slurm_perlapi_rpaths.patch b/slurm_perlapi_rpaths.patch index 66b5afe..b8c9f4e 100644 --- a/slurm_perlapi_rpaths.patch +++ b/slurm_perlapi_rpaths.patch @@ -1,11 +1,11 @@ ---- slurm-17.02.7/contribs/perlapi/libslurm/perl/Makefile.PL.in.orig 2016-11-08 15:11:32.000000000 -0500 -+++ slurm-17.02.7/contribs/perlapi/libslurm/perl/Makefile.PL.in 2017-08-17 03:06:27.363688978 -0400 +--- slurm-17.02.8/contribs/perlapi/libslurm/perl/Makefile.PL.in.old 2016-11-08 15:11:32.000000000 -0500 ++++ slurm-17.02.8/contribs/perlapi/libslurm/perl/Makefile.PL.in 2017-08-17 03:06:27.363688978 -0400 @@ -77,7 +77,7 @@ # AIX has problems with not always having the correct # flags so we have to add some :) my $os = lc(`uname`); -my $other_ld_flags = "-Wl,-rpath,@top_builddir@/src/api/.libs -Wl,-rpath,@prefix@/lib"; -+my $other_ld_flags = " "; ++my $other_ld_flags = ""; $other_ld_flags = " -brtl -G -bnoentry -bgcbypass:1000 -bexpfull" if $os =~ "aix"; @@ -16,7 +16,7 @@ # flags so we have to add some :) my $os = lc(`uname`); -my $other_ld_flags = "-Wl,-rpath,@top_builddir@/src/db_api/.libs -Wl,-rpath,@prefix@/lib"; -+my $other_ld_flags = " "; ++my $other_ld_flags = ""; $other_ld_flags = " -brtl -G -bnoentry -bgcbypass:1000 -bexpfull" if $os =~ "aix"; diff --git a/slurm_salloc_setgroups.patch b/slurm_salloc_setgroups.patch deleted file mode 100644 index efb9260..0000000 --- a/slurm_salloc_setgroups.patch +++ /dev/null @@ -1,18 +0,0 @@ ---- slurm-17.02.7/src/salloc/salloc.c.old 2017-10-05 13:25:52.403682572 -0400 -+++ slurm-17.02.7/src/salloc/salloc.c 2017-10-05 13:29:52.913975815 -0400 -@@ -333,8 +333,13 @@ - sleep (++retries); - } - -- /* become the user after the allocation has been requested. */ -- if (opt.uid != (uid_t) -1) { -+ /* If the requested uid is different than ours, become that uid */ -+ if ((getuid() != opt.uid) && (opt.uid != (uid_t) -1)) { -+ /* drop extended groups before changing uid/gid */ -+ if ((setgroups(0, NULL) < 0)) { -+ error("setgroups: %m"); -+ exit(error_exit); -+ } - if (setuid(opt.uid) < 0) { - error("setuid: %m"); - exit(error_exit); diff --git a/slurm_service_files.patch b/slurm_service_files.patch index 988262d..9f1c38a 100644 --- a/slurm_service_files.patch +++ b/slurm_service_files.patch @@ -1,5 +1,5 @@ ---- slurm-17.02.7/etc/slurmctld.service.in 2017-08-14 13:48:43.000000000 -0400 -+++ slurm-17.02.7/etc/slurmctld.service.in.new 2017-08-21 13:35:26.472209176 -0400 +--- slurm-17.02.8/etc/slurmctld.service.in.old 2017-08-14 13:48:43.000000000 -0400 ++++ slurm-17.02.8/etc/slurmctld.service.in 2017-08-21 13:35:26.472209176 -0400 @@ -8,7 +8,7 @@ EnvironmentFile=-/etc/sysconfig/slurmctld ExecStart=@sbindir@/slurmctld $SLURMCTLD_OPTIONS diff --git a/sources b/sources index 8bfd228..67bea59 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (slurm-17.02.7.tar.bz2) = 363ba06b7f2f8a1203396395a3d88b580ba76192bd050c94dbde5c0729fd20a8304f1a0842362588e6e1eed1527f8be47f17dfb0731fbc867d2a253112b147d5 +SHA512 (slurm-17.02.8.tar.bz2) = a3a7633a5a0457299434fee00487a16edc5333360cf4d39f709b13b050d3496670da85340a0b19485016def946f44b723ecc23c1668704b8d10ef0fe697b0e13