From 5e5f597dee4b5b9b1adae1cb14182c58c1d5c0f0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= Date: Sun, 1 Dec 2013 12:38:37 +0100 Subject: [PATCH] modules, gcc, cuda, openmpi --- aufgabe4.1/GCC/GCC-4.8.1-RC.eb | 31 +++++++++++++++++++ aufgabe4.1/GCC/GCC-4.8.2-RC.eb | 31 +++++++++++++++++++ aufgabe4.2/module.sh | 43 +++++++++++++++++++++++++++ aufgabe4.3/cron.daily/rsnapshot | 3 ++ aufgabe4.3/cron.weekly/rsnapshot | 3 ++ aufgabe4.3/rsnapshot.conf | 30 +++++++++++++++++++ aufgabe4.5/OpenMPI-1.7.3-GCC-4.8.2.eb | 36 ++++++++++++++++++++++ aufgabe4.6/CUDA-5.5.22.eb | 38 +++++++++++++++++++++++ bericht/abschnitte/anhang.tex | 6 ++++ bericht/abschnitte/prov-compiler.tex | 16 ++++++++++ bericht/abschnitte/prov-cuda.tex | 3 ++ bericht/abschnitte/prov-modules.tex | 8 +++++ bericht/abschnitte/prov-mpi.tex | 5 ++-- 13 files changed, 251 insertions(+), 2 deletions(-) create mode 100644 aufgabe4.1/GCC/GCC-4.8.1-RC.eb create mode 100644 aufgabe4.1/GCC/GCC-4.8.2-RC.eb create mode 100644 aufgabe4.2/module.sh create mode 100644 aufgabe4.3/cron.daily/rsnapshot create mode 100644 aufgabe4.3/cron.weekly/rsnapshot create mode 100644 aufgabe4.3/rsnapshot.conf create mode 100644 aufgabe4.5/OpenMPI-1.7.3-GCC-4.8.2.eb create mode 100644 aufgabe4.6/CUDA-5.5.22.eb diff --git a/aufgabe4.1/GCC/GCC-4.8.1-RC.eb b/aufgabe4.1/GCC/GCC-4.8.1-RC.eb new file mode 100644 index 0000000..9d5a6b8 --- /dev/null +++ b/aufgabe4.1/GCC/GCC-4.8.1-RC.eb @@ -0,0 +1,31 @@ +name = "GCC" +version = '4.8.1' + +homepage = 'http://gcc.gnu.org/' +description = ""The GNU Compiler Collection includes front ends for C, C++, +Objective-C, Fortran, Java, and Ada, + as well as libraries for these languages (libstdc++, libgcj,...)."" + +toolchain = {'name': 'dummy', 'version': 'dummy'} + +source_urls = [ + 'ftp://gcc.gnu.org/pub/gcc/snapshots/4.8.1-RC-20130527', # GCC +auto-resolving HTTP mirror + 'http://ftpmirror.gnu.org/gmp', # idem for GMP + 'http://ftpmirror.gnu.org/mpfr', # idem for MPFR + 'www.multiprecision.org/mpc/download', # MPC official +] +sources = [ + 'gcc-4.8.1-RC-20130527.tar.bz2', + 'gmp-5.1.2.tar.bz2', + 'mpfr-3.1.2.tar.gz', + 'mpc-1.0.1.tar.gz', +] + +languages = ['c', 'c++', 'fortran'] + +# building GCC sometimes fails if make parallelism is too high, so let's limit +# it +maxparallel = 4 + +moduleclass = 'compiler'" diff --git a/aufgabe4.1/GCC/GCC-4.8.2-RC.eb b/aufgabe4.1/GCC/GCC-4.8.2-RC.eb new file mode 100644 index 0000000..b78bc8b --- /dev/null +++ b/aufgabe4.1/GCC/GCC-4.8.2-RC.eb @@ -0,0 +1,31 @@ +me = "GCC" +version = '4.8.2' + +homepage = 'http://gcc.gnu.org/' +description = ""The GNU Compiler Collection includes front ends for C, C++, +Objective-C, Fortran, Java, and Ada, + as well as libraries for these languages (libstdc++, libgcj,...)."" + +toolchain = {'name': 'dummy', 'version': 'dummy'} + +source_urls = [ + 'ftp://gcc.gnu.org/pub/gcc/snapshots/4.8.2-RC-20131009/', # GCC +auto-resolving HTTP mirror + 'http://ftpmirror.gnu.org/gmp', # idem for GMP + 'http://ftpmirror.gnu.org/mpfr', # idem for MPFR + 'http://www.multiprecision.org/mpc/download', # MPC official +] +sources = [ + 'gcc-4.8.2-RC-20131009.tar.bz2', + 'gmp-5.1.3.tar.bz2', + 'mpfr-3.1.2.tar.gz', + 'mpc-1.0.1.tar.gz', +] + +languages = ['c', 'c++', 'fortran'] + +# building GCC sometimes fails if make parallelism is too high, so let's limit +# it +maxparallel = 4 + +moduleclass = 'compiler' diff --git a/aufgabe4.2/module.sh b/aufgabe4.2/module.sh new file mode 100644 index 0000000..b42c0d9 --- /dev/null +++ b/aufgabe4.2/module.sh @@ -0,0 +1,43 @@ +if [ "${MODULE_VERSION:-}" = "" ]; then + MODULE_VERSION_STACK="3.2.10" + MODULE_VERSION="3.2.10" + export MODULE_VERSION +else + MODULE_VERSION_STACK="$MODULE_VERSION" +fi +export MODULE_VERSION_STACK + +case $SHELL in + *bash) + module() { eval `/usr/local/Modules/$MODULE_VERSION/bin/modulecmd bash $*`; } + ;; + *zsh) + module() { eval `/usr/local/Modules/$MODULE_VERSION/bin/modulecmd zsh $*`; } + ;; + *) + module() { eval `/usr/local/Modules/$MODULE_VERSION/bin/modulecmd sh $*`; } + export -f module + ;; +esac + +MODULESHOME=/usr/local/Modules/3.2.10 +MODULERCFILE=/cluster/modules/rc +export MODULESHOME +export MODULERCFILE + +if [ "${LOADEDMODULES:-}" = "" ]; then + LOADEDMODULES= + export LOADEDMODULES +fi + +if [ "${MODULEPATH:-}" = "" ]; then + MODULEPATH=`sed -n 's/[ #].*$//; /./H; $ { x; s/^\n//; s/\n/:/g; p; }' ${MODULESHOME}/init/.modulespath` + MODULEPATH=/cluster/modules/all/:$MODULEPATH + export MODULEPATH +fi + +if [ ${BASH_VERSINFO:-0} -ge 3 ] && [ -r ${MODULESHOME}/init/bash_completion ]; then + . ${MODULESHOME}/init/bash_completion +fi + +module load diff --git a/aufgabe4.3/cron.daily/rsnapshot b/aufgabe4.3/cron.daily/rsnapshot new file mode 100644 index 0000000..00ebcff --- /dev/null +++ b/aufgabe4.3/cron.daily/rsnapshot @@ -0,0 +1,3 @@ +#!/bin/sh + +rsnapshot -c /etc/rsnapshot.conf daily diff --git a/aufgabe4.3/cron.weekly/rsnapshot b/aufgabe4.3/cron.weekly/rsnapshot new file mode 100644 index 0000000..1fb9660 --- /dev/null +++ b/aufgabe4.3/cron.weekly/rsnapshot @@ -0,0 +1,3 @@ +#!/bin/sh + +rsnapshot -c /etc/rsnapshot.conf weekly diff --git a/aufgabe4.3/rsnapshot.conf b/aufgabe4.3/rsnapshot.conf new file mode 100644 index 0000000..c8ff3ef --- /dev/null +++ b/aufgabe4.3/rsnapshot.conf @@ -0,0 +1,30 @@ +config_version 1.2 +snapshot_root /backup/rsnapshot +no_create_root 1 + +cmd_cp /usr/bin/cp +cmd_rm /usr/bin/rm +cmd_rsync /usr/bin/rsync +cmd_ssh /usr/bin/ssh +#cmd_preexec /path/to/preexec/script +#cmd_postexec /path/to/postexec/script + +interval daily 7 +interval weekly 4 + +verbose 2 +loglevel 3 +lockfile /var/run/rsnapshot.pid +logfile /var/log/rsnapshot + +link_dest 1 + +use_lazy_deletes 1 + +backup /home/ localhost/ +backup /etc/ localhost/ +backup /usr/local/ localhost/ +backup /cluster/ localhost/ +backup /srv/ localhost/ +backup /fastfs/ localhost/ +backup /var/lib/ localhost/ diff --git a/aufgabe4.5/OpenMPI-1.7.3-GCC-4.8.2.eb b/aufgabe4.5/OpenMPI-1.7.3-GCC-4.8.2.eb new file mode 100644 index 0000000..e02b8da --- /dev/null +++ b/aufgabe4.5/OpenMPI-1.7.3-GCC-4.8.2.eb @@ -0,0 +1,36 @@ +name = 'OpenMPI' +version = "1.7.3" + +homepage = 'http://www.open-mpi.org/' +description = """The Open MPI Project is an open source MPI-2 implementation.""" + +toolchain = {'name': 'GCC', 'version': '4.8.2'} + +sources = [SOURCELOWER_TAR_GZ] +source_urls = ['http://www.open-mpi.org/software/ompi/v%s/downloads' % '.'.join(version.split('.')[0:2])] + +#builddependencies = [ +# ('Automake', '1.14'), +# ('Autoconf', '2.69') +#] + +dependencies = [('hwloc', '1.7.2')] + +configopts = '--with-threads=posix --enable-shared --enable-mpi-thread-multiple --with-openib ' +configopts += '--enable-mpirun-prefix-by-default ' # suppress failure modes in relation to mpirun path +configopts += '--with-hwloc=$EBROOTHWLOC ' # hwloc support +configopts += '--disable-dlopen ' # statically link component, don't do dynamic loading +configopts += '--without-verbs ' + +sanity_check_paths = { + 'files': ["bin/%s" % binfile for binfile in ["ompi_info", "opal_wrapper", "orterun"]] + + ["lib/lib%s.%s" % (libfile, shared_lib_ext) for libfile in ["mpi_cxx", "mpi_mpifh", + "mpi", "ompitrace", "open-pal", + "mpi", "ompitrace", "open-pal", + "open-rte", "vt", "vt-hyb", + "vt-mpi", "vt-mpi-unify"]] + + ["include/%s.h" % x for x in ["mpi-ext", "mpif-config", "mpif", "mpi", "mpi_portable_platform"]], + 'dirs': ["include/openmpi/ompi/mpi/cxx"] +} + +moduleclass = 'mpi' diff --git a/aufgabe4.6/CUDA-5.5.22.eb b/aufgabe4.6/CUDA-5.5.22.eb new file mode 100644 index 0000000..d3b3a80 --- /dev/null +++ b/aufgabe4.6/CUDA-5.5.22.eb @@ -0,0 +1,38 @@ +## +# This file is an EasyBuild reciPY as per https://github.com/hpcugent/easybuild +# +# Copyright:: Copyright 2012-2013 Cyprus Institute / CaSToRC, University of +# Luxembourg / LCSB, Ghent University +# Authors:: George Tsouloupas , Fotis Georgatos +# , Kenneth Hoste +# License:: MIT/GPL +# $Id$ +# +# This work implements a part of the HPCBIOS project and is a component of the +# policy: +# http://hpcbios.readthedocs.org/en/latest/HPCBIOS_2012-99.html +## + +name = 'CUDA' +version = '5.5.22' + +homepage = 'https://developer.nvidia.com/cuda-toolkit' +description = ""CUDA (formerly Compute Unified Device Architecture) is a +parallel + computing platform and programming model created by NVIDIA and implemented by +the + graphics processing units (GPUs) that they produce. CUDA gives developers +access + to the virtual instruction set and memory of the parallel computational +elements in CUDA GPUs."" + +toolchain = {'name': 'dummy', 'version': 'dummy'} + +# eg. +# http://developer.download.nvidia.com/compute/cuda/5_5/rel/installers/cuda_5.5.22_linux_64.run +source_urls = +['http://developer.download.nvidia.com/compute/cuda/5_5/rel/installers/'] + +sources = ['%(namelower)s_%(version)s_linux_64.run'] + +moduleclass = 'system'" diff --git a/bericht/abschnitte/anhang.tex b/bericht/abschnitte/anhang.tex index e774ec6..3f0a4c7 100644 --- a/bericht/abschnitte/anhang.tex +++ b/bericht/abschnitte/anhang.tex @@ -30,3 +30,9 @@ automatisiert die Installation weiterer Pakete aus dem AUR und bietet ebenfalls die Möglichkeit, diese zu aktualisieren. Die Kommandozeilen-Argumente sind die gleichen wie bei {\tt pacman}, da das Tool im Grunde ein Wrapper für {\tt pacman} ist. + +\subsubsection{Easybuild} +\label{sec:easybuild} +\href{http://hpcugent.github.io/easybuild/}{Easybuild} ist ein auf den +HPC-Bereich ausgelegtes Projekt, welches die Installation/Verwaltung verschiedener Versionen +von Software ermöglicht. Darüber hinaus generiert es Environment-Modules und erkennt Abhängigkeiten. diff --git a/bericht/abschnitte/prov-compiler.tex b/bericht/abschnitte/prov-compiler.tex index 5f0c6ba..bb528d6 100644 --- a/bericht/abschnitte/prov-compiler.tex +++ b/bericht/abschnitte/prov-compiler.tex @@ -1,9 +1,25 @@ \subsection{Compiler} \label{sub:compiler} +Die benötigten Compiler/Bibliotheken für den Cluster-Betrieb wurden mit Hilfe der +Software easybuild (\ref{sec:easybuild}) installiert. +Die installierte Software ist im Verzeichnis \emph{/cluster/} zu finden. + \subsubsection{GNU Compiler Collection} \label{ssub:gnu_compiler_collection} +Wir haben folgende GCC-Versionen installiert: + +\begin{itemize} + \item \href{4.8.1-RC-20130527}{ftp://gcc.gnu.org/pub/gcc/snapshots/4.8.1-RC-20130527/} + \item \href{4.8.2-RC-20131009}{ftp://gcc.gnu.org/pub/gcc/snapshots/4.8.2-RC-20131009/} +\end{itemize} + +Die für easybuild (\ref{sec:easybuild}) benötigten Paket-Beschreibungen sind in \emph{aufgabe4.1/GCC} zu +finden. \subsubsection{Intel Compiler Suite} \label{ssub:intel_compiler_suite} + +Die für easybuild (\ref{sec:easybuild}) benötigten Paket-Beschreibungen sind in \emph{aufgabe4.1/ICC} zu +finden. diff --git a/bericht/abschnitte/prov-cuda.tex b/bericht/abschnitte/prov-cuda.tex index 9a3da46..3e3b758 100644 --- a/bericht/abschnitte/prov-cuda.tex +++ b/bericht/abschnitte/prov-cuda.tex @@ -1,2 +1,5 @@ \subsection{CUDA} \label{sub:cuda} + +Die für easybuild (\ref{sec:easybuild}) benötigten Paket-Beschreibungen sind in \emph{aufgabe4.6} zu +finden. diff --git a/bericht/abschnitte/prov-modules.tex b/bericht/abschnitte/prov-modules.tex index 2186407..f299cfd 100644 --- a/bericht/abschnitte/prov-modules.tex +++ b/bericht/abschnitte/prov-modules.tex @@ -1,3 +1,11 @@ \subsection{Modules} \label{sub:modules} +Zu Initialisierung von Modules, haben wir Shell-Skript in +\emph{/etc/profile.d/module.sh} hinterlegt (auch zu finden in aufgabe4.2/module.sh). +Dieses Skript fügt den Pfad \emph{/cluster/modules/all} zum MODULESPATH hinzu, +so dass Module in diesem Verzeichnis geladen werden können. Darüber hinaus wird die Datei \emph{/cluster/modules/rc} als MODULERCFILE konfiguriert. +Diese Datei lädt Module wie den GCC-Compiler oder OpenMPI vor. Über eine +Versionsdatei in \emph{/cluster/modules/all/GCC/.version} wird der GCC-Version 4.8.2 als default markiert. Die gesamte Modules-Konfiguration befindet sich in \emph{aufgabe4.2/modules}. + +TODO muss noch eingefügt werden. diff --git a/bericht/abschnitte/prov-mpi.tex b/bericht/abschnitte/prov-mpi.tex index e3cdcac..6cdfbef 100644 --- a/bericht/abschnitte/prov-mpi.tex +++ b/bericht/abschnitte/prov-mpi.tex @@ -1,6 +1,7 @@ \subsection{Open MPI} \label{sub:open_mpi} +OpenMPI wurde in der Version 1.7.3 mithilfe von easybuild (\ref{sec:easybuild}) - -% subsection open_mpi (end) +Die für easybuild benötigten Paket-Beschreibungen sind in \emph{aufgabe4.5/} zu +finden.