Hello community, here is the log from the commit of package slurm for openSUSE:Factory checked in at 2020-01-09 22:50:29 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/slurm (Old) and /work/SRC/openSUSE:Factory/.slurm.new.6675 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "slurm" Thu Jan 9 22:50:29 2020 rev:34 rq:761961 version:18.08.9 Changes: -------- --- /work/SRC/openSUSE:Factory/slurm/slurm.changes 2019-10-02 12:00:56.738716457 +0200 +++ /work/SRC/openSUSE:Factory/.slurm.new.6675/slurm.changes 2020-01-09 22:50:44.614713751 +0100 @@ -1,0 +2,56 @@ +Thu Jan 2 09:14:56 UTC 2020 - Egbert Eich <[email protected]> + +- Deprecate "ControlMachine" only for SLURM version upgrades and + products newer than 1501. This ensures that the original setting + is retained for the SLURM version shipped origianlly with SLE-15-SP1 + or Leap 15.1. + +------------------------------------------------------------------- +Sat Dec 21 09:07:42 UTC 2019 - Egbert Eich <[email protected]> + +- Update to v18.08.9 for fixing CVE-2019-19728 (bsc#1159692). + * Wrap END_TIMER{,2,3} macro definition in "do {} while (0)" block. + * Make sview work with glib2 v2.62. + * Make Slurm compile on linux after sys/sysctl.h was deprecated. + * Install slurmdbd.conf.example with 0600 permissions to encourage secure + use. CVE-2019-19727. + * srun - do not continue with job launch if --uid fails. CVE-2019-19728. + +------------------------------------------------------------------- +Wed Dec 11 18:23:46 UTC 2019 - Christian Goll <[email protected]> + +- added pmix support jsc#SLE-10800 + +------------------------------------------------------------------- +Sun Dec 8 11:33:42 UTC 2019 - Egbert Eich <[email protected]> + +- Use --with-shared-libslurm to build slurm binaries using libslurm. +- Make libslurm depend on slurm-config. + +------------------------------------------------------------------- +Fri Dec 6 17:06:32 UTC 2019 - Egbert Eich <[email protected]> + +- Fix ownership of /var/spool/slurm on new installations + and upgrade (boo#1158696). + +------------------------------------------------------------------- +Thu Oct 31 10:18:21 UTC 2019 - Egbert Eich <[email protected]> + +- Fix permissions of slurmdbd.conf (bsc#1155784, CVE-2019-19727). +- Fix %posttrans macro _res_update to cope with added newline + (bsc#1153259). + +------------------------------------------------------------------- +Mon Oct 21 15:54:43 UTC 2019 - Egbert Eich <[email protected]> + +- Add package slurm-webdoc which sets up a web server to provide + the documentation for the version shipped. + +------------------------------------------------------------------- +Mon Oct 7 15:39:43 UTC 2019 - Egbert Eich <[email protected]> + +- Move srun from 'slurm' to 'slurm-node': srun is required on the + nodes as well so sbatch will work. 'slurm-node' is a requirement + when 'slurm' is installed (bsc#1153095). + +------------------------------------------------------------------- Old: ---- slurm-18.08.8.tar.bz2 New: ---- slurm-18.08.9.tar.bz2 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ slurm.spec ++++++ --- /var/tmp/diff_new_pack.L6yXiW/_old 2020-01-09 22:50:46.334714612 +0100 +++ /var/tmp/diff_new_pack.L6yXiW/_new 2020-01-09 22:50:46.358714624 +0100 @@ -1,7 +1,7 @@ # # spec file for package slurm # -# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2020 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -18,7 +18,7 @@ # Check file META in sources: update so_version to (API_CURRENT - API_AGE) %define so_version 33 -%define ver 18.08.8 +%define ver 18.08.9 %define _ver _18_08 %define dl_ver %{ver} # so-version is 0 and seems to be stable @@ -43,6 +43,13 @@ %define upgrade 1 %endif +# Build with PMIx only for SLE >= 15.2 and TW +%if 0%{?sle_version} >= 150200 || 0%{suse_version} >= 1550 +%{bcond_without pmix} +%else +%{bcond_with pmix} +%endif + # For anything newer than Leap 42.1 and SLE-12-SP1 build compatible to OpenHPC. %if 0%{suse_version} > 1320 || 0%{?sle_version} >= 120200 %define OHPC_BUILD 1 @@ -51,10 +58,14 @@ %if 0%{?suse_version} >= 1220 || 0%{?sle_version} >= 120000 %define with_systemd 1 %endif + %if 0%{?suse_version:1} && 0%{?suse_version} <= 1140 %define comp_at %defattr(-,root,root) %else %define have_json_c 1 + %if 0%{?sle_version} >= 150000 || 0%{?is_opensuse} + %define have_apache_rpm_macros 1 + %endif %endif %if 0 @@ -97,7 +108,7 @@ Summary: Simple Linux Utility for Resource Management License: SUSE-GPL-2.0-with-openssl-exception Group: Productivity/Clustering/Computing -Url: https://www.schedmd.com +URL: https://www.schedmd.com Source: https://download.schedmd.com/slurm/%{pname}-%{dl_ver}.tar.bz2 Source1: slurm-rpmlintrc Patch0: slurm-2.4.4-rpath.patch @@ -141,6 +152,7 @@ %endif BuildRequires: mysql-devel >= 5.0.0 BuildRequires: ncurses-devel +%{?with_pmix:BuildRequires: pmix-devel} BuildRequires: openssl-devel >= 0.9.6 BuildRequires: pkgconfig BuildRequires: postgresql-devel >= 8.0.0 @@ -190,6 +202,20 @@ %{?upgrade:Provides: %{pname}-doc = %{version}} %{?upgrade:Conflicts: %{pname}-doc} +%package webdoc +Summary: Set up SLURM Documentation Server +Group: Productivity/Clustering/Computing +%if 0%{?have_apache_rpm_macros} +BuildRequires: apache-rpm-macros +%else +%define apache_sysconfdir /etc/apache2 +%endif +Requires: slurm-doc = %{version} +Requires(pre): apache2 + +%description webdoc +Set up HTTP server for SLURM configuration. + %description doc Documentation (HTML) for the SLURM cluster managment software. @@ -213,17 +239,20 @@ %package -n %{libslurm} Summary: Libraries for SLURM Group: System/Libraries +Requires: %{name}-config = %{version} %description -n %{libslurm} This package contains the library needed to run programs dynamically linked with SLURM. -%package -n libpmi%{pmi_so} +%package -n libpmi%{pmi_so}%{?upgrade:%{_ver}} Summary: Libraries for SLURM Group: System/Libraries +%{?upgrade:Provides: libpmi%{pmi_so} = %{version}} +%{?upgrade:Conflicts: libpmi%{pmi_so}} -%description -n libpmi%{pmi_so} +%description -n libpmi%{pmi_so}%{?upgrade:%{_ver}} This package contains the library needed to run programs dynamically linked with SLURM. @@ -233,14 +262,13 @@ Group: Development/Libraries/C and C++ Requires: %{libslurm} = %{version} Requires: %{name} = %{version} -Requires: libpmi%{pmi_so} = %{version} +Requires: libpmi%{pmi_so}%{?upgrade:%{_ver}} = %{version} %{?upgrade:Provides: %{pname}-devel = %{version}} %{?upgrade:Conflicts: %{pname}-devel} %description devel This package includes the header files for the SLURM API. - %package auth-none Summary: SLURM auth NULL implementation (no authentication) Group: Productivity/Clustering/Computing @@ -486,6 +514,7 @@ --disable-static \ --without-rpath \ --without-datawarp \ + --with-shared-libslurm \ %{!?have_netloc:--without-netloc} \ --sysconfdir=%{_sysconfdir}/%{pname} \ %{!?have_hdf5:--without-hdf5} \ @@ -516,7 +545,7 @@ ln -sf %{_initrddir}/slurm %{buildroot}%{_sbindir}/rcslurm ln -sf %{_initrddir}/slurmdbd %{buildroot}%{_sbindir}/rcslurmdbd %endif -mkdir -p %{buildroot}%{_var}/spool/slurm +mkdir -p %{buildroot}%{_localstatedir}/spool/slurm rm -f contribs/cray/opt_modulefiles_slurm rm -f %{buildroot}%{_sysconfdir}/plugstack.conf.template @@ -530,8 +559,8 @@ install -D -m644 etc/layouts.d.power_cpufreq.conf.example %{buildroot}/%{_sysconfdir}/%{pname}/layouts.d/power_cpufreq.conf.example install -D -m644 etc/layouts.d.unit.conf.example %{buildroot}/%{_sysconfdir}/%{pname}/layouts.d/unit.conf.example install -D -m644 etc/slurm.conf.example %{buildroot}/%{_sysconfdir}/%{pname}/slurm.conf%{?OHPC_BUILD:.example} -install -D -m644 etc/slurmdbd.conf.example %{buildroot}/%{_sysconfdir}/%{pname}/slurmdbd.conf -install -D -m644 etc/slurmdbd.conf.example %{buildroot}%{_sysconfdir}/%{pname}/slurmdbd.conf.example +install -D -m600 etc/slurmdbd.conf.example %{buildroot}/%{_sysconfdir}/%{pname}/slurmdbd.conf +install -D -m600 etc/slurmdbd.conf.example %{buildroot}%{_sysconfdir}/%{pname}/slurmdbd.conf.example install -D -m755 contribs/sjstat %{buildroot}%{_bindir}/sjstat install -D -m755 contribs/sgather/sgather %{buildroot}%{_bindir}/sgather @@ -544,11 +573,13 @@ sed -i 's#^\(SlurmdPidFile=\).*$#\1%{_localstatedir}/run/slurm/slurmd.pid#' %{buildroot}/%{_sysconfdir}/%{pname}/slurm.conf sed -i 's#^\(SlurmctldPidFile=\).*$#\1%{_localstatedir}/run/slurm/slurmctld.pid#' %{buildroot}/%{_sysconfdir}/%{pname}/slurm.conf sed -i 's#^\(SlurmdSpoolDir=\)/.*#\1%{_localstatedir}/spool/slurm#' %{buildroot}/%{_sysconfdir}/%{pname}/slurm.conf +%if 0%{?upgrade} || 0%{suse_version} > 1501 sed -i -e '/^ControlMachine=/i# Ordered List of Control Nodes' \ -e 's#ControlMachine=\(.*\)$#SlurmctldHost=\1(10.0.10.20)#' \ -e 's#BackupController=.*#SlurmctldHost=linux1(10.0.10.21)#' \ -e '/.*ControlAddr=.*/d' \ -e '/.*BackupAddr=.*/d' %{buildroot}/%{_sysconfdir}/%{pname}/slurm.conf +%endif cat >>%{buildroot}/%{_sysconfdir}/%{pname}/slurm.conf <<EOF # SUSE default configuration PropagateResourceLimitsExcept=MEMLOCK @@ -644,9 +675,27 @@ } EOF done +mkdir -p %{buildroot}/%{apache_sysconfdir}/conf.d +cat > %{buildroot}/%{apache_sysconfdir}/conf.d/slurm.conf <<EOF +Alias /slurm/ "/usr/share/doc/slurm-%{ver}/html/" +<Directory "/usr/share/doc/slurm-%{ver}/html/"> + AllowOverride None + DirectoryIndex slurm.html + # Controls who can get stuff from this server. + <IfModule !mod_access_compat.c> + Require all granted + </IfModule> + <IfModule mod_access_compat.c> + Order allow,deny + Allow from all + </IfModule> +</Directory> +EOF %fdupes -s %{buildroot} +%define fixperm() [ $1 -eq 1 -a -e %2 ] && /bin/chmod %1 %2 + %pre %if 0%{?with_systemd} %service_add_pre slurmctld.service @@ -677,6 +726,8 @@ %endif %post slurmdbd +%{fixperm 0600 %{_sysconfdir}/%{pname}/slurmdbd.conf} +%{fixperm 0600 %{_sysconfdir}/%{pname}/slurmdbd.conf.example} %if 0%{?with_systemd} %service_add_post slurmdbd.service %else @@ -691,6 +742,8 @@ %endif %postun slurmdbd +%{fixperm 0600 %{_sysconfdir}/%{pname}/slurmdbd.conf} +%{fixperm 0600 %{_sysconfdir}/%{pname}/slurmdbd.conf.example} %if 0%{?with_systemd} %service_del_postun -n slurmdbd.service %else @@ -728,6 +781,7 @@ %define slurmdescr "SLURM workload manager" getent group %slurm_g >/dev/null || groupadd -r %slurm_g getent passwd %slurm_u >/dev/null || useradd -r -g %slurm_g -d %slurmdir -s /bin/false -c %{slurmdescr} %slurm_u +[ -d %{_localstatedir}/spool/slurm ] && /bin/chown -h %slurm_u:%slurm_g %{_localstatedir}/spool/slurm exit 0 %post config @@ -742,8 +796,8 @@ %post -n %{libslurm} -p /sbin/ldconfig %postun -n %{libslurm} -p /sbin/ldconfig -%post -n libpmi%{pmi_so} -p /sbin/ldconfig -%postun -n libpmi%{pmi_so} -p /sbin/ldconfig +%post -n libpmi%{pmi_so}%{?upgrade:%{_ver}} -p /sbin/ldconfig +%postun -n libpmi%{pmi_so}%{?upgrade:%{_ver}} -p /sbin/ldconfig %{!?nil: # On update the %%postun code of the old package restarts the @@ -768,8 +822,12 @@ %define _rest() %{?with_systemd:[ -e /run/%{1}.rst ] && { systemctl status %{1} &>/dev/null || systemctl restart %{1}; }; rm -f /run/%{1}.rst;} %{!?nil: # Until a posttrans macro has been added to macros.systemd, we need this +# Do NOT delete the line breaks in the macro definition: they help +# to cope with different versions of the %_restart_on_update. +} +%define _res_update() %{?with_systemd: + %{expand:%%_restart_on_update %{?*}} } -%define _res_update() %{?with_systemd:%{expand:%%_restart_on_update %{?*}};} %pretrans -p <lua> %_test_rest slurmctld @@ -817,7 +875,6 @@ %{_bindir}/sprio %{_bindir}/squeue %{_bindir}/sreport -%{_bindir}/srun %{_bindir}/smap %{_bindir}/sshare %{_bindir}/sstat @@ -846,7 +903,6 @@ %{_mandir}/man1/sprio.1* %{_mandir}/man1/squeue.1* %{_mandir}/man1/sreport.1* -%{_mandir}/man1/srun.1* %{_mandir}/man1/sshare.1* %{_mandir}/man1/sstat.1* %{_mandir}/man1/strigger.1* @@ -872,11 +928,15 @@ %dir %{_datadir}/doc/%{pname}-%{dl_ver} %{_datadir}/doc/%{pname}-%{dl_ver}/* +%files webdoc +%{?comp_at} +%{apache_sysconfdir}/conf.d/slurm.conf + %files -n %{libslurm} %{?comp_at} %{_libdir}/libslurm*.so.%{so_version}* -%files -n libpmi%{pmi_so} +%files -n libpmi%{pmi_so}%{?upgrade:%{_ver}} %{?comp_at} %{_libdir}/libpmi*.so.%{pmi_so}* @@ -919,8 +979,8 @@ %{_sbindir}/slurmdbd %{_mandir}/man5/slurmdbd.* %{_mandir}/man8/slurmdbd.* -%config(noreplace) %{_sysconfdir}/%{pname}/slurmdbd.conf -%{_sysconfdir}/%{pname}/slurmdbd.conf.example +%config(noreplace) %attr(0600,%slurm_u,%slurm_g) %{_sysconfdir}/%{pname}/slurmdbd.conf +%attr(0600,%slurm_u,%slurm_g) %{_sysconfdir}/%{pname}/slurmdbd.conf.example %if 0%{?with_systemd} %{_unitdir}/slurmdbd.service %else @@ -983,6 +1043,10 @@ %{_libdir}/slurm/mpi_none.so %{_libdir}/slurm/mpi_openmpi.so %{_libdir}/slurm/mpi_pmi2.so +%if %{with pmix} +%{_libdir}/slurm/mpi_pmix.so +%{_libdir}/slurm/mpi_pmix_v3.so +%endif %{_libdir}/slurm/power_none.so %{_libdir}/slurm/preempt_none.so %{_libdir}/slurm/preempt_partition_prio.so @@ -1068,6 +1132,9 @@ %{?comp_at} %{_sbindir}/slurmd %{_sbindir}/slurmstepd +# bsc#1153095 +%{_bindir}/srun +%{_mandir}/man1/srun.1* %{_mandir}/man8/slurmd.* %{_mandir}/man8/slurmstepd* %if 0%{?with_systemd} @@ -1090,7 +1157,7 @@ %config(noreplace) %{_sysconfdir}/%{pname}/layouts.d/unit.conf.example %{?OHPC_BUILD:%attr(0755, %slurm_u, %slurm_g) %_localstatedir/lib/slurm} %{?with_systemd:%{_tmpfilesdir}/%{pname}.conf} -%dir %{_var}/spool/slurm +%dir %attr(0755, %slurm_u, %slurm_g)%{_localstatedir}/spool/slurm %config(noreplace) %{_sysconfdir}/logrotate.d/slurm* %files config-man ++++++ slurm-18.08.8.tar.bz2 -> slurm-18.08.9.tar.bz2 ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/META new/slurm-18.08.9/META --- old/slurm-18.08.8/META 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/META 2019-12-20 21:33:14.000000000 +0100 @@ -7,8 +7,8 @@ Name: slurm Major: 18 Minor: 08 - Micro: 8 - Version: 18.08.8 + Micro: 9 + Version: 18.08.9 Release: 1 ## diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/NEWS new/slurm-18.08.9/NEWS --- old/slurm-18.08.8/NEWS 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/NEWS 2019-12-20 21:33:14.000000000 +0100 @@ -1,6 +1,15 @@ This file describes changes in recent versions of Slurm. It primarily documents those changes that are of interest to users and administrators. +* Changes in Slurm 18.08.9 +========================== + -- Wrap END_TIMER{,2,3} macro definition in "do {} while (0)" block. + -- Make sview work with glib2 v2.62. + -- Make Slurm compile on linux after sys/sysctl.h was deprecated. + -- Install slurmdbd.conf.example with 0600 permissions to encourage secure + use. CVE-2019-19727. + -- srun - do not continue with job launch if --uid fails. CVE-2019-19728. + * Changes in Slurm 18.08.8 ========================== -- Update "xauth list" to use the same 10000ms timeout as the other xauth diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/contribs/slurm.spec-legacy new/slurm-18.08.9/contribs/slurm.spec-legacy --- old/slurm-18.08.8/contribs/slurm.spec-legacy 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/contribs/slurm.spec-legacy 2019-12-20 21:33:14.000000000 +0100 @@ -2,7 +2,7 @@ # DEPRECATED, NOT MAINTAINED, WILL BE REMOVED IN A FUTURE RELEASE. Name: slurm -Version: 18.08.8 +Version: 18.08.9 %define rel 1 Release: %{rel}%{?dist} Summary: Slurm Workload Manager @@ -471,7 +471,7 @@ install -D -m644 etc/layouts.d.power_cpufreq.conf.example ${RPM_BUILD_ROOT}%{_sysconfdir}/layouts.d/power_cpufreq.conf.example install -D -m644 etc/layouts.d.unit.conf.example ${RPM_BUILD_ROOT}%{_sysconfdir}/layouts.d/unit.conf.example install -D -m644 etc/slurm.conf.example ${RPM_BUILD_ROOT}%{_sysconfdir}/slurm.conf.example -install -D -m644 etc/slurmdbd.conf.example ${RPM_BUILD_ROOT}%{_sysconfdir}/slurmdbd.conf.example +install -D -m600 etc/slurmdbd.conf.example ${RPM_BUILD_ROOT}%{_sysconfdir}/slurmdbd.conf.example install -D -m755 contribs/sjstat ${RPM_BUILD_ROOT}%{_bindir}/sjstat # Delete unpackaged files: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/doc/man/man1/sbatch.1 new/slurm-18.08.9/doc/man/man1/sbatch.1 --- old/slurm-18.08.8/doc/man/man1/sbatch.1 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/doc/man/man1/sbatch.1 2019-12-20 21:33:14.000000000 +0100 @@ -587,6 +587,9 @@ task environment variables are always exported to the environment. This option is particularly important for jobs that are submitted on one cluster and execute on a different cluster (e.g. with different paths). +To avoid steps inheriting environment export settings (e.g. \fINONE\fR) from +sbatch command, the environment variable SLURM_EXPORT_ENV should be set to +\fIALL\fR in the job script. .TP \fB\-\-export\-file\fR=<\fIfilename\fR | \fIfd\fR> @@ -1953,6 +1956,9 @@ \fBSLURM_DISTRIBUTION\fR Same as \fB\-m, \-\-distribution\fR .TP +\fBSLURM_EXPORT_ENV\fR +Same as \fB\-e, \-\-export\fR. +.TP \fBSLURM_GTIDS\fR Global task IDs running on this node. Zero origin and comma separated. .TP diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/doc/man/man1/srun.1 new/slurm-18.08.9/doc/man/man1/srun.1 --- old/slurm-18.08.8/doc/man/man1/srun.1 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/doc/man/man1/srun.1 2019-12-20 21:33:14.000000000 +0100 @@ -2468,6 +2468,9 @@ various Slurm error conditions. Also see \fBSLURM_EXIT_ERROR\fR. .TP +\fBSLURM_EXPORT_ENV\fR +Same as \fB\-e, \-\-export\fR. +.TP \fBSLURM_GRES_FLAGS\fR Same as \-\-gres\-flags\fR .TP diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/slurm.spec new/slurm-18.08.9/slurm.spec --- old/slurm-18.08.8/slurm.spec 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/slurm.spec 2019-12-20 21:33:14.000000000 +0100 @@ -1,5 +1,5 @@ Name: slurm -Version: 18.08.8 +Version: 18.08.9 %define rel 1 Release: %{rel}%{?dist} Summary: Slurm Workload Manager @@ -364,7 +364,7 @@ install -D -m644 etc/layouts.d.power_cpufreq.conf.example %{buildroot}/%{_sysconfdir}/layouts.d/power_cpufreq.conf.example install -D -m644 etc/layouts.d.unit.conf.example %{buildroot}/%{_sysconfdir}/layouts.d/unit.conf.example install -D -m644 etc/slurm.conf.example %{buildroot}/%{_sysconfdir}/slurm.conf.example -install -D -m644 etc/slurmdbd.conf.example %{buildroot}/%{_sysconfdir}/slurmdbd.conf.example +install -D -m600 etc/slurmdbd.conf.example %{buildroot}/%{_sysconfdir}/slurmdbd.conf.example install -D -m755 contribs/sjstat %{buildroot}/%{_bindir}/sjstat # Delete unpackaged files: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/src/common/slurm_protocol_defs.h new/slurm-18.08.9/src/common/slurm_protocol_defs.h --- old/slurm-18.08.8/src/common/slurm_protocol_defs.h 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/src/common/slurm_protocol_defs.h 2019-12-20 21:33:14.000000000 +0100 @@ -44,6 +44,15 @@ #include <inttypes.h> #include <sys/wait.h> +#ifdef HAVE_SYSCTLBYNAME +#if defined(__FreeBSD__) +#include <sys/types.h> +#else +#include <sys/param.h> +#endif +# include <sys/sysctl.h> +#endif + #include "slurm/slurm.h" #include "slurm/slurmdb.h" #include "src/common/bitstring.h" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/src/common/timers.h new/slurm-18.08.9/src/common/timers.h --- old/slurm-18.08.8/src/common/timers.h 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/src/common/timers.h 2019-12-20 21:33:14.000000000 +0100 @@ -43,12 +43,18 @@ #define DEF_TIMERS struct timeval tv1, tv2; char tv_str[20] = ""; long delta_t; #define START_TIMER gettimeofday(&tv1, NULL) -#define END_TIMER gettimeofday(&tv2, NULL); \ - slurm_diff_tv_str(&tv1, &tv2, tv_str, 20, NULL, 0, &delta_t) -#define END_TIMER2(from) gettimeofday(&tv2, NULL); \ - slurm_diff_tv_str(&tv1, &tv2, tv_str, 20, from, 0, &delta_t) -#define END_TIMER3(from, limit) gettimeofday(&tv2, NULL); \ - slurm_diff_tv_str(&tv1, &tv2, tv_str, 20, from, limit, &delta_t) +#define END_TIMER do { \ + gettimeofday(&tv2, NULL); \ + slurm_diff_tv_str(&tv1, &tv2, tv_str, 20, NULL, 0, &delta_t); \ +} while (0) +#define END_TIMER2(from) do { \ + gettimeofday(&tv2, NULL); \ + slurm_diff_tv_str(&tv1, &tv2, tv_str, 20, from, 0, &delta_t); \ +} while (0) +#define END_TIMER3(from, limit) do { \ + gettimeofday(&tv2, NULL); \ + slurm_diff_tv_str(&tv1, &tv2, tv_str, 20, from, limit, &delta_t); \ +} while (0) #define DELTA_TIMER delta_t #define TIME_STR tv_str diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/src/plugins/task/affinity/affinity.c new/slurm-18.08.9/src/plugins/task/affinity/affinity.c --- old/slurm-18.08.8/src/plugins/task/affinity/affinity.c 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/src/plugins/task/affinity/affinity.c 2019-12-20 21:33:14.000000000 +0100 @@ -226,19 +226,13 @@ return false; } -/* For sysctl() functions */ -#if defined(__FreeBSD__) || defined(__NetBSD__) -#include <sys/types.h> -#include <sys/sysctl.h> -#endif - #define BUFFLEN 127 /* Return true if Power7 processor */ static bool _is_power_cpu(void) { if (is_power == -1) { -#if defined(__FreeBSD__) || defined(__NetBSD__) +#ifdef HAVE_SYSCTLBYNAME char buffer[BUFFLEN+1]; size_t len = BUFFLEN; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/src/slurmd/slurmd/get_mach_stat.c new/slurm-18.08.9/src/slurmd/slurmd/get_mach_stat.c --- old/slurm-18.08.8/src/slurmd/slurmd/get_mach_stat.c 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/src/slurmd/slurmd/get_mach_stat.c 2019-12-20 21:33:14.000000000 +0100 @@ -49,13 +49,6 @@ # include <sys/dr.h> #endif -#ifdef HAVE_SYS_SYSCTL_H -#if defined(__FreeBSD__) -#include <sys/types.h> -#endif -# include <sys/sysctl.h> -#endif - #include <errno.h> #include <fcntl.h> #include <stdio.h> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/src/srun/libsrun/srun_job.c new/slurm-18.08.9/src/srun/libsrun/srun_job.c --- old/slurm-18.08.8/src/srun/libsrun/srun_job.c 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/src/srun/libsrun/srun_job.c 2019-12-20 21:33:14.000000000 +0100 @@ -1286,7 +1286,7 @@ * Become --uid user */ if (_become_user () < 0) - info("Warning: Unable to assume uid=%u", opt.uid); + fatal("Unable to assume uid=%u", opt.uid); if (_create_job_step(job, true, srun_job_list, pack_jobid, pack_nodelist) < 0) { slurm_complete_job(my_job_id, 1); @@ -1312,7 +1312,7 @@ * Become --uid user */ if (_become_user () < 0) - info("Warning: Unable to assume uid=%u", opt.uid); + fatal("Unable to assume uid=%u", opt.uid); if (!slurm_started) { /* @@ -1587,7 +1587,9 @@ return (error ("setgid: %m")); } - (void) initgroups(user, gid); /* Ignore errors */ + if (initgroups(user, gid)) + return (error ("initgroups: %m")); + xfree(user); if (setuid (opt.uid) < 0) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/src/sview/Makefile.am new/slurm-18.08.9/src/sview/Makefile.am --- old/slurm-18.08.8/src/sview/Makefile.am 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/src/sview/Makefile.am 2019-12-20 21:33:14.000000000 +0100 @@ -21,7 +21,7 @@ @cd `dirname $@` && $(MAKE) `basename $@` sview_LDFLAGS = -export-dynamic $(CMD_LDFLAGS) $(BG_LDFLAGS) $(GTK_LIBS) -sview_CFLAGS = $(GTK_CFLAGS) +sview_CFLAGS = $(GTK_CFLAGS) -DGTK_DISABLE_DEPRECATED else diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/src/sview/Makefile.in new/slurm-18.08.9/src/sview/Makefile.in --- old/slurm-18.08.8/src/sview/Makefile.in 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/src/sview/Makefile.in 2019-12-20 21:33:14.000000000 +0100 @@ -524,7 +524,7 @@ @BUILD_SVIEW_TRUE@ config_info.c defaults.c gthread_helper.c bb_info.c @BUILD_SVIEW_TRUE@sview_LDFLAGS = -export-dynamic $(CMD_LDFLAGS) $(BG_LDFLAGS) $(GTK_LIBS) -@BUILD_SVIEW_TRUE@sview_CFLAGS = $(GTK_CFLAGS) +@BUILD_SVIEW_TRUE@sview_CFLAGS = $(GTK_CFLAGS) -DGTK_DISABLE_DEPRECATED @BUILD_SVIEW_FALSE@EXTRA_sview_SOURCES = sview.h sview.c popups.c grid.c part_info.c job_info.c \ @BUILD_SVIEW_FALSE@ front_end_info.c node_info.c resv_info.c gthread_helper.c \ @BUILD_SVIEW_FALSE@ submit_info.c admin_info.c common.c config_info.c defaults.c diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/src/sview/bb_info.c new/slurm-18.08.9/src/sview/bb_info.c --- old/slurm-18.08.8/src/sview/bb_info.c 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/src/sview/bb_info.c 2019-12-20 21:33:14.000000000 +0100 @@ -534,7 +534,7 @@ treeview = create_treeview_2cols_attach_to_table( popup_win->table); spec_info->display_widget = - gtk_widget_ref(GTK_WIDGET(treeview)); + g_object_ref(GTK_WIDGET(treeview)); } else { treeview = GTK_TREE_VIEW(spec_info->display_widget); update = 1; @@ -695,7 +695,7 @@ label = gtk_label_new("Not available in a federated view"); gtk_table_attach_defaults(GTK_TABLE(table), label, 0, 1, 0, 1); gtk_widget_show(label); - display_widget = gtk_widget_ref(label); + display_widget = g_object_ref(label); goto end_it; } @@ -719,7 +719,7 @@ label = gtk_label_new(error_char); gtk_table_attach_defaults(table, label, 0, 1, 0, 1); gtk_widget_show(label); - display_widget = gtk_widget_ref(GTK_WIDGET(label)); + display_widget = g_object_ref(GTK_WIDGET(label)); goto end_it; } @@ -754,7 +754,7 @@ gtk_tree_selection_set_mode( gtk_tree_view_get_selection(tree_view), GTK_SELECTION_MULTIPLE); - display_widget = gtk_widget_ref(GTK_WIDGET(tree_view)); + display_widget = g_object_ref(GTK_WIDGET(tree_view)); gtk_table_attach_defaults(table, GTK_WIDGET(tree_view), 0, 1, 0, 1); @@ -821,7 +821,7 @@ label, 0, 1, 0, 1); gtk_widget_show(label); - spec_info->display_widget = gtk_widget_ref(label); + spec_info->display_widget = g_object_ref(label); goto end_it; } @@ -842,7 +842,7 @@ gtk_tree_view_get_selection(tree_view), GTK_SELECTION_MULTIPLE); spec_info->display_widget = - gtk_widget_ref(GTK_WIDGET(tree_view)); + g_object_ref(GTK_WIDGET(tree_view)); gtk_table_attach_defaults(popup_win->table, GTK_WIDGET(tree_view), 0, 1, 0, 1); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/src/sview/common.c new/slurm-18.08.9/src/sview/common.c --- old/slurm-18.08.8/src/sview/common.c 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/src/sview/common.c 2019-12-20 21:33:14.000000000 +0100 @@ -1004,8 +1004,8 @@ { GtkTreeView *tree_view = GTK_TREE_VIEW(gtk_tree_view_new()); GtkTreeStore *treestore = - gtk_tree_store_new(3, GTK_TYPE_STRING, - GTK_TYPE_STRING, GTK_TYPE_STRING); + gtk_tree_store_new(3, G_TYPE_STRING, + G_TYPE_STRING, G_TYPE_STRING); GtkTreeViewColumn *col = gtk_tree_view_column_new(); GtkCellRenderer *renderer = gtk_cell_renderer_text_new(); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/src/sview/front_end_info.c new/slurm-18.08.9/src/sview/front_end_info.c --- old/slurm-18.08.8/src/sview/front_end_info.c 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/src/sview/front_end_info.c 2019-12-20 21:33:14.000000000 +0100 @@ -441,7 +441,7 @@ treeview = create_treeview_2cols_attach_to_table( popup_win->table); spec_info->display_widget = - gtk_widget_ref(GTK_WIDGET(treeview)); + g_object_ref(GTK_WIDGET(treeview)); } else { treeview = GTK_TREE_VIEW(spec_info->display_widget); update = 1; @@ -654,7 +654,7 @@ label = gtk_label_new("Not available in a federated view"); gtk_table_attach_defaults(GTK_TABLE(table), label, 0, 1, 0, 1); gtk_widget_show(label); - display_widget = gtk_widget_ref(label); + display_widget = g_object_ref(label); goto end_it; } @@ -678,7 +678,7 @@ label = gtk_label_new(error_char); gtk_table_attach_defaults(table, label, 0, 1, 0, 1); gtk_widget_show(label); - display_widget = gtk_widget_ref(GTK_WIDGET(label)); + display_widget = g_object_ref(GTK_WIDGET(label)); goto end_it; } @@ -730,7 +730,7 @@ gtk_tree_selection_set_mode( gtk_tree_view_get_selection(tree_view), GTK_SELECTION_MULTIPLE); - display_widget = gtk_widget_ref(GTK_WIDGET(tree_view)); + display_widget = g_object_ref(GTK_WIDGET(tree_view)); gtk_table_attach_defaults(table, GTK_WIDGET(tree_view), 0, 1, 0, 1); @@ -798,7 +798,7 @@ label, 0, 1, 0, 1); gtk_widget_show(label); - spec_info->display_widget = gtk_widget_ref(label); + spec_info->display_widget = g_object_ref(label); goto end_it; } @@ -820,7 +820,7 @@ gtk_tree_view_get_selection(tree_view), GTK_SELECTION_MULTIPLE); spec_info->display_widget = - gtk_widget_ref(GTK_WIDGET(tree_view)); + g_object_ref(GTK_WIDGET(tree_view)); gtk_table_attach_defaults(popup_win->table, GTK_WIDGET(tree_view), 0, 1, 0, 1); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/src/sview/grid.c new/slurm-18.08.9/src/sview/grid.c --- old/slurm-18.08.8/src/sview/grid.c 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/src/sview/grid.c 2019-12-20 21:33:14.000000000 +0100 @@ -78,14 +78,12 @@ bool force_row_break; } button_processor_t; -GStaticMutex blinking_mutex = G_STATIC_MUTEX_INIT; - static gboolean _mouseover_node(GtkWidget *widget, GdkEventButton *event, grid_button_t *grid_button) { gboolean rc = true; - grid_button->last_state = GTK_WIDGET_STATE(widget); + grid_button->last_state = gtk_widget_get_state(widget); #ifdef GTK2_USE_TOOLTIP gtk_widget_set_tooltip_text(grid_button->button, grid_button->node_name); @@ -392,7 +390,7 @@ sview_colors[color_inx], color, 0, 0); - if (GTK_WIDGET_STATE(grid_button->button) != GTK_STATE_NORMAL) + if (gtk_widget_get_state(grid_button->button) != GTK_STATE_NORMAL) gtk_widget_set_state(grid_button->button, GTK_STATE_NORMAL); @@ -432,7 +430,7 @@ * (previously this assumed only one selected). */ if (grid_button->inx != node_inx) continue; - else if (GTK_WIDGET_STATE(grid_button->button) + else if (gtk_widget_get_state(grid_button->button) != GTK_STATE_NORMAL) { gtk_widget_set_state(grid_button->button, GTK_STATE_NORMAL); @@ -1055,7 +1053,7 @@ itr = list_iterator_create(button_list); while ((grid_button = list_next(itr))) { /* clear everyone */ - if ((GTK_WIDGET_STATE(grid_button->button) + if ((gtk_widget_get_state(grid_button->button) != GTK_STATE_ACTIVE)) { gtk_widget_set_state(grid_button->button, GTK_STATE_ACTIVE); @@ -1096,7 +1094,7 @@ if ((grid_button->inx < start) || (grid_button->inx > end)) { /* clear everyone else */ - if ((GTK_WIDGET_STATE(grid_button->button) + if ((gtk_widget_get_state(grid_button->button) != GTK_STATE_ACTIVE)) gtk_widget_set_state( grid_button->button, @@ -1106,7 +1104,7 @@ /* highlight this one, if it is already hightlighted, * put it back to normal */ //g_print("highlighting %d\n", grid_button->inx); - if ((GTK_WIDGET_STATE(grid_button->button) + if ((gtk_widget_get_state(grid_button->button) != GTK_STATE_NORMAL)) gtk_widget_set_state(grid_button->button, GTK_STATE_NORMAL); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/src/sview/job_info.c new/slurm-18.08.9/src/sview/job_info.c --- old/slurm-18.08.8/src/sview/job_info.c 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/src/sview/job_info.c 2019-12-20 21:33:14.000000000 +0100 @@ -3251,7 +3251,7 @@ treeview = create_treeview_2cols_attach_to_table( popup_win->table); spec_info->display_widget = - gtk_widget_ref(GTK_WIDGET(treeview)); + g_object_ref(GTK_WIDGET(treeview)); } else { treeview = GTK_TREE_VIEW(spec_info->display_widget); update = 1; @@ -3799,7 +3799,7 @@ label = gtk_label_new(error_char); gtk_table_attach_defaults(table, label, 0, 1, 0, 1); gtk_widget_show(label); - display_widget = gtk_widget_ref(GTK_WIDGET(label)); + display_widget = g_object_ref(GTK_WIDGET(label)); goto end_it; } @@ -3820,7 +3820,7 @@ label = gtk_label_new(error_char); gtk_table_attach_defaults(table, label, 0, 1, 0, 1); gtk_widget_show(label); - display_widget = gtk_widget_ref(GTK_WIDGET(label)); + display_widget = g_object_ref(GTK_WIDGET(label)); goto end_it; } display_it: @@ -3893,7 +3893,7 @@ gtk_tree_selection_set_mode( gtk_tree_view_get_selection(tree_view), GTK_SELECTION_MULTIPLE); - display_widget = gtk_widget_ref(GTK_WIDGET(tree_view)); + display_widget = g_object_ref(GTK_WIDGET(tree_view)); gtk_table_attach_defaults(GTK_TABLE(table), GTK_WIDGET(tree_view), 0, 1, 0, 1); @@ -3972,7 +3972,7 @@ label, 0, 1, 0, 1); gtk_widget_show(label); - spec_info->display_widget = gtk_widget_ref(GTK_WIDGET(label)); + spec_info->display_widget = g_object_ref(GTK_WIDGET(label)); goto end_it; } @@ -3995,7 +3995,7 @@ gtk_table_attach_defaults(popup_win->table, label, 0, 1, 0, 1); gtk_widget_show(label); - spec_info->display_widget = gtk_widget_ref(GTK_WIDGET(label)); + spec_info->display_widget = g_object_ref(GTK_WIDGET(label)); goto end_it; } display_it: @@ -4016,7 +4016,7 @@ gtk_tree_view_get_selection(tree_view), GTK_SELECTION_MULTIPLE); spec_info->display_widget = - gtk_widget_ref(GTK_WIDGET(tree_view)); + g_object_ref(GTK_WIDGET(tree_view)); gtk_table_attach_defaults(popup_win->table, GTK_WIDGET(tree_view), 0, 1, 0, 1); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/src/sview/node_info.c new/slurm-18.08.9/src/sview/node_info.c --- old/slurm-18.08.8/src/sview/node_info.c 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/src/sview/node_info.c 2019-12-20 21:33:14.000000000 +0100 @@ -706,7 +706,7 @@ treeview = create_treeview_2cols_attach_to_table( popup_win->table); spec_info->display_widget = - gtk_widget_ref(GTK_WIDGET(treeview)); + g_object_ref(GTK_WIDGET(treeview)); } else { treeview = GTK_TREE_VIEW(spec_info->display_widget); update = 1; @@ -1564,7 +1564,7 @@ sprintf(error_char, "slurm_load_node: %s", slurm_strerror(slurm_get_errno())); label = gtk_label_new(error_char); - display_widget = gtk_widget_ref(label); + display_widget = g_object_ref(label); gtk_table_attach_defaults(table, label, 0, 1, 0, 1); gtk_widget_show(label); goto end_it; @@ -1617,7 +1617,7 @@ gtk_tree_selection_set_mode( gtk_tree_view_get_selection(tree_view), GTK_SELECTION_MULTIPLE); - display_widget = gtk_widget_ref(GTK_WIDGET(tree_view)); + display_widget = g_object_ref(GTK_WIDGET(tree_view)); gtk_table_attach_defaults(GTK_TABLE(table), GTK_WIDGET(tree_view), 0, 1, 0, 1); @@ -1700,7 +1700,7 @@ label, 0, 1, 0, 1); gtk_widget_show(label); - spec_info->display_widget = gtk_widget_ref(label); + spec_info->display_widget = g_object_ref(label); return; } display_it: @@ -1722,7 +1722,7 @@ gtk_tree_view_get_selection(tree_view), GTK_SELECTION_MULTIPLE); spec_info->display_widget = - gtk_widget_ref(GTK_WIDGET(tree_view)); + g_object_ref(GTK_WIDGET(tree_view)); gtk_table_attach_defaults(popup_win->table, GTK_WIDGET(tree_view), 0, 1, 0, 1); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/src/sview/part_info.c new/slurm-18.08.9/src/sview/part_info.c --- old/slurm-18.08.8/src/sview/part_info.c 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/src/sview/part_info.c 2019-12-20 21:33:14.000000000 +0100 @@ -1926,7 +1926,7 @@ treeview = create_treeview_2cols_attach_to_table( popup_win->table); spec_info->display_widget = - gtk_widget_ref(GTK_WIDGET(treeview)); + g_object_ref(GTK_WIDGET(treeview)); } else { treeview = GTK_TREE_VIEW(spec_info->display_widget); update = 1; @@ -2508,7 +2508,7 @@ snprintf(error_char, 100, "slurm_load_partitions: %s", slurm_strerror(slurm_get_errno())); label = gtk_label_new(error_char); - display_widget = gtk_widget_ref(GTK_WIDGET(label)); + display_widget = g_object_ref(GTK_WIDGET(label)); gtk_table_attach_defaults(table, label, 0, 1, 0, 1); gtk_widget_show(label); goto end_it; @@ -2528,7 +2528,7 @@ snprintf(error_char, 100, "slurm_load_node: %s", slurm_strerror(slurm_get_errno())); label = gtk_label_new(error_char); - display_widget = gtk_widget_ref(GTK_WIDGET(label)); + display_widget = g_object_ref(GTK_WIDGET(label)); gtk_table_attach_defaults(table, label, 0, 1, 0, 1); gtk_widget_show(label); goto end_it; @@ -2594,7 +2594,7 @@ gtk_tree_selection_set_mode( gtk_tree_view_get_selection(tree_view), GTK_SELECTION_MULTIPLE); - display_widget = gtk_widget_ref(GTK_WIDGET(tree_view)); + display_widget = g_object_ref(GTK_WIDGET(tree_view)); gtk_table_attach_defaults(table, GTK_WIDGET(tree_view), 0, 1, 0, 1); @@ -2660,7 +2660,7 @@ snprintf(error_char, 100, "slurm_load_partitions: %s", slurm_strerror(slurm_get_errno())); label = gtk_label_new(error_char); - spec_info->display_widget = gtk_widget_ref(GTK_WIDGET(label)); + spec_info->display_widget = g_object_ref(GTK_WIDGET(label)); gtk_table_attach_defaults(popup_win->table, label, 0, 1, 0, 1); gtk_widget_show(label); goto end_it; @@ -2682,7 +2682,7 @@ snprintf(error_char, 100, "slurm_load_node: %s", slurm_strerror(slurm_get_errno())); label = gtk_label_new(error_char); - spec_info->display_widget = gtk_widget_ref(GTK_WIDGET(label)); + spec_info->display_widget = g_object_ref(GTK_WIDGET(label)); gtk_table_attach_defaults(popup_win->table, label, 0, 1, 0, 1); gtk_widget_show(label); goto end_it; @@ -2709,7 +2709,7 @@ GTK_SELECTION_MULTIPLE); spec_info->display_widget = - gtk_widget_ref(GTK_WIDGET(tree_view)); + g_object_ref(GTK_WIDGET(tree_view)); gtk_table_attach_defaults(popup_win->table, GTK_WIDGET(tree_view), 0, 1, 0, 1); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/src/sview/resv_info.c new/slurm-18.08.9/src/sview/resv_info.c --- old/slurm-18.08.8/src/sview/resv_info.c 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/src/sview/resv_info.c 2019-12-20 21:33:14.000000000 +0100 @@ -814,7 +814,7 @@ treeview = create_treeview_2cols_attach_to_table( popup_win->table); spec_info->display_widget = - gtk_widget_ref(GTK_WIDGET(treeview)); + g_object_ref(GTK_WIDGET(treeview)); } else { treeview = GTK_TREE_VIEW(spec_info->display_widget); update = 1; @@ -1128,7 +1128,7 @@ label = gtk_label_new("Not available in a federated view"); gtk_table_attach_defaults(GTK_TABLE(table), label, 0, 1, 0, 1); gtk_widget_show(label); - display_widget = gtk_widget_ref(label); + display_widget = g_object_ref(label); goto end_it; } @@ -1151,7 +1151,7 @@ label = gtk_label_new(error_char); gtk_table_attach_defaults(table, label, 0, 1, 0, 1); gtk_widget_show(label); - display_widget = gtk_widget_ref(GTK_WIDGET(label)); + display_widget = g_object_ref(GTK_WIDGET(label)); goto end_it; } @@ -1207,7 +1207,7 @@ gtk_tree_selection_set_mode( gtk_tree_view_get_selection(tree_view), GTK_SELECTION_MULTIPLE); - display_widget = gtk_widget_ref(GTK_WIDGET(tree_view)); + display_widget = g_object_ref(GTK_WIDGET(tree_view)); gtk_table_attach_defaults(table, GTK_WIDGET(tree_view), 0, 1, 0, 1); @@ -1274,7 +1274,7 @@ label, 0, 1, 0, 1); gtk_widget_show(label); - spec_info->display_widget = gtk_widget_ref(label); + spec_info->display_widget = g_object_ref(label); goto end_it; } @@ -1296,7 +1296,7 @@ gtk_tree_view_get_selection(tree_view), GTK_SELECTION_MULTIPLE); spec_info->display_widget = - gtk_widget_ref(GTK_WIDGET(tree_view)); + g_object_ref(GTK_WIDGET(tree_view)); gtk_table_attach_defaults(popup_win->table, GTK_WIDGET(tree_view), 0, 1, 0, 1); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/src/sview/sview.c new/slurm-18.08.9/src/sview/sview.c --- old/slurm-18.08.8/src/sview/sview.c 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/src/sview/sview.c 2019-12-20 21:33:14.000000000 +0100 @@ -259,7 +259,7 @@ } static void _page_switched(GtkNotebook *notebook, - GtkNotebookPage *page, + GtkNotebookTab *page, guint page_num, gpointer user_data) { diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/testsuite/expect/globals new/slurm-18.08.9/testsuite/expect/globals --- old/slurm-18.08.8/testsuite/expect/globals 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/testsuite/expect/globals 2019-12-20 21:33:14.000000000 +0100 @@ -1786,7 +1786,7 @@ set user [get_my_user_name] } - spawn $sacctmgr -n list user $user format="DefaultAccount" + spawn $sacctmgr -n list -P user $user format="DefaultAccount" expect { -re "($alpha_numeric_under)" { set def_acct $expect_out(1,string) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/testsuite/expect/regression.py new/slurm-18.08.9/testsuite/expect/regression.py --- old/slurm-18.08.8/testsuite/expect/regression.py 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/testsuite/expect/regression.py 2019-12-20 21:33:14.000000000 +0100 @@ -44,6 +44,7 @@ tests = [] failed_tests = [] passed_tests = [] + begin = (1,1) # Handle command line parameters if argv is None: @@ -60,6 +61,10 @@ help='comma or space separated string of tests to include') parser.add_option('-k', '--keep-logs', action='store_true', default=False) parser.add_option('-s', '--stop-on-first-fail', action='store_true', default=False) + parser.add_option('-b', '--begin-from-test', type='string', + dest='begin_from_test', action='callback', + callback=test_parser) + (options, args) = parser.parse_args(args=argv) # Sanity check @@ -91,11 +96,17 @@ return -1 tests.sort(test_cmp) + # Set begin value + if options.begin_from_test is not None: + begin = options.begin_from_test[0] + # Now run the tests start_time = time.time() print >>sys.stdout, 'Started:', time.asctime(time.localtime(start_time)) sys.stdout.flush() for test in tests: + if begin[0] > test[0] or (begin[0] == test[0] and begin[1] > test[1]): + continue sys.stdout.write('Running test %d.%d ' % (test[0],test[1])) sys.stdout.flush() testlog_name = 'test%d.%d.log' % (test[0],test[1]) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/testsuite/expect/test12.10 new/slurm-18.08.9/testsuite/expect/test12.10 --- old/slurm-18.08.8/testsuite/expect/test12.10 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/testsuite/expect/test12.10 2019-12-20 21:33:14.000000000 +0100 @@ -53,13 +53,13 @@ ############################################################################ proc sacct_query {jobname sacct_args expected_job {expected_err false}} { - global sacct number ntest + global sacct ntest set job_found false set err_found false set rc 0 - set cmd_str "$sacct -v -X --format=job,jobname,eligible,start,end,state $sacct_args" + set cmd_str "$sacct -v -X -p --format=job,jobname,eligible,start,end,state $sacct_args" spawn [lindex $cmd_str 0] {*}[lrange $cmd_str 1 end] expect { -re "($jobname)" { @@ -198,17 +198,14 @@ ############################################################################ -global srun squeue sacct -global bin_sleep bin_date -global number - set failures 0 # # Get Random name for the job, to avoid errors with old/duplicated jobs # -set jobname [exec bash -c "cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 4 | head -n 1"] -log_info "Random job name used to avoid false test error with old/duplicated jobs: $jobname-test$test_id." +set current_timestamp [clock seconds] +set jobname "test${test_id}-${current_timestamp}" +log_info "Unique job name used to avoid false test errors with old/duplicated jobs: $jobname." # # Get query times before any job is run (QsS and QeS) @@ -223,7 +220,7 @@ # Test job will depend on it to test non-eligible # set def_node [get_idle_node_in_part [default_partition]] -set pid_queue [spawn $sbatch -w $def_node --exclusive -J queue-test$test_id --output=/dev/null --error=/dev/null --wrap "$bin_sleep 300"] +set pid_depend [spawn $sbatch -t5 -w $def_node --exclusive -J queue-test$test_id --output=/dev/null --error=/dev/null --wrap "$bin_sleep 300"] expect { -re "Submitted batch job ($number)" { set jobid_dependent $expect_out(1,string) @@ -231,7 +228,7 @@ } timeout { log_error "$sbatch not responding." - slow_kill $pid_batch + slow_kill $pid_depend incr failures } eof { @@ -250,7 +247,7 @@ # Test job will wait until this job, to test eligible # set def_node [get_idle_node_in_part [default_partition]] -set pid_queue [spawn $sbatch -w $def_node --exclusive -J queue-test$test_id --output=/dev/null --error=/dev/null --wrap "$bin_sleep 300"] +set pid_queue [spawn $sbatch -t5 -w $def_node --exclusive -J queue-test$test_id --output=/dev/null --error=/dev/null --wrap "$bin_sleep 300"] expect { -re "Submitted batch job ($number)" { set jobid_queue $expect_out(1,string) @@ -258,7 +255,7 @@ } timeout { log_error "$sbatch not responding." - slow_kill $pid_batch + slow_kill $pid_queue incr failures } eof { @@ -273,7 +270,7 @@ # # Start main job used for testing # -set pid_batch [spawn $sbatch --dependency=afterany:$jobid_dependent -w $def_node -J $jobname-test$test_id --output=/dev/null --error=/dev/null --wrap "$bin_sleep 300"] +set pid_batch [spawn $sbatch -t5 --dependency=afterany:$jobid_dependent -w $def_node -J $jobname-test$test_id --output=/dev/null --error=/dev/null --wrap "$bin_sleep 300"] expect { -re "Submitted batch job ($number)" { set jobid $expect_out(1,string) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/testsuite/expect/test17.12 new/slurm-18.08.9/testsuite/expect/test17.12 --- old/slurm-18.08.8/testsuite/expect/test17.12 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/testsuite/expect/test17.12 2019-12-20 21:33:14.000000000 +0100 @@ -728,7 +728,7 @@ # exec $bin_rm -f $file_in make_bash_script $file_in " - $bin_sleep 2 + $bin_sleep 5 " # @@ -879,6 +879,7 @@ nodes=$nodes(0)\,$nodes(1)\,$nodes(2)\,$nodes(3) expect { -re "Error" { + log_error "scontrol returned an error when creating a partition" set exit_code 1 } timeout { diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/testsuite/expect/test22.1 new/slurm-18.08.9/testsuite/expect/test22.1 --- old/slurm-18.08.8/testsuite/expect/test22.1 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/testsuite/expect/test22.1 2019-12-20 21:33:14.000000000 +0100 @@ -296,7 +296,7 @@ exit $exit_code } -#get the user association ids for the jobs we plan to add +#get the wckey ids for the jobs we plan to add set user1wckey1 0 set user2wckey1 0 set my_pid [eval spawn $sacctmgr -n -p list wckeys users=$users wckeys=$wckey1 cluster=$cluster1 format="user,wckey,id"] @@ -314,7 +314,7 @@ exp_continue } timeout { - send_user "\nFAILURE: sacctmgr list associations not responding\n" + send_user "\nFAILURE: sacctmgr list wckeys not responding\n" slow_kill $my_pid incr exit_code 1 } @@ -323,7 +323,7 @@ } } -if {!$user1wckey1 || !$user1wckey1} { +if {!$user1wckey1 || !$user2wckey1} { send_user "\nFAILURE: Didn't get one of the user wckeys $user1wckey1 $user2wckey1.\n" incr exit_code 1 remove_user "" "" $users diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/testsuite/expect/test31.2 new/slurm-18.08.9/testsuite/expect/test31.2 --- old/slurm-18.08.8/testsuite/expect/test31.2 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/testsuite/expect/test31.2 2019-12-20 21:33:14.000000000 +0100 @@ -96,7 +96,9 @@ exit $exit_code } +# Ensure that Prolog and nohold_on_prolog_fail params are removed exec $bin_sed -i {s/^\(Prolog=\)/#\1/gI} $config_dir/slurm.conf +exec $bin_sed -i {s/nohold_on_prolog_fail//gI} $config_dir/slurm.conf # Append Prolog config to the slurm.conf exec $bin_echo "Prolog=$cwd/$good_prolog" >> $config_dir/slurm.conf diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/testsuite/expect/test34.2 new/slurm-18.08.9/testsuite/expect/test34.2 --- old/slurm-18.08.8/testsuite/expect/test34.2 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/testsuite/expect/test34.2 2019-12-20 21:33:14.000000000 +0100 @@ -181,10 +181,13 @@ set cleanqos(1) $qos_2 set clean 0 + + wait_for_account_done $acct_1,$acct_2 + for {set i 0} {$i<2} {incr i 1} { spawn $sacctmgr delete -i account $cleanacct($i) expect { - -re "Deleting accounts" { + -re "(Deleting accounts|Nothing deleted)" { incr clean 1 exp_continue } @@ -199,7 +202,7 @@ spawn $sacctmgr delete -i qos $cleanqos($i) expect { - -re "Deleting QOS" { + -re "(Deleting QOS|Nothing deleted)" { incr clean 1 exp_continue } @@ -218,9 +221,6 @@ set exit_code 1 } - cancel_job $qos_1_id - cancel_job $qos_2_id - if {$rc != 0} { exit $rc } @@ -232,6 +232,9 @@ ###################### Test preempt cancel ###################### +log_info "**** Cleanup from previous run ****" +clean_up 0 + send_user "\n*** TEST PREEMPT CANCEL ***\n" acct_setup $acct_1 $qos_1 "" cancel @@ -239,21 +242,20 @@ set qos_1_id [sub_job $acct_1] if { [wait_for_job $qos_1_id RUNNING] != 0} { - send_user "\nFAILURE: job $qos_id_1 failed to start\n" + send_user "\nFAILURE: job $qos_1_id failed to start\n" clean_up 1 } set qos_2_id [sub_job $acct_2] if { [wait_for_job $qos_2_id RUNNING] != 0} { - send_user "\nFAILURE: job $qos_id_2 failed to start\n" + send_user "\nFAILURE: job $qos_2_id failed to start\n" clean_up 1 } sleep 2 check_job_state $qos_1_id PREEMPTED -cancel_job $qos_1_id -cancel_job $qos_2_id +wait_for_account_done $acct_1,$acct_2 ###################### Test preempt requeue ###################### send_user "\n*** TEST PREEMPT REQUEUE ***\n" @@ -262,13 +264,13 @@ set qos_1_id [sub_job $acct_1] if { [wait_for_job $qos_1_id RUNNING] != 0} { - send_user "\nFAILURE: job $qos_id_1 failed to start\n" + send_user "\nFAILURE: job $qos_1_id failed to start\n" clean_up 1 } set qos_2_id [sub_job $acct_2] if { [wait_for_job $qos_2_id RUNNING] != 0} { - send_user "\nFAILURE: job $qos_id_2 failed to start\n" + send_user "\nFAILURE: job $qos_2_id failed to start\n" clean_up 1 } @@ -282,8 +284,7 @@ sleep 2 check_job_state $qos_1_id RUNNING -cancel_job $qos_1_id -cancel_job $qos_2_id +wait_for_account_done $acct_1,$acct_2 clean_up 0 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/testsuite/expect/test36.2 new/slurm-18.08.9/testsuite/expect/test36.2 --- old/slurm-18.08.8/testsuite/expect/test36.2 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/testsuite/expect/test36.2 2019-12-20 21:33:14.000000000 +0100 @@ -94,6 +94,11 @@ exit 1 } +if {[string length $job_id] > 7} { + log_warn "jobid is longer than 7 characters.\n" + exit 0 +} + # # Test bjobs <jobid> wrapper # diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/slurm-18.08.8/testsuite/expect/test9.9 new/slurm-18.08.9/testsuite/expect/test9.9 --- old/slurm-18.08.8/testsuite/expect/test9.9 2019-07-10 20:46:42.000000000 +0200 +++ new/slurm-18.08.9/testsuite/expect/test9.9 2019-12-20 21:33:14.000000000 +0100 @@ -80,7 +80,7 @@ } } -set time_took [string trim [time {_submit_jobs "hostname" "/dev/null"}] " per iteration microseconds"] +set time_took [string trim [time {_submit_jobs "test$test_id" "/dev/null"}] " per iteration microseconds"] set jobs_per_sec [expr $job_cnt * 1000000 / $time_took] send_user "Ran $job_cnt jobs in $time_took microseconds or $jobs_per_sec jobs per second\n"
