From 8b71173c6902641420b9c6fd0a31c6609ffa1b4d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= Date: Sun, 8 Dec 2013 19:49:55 +0100 Subject: [PATCH 1/4] modules: update --- aufgabe4.2/modules/all/GCC/4.7.3 | 30 ++++++++++++++ aufgabe4.2/modules/all/GCC/4.8.1 | 2 + aufgabe4.2/modules/all/GCC/4.8.2 | 2 + aufgabe4.2/modules/all/ifort/2013_sp1.1.106 | 28 +++++++++++++ aufgabe4.2/modules/compiler/GCC/4.7.3 | 30 ++++++++++++++ aufgabe4.2/modules/compiler/GCC/4.8.1 | 31 +++++++++++++- aufgabe4.2/modules/compiler/GCC/4.8.2 | 31 +++++++++++++- .../modules/compiler/icc/2013_sp1.1.106 | 29 +++++++++++++- .../modules/compiler/ifort/2013_sp1.1.106 | 28 +++++++++++++ aufgabe4.2/modules/modules.install | 10 ----- .../modules/mpi/OpenMPI/1.7.3-GCC-4.8.2 | 34 +++++++++++++++- aufgabe4.2/modules/system/CUDA/5.5.22 | 17 +++++++- .../modules/system/hwloc/1.7.2-GCC-4.8.2 | 40 ++++++++++++++++++- 13 files changed, 296 insertions(+), 16 deletions(-) create mode 100644 aufgabe4.2/modules/all/GCC/4.7.3 create mode 100644 aufgabe4.2/modules/all/ifort/2013_sp1.1.106 create mode 100644 aufgabe4.2/modules/compiler/GCC/4.7.3 mode change 120000 => 100644 aufgabe4.2/modules/compiler/GCC/4.8.1 mode change 120000 => 100644 aufgabe4.2/modules/compiler/GCC/4.8.2 mode change 120000 => 100644 aufgabe4.2/modules/compiler/icc/2013_sp1.1.106 create mode 100644 aufgabe4.2/modules/compiler/ifort/2013_sp1.1.106 delete mode 100644 aufgabe4.2/modules/modules.install mode change 120000 => 100644 aufgabe4.2/modules/mpi/OpenMPI/1.7.3-GCC-4.8.2 mode change 120000 => 100644 aufgabe4.2/modules/system/CUDA/5.5.22 mode change 120000 => 100644 aufgabe4.2/modules/system/hwloc/1.7.2-GCC-4.8.2 diff --git a/aufgabe4.2/modules/all/GCC/4.7.3 b/aufgabe4.2/modules/all/GCC/4.7.3 new file mode 100644 index 0000000..c50ba45 --- /dev/null +++ b/aufgabe4.2/modules/all/GCC/4.7.3 @@ -0,0 +1,30 @@ +#%Module + +proc ModulesHelp { } { + puts stderr { 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,...). - Homepage: http://gcc.gnu.org/ + } +} + +module-whatis {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,...). - Homepage: http://gcc.gnu.org/} + +set root /cluster/software/GCC/4.7.3 + +conflict GCC +conflict icc +conflict ifort + +prepend-path CPATH $root/include +prepend-path LD_LIBRARY_PATH $root/lib +prepend-path LD_LIBRARY_PATH $root/lib64 +prepend-path LD_LIBRARY_PATH $root/lib/gcc/x86_64-unknown-linux-gnu/4.7.3 +prepend-path MANPATH $root/share/man +prepend-path PATH $root/bin + +setenv EBROOTGCC "$root" +setenv EBVERSIONGCC "4.7.3" +setenv EBDEVELGCC "$root/easybuild/GCC-4.7.3-easybuild-devel" + + +# built with EasyBuild version 1.9.0 diff --git a/aufgabe4.2/modules/all/GCC/4.8.1 b/aufgabe4.2/modules/all/GCC/4.8.1 index 9f21237..76ea401 100644 --- a/aufgabe4.2/modules/all/GCC/4.8.1 +++ b/aufgabe4.2/modules/all/GCC/4.8.1 @@ -12,6 +12,8 @@ module-whatis {The GNU Compiler Collection includes front ends for C, C++, Objec set root /cluster/software/GCC/4.8.1 conflict GCC +conflict icc +conflict ifort prepend-path CPATH $root/include prepend-path LD_LIBRARY_PATH $root/lib diff --git a/aufgabe4.2/modules/all/GCC/4.8.2 b/aufgabe4.2/modules/all/GCC/4.8.2 index a4e388f..17b77d1 100644 --- a/aufgabe4.2/modules/all/GCC/4.8.2 +++ b/aufgabe4.2/modules/all/GCC/4.8.2 @@ -12,6 +12,8 @@ module-whatis {The GNU Compiler Collection includes front ends for C, C++, Objec set root /cluster/software/GCC/4.8.2 conflict GCC +conflict icc +conflict ifort prepend-path CPATH $root/include prepend-path LD_LIBRARY_PATH $root/lib diff --git a/aufgabe4.2/modules/all/ifort/2013_sp1.1.106 b/aufgabe4.2/modules/all/ifort/2013_sp1.1.106 new file mode 100644 index 0000000..25c2fc7 --- /dev/null +++ b/aufgabe4.2/modules/all/ifort/2013_sp1.1.106 @@ -0,0 +1,28 @@ +#%Module + +proc ModulesHelp { } { + puts stderr { Fortran compiler from Intel - Homepage: http://software.intel.com/en-us/intel-compilers/ + } +} + +module-whatis {Fortran compiler from Intel - Homepage: http://software.intel.com/en-us/intel-compilers/} + +set root /cluster/software/ifort/2013_sp1.1.106 + +conflict ifort +conflict GCC + +prepend-path LD_LIBRARY_PATH $root/lib +prepend-path LD_LIBRARY_PATH $root/lib/intel64 +prepend-path MANPATH $root/man +prepend-path MANPATH $root/man/en_US +prepend-path PATH $root/bin + +setenv EBROOTIFORT "$root" +setenv EBVERSIONIFORT "2013_sp1.1.106" +setenv EBDEVELIFORT "$root/easybuild/ifort-2013_sp1.1.106-easybuild-devel" + +prepend-path INTEL_LICENSE_FILE /home/jthalheim/licenses/intel/l_SM3CCW49.lic +prepend-path NLSPATH $root/idb/intel64/locale/%l_%t/%N + +# built with EasyBuild version 1.9.0 diff --git a/aufgabe4.2/modules/compiler/GCC/4.7.3 b/aufgabe4.2/modules/compiler/GCC/4.7.3 new file mode 100644 index 0000000..c50ba45 --- /dev/null +++ b/aufgabe4.2/modules/compiler/GCC/4.7.3 @@ -0,0 +1,30 @@ +#%Module + +proc ModulesHelp { } { + puts stderr { 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,...). - Homepage: http://gcc.gnu.org/ + } +} + +module-whatis {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,...). - Homepage: http://gcc.gnu.org/} + +set root /cluster/software/GCC/4.7.3 + +conflict GCC +conflict icc +conflict ifort + +prepend-path CPATH $root/include +prepend-path LD_LIBRARY_PATH $root/lib +prepend-path LD_LIBRARY_PATH $root/lib64 +prepend-path LD_LIBRARY_PATH $root/lib/gcc/x86_64-unknown-linux-gnu/4.7.3 +prepend-path MANPATH $root/share/man +prepend-path PATH $root/bin + +setenv EBROOTGCC "$root" +setenv EBVERSIONGCC "4.7.3" +setenv EBDEVELGCC "$root/easybuild/GCC-4.7.3-easybuild-devel" + + +# built with EasyBuild version 1.9.0 diff --git a/aufgabe4.2/modules/compiler/GCC/4.8.1 b/aufgabe4.2/modules/compiler/GCC/4.8.1 deleted file mode 120000 index 7e5c0e2..0000000 --- a/aufgabe4.2/modules/compiler/GCC/4.8.1 +++ /dev/null @@ -1 +0,0 @@ -/cluster/modules/all/GCC/4.8.1 \ No newline at end of file diff --git a/aufgabe4.2/modules/compiler/GCC/4.8.1 b/aufgabe4.2/modules/compiler/GCC/4.8.1 new file mode 100644 index 0000000..76ea401 --- /dev/null +++ b/aufgabe4.2/modules/compiler/GCC/4.8.1 @@ -0,0 +1,30 @@ +#%Module + +proc ModulesHelp { } { + puts stderr { 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,...). - Homepage: http://gcc.gnu.org/ + } +} + +module-whatis {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,...). - Homepage: http://gcc.gnu.org/} + +set root /cluster/software/GCC/4.8.1 + +conflict GCC +conflict icc +conflict ifort + +prepend-path CPATH $root/include +prepend-path LD_LIBRARY_PATH $root/lib +prepend-path LD_LIBRARY_PATH $root/lib64 +prepend-path LD_LIBRARY_PATH $root/lib/gcc/x86_64-unknown-linux-gnu/4.8.1 +prepend-path MANPATH $root/share/man +prepend-path PATH $root/bin + +setenv EBROOTGCC "$root" +setenv EBVERSIONGCC "4.8.1" +setenv EBDEVELGCC "$root/easybuild/GCC-4.8.1-easybuild-devel" + + +# built with EasyBuild version 1.9.0 diff --git a/aufgabe4.2/modules/compiler/GCC/4.8.2 b/aufgabe4.2/modules/compiler/GCC/4.8.2 deleted file mode 120000 index 6f3e7d7..0000000 --- a/aufgabe4.2/modules/compiler/GCC/4.8.2 +++ /dev/null @@ -1 +0,0 @@ -/cluster/modules/all/GCC/4.8.2 \ No newline at end of file diff --git a/aufgabe4.2/modules/compiler/GCC/4.8.2 b/aufgabe4.2/modules/compiler/GCC/4.8.2 new file mode 100644 index 0000000..17b77d1 --- /dev/null +++ b/aufgabe4.2/modules/compiler/GCC/4.8.2 @@ -0,0 +1,30 @@ +#%Module + +proc ModulesHelp { } { + puts stderr { 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,...). - Homepage: http://gcc.gnu.org/ + } +} + +module-whatis {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,...). - Homepage: http://gcc.gnu.org/} + +set root /cluster/software/GCC/4.8.2 + +conflict GCC +conflict icc +conflict ifort + +prepend-path CPATH $root/include +prepend-path LD_LIBRARY_PATH $root/lib +prepend-path LD_LIBRARY_PATH $root/lib64 +prepend-path LD_LIBRARY_PATH $root/lib/gcc/x86_64-unknown-linux-gnu/4.8.2 +prepend-path MANPATH $root/share/man +prepend-path PATH $root/bin + +setenv EBROOTGCC "$root" +setenv EBVERSIONGCC "4.8.2" +setenv EBDEVELGCC "$root/easybuild/GCC-4.8.2-easybuild-devel" + + +# built with EasyBuild version 1.9.0 diff --git a/aufgabe4.2/modules/compiler/icc/2013_sp1.1.106 b/aufgabe4.2/modules/compiler/icc/2013_sp1.1.106 deleted file mode 120000 index 9cb9440..0000000 --- a/aufgabe4.2/modules/compiler/icc/2013_sp1.1.106 +++ /dev/null @@ -1 +0,0 @@ -/cluster/modules/all/icc/2013_sp1.1.106 \ No newline at end of file diff --git a/aufgabe4.2/modules/compiler/icc/2013_sp1.1.106 b/aufgabe4.2/modules/compiler/icc/2013_sp1.1.106 new file mode 100644 index 0000000..6414a08 --- /dev/null +++ b/aufgabe4.2/modules/compiler/icc/2013_sp1.1.106 @@ -0,0 +1,28 @@ +#%Module + +proc ModulesHelp { } { + puts stderr { C and C++ compiler from Intel - Homepage: http://software.intel.com/en-us/intel-compilers/ + } +} + +module-whatis {C and C++ compiler from Intel - Homepage: http://software.intel.com/en-us/intel-compilers/} + +set root /cluster/software/icc/2013_sp1.1.106 + +conflict icc +conflict GCC + +prepend-path LD_LIBRARY_PATH $root/lib +prepend-path LD_LIBRARY_PATH $root/lib/intel64 +prepend-path MANPATH $root/man +prepend-path MANPATH $root/man/en_US +prepend-path PATH $root/bin + +setenv EBROOTICC "$root" +setenv EBVERSIONICC "2013_sp1.1.106" +setenv EBDEVELICC "$root/easybuild/icc-2013_sp1.1.106-easybuild-devel" + +prepend-path INTEL_LICENSE_FILE /home/jthalheim/licenses/intel/license.lic +prepend-path NLSPATH $root/idb/intel64/locale/%l_%t/%N + +# built with EasyBuild version 1.9.0 diff --git a/aufgabe4.2/modules/compiler/ifort/2013_sp1.1.106 b/aufgabe4.2/modules/compiler/ifort/2013_sp1.1.106 new file mode 100644 index 0000000..25c2fc7 --- /dev/null +++ b/aufgabe4.2/modules/compiler/ifort/2013_sp1.1.106 @@ -0,0 +1,28 @@ +#%Module + +proc ModulesHelp { } { + puts stderr { Fortran compiler from Intel - Homepage: http://software.intel.com/en-us/intel-compilers/ + } +} + +module-whatis {Fortran compiler from Intel - Homepage: http://software.intel.com/en-us/intel-compilers/} + +set root /cluster/software/ifort/2013_sp1.1.106 + +conflict ifort +conflict GCC + +prepend-path LD_LIBRARY_PATH $root/lib +prepend-path LD_LIBRARY_PATH $root/lib/intel64 +prepend-path MANPATH $root/man +prepend-path MANPATH $root/man/en_US +prepend-path PATH $root/bin + +setenv EBROOTIFORT "$root" +setenv EBVERSIONIFORT "2013_sp1.1.106" +setenv EBDEVELIFORT "$root/easybuild/ifort-2013_sp1.1.106-easybuild-devel" + +prepend-path INTEL_LICENSE_FILE /home/jthalheim/licenses/intel/l_SM3CCW49.lic +prepend-path NLSPATH $root/idb/intel64/locale/%l_%t/%N + +# built with EasyBuild version 1.9.0 diff --git a/aufgabe4.2/modules/modules.install b/aufgabe4.2/modules/modules.install deleted file mode 100644 index 186885d..0000000 --- a/aufgabe4.2/modules/modules.install +++ /dev/null @@ -1,10 +0,0 @@ -post_install() { - echo 'Please run the following command for every user of Modules package' - echo ' /usr/local/Modules/default/bin/add.modules' - echo 'You will likely have to log out and in again to have the environment' - echo 'configured properly' -} - -post_upgrade() { - post_install $1 -} diff --git a/aufgabe4.2/modules/mpi/OpenMPI/1.7.3-GCC-4.8.2 b/aufgabe4.2/modules/mpi/OpenMPI/1.7.3-GCC-4.8.2 deleted file mode 120000 index ad956c0..0000000 --- a/aufgabe4.2/modules/mpi/OpenMPI/1.7.3-GCC-4.8.2 +++ /dev/null @@ -1 +0,0 @@ -/cluster/modules/all/OpenMPI/1.7.3-GCC-4.8.2 \ No newline at end of file diff --git a/aufgabe4.2/modules/mpi/OpenMPI/1.7.3-GCC-4.8.2 b/aufgabe4.2/modules/mpi/OpenMPI/1.7.3-GCC-4.8.2 new file mode 100644 index 0000000..5625240 --- /dev/null +++ b/aufgabe4.2/modules/mpi/OpenMPI/1.7.3-GCC-4.8.2 @@ -0,0 +1,33 @@ +#%Module + +proc ModulesHelp { } { + puts stderr { The Open MPI Project is an open source MPI-2 implementation. - Homepage: http://www.open-mpi.org/ + } +} + +module-whatis {The Open MPI Project is an open source MPI-2 implementation. - Homepage: http://www.open-mpi.org/} + +set root /cluster/software/OpenMPI/1.7.3-GCC-4.8.2 + +conflict OpenMPI + +if { ![is-loaded GCC/4.8.2] } { + module load GCC/4.8.2 +} + +if { ![is-loaded hwloc/1.7.2-GCC-4.8.2] } { + module load hwloc/1.7.2-GCC-4.8.2 +} + +prepend-path CPATH $root/include +prepend-path LD_LIBRARY_PATH $root/lib +prepend-path MANPATH $root/share/man +prepend-path PATH $root/bin +prepend-path PKG_CONFIG_PATH $root/lib/pkgconfig + +setenv EBROOTOPENMPI "$root" +setenv EBVERSIONOPENMPI "1.7.3" +setenv EBDEVELOPENMPI "$root/easybuild/OpenMPI-1.7.3-GCC-4.8.2-easybuild-devel" + + +# built with EasyBuild version 1.9.0 diff --git a/aufgabe4.2/modules/system/CUDA/5.5.22 b/aufgabe4.2/modules/system/CUDA/5.5.22 deleted file mode 120000 index 8748771..0000000 --- a/aufgabe4.2/modules/system/CUDA/5.5.22 +++ /dev/null @@ -1 +0,0 @@ -/cluster/modules/all/CUDA/5.5.22 \ No newline at end of file diff --git a/aufgabe4.2/modules/system/CUDA/5.5.22 b/aufgabe4.2/modules/system/CUDA/5.5.22 new file mode 100644 index 0000000..9a9afd9 --- /dev/null +++ b/aufgabe4.2/modules/system/CUDA/5.5.22 @@ -0,0 +1,16 @@ +#%Module + +proc ModulesHelp { } { + puts stderr { 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. } +} + +module-whatis { 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. } + +set root /cluster/software/CUDA/5.5.22 + +prepend-path CPATH $root/include +prepend-path LD_LIBRARY_PATH $root/lib64 +prepend-path PATH $root/bin +prepend-path PATH $root/open64/bin +prepend-path CUDA_HOME $root +prepend-path CUDA_PATH $root diff --git a/aufgabe4.2/modules/system/hwloc/1.7.2-GCC-4.8.2 b/aufgabe4.2/modules/system/hwloc/1.7.2-GCC-4.8.2 deleted file mode 120000 index c5d3069..0000000 --- a/aufgabe4.2/modules/system/hwloc/1.7.2-GCC-4.8.2 +++ /dev/null @@ -1 +0,0 @@ -/cluster/modules/all/hwloc/1.7.2-GCC-4.8.2 \ No newline at end of file diff --git a/aufgabe4.2/modules/system/hwloc/1.7.2-GCC-4.8.2 b/aufgabe4.2/modules/system/hwloc/1.7.2-GCC-4.8.2 new file mode 100644 index 0000000..d458e35 --- /dev/null +++ b/aufgabe4.2/modules/system/hwloc/1.7.2-GCC-4.8.2 @@ -0,0 +1,39 @@ +#%Module + +proc ModulesHelp { } { + puts stderr { The Portable Hardware Locality (hwloc) software package provides a portable abstraction + (across OS, versions, architectures, ...) of the hierarchical topology of modern architectures, including + NUMA memory nodes, sockets, shared caches, cores and simultaneous multithreading. It also gathers various + system attributes such as cache and memory information as well as the locality of I/O devices such as + network interfaces, InfiniBand HCAs or GPUs. It primarily aims at helping applications with gathering + information about modern computing hardware so as to exploit it accordingly and efficiently. - Homepage: http://www.open-mpi.org/projects/hwloc/ + } +} + +module-whatis {The Portable Hardware Locality (hwloc) software package provides a portable abstraction + (across OS, versions, architectures, ...) of the hierarchical topology of modern architectures, including + NUMA memory nodes, sockets, shared caches, cores and simultaneous multithreading. It also gathers various + system attributes such as cache and memory information as well as the locality of I/O devices such as + network interfaces, InfiniBand HCAs or GPUs. It primarily aims at helping applications with gathering + information about modern computing hardware so as to exploit it accordingly and efficiently. - Homepage: http://www.open-mpi.org/projects/hwloc/} + +set root /cluster/software/hwloc/1.7.2-GCC-4.8.2 + +conflict hwloc + +if { ![is-loaded GCC/4.8.2] } { + module load GCC/4.8.2 +} + +prepend-path CPATH $root/include +prepend-path LD_LIBRARY_PATH $root/lib +prepend-path MANPATH $root/share/man +prepend-path PATH $root/bin +prepend-path PKG_CONFIG_PATH $root/lib/pkgconfig + +setenv EBROOTHWLOC "$root" +setenv EBVERSIONHWLOC "1.7.2" +setenv EBDEVELHWLOC "$root/easybuild/hwloc-1.7.2-GCC-4.8.2-easybuild-devel" + + +# built with EasyBuild version 1.9.0 From 4dd7ec3182862d27348dce70f881338f61dc2e08 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= Date: Sun, 8 Dec 2013 19:52:51 +0100 Subject: [PATCH 2/4] ifort easybuild config --- aufgabe4.1/icc/ifort-2013_sp1.1.106.eb | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 aufgabe4.1/icc/ifort-2013_sp1.1.106.eb diff --git a/aufgabe4.1/icc/ifort-2013_sp1.1.106.eb b/aufgabe4.1/icc/ifort-2013_sp1.1.106.eb new file mode 100644 index 0000000..74a6baf --- /dev/null +++ b/aufgabe4.1/icc/ifort-2013_sp1.1.106.eb @@ -0,0 +1,18 @@ +name = 'ifort' +version = '2013_sp1.1.106' + +homepage = 'http://software.intel.com/en-us/intel-compilers/' +description = "Fortran compiler from Intel" + +toolchain = {'name': 'dummy', 'version': 'dummy'} + +sources = ['l_fcompxe_2013_sp1.1.106.tgz'] + +# compiler class +moduleclass = 'compiler' + +dontcreateinstalldir = 'True' + +# license file +import os +license_file = os.path.join(os.getenv('HOME'), "licenses", "intel", "license.lic") From ac208d1dc18b255d8ae53aab2d44893736866569 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= Date: Sun, 8 Dec 2013 19:56:14 +0100 Subject: [PATCH 3/4] ifort compiler: Befehl zum laden --- bericht/abschnitte/prov-compiler.tex | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/bericht/abschnitte/prov-compiler.tex b/bericht/abschnitte/prov-compiler.tex index ee31983..a7801e4 100644 --- a/bericht/abschnitte/prov-compiler.tex +++ b/bericht/abschnitte/prov-compiler.tex @@ -26,3 +26,12 @@ finden. Zwischen den Versionen kann mit folgendem Befehl gewechselt werden: Wir installierten die Intel Compiler Suite in der Version 2013\_sp1.1.106 Die für easybuild (\ref{sec:easybuild}) benötigten Paket-Beschreibungen sind in \emph{aufgabe4.1/icc} zu finden. + +Der C-Compiler wird mit folgenden Befehl geladen: + +\shellcmd{module load icc} + +und der Fortran-Compiler diesem: + +\shellcmd{module load ifort} + From ad91308b7477c4bffa936b1d4e33502d75d79302 Mon Sep 17 00:00:00 2001 From: Alfred Krohmer Date: Sun, 8 Dec 2013 21:13:48 +0100 Subject: [PATCH 4/4] =?UTF-8?q?Provisionierung=20hinzugef=C3=BCgt?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- aufgabe4.4/clone.sh | 20 ++++ aufgabe4.4/cluster | 124 +++++++++++++++++++++++ aufgabe4.4/dhcpd.client.conf | 6 ++ aufgabe4.4/dhcpd.conf | 124 +++++++++++++++++++++++ aufgabe4.4/dhcpd.d/all | 4 + aufgabe4.4/dhcpd.d/zotac1 | 6 ++ aufgabe4.4/dhcpd.d/zotac2 | 6 ++ aufgabe4.4/dhcpd.d/zotac3 | 6 ++ aufgabe4.4/dhcpd.d/zotac4 | 6 ++ aufgabe4.4/partclone.dd-clone | 3 + aufgabe4.4/partclone.dd-restore | 3 + aufgabe4.4/pxelinux.cfg/clone | 3 + aufgabe4.4/pxelinux.cfg/default | 3 + aufgabe4.4/pxelinux.cfg/local | 5 + aufgabe4.4/pxelinux.cfg/restore | 3 + aufgabe4.4/restore.sh | 42 ++++++++ aufgabe4.4/tftpd.service | 10 ++ bericht/abschnitte/prov-provisioning.tex | 36 +++++++ 18 files changed, 410 insertions(+) create mode 100644 aufgabe4.4/clone.sh create mode 100755 aufgabe4.4/cluster create mode 100644 aufgabe4.4/dhcpd.client.conf create mode 100644 aufgabe4.4/dhcpd.conf create mode 100644 aufgabe4.4/dhcpd.d/all create mode 100644 aufgabe4.4/dhcpd.d/zotac1 create mode 100644 aufgabe4.4/dhcpd.d/zotac2 create mode 100644 aufgabe4.4/dhcpd.d/zotac3 create mode 100644 aufgabe4.4/dhcpd.d/zotac4 create mode 100644 aufgabe4.4/partclone.dd-clone create mode 100644 aufgabe4.4/partclone.dd-restore create mode 100644 aufgabe4.4/pxelinux.cfg/clone create mode 100644 aufgabe4.4/pxelinux.cfg/default create mode 100644 aufgabe4.4/pxelinux.cfg/local create mode 100644 aufgabe4.4/pxelinux.cfg/restore create mode 100644 aufgabe4.4/restore.sh create mode 100644 aufgabe4.4/tftpd.service diff --git a/aufgabe4.4/clone.sh b/aufgabe4.4/clone.sh new file mode 100644 index 0000000..b31b6ed --- /dev/null +++ b/aufgabe4.4/clone.sh @@ -0,0 +1,20 @@ +#!/bin/sh + +IP="10.20.0.1" + +# our partclone.dd wrapper script to support ext4 +cd /usr/sbin +mv partclone.dd partclone.dd-backup +wget http://$IP/pxelinux/scripts/partclone.dd-clone -O partclone.dd +chmod +x partclone.dd + +# mount NFS and symlink image folder +mount -t nfs $IP:/cluster /mnt +rm -rf /home/partimag +ln -s /mnt/images /home/partimag + +# save image and umount NFS afterwards +ocs-sr -b -p /bin/true -z3 saveparts computenode sda1 sda3 +umount /mnt + +bash diff --git a/aufgabe4.4/cluster b/aufgabe4.4/cluster new file mode 100755 index 0000000..54755ff --- /dev/null +++ b/aufgabe4.4/cluster @@ -0,0 +1,124 @@ +#!/bin/bash + +function valid_ip() +{ + local ip=$1 + local stat=1 + + if [[ $ip =~ ^[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}$ ]]; then + OIFS=$IFS + IFS='.' + ip=($ip) + IFS=$OIFS + [[ ${ip[0]} -le 255 && ${ip[1]} -le 255 \ + && ${ip[2]} -le 255 && ${ip[3]} -le 255 ]] + stat=$? + fi + return $stat +} + +function valid_mac() +{ + local mac=$1 + + if [[ $mac =~ ^[0-9a-z]{2}:[0-9a-z]{2}:[0-9a-z]{2}:[0-9a-z]{2}:[0-9a-z]{2}:[0-9a-z]{2}$ ]]; then + return 0 + fi + + return 1 +} + + +if [ $# -lt 2 ] +then + echo "Usage: $0 add HOSTNAME IP HWADDR | delete HOSTNAME | set-clone HOSTNAME | set-restore HOSTNAME | set-normal HOSTNAME" >&2 + exit 1 +fi + +if [[ $2 = *[[:space:]]* ]] +then + echo "Hostname must not contain whitespaces" + exit 1 +fi +HOSTNAME="$2" + +if [ "$1" == "status" ] +then + echo -n "$HOSTNAME is booting " + TARGET="`readlink /srv/tftp/pxelinux/pxelinux.cfg/$HOSTNAME`" + if [ "$TARGET" == "/pxelinux.cfg/local" ] + then + echo "from local harddisk" + elif [ "$TARGET" == "/pxelinux.cfg/live" ]; then + echo "to live Clonezilla environment" + elif [ "$TARGET" == "/pxelinux.cfg/clone" ]; then + echo "to Clonezilla to clone its harddisk" + elif [ "$TARGET" == "/pxelinux.cfg/live" ]; then + echo "to Clonezilla to restore its harddisk" + fi + + exit 0 +fi + +if [ "$1" == "add" ] +then + if [ $# -lt 4 ] + then + echo "Missing arguments" >&2 + exit 1 + fi + + if ! valid_ip $3; then + echo "Invalid IP: $3" >&2 + exit 1 + fi + IP="$3" + + if ! valid_mac $4; then + echo "Invalid MAC: $4" >&2 + exit 1 + fi + HWADDR="$4" + + grep -q "include \"/etc/dhcpd.d/$HOSTNAME\";" /etc/dhcpd.d/all || echo "include \"/etc/dhcpd.d/$HOSTNAME\";" >> /etc/dhcpd.d/all + [ -e "/etc/dhcpd.d/$HOSTNAME" ] || cat /etc/dhcpd.client.conf | sed "s/HOSTNAME/$HOSTNAME/g" | sed "s/HWADDR/$HWADDR/g" > "/etc/dhcpd.d/$HOSTNAME" + grep -q "$HOSTNAME A $IP" /var/named/zotac.zone || (echo "$HOSTNAME A $IP" >> /var/named/zotac.zone && rndc reload zotac) + + ln -sf /srv/tftp/pxelinux/pxelinux.cfg/default /srv/tftp/pxelinux/pxelinux.cfg/$HOSTNAME +fi + +if [ "$1" == "delete" ] +then + rm -f "/etc/dhcpd.d/$HOSTNAME" + sed -i "/include \"\/etc\/dhcpd.d\/$HOSTNAME\";/d" /etc/dhcpd.d/all + sed -i "/$HOSTNAME A $IP/d" /var/named/zotac.zone + rndc reload zotac + + rm -f /srv/tftp/pxelinux/pxelinux.cfg/$HOSTNAME +fi + +if [ "$1" == "set-live" ] +then + sed -i -E "s/^(\s*)#filename \"\/pxelinux.0\";/\\1filename \"\/pxelinux.0\";/" "/etc/dhcpd.d/$HOSTNAME" + ln -sf /pxelinux.cfg/default /srv/tftp/pxelinux/pxelinux.cfg/$HOSTNAME +fi + +if [ "$1" == "set-clone" ] +then + sed -i -E "s/^(\s*)#filename \"\/pxelinux.0\";/\\1filename \"\/pxelinux.0\";/" "/etc/dhcpd.d/$HOSTNAME" + ln -sf /pxelinux.cfg/clone /srv/tftp/pxelinux/pxelinux.cfg/$HOSTNAME +fi + +if [ "$1" == "set-restore" ] +then + sed -i -E "s/^(\s*)#filename \"\/pxelinux.0\";/\\1filename \"\/pxelinux.0\";/" "/etc/dhcpd.d/$HOSTNAME" + ln -sf /pxelinux.cfg/restore /srv/tftp/pxelinux/pxelinux.cfg/$HOSTNAME +fi + +if [ "$1" == "set-local" ] +then + #sed -i -E "s/^(\s*)filename \"\/pxelinux.0\";/\\1#filename \"\/pxelinux.0\";/" "/etc/dhcpd.d/$HOSTNAME" + ln -sf /pxelinux.cfg/local /srv/tftp/pxelinux/pxelinux.cfg/$HOSTNAME +fi + +systemctl restart dhcpd4@eth1 diff --git a/aufgabe4.4/dhcpd.client.conf b/aufgabe4.4/dhcpd.client.conf new file mode 100644 index 0000000..2796121 --- /dev/null +++ b/aufgabe4.4/dhcpd.client.conf @@ -0,0 +1,6 @@ +host HOSTNAME { + hardware ethernet HWADDR; + fixed-address HOSTNAME; + option configfile "pxelinux.cfg/HOSTNAME"; + #filename "/pxelinux.0"; +} diff --git a/aufgabe4.4/dhcpd.conf b/aufgabe4.4/dhcpd.conf new file mode 100644 index 0000000..f4164e6 --- /dev/null +++ b/aufgabe4.4/dhcpd.conf @@ -0,0 +1,124 @@ +# dhcpd.conf +# +# Sample configuration file for ISC dhcpd +# + +# option definitions common to all supported networks... +option domain-name "zotac"; +option domain-name-servers zotac0.zotac; + +option dhcp-parameter-request-list = concat(option dhcp-parameter-request-list,d1); +option configfile code 209 = text; + +use-host-decl-names true; + +default-lease-time 43200; +max-lease-time 86400; + +# Use this to enble / disable dynamic dns updates globally. +#ddns-update-style none; + +# If this DHCP server is the official DHCP server for the local +# network, the authoritative directive should be uncommented. +authoritative; + +allow booting; +allow bootp; + +# Use this to send dhcp log messages to a different log file (you also +# have to hack syslog.conf to complete the redirection). +log-facility local7; + +# No service will be given on this subnet, but declaring it helps the +# DHCP server to understand the network topology. + +subnet 10.20.0.0 netmask 255.255.255.0 { +# range 10.20.0.100 10.20.0.200; + option routers zotac0.zotac; +} + +# This is a very basic subnet declaration. + +#subnet 10.254.239.0 netmask 255.255.255.224 { +# range 10.254.239.10 10.254.239.20; +# option routers rtr-239-0-1.example.org, rtr-239-0-2.example.org; +#} + +# This declaration allows BOOTP clients to get dynamic addresses, +# which we don't really recommend. + +#subnet 10.254.239.32 netmask 255.255.255.224 { +# range dynamic-bootp 10.254.239.40 10.254.239.60; +# option broadcast-address 10.254.239.31; +# option routers rtr-239-32-1.example.org; +#} + +# A slightly different configuration for an internal subnet. +#subnet 10.5.5.0 netmask 255.255.255.224 { +# range 10.5.5.26 10.5.5.30; +# option domain-name-servers ns1.internal.example.org; +# option domain-name "internal.example.org"; +# option routers 10.5.5.1; +# option broadcast-address 10.5.5.31; +# default-lease-time 600; +# max-lease-time 7200; +#} + +# Hosts which require special configuration options can be listed in +# host statements. If no address is specified, the address will be +# allocated dynamically (if possible), but the host-specific information +# will still come from the host declaration. + +#host zotac1 { +# hardware ethernet 00:1c:c0:d5:a9:ee; +# fixed-address zotac1.zotac; +# use-host-decl-names true; +# next-server 10.20.0.1; +# filename "/pxelinux.0"; +#} + +include "/etc/dhcpd.d/all"; + +#host passacaglia { +# hardware ethernet 0:0:c0:5d:bd:95; +# filename "vmunix.passacaglia"; +# server-name "toccata.fugue.com"; +#} + +# Fixed IP addresses can also be specified for hosts. These addresses +# should not also be listed as being available for dynamic assignment. +# Hosts for which fixed IP addresses have been specified can boot using +# BOOTP or DHCP. Hosts for which no fixed address is specified can only +# be booted with DHCP, unless there is an address range on the subnet +# to which a BOOTP client is connected which has the dynamic-bootp flag +# set. +#host fantasia { +# hardware ethernet 08:00:07:26:c0:a5; +# fixed-address fantasia.fugue.com; +#} + +# You can declare a class of clients and then do address allocation +# based on that. The example below shows a case where all clients +# in a certain class get addresses on the 10.17.224/24 subnet, and all +# other clients get addresses on the 10.0.29/24 subnet. + +#class "foo" { +# match if substring (option vendor-class-identifier, 0, 4) = "SUNW"; +#} +# +#shared-network 224-29 { +# subnet 10.17.224.0 netmask 255.255.255.0 { +# option routers rtr-224.example.org; +# } +# subnet 10.0.29.0 netmask 255.255.255.0 { +# option routers rtr-29.example.org; +# } +# pool { +# allow members of "foo"; +# range 10.17.224.10 10.17.224.250; +# } +# pool { +# deny members of "foo"; +# range 10.0.29.10 10.0.29.230; +# } +#} diff --git a/aufgabe4.4/dhcpd.d/all b/aufgabe4.4/dhcpd.d/all new file mode 100644 index 0000000..14f90a0 --- /dev/null +++ b/aufgabe4.4/dhcpd.d/all @@ -0,0 +1,4 @@ +include "/etc/dhcpd.d/zotac1"; +include "/etc/dhcpd.d/zotac2"; +include "/etc/dhcpd.d/zotac3"; +include "/etc/dhcpd.d/zotac4"; diff --git a/aufgabe4.4/dhcpd.d/zotac1 b/aufgabe4.4/dhcpd.d/zotac1 new file mode 100644 index 0000000..3c48221 --- /dev/null +++ b/aufgabe4.4/dhcpd.d/zotac1 @@ -0,0 +1,6 @@ +host zotac1 { + hardware ethernet 00:1c:c0:d5:a9:ee; + fixed-address zotac1; + option configfile "pxelinux.cfg/zotac1"; + filename "/pxelinux.0"; +} diff --git a/aufgabe4.4/dhcpd.d/zotac2 b/aufgabe4.4/dhcpd.d/zotac2 new file mode 100644 index 0000000..08e3927 --- /dev/null +++ b/aufgabe4.4/dhcpd.d/zotac2 @@ -0,0 +1,6 @@ +host zotac2 { + hardware ethernet 00:01:2e:2c:91:69; + fixed-address zotac2; + option configfile "pxelinux.cfg/zotac2"; + filename "/pxelinux.0"; +} diff --git a/aufgabe4.4/dhcpd.d/zotac3 b/aufgabe4.4/dhcpd.d/zotac3 new file mode 100644 index 0000000..8b4a4df --- /dev/null +++ b/aufgabe4.4/dhcpd.d/zotac3 @@ -0,0 +1,6 @@ +host zotac3 { + hardware ethernet 00:01:2e:2c:82:f1; + fixed-address zotac3; + option configfile "pxelinux.cfg/zotac3"; + filename "/pxelinux.0"; +} diff --git a/aufgabe4.4/dhcpd.d/zotac4 b/aufgabe4.4/dhcpd.d/zotac4 new file mode 100644 index 0000000..2354a65 --- /dev/null +++ b/aufgabe4.4/dhcpd.d/zotac4 @@ -0,0 +1,6 @@ +host zotac4 { + hardware ethernet 00:01:2e:2c:5d:09; + fixed-address zotac4; + option configfile "pxelinux.cfg/zotac4"; + filename "/pxelinux.0"; +} diff --git a/aufgabe4.4/partclone.dd-clone b/aufgabe4.4/partclone.dd-clone new file mode 100644 index 0000000..3503db6 --- /dev/null +++ b/aufgabe4.4/partclone.dd-clone @@ -0,0 +1,3 @@ +#!/bin/bash + +exec /usr/sbin/partclone.ext4 -c "$@" diff --git a/aufgabe4.4/partclone.dd-restore b/aufgabe4.4/partclone.dd-restore new file mode 100644 index 0000000..e82a331 --- /dev/null +++ b/aufgabe4.4/partclone.dd-restore @@ -0,0 +1,3 @@ +#!/bin/bash + +exec /usr/sbin/partclone.ext4 -r "$@" diff --git a/aufgabe4.4/pxelinux.cfg/clone b/aufgabe4.4/pxelinux.cfg/clone new file mode 100644 index 0000000..8fee4fc --- /dev/null +++ b/aufgabe4.4/pxelinux.cfg/clone @@ -0,0 +1,3 @@ +label Clonezilla-live +MENU LABEL Clonezilla Live (Ramdisk) +DEFAULT vmlinuz initrd=initrd.img boot=live config noswap nolocales edd=on nomodeset ocs_prerun1="wget http://10.20.0.1/pxelinux/scripts/clone.sh -P /tmp" ocs_live_run="bash /tmp/clone.sh" ocs_live_extra_param="" keyboard-layouts="de" ocs_live_batch="no" live-getty locales="en_US.UTF-8" vga=788 nosplash noprompt fetch=tftp://10.20.0.1/filesystem.squashfs ethdevice-timeout=120 ocs_daemonon="ssh" usercrypted=h651XdpmWpnEo diff --git a/aufgabe4.4/pxelinux.cfg/default b/aufgabe4.4/pxelinux.cfg/default new file mode 100644 index 0000000..5c84983 --- /dev/null +++ b/aufgabe4.4/pxelinux.cfg/default @@ -0,0 +1,3 @@ +label Clonezilla-live +MENU LABEL Clonezilla Live (Ramdisk) +DEFAULT vmlinuz initrd=initrd.img boot=live config noswap nolocales edd=on nomodeset ocs_live_run="bash" ocs_live_extra_param="" keyboard-layouts="de" ocs_live_batch="no" live-getty locales="en_US.UTF-8" vga=788 nosplash noprompt fetch=tftp://10.20.0.1/filesystem.squashfs ethdevice-timeout=120 ocs_daemonon="ssh" usercrypted=h651XdpmWpnEo diff --git a/aufgabe4.4/pxelinux.cfg/local b/aufgabe4.4/pxelinux.cfg/local new file mode 100644 index 0000000..af38d2a --- /dev/null +++ b/aufgabe4.4/pxelinux.cfg/local @@ -0,0 +1,5 @@ +DEFAULT localboot +label localboot +MENU LABEL localboot +COM32 chain.c32 +APPEND hd0 diff --git a/aufgabe4.4/pxelinux.cfg/restore b/aufgabe4.4/pxelinux.cfg/restore new file mode 100644 index 0000000..c8275ea --- /dev/null +++ b/aufgabe4.4/pxelinux.cfg/restore @@ -0,0 +1,3 @@ +label Clonezilla-live +MENU LABEL Clonezilla Live (Ramdisk) +DEFAULT vmlinuz initrd=initrd.img boot=live config noswap nolocales edd=on nomodeset ocs_prerun1="wget http://10.20.0.1/pxelinux/scripts/restore.sh -P /tmp" ocs_live_run="bash /tmp/restore.sh" ocs_live_extra_param="" keyboard-layouts="de" ocs_live_batch="no" live-getty locales="en_US.UTF-8" vga=788 nosplash noprompt fetch=tftp://10.20.0.1/filesystem.squashfs ethdevice-timeout=120 ocs_daemonon="ssh" usercrypted=h651XdpmWpnEo diff --git a/aufgabe4.4/restore.sh b/aufgabe4.4/restore.sh new file mode 100644 index 0000000..0eebd24 --- /dev/null +++ b/aufgabe4.4/restore.sh @@ -0,0 +1,42 @@ +#!/bin/sh + +IP="10.20.0.1" + +# our partclone.dd wrapper script to support ext4 +cd /usr/sbin +mv partclone.dd partclone.dd-backup +wget http://$IP/pxelinux/scripts/partclone.dd-restore -O partclone.dd +chmod +x partclone.dd + +# mount NFS and symlink image folder +mount -t nfs $IP:/cluster /mnt +rm -rf /home/partimag +ln -s /mnt/images /home/partimag + +# restore image and umount NFS afterwards +ocs-sr -b -p /bin/true -e -g auto restoreparts computenode sda1 sda3 +umount /mnt + +# mount restored system +mount /dev/sda3 /mnt +mount /dev/sda1 /mnt/boot +mount -o bind /proc /mnt/proc +mount -o bind /dev /mnt/dev +mount -o bind /sys /mnt/sys + +# create system specific initrd +chroot /mnt /usr/bin/mkinitcpio -p linux + +# create miscellaneous file systems +mkswap -U 72f3bc4e-237f-4737-94fa-fa3e4d598642 /dev/sda2 +mkfs.xfs /dev/sda5 +xfs_admin -U cf837a59-c7b3-40a9-bf83-20acb6eb0fb8 /dev/sda5 + +# clean up +umount /mnt/sys +umount /mnt/dev +umount /mnt/proc +umount /mnt/boot +umount /mnt + +bash diff --git a/aufgabe4.4/tftpd.service b/aufgabe4.4/tftpd.service new file mode 100644 index 0000000..03bbb22 --- /dev/null +++ b/aufgabe4.4/tftpd.service @@ -0,0 +1,10 @@ +[Unit] +Description=hpa's original TFTP daemon + +[Service] +Type=forking +ExecStart=/usr/bin/in.tftpd -l -s -vv /srv/tftp/pxelinux +StandardError=journal + +[Install] +WantedBy=multi-user.target diff --git a/bericht/abschnitte/prov-provisioning.tex b/bericht/abschnitte/prov-provisioning.tex index f047b49..09b5f06 100644 --- a/bericht/abschnitte/prov-provisioning.tex +++ b/bericht/abschnitte/prov-provisioning.tex @@ -1,2 +1,38 @@ \subsection{Provisionierung} \label{sub:provisionierung} + +\subsubsection{Vorbereitung} + +\begin{sloppypar} + +Wir verwenden Clonezilla um die Provisionierung durchzuführen. Um dieses auf den Computenodes zu booten, haben wir den {\tt in.tftpd}-Server installiert und das Service-File für {\tt systemd} angepasst (siehe {\tt aufgabe4.4/tftpd.service}). Außerdem haben wir die Konfiguration des DHCP-Servers so angepasst, dass nun jeder Compute-Node eine eigene Konfigurationsdatei in {\tt /etc/dhcpd.d/} hat, die jeweils in von {\tt /etc/dhcpd.d/all} inkludiert wird. + +Außerdem haben wir ein Script {\tt cluster} geschrieben, mit dem die Computenodes verwaltet werden können. Mit +\begin{lstlisting} +cluster add +\end{lstlisting} +wird ein neuer Node hinzugefügt (DHCP- und DNS-Eintrag). Mit +\begin{lstlisting} +cluster set- +\end{lstlisting} +kann der Modus für den nächsten Boot des Nodes festgelegt werden. Hier kann man zwischen {\tt local} (Boot von lokaler Festplatte), {\tt live} (Boot in das Clonezilla Image), {\tt clone} (Clonen nach Boot) und {\tt restore} (Image laden nach Boot) wählen. + +Um den Netzwerk-Boot zu ermöglichen, haben wir {\tt pxelinux} unter {\tt /srv/tftp/pxelinux} installiert und konfiguriert. In dieses Verzeichnis haben wir die Dateien {\tt vmlinuz}, {\tt initrd.img} und {\tt filesystem.squashfs} aus der Clonezilla-Live-ISO kopiert, sowie außerdem noch {\tt ldlinux.c32, libcom32.c32, libutil.c32, menu.c32, chain.c32} und {\tt pxelinux.0} aus der {\tt syslinux}-Installation. Die Konfigurationsdateien liegen in {\tt /srv/tftp/pxelinux/pxelinux.cfg}. + +\end{sloppypar} + +\subsubsection{Provisionierung der Computenodes} + +\begin{sloppypar} + +Um den Clone-Vorgang zu starten, wir nun mit {\tt sudo cluster set-clone } und anschließendem (Neu-)Starten des Nodes das Clonezilla Live Image gebootet. Dieses holt sich nun vom Headnode ein Script und führt dieses aus. In diesem Script haben wir alle nötigen Befehle eingetragen, um das Clonen vorzubereiten und zu starten (siehe {\tt aufgabe4.4/clone.sh}). Dazu wird per NFS das {\tt /cluster}-Verzeichnis des Headnodes eingebunden und dort im Unterverzeichnis {\tt images} das Image der Festplatte abgelegt. Geclont werden nur die {\tt /}- und die {\tt /boot}-Partition. + +Zum Wiederherstellen des Images wird mit {\tt sudo cluster set-restore } wieder der entsprechende Boot-Modus gesetzt und der Node neugestartet. Dort wird nun ein anderes Script vom Headnode geholt (siehe {\tt aufgabe4.4/restore.sh}) und die beiden Partitionen wiederhergestellt. Anschließend werden noch die Swap-Partition und die Daten-Partition für das verteilte Dateisystem neu formatiert und die alten UUIDs gesetzt. + +Da Clonezilla bei uns {\tt ext4} irgendwie nicht erkannt hat, hat es, um die Partitionen zu klonen, {\tt partclone.dd} verwendet, was allerdings sehr langsam ist, weil es die komplette Partition klont und freie Blöcke nicht auslässt. Deswegen haben wir zwei kleine Wrapper-Scripts geschrieben, die stattdessen {\tt partclone.ext4} aufrufen. (siehe {\tt aufgabe4.4/partclone.dd-clone} und {\tt partclone.dd-restore}) + +Da wir in unserem Cluster gemischte Boards haben (Intel und Zotac), mussten wir anschließend außerdem noch das Ziel-Root-Verzeichnis mounten und dort mit {\tt mkinitcpio -p linux} ein neues {\tt initrd} erstellen lassen, damit die entsprechenden richtigen Treiber beim Bootvorgang geladen werden können. + +Um die automatische Umbenennung der Netzwerk-Interfaces vorzubeugen, mussten wir außerdem einen Symlink {\tt /etc/udev/rules.d/80-net-name-slot.rules -> /dev/null} erstellen. Dieser verhindert, dass das Ethernet-Interface nicht enpXsY sondern fest eth0 benannt wird. + +\end{sloppypar} \ No newline at end of file