diff options
author | Robin H. Johnson <robbat2@gentoo.org> | 2015-08-08 13:49:04 -0700 |
---|---|---|
committer | Robin H. Johnson <robbat2@gentoo.org> | 2015-08-08 17:38:18 -0700 |
commit | 56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch) | |
tree | 3f91093cdb475e565ae857f1c5a7fd339e2d781e /sys-cluster/slurm/files | |
download | gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2 gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip |
proj/gentoo: Initial commit
This commit represents a new era for Gentoo:
Storing the gentoo-x86 tree in Git, as converted from CVS.
This commit is the start of the NEW history.
Any historical data is intended to be grafted onto this point.
Creation process:
1. Take final CVS checkout snapshot
2. Remove ALL ChangeLog* files
3. Transform all Manifests to thin
4. Remove empty Manifests
5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$
5.1. Do not touch files with -kb/-ko keyword flags.
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests
X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project
X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration
X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn
X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts
X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration
X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging
X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'sys-cluster/slurm/files')
-rw-r--r-- | sys-cluster/slurm/files/logrotate | 20 | ||||
-rw-r--r-- | sys-cluster/slurm/files/slurm-2.5.4-nogtk.patch | 43 | ||||
-rw-r--r-- | sys-cluster/slurm/files/slurm.confd | 6 | ||||
-rw-r--r-- | sys-cluster/slurm/files/slurmctld.initd | 69 | ||||
-rw-r--r-- | sys-cluster/slurm/files/slurmd.initd | 72 | ||||
-rw-r--r-- | sys-cluster/slurm/files/slurmdbd.initd | 67 |
6 files changed, 277 insertions, 0 deletions
diff --git a/sys-cluster/slurm/files/logrotate b/sys-cluster/slurm/files/logrotate new file mode 100644 index 000000000000..978a869eb993 --- /dev/null +++ b/sys-cluster/slurm/files/logrotate @@ -0,0 +1,20 @@ +/var/log/slurm/*.log { + weekly + compress + missingok + nocopytruncate + nocreate + nodelaycompress + nomail + notifempty + noolddir + rotate 5 + sharedscripts + size=5M + create 640 slurm slurm + postrotate + /etc/init.d/slurmd reload + /etc/init.d/slurmctld reload + /etc/init.d/slurmdbd reload + endscript +} diff --git a/sys-cluster/slurm/files/slurm-2.5.4-nogtk.patch b/sys-cluster/slurm/files/slurm-2.5.4-nogtk.patch new file mode 100644 index 000000000000..12741f53b449 --- /dev/null +++ b/sys-cluster/slurm/files/slurm-2.5.4-nogtk.patch @@ -0,0 +1,43 @@ +--- slurm-2.5.4/configure.ac.orig 2013-04-11 12:58:24.971724348 +0400 ++++ slurm-2.5.4/configure.ac 2013-04-11 12:59:00.921724309 +0400 +@@ -229,40 +229,6 @@ + AM_CONDITIONAL(HAVE_SOME_CURSES, test "x$ac_have_some_curses" = "xyes") + AC_SUBST(HAVE_SOME_CURSES) + +-# +-# Tests for GTK+ +-# +- +-# use the correct libs if running on 64bit +-if test -d "/usr/lib64/pkgconfig"; then +- PKG_CONFIG_PATH="/usr/lib64/pkgconfig/:$PKG_CONFIG_PATH" +-fi +- +-if test -d "/opt/gnome/lib64/pkgconfig"; then +- PKG_CONFIG_PATH="/opt/gnome/lib64/pkgconfig/:$PKG_CONFIG_PATH" +-fi +- +-AM_PATH_GLIB_2_0([2.7.1], [ac_glib_test="yes"], [ac_glib_test="no"], [gthread]) +- +-if test ${glib_config_minor_version=0} -ge 32 ; then +- AC_DEFINE([GLIB_NEW_THREADS], 1, [Define to 1 if using glib-2.32.0 or higher]) +-fi +- +-AM_PATH_GTK_2_0([2.7.1], [ac_gtk_test="yes"], [ac_gtk_test="no"], [gthread]) +-if test ${gtk_config_minor_version=0} -ge 10 ; then +- AC_DEFINE([GTK2_USE_RADIO_SET], 1, [Define to 1 if using gtk+-2.10.0 or higher]) +-fi +- +-if test ${gtk_config_minor_version=0} -ge 12 ; then +- AC_DEFINE([GTK2_USE_TOOLTIP], 1, [Define to 1 if using gtk+-2.12.0 or higher]) +-fi +- +-if test ${gtk_config_minor_version=0} -ge 14 ; then +- AC_DEFINE([GTK2_USE_GET_FOCUS], 1, [Define to 1 if using gtk+-2.14.0 or higher]) +-fi +- +-AM_CONDITIONAL(BUILD_SVIEW, [test "x$ac_glib_test" = "xyes"] && [test "x$ac_gtk_test" = "xyes"]) +- + X_AC_DATABASES + + dnl Cray ALPS/Basil support depends on mySQL diff --git a/sys-cluster/slurm/files/slurm.confd b/sys-cluster/slurm/files/slurm.confd new file mode 100644 index 000000000000..c406dc3f2a2c --- /dev/null +++ b/sys-cluster/slurm/files/slurm.confd @@ -0,0 +1,6 @@ +# /etc/conf.d/slurm: config file for /etc/init.d/slurm* +SLURMCTLD_OPTIONS="" +SLURMDBD_OPTIONS="" +SLURMD_OPTIONS="" +SLURM_USE_MUNGE="0" +SLURM_USE_YPBIND="0"
\ No newline at end of file diff --git a/sys-cluster/slurm/files/slurmctld.initd b/sys-cluster/slurm/files/slurmctld.initd new file mode 100644 index 000000000000..145909b007eb --- /dev/null +++ b/sys-cluster/slurm/files/slurmctld.initd @@ -0,0 +1,69 @@ +#!/sbin/runscript +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +extra_commands="reload" + +[[ -f /etc/conf.d/slurm ]] && . /etc/conf.d/slurm + +depend() { + local _need="net" + [[ ${SLURM_USE_MUNGE} -ne 0 ]] && _need="${_need} munged" + [[ ${SLURM_USE_YPBIND} -ne 0 ]] && _need="${_need} ypbind" + after logger slurmdbd + need ${_need} +} + +create_folder_and_set_permission() { + folder=${1} + # Fix permissions (/tmp is wiped at boot) + if [[ "${folder}" == "/tmp" ]]; then + eerror "SLURM: folder == ${folder} == /tmp" + exit + fi + if [[ "${folder}" == "/var/tmp" ]]; then + eerror "SLURM: folder == ${folder} == /var/tmp" + exit + fi + checkpath -d -o slurm:slurm ${folder} +} + +checkconfig() { + if [ ! -e "/etc/slurm/slurm.conf" ]; then + eerror "Missing config /etc/slurm/slurm.conf" + eerror "Customize sample one or generate new by configurator.html" + eerror "in slurm doc directory" + return 1 + fi + + # Make sure folders exists + . /etc/slurm/slurm.conf + folders=(${SlurmdSpoolDir} `dirname ${SlurmctldLogFile}` `dirname ${SlurmctldPidFile}` `dirname ${SlurmdLogFile}` `dirname ${SlurmdPidFile}` ${SlurmdSpoolDir} ${StateSaveLocation}) + for folder in ${folders[*]}; do + create_folder_and_set_permission ${folder} + done +} + +start() { + ebegin "Starting slurm control daemon" + checkconfig + start-stop-daemon --start --quiet --background \ + --pidfile /var/run/slurm/slurmctld.pid \ + --user slurm \ + --group slurm \ + --exec /usr/sbin/slurmctld -- ${SLURMCTLD_OPTS} + eend $? +} + +stop() { + ebegin "Stopping slurm control daemon" + start-stop-daemon --stop --pidfile /var/run/slurm/slurmctld.pid + eend $? +} + +reload() { + ebegin "Reloading slurm daemon configuration" + start-stop-daemon --signal HUP --pidfile /var/run/slurm/slurmctld.pid + eend $? +} diff --git a/sys-cluster/slurm/files/slurmd.initd b/sys-cluster/slurm/files/slurmd.initd new file mode 100644 index 000000000000..cc4adcfb6d12 --- /dev/null +++ b/sys-cluster/slurm/files/slurmd.initd @@ -0,0 +1,72 @@ +#!/sbin/runscript +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +extra_commands="reload" + +[[ -f /etc/conf.d/slurm ]] && . /etc/conf.d/slurm + +depend() { + local _need="net" + [[ ${SLURM_USE_MUNGE} -ne 0 ]] && _need="${_need} munged" + [[ ${SLURM_USE_YPBIND} -ne 0 ]] && _need="${_need} ypbind" + after logger + need ${_need} +} + +create_folder_and_set_permission() { + folder=${1} + # Fix permissions (/tmp is wiped at boot) + if [[ "${folder}" == "/tmp" ]]; then + eerror "SLURM: folder == ${folder} == /tmp" + exit + fi + if [[ "${folder}" == "/var/tmp" ]]; then + eerror "SLURM: folder == ${folder} == /var/tmp" + exit + fi + checkpath -d -o slurm:slurm ${folder} +} + +checkconfig() { + if [ ! -e "/etc/slurm/slurm.conf" ]; then + eerror "Missing config /etc/slurm/slurm.conf" + eerror "Customize sample one or generate new by configurator.html" + eerror "in slurm doc directory" + return 1 + fi + # Make sure folders exists + . /etc/slurm/slurm.conf + folders=(${SlurmdSpoolDir} `dirname ${SlurmctldLogFile}` `dirname ${SlurmctldPidFile}` `dirname ${SlurmdLogFile}` `dirname ${SlurmdPidFile}` ${SlurmdSpoolDir} ${StateSaveLocation}) + for folder in ${folders[*]}; do + create_folder_and_set_permission ${folder} + done +} + +start() { + ebegin "Starting slurm daemon" + checkconfig + # Slurm does not propagate limits, which can brakes InfiniBand + # See http://www.open-mpi.org/faq/?category=openfabrics + # and https://computing.llnl.gov/linux/slurm/faq.html#rlimit + ulimit -l unlimited + start-stop-daemon --start --quiet --background \ + --pidfile /var/run/slurm/slurmd.pid \ + --user root \ + --group root \ + --exec /usr/sbin/slurmd -- ${SLURMD_OPTS} + eend $? +} + +stop() { + ebegin "Stopping slurm daemon" + start-stop-daemon --stop --pidfile /var/run/slurm/slurmd.pid + eend $? +} + +reload() { + ebegin "Reloading slurm daemon configuration" + start-stop-daemon --signal HUP --pidfile /var/run/slurm/slurmd.pid + eend $? +} diff --git a/sys-cluster/slurm/files/slurmdbd.initd b/sys-cluster/slurm/files/slurmdbd.initd new file mode 100644 index 000000000000..c6acccf47678 --- /dev/null +++ b/sys-cluster/slurm/files/slurmdbd.initd @@ -0,0 +1,67 @@ +#!/sbin/runscript +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +extra_commands="reload" + +[[ -f /etc/conf.d/slurm ]] && . /etc/conf.d/slurm + +depend() { + local _need="net" + [[ ${SLURM_USE_MUNGE} -ne 0 ]] && _need="${_need} munged" + [[ ${SLURM_USE_YPBIND} -ne 0 ]] && _need="${_need} ypbind" + after logger + need ${_need} +} + +create_folder_and_set_permission() { + folder=${1} + # Fix permissions (/tmp is wiped at boot) + if [[ "${folder}" == "/tmp" ]]; then + eerror "SLURM: folder == ${folder} == /tmp" + exit + fi + if [[ "${folder}" == "/var/tmp" ]]; then + eerror "SLURM: folder == ${folder} == /var/tmp" + exit + fi + checkpath -d -o slurm:slurm ${folder} +} + +checkconfig() { + if [ ! -e "/etc/slurm/slurmdbd.conf" ]; then + eerror "Missing config /etc/slurm/slurmdbd.conf" + return 1 + fi + + # Make sure folders exists + . /etc/slurm/slurm.conf + folders=(${SlurmdSpoolDir} `dirname ${SlurmctldLogFile}` `dirname ${SlurmctldPidFile}` `dirname ${SlurmdLogFile}` `dirname ${SlurmdPidFile}` ${SlurmdSpoolDir} ${StateSaveLocation}) + for folder in ${folders[*]}; do + create_folder_and_set_permission ${folder} + done +} + +start() { + ebegin "Starting slurmdb daemon" + checkconfig + start-stop-daemon --start --quiet --background \ + --pidfile /var/run/slurm/slurmdbd.pid \ + --user slurm \ + --group slurm \ + --exec /usr/sbin/slurmdbd -- ${SLURMD_OPTS} + eend $? +} + +stop() { + ebegin "Stopping slurmdb daemon" + start-stop-daemon --stop --pidfile /var/run/slurm/slurmdbd.pid + eend $? +} + +reload() { + ebegin "Reloading slurmdb daemon configuration" + start-stop-daemon --signal HUP --pidfile /var/run/slurm/slurmdbd.pid + eend $? +} |