{"id":4072,"date":"2018-10-17T10:55:21","date_gmt":"2018-10-17T10:55:21","guid":{"rendered":"http:\/\/escience.sdu.dk\/?page_id=4072"},"modified":"2019-05-28T11:58:41","modified_gmt":"2019-05-28T11:58:41","slug":"easybuild","status":"publish","type":"page","link":"http:\/\/escience.sdu.dk\/index.php\/easybuild\/","title":{"rendered":"EasyBuild"},"content":{"rendered":"<h4>What is EasyBuild ?<\/h4>\n<p><a href=\"https:\/\/easybuild.readthedocs.io\/en\/latest\/\">EasyBuild<\/a> is a software build and installation framework written in Python, which allows to deploy and manage (scientific) applications on High Performance Computing systems. EasyBuild v3.6.2 is currently installed on ABACUS2.0 and can be loaded as a module:<\/p>\n<pre><code>testuser@fe1:~$ module load\u00a0easybuild<\/code><\/pre>\n<h4>How to search for a particular software<\/h4>\n<p>The shell command\u00a0<code>eb -S<\/code>\u00a0is used to search for\u00a0<em>easyconfig files <\/em>included in the EasyBuild online\u00a0<a href=\"https:\/\/github.com\/easybuilders\/easybuild-easyconfigs\/tree\/master\/easybuild\/easyconfigs\/\">repository<\/a>. Easyconfig files are used to specify the version, dependencies and build parameters of the software. For example:<\/p>\n<pre><code>testuser@fe1:~$ eb\u00a0-S\u00a0'^Python-3.6.4-*'\n...\n  * $CFGS1\/Python-3.6.4-foss-2017a.eb\n  * $CFGS1\/Python-3.6.4-foss-2018a.eb\n  * $CFGS1\/Python-3.6.4-golf-2018a.eb\n  * $CFGS1\/Python-3.6.4-intel-2018a.eb\n  * $CFGS1\/Python-3.6.4-iomkl-2018.02.eb\n  * $CFGS1\/Python-3.6.4-iomkl-2018a.eb<\/code><\/pre>\n<p>The output shows the list of well-tested easyconfig\u00a0files which include the instructions to configure, build and install the application with a particular compiler toolchain. The full list of toolchains implemented in the EasyBuild environment is printed with the command:\u00a0<code>eb --list-toolchains<\/code>. Currently, the following toolchains are installed on ABACUS2.0 and can be loaded together with the\u00a0<code>easybuild<\/code>\u00a0module.<\/p>\n<pre><code>foss    date       binutils   GCC     Open MPI   OpenBLAS    LAPACK                 ScaLAPACK    FFTW\n2017b   Jul 2017   2.28       6.4.0   2.1.1\t 0.2.20     (incl. with OpenBLAS)   2.0.20   \t3.3.6\n2018a   Jan 2018   2.28       6.4.0   2.1.2\t 0.2.20     (incl. with OpenBLAS)   2.0.20  \t3.3.7\n2018b   Jul 2018   2.30       7.3.0   3.1.1\t 0.3.1      (incl. with OpenBLAS)   2.0.20   \t3.3.8\n\ngoolfc\tdate\t   binutils   GCC     Open MPI\t OpenBLAS    LAPACK      \t   ScaLAPACK\tFFTW\tCUDA\n2018a   Jan 2018   2.28       6.4.0   2.1.2\t 0.2.20     (incl. with OpenBLAS)   2.0.20   \t3.3.7\t9.1.85\n\nintel\tdate       binutils   GCC     Intel compilers\t    Intel MPI\t    Intel MKL\n2018a\tJan 2018   2.28\t      6.4.0   2018.1.163\t    2018.1.163\t    2018.1.163\n2018b\tJul 2018   2.30\t      7.3.0   2018.3.222\t    2018.3.222\t    2018.3.222\n\niomkl\tdate       binutils   GCC     Intel Compilers\t    Open MPI\t    Intel MKL\n2018a\tJan 2018   2.28\t      6.4.0   2018.1.163 \t    2.1.2 \t    2018.1.163\n2018b\tJul 2018   2.30\t      7.3.0   2018.3.222            3.1.1   \t    2018.3.222<\/code> <code>\n<\/code><\/pre>\n<h4>How to install a software using the online repository<\/h4>\n<p>It is possible to check all the dependencies defined in a particular software easyconfig file by executing the\u00a0<code>eb<\/code>\u00a0command with the option\u00a0<code>--dry-run<\/code>\u00a0(or\u00a0<code>-D<\/code>). For example:<\/p>\n<pre><code>testuser@fe1:~$ eb GROMACS-2018-foss-2018a.eb -D\nDry run: printing build status of easyconfigs and dependencies\n...\n * [x] $CFGS\/m\/M4\/M4-1.4.18.eb (module: M4\/1.4.18)\n * [x] $CFGS\/z\/zlib\/zlib-1.2.11.eb (module: zlib\/1.2.11)\n * [x] $CFGS\/h\/help2man\/help2man-1.47.4.eb (module: help2man\/1.47.4)\n * [x] $CFGS\/m\/M4\/M4-1.4.17.eb (module: M4\/1.4.17)\n * [x] $CFGS\/b\/Bison\/Bison-3.0.4.eb (module: Bison\/3.0.4)\n * [x] $CFGS\/f\/flex\/flex-2.6.3.eb (module: flex\/2.6.3)\n * [x] $CFGS\/b\/binutils\/binutils-2.28.eb (module: binutils\/2.28)\n * [x] $CFGS\/g\/GCCcore\/GCCcore-6.4.0.eb (module: GCCcore\/6.4.0)\n * [x] $CFGS\/m\/M4\/M4-1.4.18-GCCcore-6.4.0.eb (module: M4\/1.4.18-GCCcore-6.4.0)\n * [x] $CFGS\/z\/zlib\/zlib-1.2.11-GCCcore-6.4.0.eb (module: zlib\/1.2.11-GCCcore-6.4.0)\n * [x] $CFGS\/h\/help2man\/help2man-1.47.4-GCCcore-6.4.0.eb (module: help2man\/1.47.4-GCCcore-6.4.0)\n * [x] $CFGS\/b\/Bison\/Bison-3.0.4-GCCcore-6.4.0.eb (module: Bison\/3.0.4-GCCcore-6.4.0)\n * [x] $CFGS\/f\/flex\/flex-2.6.4-GCCcore-6.4.0.eb (module: flex\/2.6.4-GCCcore-6.4.0)\n * [x] $CFGS\/b\/binutils\/binutils-2.28-GCCcore-6.4.0.eb (module: binutils\/2.28-GCCcore-6.4.0)\n * [x] $CFGS\/g\/GCC\/GCC-6.4.0-2.28.eb (module: GCC\/6.4.0-2.28)\n * [x] $CFGS\/o\/OpenBLAS\/OpenBLAS-0.2.20-GCC-6.4.0-2.28.eb (module: OpenBLAS\/0.2.20-GCC-6.4.0-2.28)\n * [x] $CFGS\/a\/Autoconf\/Autoconf-2.69-GCCcore-6.4.0.eb (module: Autoconf\/2.69-GCCcore-6.4.0)\n * [x] $CFGS\/a\/Automake\/Automake-1.15.1-GCCcore-6.4.0.eb (module: Automake\/1.15.1-GCCcore-6.4.0)\n * [x] $CFGS\/n\/ncurses\/ncurses-6.0-GCCcore-6.4.0.eb (module: ncurses\/6.0-GCCcore-6.4.0)\n * [ ] $CFGS\/c\/CMake\/CMake-3.10.2-GCCcore-6.4.0.eb (module: CMake\/3.10.2-GCCcore-6.4.0)\n * [x] $CFGS\/l\/libtool\/libtool-2.4.6-GCCcore-6.4.0.eb (module: libtool\/2.4.6-GCCcore-6.4.0)\n * [x] $CFGS\/a\/Autotools\/Autotools-20170619-GCCcore-6.4.0.eb (module: Autotools\/20170619-GCCcore-6.4.0)\n * [x] $CFGS\/n\/numactl\/numactl-2.0.11-GCCcore-6.4.0.eb (module: numactl\/2.0.11-GCCcore-6.4.0)\n * [x] $CFGS\/h\/hwloc\/hwloc-1.11.8-GCCcore-6.4.0.eb (module: hwloc\/1.11.8-GCCcore-6.4.0)\n * [x] $CFGS\/o\/OpenMPI\/OpenMPI-2.1.2-GCC-6.4.0-2.28.eb (module: OpenMPI\/2.1.2-GCC-6.4.0-2.28)\n * [x] $CFGS\/g\/gompi\/gompi-2018a.eb (module: gompi\/2018a)\n * [x] $CFGS\/f\/FFTW\/FFTW-3.3.7-gompi-2018a.eb (module: FFTW\/3.3.7-gompi-2018a)\n * [x] $CFGS\/s\/ScaLAPACK\/ScaLAPACK-2.0.2-gompi-2018a-OpenBLAS-0.2.20.eb (module: ScaLAPACK\/2.0.2-gompi-2018a-OpenBLAS-0.2.20)\n * [x] $CFGS\/f\/foss\/foss-2018a.eb (module: foss\/2018a)\n * [ ] $CFGS\/g\/GROMACS\/GROMACS-2018-foss-2018a.eb (module: GROMACS\/2018-foss-2018a)\n== Temporary log file(s) \/tmp\/eb-tXC0pK\/easybuild-smjQ9R.log* have been removed.\n== Temporary directory \/tmp\/eb-tXC0pK has been removed.<\/code><\/pre>\n<p>All the dependencies marked with\u00a0<code>[x]<\/code> are already installed on ABACUS2.0 and can be loaded together with the EasyBuild module. The user can enforce the installation of the missing dependencies using\u00a0<code>--robot\/-r<\/code>, e.g.<\/p>\n<pre>\u00a0<code>testuser@fe1:~$ eb GROMACS-2018-foss-2018a.eb -d --robot<\/code><\/pre>\n<p>The additional option\u00a0<code>--debug\/-d<\/code>\u00a0enables debug logging, which includes all the details of the software build and installation in the log file.<\/p>\n<p>By default, EasyBuild will install the software in\u00a0<code>$HOME\/easybuild\/software<\/code>\u00a0and the corresponding Lua module file in\u00a0<code>$HOME\/easybuild\/modules\/all<\/code>. The path of the module file is automatically added to\u00a0<code>$MODULEPATH<\/code>, once the EasyBuild module is loaded. The user can also specify a different installation path for a particular software and the corresponding module using the option\u00a0<code>--installpath<\/code>\u00a0(or, more specifically,\u00a0\u00a0<code>--installpath-software<\/code>\u00a0and\u00a0<code>--installpath-modules<\/code>). In this case the new module path must be added with the command:\u00a0<code>module use &lt;new_module_path&gt;<\/code>.<\/p>\n<p>An overview of the EasyBuild configuration settings is given by <code>eb --show-config<\/code>.<\/p>\n<h4>How to create new easyconfig files<\/h4>\n<p>The user can define new easyconfig files to install applications which are not currently reported on the online repository. EasyBuild provides templates to implement procedures for building and installing software, called <a href=\"https:\/\/easybuild.readthedocs.io\/en\/latest\/version-specific\/generic_easyblocks.html\">easyblocks<\/a>. For example, the following easyconfig file can be used to install a particular release of the RStudio software:<\/p>\n<pre><code>easyblock = 'PackedBinary'\nname = 'RStudio'\nversion = '1.1.456'\nhomepage = 'https:\/\/www.rstudio.com\ndescription = \"RStudio is a set of integrated tools designed to help you be more productive with R. It includes a console, syntax-highlighting editor that supports direct code execution, as well as tools for plotting, history, debugging and workspace management.\"\n\ntoolchain = {'name': 'dummy', 'version': ''}\nsources = ['rstudio-%(version)s-amd64-debian.tar.gz']\nsource_urls = ['http:\/\/download1.rstudio.org']\n\nskipsteps = ['build']\n\nsanity_check_paths = {\n\u00a0   'files': ['bin\/rstudio'],\n\u00a0   'dirs': ['R']\n}\n\nmoduleclass = 'tools'<\/code><\/pre>\n<p>In this case EasyBuild leverages the\u00a0<code>PackedBinary<\/code>\u00a0<a href=\"https:\/\/easybuild.readthedocs.io\/en\/latest\/version-specific\/generic_easyblocks.html#packedbinary\">easyblock<\/a>, which provides the support for installing packed binary software. Since the software is not compiled, it is used in the <code>dummy<\/code>\u00a0toolchain.<\/p>\n<h4>How to include external dependencies<\/h4>\n<p>Sometimes it can be useful to build a new software where some of the dependencies are already installed on ABACUS2.0. In this case, any of these dependencies must be indicated as <code>EXTERNAL_MODULE<\/code>\u00a0and added as separate metadata. For example, in the following the repository\u00a0 easyconfig file for the Intel C\/C++ compilers in the\u00a0<code>intel-2018b<\/code>\u00a0toolchain is tweaked in order to use the preinstalled Intel compiler module:<\/p>\n<pre><code># new easyconfig file icc-2018.3.222-GCC-7.3.0-2.30.eb\nname = 'icc'\nversion = '2018.3.222'\n\nhomepage = 'http:\/\/software.intel.com\/en-us\/intel-compilers\/'\ndescription = \"Intel C and C++ compilers\"\n\ntoolchain = {'name': 'dummy', 'version': 'dummy'}\ngccver = '7.3.0'\nbinutilsver = '2.30'\nversionsuffix = '-GCC-%s-%s' % (gccver, binutilsver)\n\ndependencies = [\n    ('GCCcore', gccver),\n    ('binutils', binutilsver, '', ('GCCcore', gccver)),\n    ('intel\/2018.05', EXTERNAL_MODULE)\n]\n\nskipsteps = ['configure', 'build', 'install']\n\ndontcreateinstalldir = 'True'\n\npath_compiler = '\/opt\/sys\/apps\/intel\/2018.05\/bin'\nsanity_check_paths = {\n    'files': [path_compiler+\"\/icc\", path_compiler+\"\/icpc\"],\n    'dirs': [],\n}\n\nlicense_file = '\/opt\/sys\/apps\/intel\/licenses\/USE_SERVER.lic'\n\nmoduleclass = 'compiler'\n<\/code><\/pre>\n<p>Metadata for the external module\u00a0<code>intel\/2018.05<\/code>\u00a0must be declared in a separate file, in this case called <code>ext_module_metadata.cfg<\/code>, as follows:<\/p>\n<pre><code>[intel\/2018.05]\nname = icc, icpc, ifort\nversion = 18.0.3, 18.0.3, 18.0.3\nprefix = \/opt\/sys\/apps\/intel\/2018.05\/bin\/<\/code><\/pre>\n<p>The location of the file with the external module metadata can be specified with the configuration option\u00a0<code>--external_module_metadata<\/code>. For example, if both\u00a0<code>icc-2018.3.222-GCC-7.3.0-2.30.eb<\/code>\u00a0 and\u00a0 <code>ext_module_metadata.cfg<\/code>\u00a0are located in the same directory, then the following command is used to install the <code>icc<\/code> compiler and define the environmental variables to load the external module\u00a0<code>intel\/2018.05<\/code>:<\/p>\n<pre><code>testuser@fe1:~$ eb icc-2018.1.163-GCC-6.4.0-2.28.eb --external-modules-metadata=ext_module_metadata.cfg --robot <\/code><\/pre>\n<p>Similarly, the Intel Fortran compiler in <code>intel\/2018.05<\/code>\u00a0can be linked to a modified\u00a0<code>ifort-2018.3.222-GCC-7.3.0-2.30.eb<\/code>\u00a0easyconfig file of the\u00a0<code>intel-2018b<\/code> toolchain. In this case, it is not necessary to run the <code>eb<\/code>\u00a0 command with the option for the metadata file, because the external module is already configured.<\/p>\n<h4 id=\"further-reading\">Further information:<\/h4>\n<ul>\n<li><a href=\"https:\/\/easybuild.readthedocs.io\/en\/latest\/Configuration.html\">Configuring EasyBuild<\/a><\/li>\n<li><a href=\"https:\/\/easybuild.readthedocs.io\/en\/latest\/Writing_easyconfig_files.html\">Writing easyconfig files<\/a><\/li>\n<li><a href=\"https:\/\/easybuild.readthedocs.io\/en\/latest\/version-specific\/generic_easyblocks.html#packedbinary\">Overview of generic easyblocks<\/a><\/li>\n<li><a href=\"https:\/\/easybuild.readthedocs.io\/en\/latest\/version-specific\/generic_easyblocks.html\">Using external modules<\/a><\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>What is EasyBuild ? EasyBuild is a software build and installation framework written in Python, which allows to deploy and manage (scientific) applications on High Performance Computing systems. EasyBuild v3.6.2 is currently installed on ABACUS2.0<a class=\"moretag\" href=\"http:\/\/escience.sdu.dk\/index.php\/easybuild\/\"> Read more&hellip;<\/a><\/p>\n","protected":false},"author":5,"featured_media":3986,"parent":0,"menu_order":8,"comment_status":"closed","ping_status":"closed","template":"page-templates\/template-fullwidth.php","meta":[],"_links":{"self":[{"href":"http:\/\/escience.sdu.dk\/index.php\/wp-json\/wp\/v2\/pages\/4072"}],"collection":[{"href":"http:\/\/escience.sdu.dk\/index.php\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"http:\/\/escience.sdu.dk\/index.php\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"http:\/\/escience.sdu.dk\/index.php\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"http:\/\/escience.sdu.dk\/index.php\/wp-json\/wp\/v2\/comments?post=4072"}],"version-history":[{"count":89,"href":"http:\/\/escience.sdu.dk\/index.php\/wp-json\/wp\/v2\/pages\/4072\/revisions"}],"predecessor-version":[{"id":6379,"href":"http:\/\/escience.sdu.dk\/index.php\/wp-json\/wp\/v2\/pages\/4072\/revisions\/6379"}],"wp:featuredmedia":[{"embeddable":true,"href":"http:\/\/escience.sdu.dk\/index.php\/wp-json\/wp\/v2\/media\/3986"}],"wp:attachment":[{"href":"http:\/\/escience.sdu.dk\/index.php\/wp-json\/wp\/v2\/media?parent=4072"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}