diff --git a/compass/landice/tests/circular_shelf/albany_input.yaml b/compass/landice/tests/circular_shelf/albany_input.yaml index 2618967bef..6354b4ae15 100644 --- a/compass/landice/tests/circular_shelf/albany_input.yaml +++ b/compass/landice/tests/circular_shelf/albany_input.yaml @@ -1,8 +1,6 @@ %YAML 1.1 --- ANONYMOUS: - Build Type: Tpetra - Problem: LandIce Viscosity: Type: 'Glen''s Law' diff --git a/compass/landice/tests/dome/albany_input.yaml b/compass/landice/tests/dome/albany_input.yaml index d2d4522adb..2ca45d2470 100644 --- a/compass/landice/tests/dome/albany_input.yaml +++ b/compass/landice/tests/dome/albany_input.yaml @@ -1,8 +1,6 @@ %YAML 1.1 --- ANONYMOUS: - Build Type: Tpetra - Problem: LandIce Viscosity: Type: 'Glen''s Law' diff --git a/compass/landice/tests/ensemble_generator/albany_input.yaml b/compass/landice/tests/ensemble_generator/albany_input.yaml index a4fbcb470e..8c70870f77 100644 --- a/compass/landice/tests/ensemble_generator/albany_input.yaml +++ b/compass/landice/tests/ensemble_generator/albany_input.yaml @@ -1,8 +1,6 @@ %YAML 1.1 --- ANONYMOUS: - Build Type: Tpetra - Problem: LandIce Field Norm: sliding_velocity_basalside: diff --git a/compass/landice/tests/greenland/albany_input.yaml b/compass/landice/tests/greenland/albany_input.yaml index b87d234d5f..4c2f498dc6 100644 --- a/compass/landice/tests/greenland/albany_input.yaml +++ b/compass/landice/tests/greenland/albany_input.yaml @@ -1,8 +1,6 @@ %YAML 1.1 --- ANONYMOUS: - Build Type: Tpetra - # Discretization Description Discretization: Exodus Output File Name: albany_output.exo diff --git a/compass/landice/tests/humboldt/albany_input.yaml b/compass/landice/tests/humboldt/albany_input.yaml index 236141a5c3..a675d3963a 100644 --- a/compass/landice/tests/humboldt/albany_input.yaml +++ b/compass/landice/tests/humboldt/albany_input.yaml @@ -1,8 +1,6 @@ %YAML 1.1 --- ANONYMOUS: - Build Type: Tpetra - Problem: LandIce Field Norm: sliding_velocity_basalside: diff --git a/compass/landice/tests/humboldt/albany_input_depthInt.yaml b/compass/landice/tests/humboldt/albany_input_depthInt.yaml index 0420dfe1e1..faa273b96d 100644 --- a/compass/landice/tests/humboldt/albany_input_depthInt.yaml +++ b/compass/landice/tests/humboldt/albany_input_depthInt.yaml @@ -1,8 +1,6 @@ %YAML 1.1 --- ANONYMOUS: - Build Type: Tpetra - Problem: LandIce Field Norm: sliding_velocity_basalside: diff --git a/compass/landice/tests/ismip6_run/ismip6_ais_proj2300/albany_input.yaml b/compass/landice/tests/ismip6_run/ismip6_ais_proj2300/albany_input.yaml index 0f6fbb0aaa..5903833a18 100644 --- a/compass/landice/tests/ismip6_run/ismip6_ais_proj2300/albany_input.yaml +++ b/compass/landice/tests/ismip6_run/ismip6_ais_proj2300/albany_input.yaml @@ -1,10 +1,6 @@ %YAML 1.1 --- ANONYMOUS: -# In order to use ML, change Tpetra to Epetra in the following line, -# and "Preconditioner Type: MueLu" to " Preconditioner Type: ML" several lines below - Build Type: Tpetra - Problem: LandIce Field Norm: sliding_velocity_basalside: diff --git a/compass/landice/tests/mismipplus/albany_input.yaml b/compass/landice/tests/mismipplus/albany_input.yaml index b81e12a91b..6930883712 100644 --- a/compass/landice/tests/mismipplus/albany_input.yaml +++ b/compass/landice/tests/mismipplus/albany_input.yaml @@ -1,8 +1,6 @@ %YAML 1.1 --- ANONYMOUS: - Build Type: Tpetra - Problem: Dirichlet BCs: SDBC on NS dirichlet for DOF U1 prescribe Field: dirichlet_field diff --git a/compass/landice/tests/thwaites/albany_input.yaml b/compass/landice/tests/thwaites/albany_input.yaml index d7d684edcd..91d7c7ccd8 100644 --- a/compass/landice/tests/thwaites/albany_input.yaml +++ b/compass/landice/tests/thwaites/albany_input.yaml @@ -1,8 +1,6 @@ %YAML 1.1 --- ANONYMOUS: - Build Type: Tpetra - # Problem Description Problem: Cubature Degree: 4 diff --git a/compass/landice/tests/thwaites/albany_input_depthInt.yaml b/compass/landice/tests/thwaites/albany_input_depthInt.yaml index 27a5eeea53..f3834def85 100644 --- a/compass/landice/tests/thwaites/albany_input_depthInt.yaml +++ b/compass/landice/tests/thwaites/albany_input_depthInt.yaml @@ -1,8 +1,6 @@ %YAML 1.1 --- ANONYMOUS: - Build Type: Tpetra - Problem: Depth Integrated Model: true diff --git a/compass/machines/chicoma-cpu.cfg b/compass/machines/chicoma-cpu.cfg index 70a2256f6d..34211cf53f 100644 --- a/compass/machines/chicoma-cpu.cfg +++ b/compass/machines/chicoma-cpu.cfg @@ -28,6 +28,8 @@ spack = /usr/projects/e3sm/compass/chicoma-cpu/spack # pnetcdf as E3SM (spack modules are used otherwise) use_e3sm_hdf5_netcdf = True +# location of a spack mirror for compass to use +spack_mirror = /usr/projects/e3sm/compass/chicoma-cpu/spack/spack_mirror # The parallel section describes options related to running jobs in parallel [parallel] diff --git a/compass/ocean/suites/nonhydro.txt b/compass/ocean/suites/nonhydro.txt new file mode 100644 index 0000000000..ba1abd7042 --- /dev/null +++ b/compass/ocean/suites/nonhydro.txt @@ -0,0 +1,2 @@ +ocean/nonhydro/solitary_wave +ocean/nonhydro/stratified_seiche diff --git a/compass/version.py b/compass/version.py index 7c2b0c7b44..864ac90c1a 100644 --- a/compass/version.py +++ b/compass/version.py @@ -1 +1 @@ -__version__ = '1.2.0-alpha.9' +__version__ = '1.3.0-alpha.1' diff --git a/conda/bootstrap.py b/conda/bootstrap.py index 58cc1fd99d..826babd4f1 100755 --- a/conda/bootstrap.py +++ b/conda/bootstrap.py @@ -340,42 +340,7 @@ def build_conda_env(env_type, recreate, mpi, conda_mpi, version, check_call(commands, logger=logger) if recreate or update_jigsaw: - # remove conda jigsaw and jigsaw-python - t0 = time.time() - commands = \ - f'{activate_env} && ' \ - f'conda remove -y --force-remove jigsaw jigsawpy' - check_call(commands, logger=logger) - - commands = \ - f'{activate_env} && ' \ - f'cd {source_path} && ' \ - f'git submodule update --init jigsaw-python' - check_call(commands, logger=logger) - - print('Building JIGSAW\n') - # add build tools to deployment env, not compass env - commands = \ - f'conda install -y cmake cxx-compiler && ' \ - f'cd {source_path}/jigsaw-python && ' \ - f'python setup.py build_external' - check_call(commands, logger=logger) - - print('Installing JIGSAW and JIGSAW-Python\n') - commands = \ - f'{activate_env} && ' \ - f'cd {source_path}/jigsaw-python && ' \ - f'python -m pip install --no-deps -e . && ' \ - f'cp jigsawpy/_bin/* ${{CONDA_PREFIX}}/bin' - check_call(commands, logger=logger) - - t1 = time.time() - total = t1 - t0 - message = f'JIGSAW install took {total:.1f} s.' - if logger is None: - print(message) - else: - logger.info(message) + build_jigsaw(activate_env, source_path, env_path, logger) # install (or reinstall) compass in edit mode print('Installing compass\n') @@ -383,7 +348,7 @@ def build_conda_env(env_type, recreate, mpi, conda_mpi, version, f'{activate_env} && ' \ f'cd {source_path} && ' \ f'rm -rf compass.egg-info && ' \ - f'python -m pip install -e .' + f'python -m pip install --no-deps -e .' check_call(commands, logger=logger) print('Installing pre-commit\n') @@ -394,6 +359,57 @@ def build_conda_env(env_type, recreate, mpi, conda_mpi, version, check_call(commands, logger=logger) +def build_jigsaw(activate_env, source_path, env_path, logger): + # remove conda jigsaw and jigsaw-python + t0 = time.time() + commands = \ + f'{activate_env} && ' \ + f'conda remove -y --force-remove jigsaw jigsawpy' + check_call(commands, logger=logger) + + commands = \ + f'{activate_env} && ' \ + f'cd {source_path} && ' \ + f'git submodule update --init jigsaw-python' + check_call(commands, logger=logger) + + print('Building JIGSAW\n') + # add build tools to deployment env, not compass env + jigsaw_build_deps = 'cxx-compiler cmake' + netcdf_lib = f'{env_path}/lib/libnetcdf.so' + cmake_args = f'-DCMAKE_BUILD_TYPE=Release -DNETCDF_LIBRARY={netcdf_lib}' + + commands = \ + f'conda install -y {jigsaw_build_deps} && ' \ + f'cd {source_path}/jigsaw-python/external/jigsaw && ' \ + f'rm -rf tmp && ' \ + f'mkdir tmp && ' \ + f'cd tmp && ' \ + f'cmake .. {cmake_args} && ' \ + f'cmake --build . --config Release --target install --parallel 4 && ' \ + f'cd {source_path}/jigsaw-python && ' \ + f'rm -rf jigsawpy/_bin jigsawpy/_lib && ' \ + f'cp -r external/jigsaw/bin/ jigsawpy/_bin && ' \ + f'cp -r external/jigsaw/lib/ jigsawpy/_lib' + check_call(commands, logger=logger) + + print('Installing JIGSAW and JIGSAW-Python\n') + commands = \ + f'{activate_env} && ' \ + f'cd {source_path}/jigsaw-python && ' \ + f'python -m pip install --no-deps -e . && ' \ + f'cp jigsawpy/_bin/* ${{CONDA_PREFIX}}/bin' + check_call(commands, logger=logger) + + t1 = time.time() + total = int(t1 - t0 + 0.5) + message = f'JIGSAW install took {total:.1f} s.' + if logger is None: + print(message) + else: + logger.info(message) + + def get_env_vars(machine, compiler, mpilib): if machine is None: @@ -449,10 +465,16 @@ def build_spack_env(config, update_spack, machine, compiler, mpi, # noqa: C901 cmake = config.get('deploy', 'cmake') esmf = config.get('deploy', 'esmf') lapack = config.get('deploy', 'lapack') + moab = config.get('deploy', 'moab') petsc = config.get('deploy', 'petsc') scorpio = config.get('deploy', 'scorpio') parallelio = config.get('deploy', 'parallelio') + if config.has_option('deploy', 'spack_mirror'): + spack_mirror = config.get('deploy', 'spack_mirror') + else: + spack_mirror = None + spack_branch_base = f'{spack_base}/{spack_env}' specs = list() @@ -479,6 +501,9 @@ def build_spack_env(config, update_spack, machine, compiler, mpi, # noqa: C901 include_e3sm_lapack = False else: include_e3sm_lapack = True + if moab != 'None': + specs.append( + f'"moab@{moab}+mpi+hdf5+netcdf+pnetcdf+metis+parmetis+tempest"') if petsc != 'None': specs.append(f'"petsc@{petsc}+mpi+batch"') @@ -503,7 +528,7 @@ def build_spack_env(config, update_spack, machine, compiler, mpi, # noqa: C901 if albany != 'None': specs.append(f'"trilinos-for-albany@{albany}"') - specs.append(f'"albany@{albany}+mpas"') + specs.append(f'"albany@{albany}+mpas~py+unit_tests"') yaml_template = f'{spack_template_path}/{machine}_{compiler}_{mpi}.yaml' if not os.path.exists(yaml_template): @@ -526,7 +551,7 @@ def build_spack_env(config, update_spack, machine, compiler, mpi, # noqa: C901 include_e3sm_lapack=include_e3sm_lapack, include_e3sm_hdf5_netcdf=e3sm_hdf5_netcdf, yaml_template=yaml_template, tmpdir=tmpdir, - custom_spack=custom_spack) + custom_spack=custom_spack, spack_mirror=spack_mirror) # remove ESMC/ESMF include files that interfere with MPAS time keeping include_path = f'{spack_branch_base}/var/spack/environments/' \ @@ -645,11 +670,11 @@ def write_load_compass(template_path, activ_path, conda_base, env_type, mkdir -p conda/logs echo Reinstalling compass package in edit mode... rm -rf compass.egg-info - python -m pip install -e . &> conda/logs/install_compass.log + python -m pip install --no-deps -e . &> conda/logs/install_compass.log echo Done. echo fi - """ + """ # noqa: E501 else: update_compass = '' @@ -1049,7 +1074,7 @@ def main(): # noqa: C901 commands = f'source {conda_base}/etc/profile.d/conda.sh && ' \ f'conda activate {conda_env_name} && ' \ 'cd ../build_mache/mache && ' \ - 'python -m pip install .' + 'python -m pip install --no-deps .' check_call(commands, logger=logger) previous_conda_env = conda_env_name diff --git a/conda/compass_env/spec-file.template b/conda/compass_env/spec-file.template index fdeddcf110..7435830a3e 100644 --- a/conda/compass_env/spec-file.template +++ b/conda/compass_env/spec-file.template @@ -6,7 +6,7 @@ python>=3.8 cartopy cartopy_offlinedata cmocean -esmf=*={{ mpi_prefix }}_* +esmf=8.6.0={{ mpi_prefix }}_* ffmpeg geometric_features=1.3.0 git @@ -16,11 +16,13 @@ ipython jupyter lxml {% if include_mache %} -mache=1.17.0 +mache=1.20.0 {% endif %} matplotlib-base metis -mpas_tools=0.29.0 +moab >=5.5.1 +moab=*={{ mpi_prefix }}_tempest_* +mpas_tools=0.32.0 nco netcdf4=*=nompi_* numpy @@ -30,7 +32,7 @@ otps=2021.10 progressbar2 pyamg >=4.2.2 pyproj -pyremap>=1.1.0,<2.0.0 +pyremap>=1.3.0,<2.0.0 requests ruamel.yaml # having pip check problems with this version diff --git a/conda/configure_compass_env.py b/conda/configure_compass_env.py index 3a7906170a..871b43901c 100755 --- a/conda/configure_compass_env.py +++ b/conda/configure_compass_env.py @@ -100,7 +100,7 @@ def main(): if local_mache: mache = '' else: - mache = '"mache=1.17.0"' + mache = '"mache=1.20.0"' setup_install_env(env_name, activate_base, args.use_local, logger, args.recreate, conda_base, mache) @@ -114,7 +114,7 @@ def main(): f'git clone -b {args.mache_branch} ' \ f'git@github.com:{args.mache_fork}.git mache && ' \ f'cd mache && ' \ - f'python -m pip install .' + f'python -m pip install --no-deps .' check_call(commands, logger=logger) diff --git a/conda/default.cfg b/conda/default.cfg index 2bfba1d0a4..0a410ac5d0 100644 --- a/conda/default.cfg +++ b/conda/default.cfg @@ -14,22 +14,23 @@ recreate = False suffix = # the python version -python = 3.10 +python = 3.11 # the MPI version (nompi, mpich or openmpi) mpi = nompi # the version of various packages to include if using spack -albany = compass-2023-08-03 +albany = compass-2024-03-13 # cmake newer than 3.23.0 needed for Trilinos cmake = 3.23.0: -esmf = 8.4.2 -hdf5 = 1.14.1 +esmf = 8.6.0 +hdf5 = 1.14.3 lapack = 3.9.1 +moab = 5.5.1 netcdf_c = 4.9.2 netcdf_fortran = 4.6.0 petsc = 3.19.1 pnetcdf = 1.12.3 -scorpio = 1.4.1 -# parallelio = 2.5.10 +scorpio = 1.6.0 +# parallelio = 2.6.2 parallelio = None diff --git a/conda/pnetcdf/ci/linux_mpi_mpich.yaml b/conda/pnetcdf/ci/linux_mpi_mpich.yaml deleted file mode 100644 index 6ab74005ed..0000000000 --- a/conda/pnetcdf/ci/linux_mpi_mpich.yaml +++ /dev/null @@ -1,32 +0,0 @@ -c_compiler: -- gcc -c_compiler_version: -- '11' -channel_sources: -- conda-forge -channel_targets: -- e3sm main -cxx_compiler: -- gxx -cxx_compiler_version: -- '11' -fortran_compiler: -- gfortran -fortran_compiler_version: -- '11' -hdf5: -- 1.12.2 -libnetcdf: -- 4.8.1 -mpi: -- mpich -mpich: -- '4' -netcdf_fortran: -- '4.6' -target_platform: -- linux-64 -zip_keys: -- - c_compiler_version - - cxx_compiler_version - - fortran_compiler_version diff --git a/conda/pnetcdf/ci/linux_mpi_openmpi.yaml b/conda/pnetcdf/ci/linux_mpi_openmpi.yaml deleted file mode 100644 index 66a9dc7cef..0000000000 --- a/conda/pnetcdf/ci/linux_mpi_openmpi.yaml +++ /dev/null @@ -1,32 +0,0 @@ -c_compiler: -- gcc -c_compiler_version: -- '11' -channel_sources: -- conda-forge -channel_targets: -- e3sm main -cxx_compiler: -- gxx -cxx_compiler_version: -- '11' -fortran_compiler: -- gfortran -fortran_compiler_version: -- '11' -hdf5: -- 1.12.2 -libnetcdf: -- 4.8.1 -mpi: -- openmpi -netcdf_fortran: -- '4.6' -openmpi: -- '4' -target_platform: -- linux-64 -zip_keys: -- - c_compiler_version - - cxx_compiler_version - - fortran_compiler_version diff --git a/conda/pnetcdf/ci/osx_mpi_mpich.yaml b/conda/pnetcdf/ci/osx_mpi_mpich.yaml deleted file mode 100644 index 932c91fc52..0000000000 --- a/conda/pnetcdf/ci/osx_mpi_mpich.yaml +++ /dev/null @@ -1,32 +0,0 @@ -c_compiler: -- clang -c_compiler_version: -- '11' -channel_sources: -- conda-forge,defaults -channel_targets: -- e3sm main -cxx_compiler: -- clangxx -cxx_compiler_version: -- '11' -fortran_compiler: -- gfortran -fortran_compiler_version: -- '11' -hdf5: -- 1.12.2 -libnetcdf: -- 4.8.1 -mpi: -- mpich -mpich: -- '4' -netcdf_fortran: -- '4.6' -target_platform: -- osx-64 -zip_keys: -- - c_compiler_version - - cxx_compiler_version - - fortran_compiler_version diff --git a/conda/pnetcdf/ci/osx_mpi_openmpi.yaml b/conda/pnetcdf/ci/osx_mpi_openmpi.yaml deleted file mode 100644 index 967a9e07fc..0000000000 --- a/conda/pnetcdf/ci/osx_mpi_openmpi.yaml +++ /dev/null @@ -1,33 +0,0 @@ -c_compiler: -- clang -c_compiler_version: -- '11' -channel_sources: -- conda-forge,defaults -channel_targets: -- e3sm main -cxx_compiler: -- clangxx -cxx_compiler_version: -- '11' -fortran_compiler: -- gfortran -fortran_compiler_version: -- '11' -hdf5: -- 1.12.2 -libnetcdf: -- 4.8.1 -mpi: -- openmpi -netcdf_fortran: -- '4.6' -openmpi: -- '4' -target_platform: -- osx-64 -zip_keys: -- - c_compiler_version - - cxx_compiler_version - - fortran_compiler_version - diff --git a/conda/pnetcdf/recipe/build.sh b/conda/pnetcdf/recipe/build.sh deleted file mode 100644 index 58a83e7902..0000000000 --- a/conda/pnetcdf/recipe/build.sh +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/bash - -set -xe - -export MPICC=mpicc -export MPICXX=mpicxx -export MPIF77=mpifort -export MPIF90=mpifort - -./configure --prefix=${PREFIX} \ - --with-netcdf4=${PREFIX} \ - --enable-shared=yes \ - --enable-static=no - -make -# serial tests -make check -# lighter weight parallel tests (4 MPI tasks) -make ptest - -make install diff --git a/conda/pnetcdf/recipe/conda_build_config.yaml b/conda/pnetcdf/recipe/conda_build_config.yaml deleted file mode 100644 index 77e22bcaa2..0000000000 --- a/conda/pnetcdf/recipe/conda_build_config.yaml +++ /dev/null @@ -1,4 +0,0 @@ -mpi: - - openmpi - - mpich - diff --git a/conda/pnetcdf/recipe/meta.yaml b/conda/pnetcdf/recipe/meta.yaml deleted file mode 100644 index 02996ba07b..0000000000 --- a/conda/pnetcdf/recipe/meta.yaml +++ /dev/null @@ -1,68 +0,0 @@ -{% set version = "1.12.3" %} -{% set build = 0 %} - -# recipe-lint fails if mpi is undefined -{% set mpi = mpi or 'mpich' %} -{% if mpi == "mpich" %} -# prioritize mpich via build number -{% set build = build + 100 %} -{% endif %} - -package: - name: libpnetcdf - version: {{ version }} - -source: - url: https://parallel-netcdf.github.io/Release/pnetcdf-{{ version }}.tar.gz - sha256: 439e359d09bb93d0e58a6e3f928f39c2eae965b6c97f64e67cd42220d6034f77 - -build: - number: {{ build }} - skip: True # [win] - {% set mpi_prefix = "mpi_" + mpi %} - # add build string so packages can depend on mpi variants dependencies: - # `PKG_NAME * mpi_mpich_*` for mpich - # `PKG_NAME * mpi_*` for any mpi - string: {{ mpi_prefix }}_h{{ PKG_HASH }}_{{ build }} - - run_exports: - - {{ pin_subpackage('libpnetcdf', max_pin='x.x.x') }} {{ mpi_prefix }}_* - ignore_run_exports_from: - - netcdf-fortran - -requirements: - build: - - {{ compiler('c') }} - - {{ compiler('cxx') }} - - {{ compiler('fortran') }} - - m4 - - make - host: - - {{ mpi }} - # these need to be listed twice so conda build picks up the pins - - hdf5 - - hdf5 * {{ mpi_prefix }}_* - - libnetcdf - - libnetcdf * {{ mpi_prefix }}_* - - netcdf-fortran - - netcdf-fortran * {{ mpi_prefix }}_* - -test: - commands: - - pnetcdf-config --all - - test ! -f ${PREFIX}/lib/libpnetcdf.a - - test -f ${PREFIX}/lib/libpnetcdf${SHLIB_EXT} - -about: - home: https://parallel-netcdf.github.io/ - license: custom - license_file: COPYRIGHT - summary: | - PnetCDF is a high-performance parallel I/O library for accessing Unidata's - NetCDF, files in classic formats, specifically the formats of CDF-1, 2, and - 5. - dev_url: https://github.com/Parallel-NetCDF/PnetCDF - -extra: - recipe-maintainers: - - xylar diff --git a/conda/pnetcdf/recipe/run_test.sh b/conda/pnetcdf/recipe/run_test.sh deleted file mode 100644 index f3a1a28018..0000000000 --- a/conda/pnetcdf/recipe/run_test.sh +++ /dev/null @@ -1,3 +0,0 @@ -pnetcdf-config --has-c++ | grep -q yes -pnetcdf-config --has-fortran | grep -q yes -pnetcdf-config --netcdf4 | grep -q enabled diff --git a/conda/unsupported.txt b/conda/unsupported.txt index 9103260d04..5014d526ea 100644 --- a/conda/unsupported.txt +++ b/conda/unsupported.txt @@ -24,3 +24,6 @@ anvil, intel, mvapich # can't build ESMF chrysalis, intel, impi + +# can't build MOAB +anvil, gnu, mvapich diff --git a/docs/developers_guide/deploying_spack.rst b/docs/developers_guide/deploying_spack.rst index b3c4431873..95454da3e0 100644 --- a/docs/developers_guide/deploying_spack.rst +++ b/docs/developers_guide/deploying_spack.rst @@ -105,6 +105,59 @@ for machines that mache knows about get updated. When this happens, we update mache’s copy of ``config_machines.xml`` and that tells me which modules to update in spack, see below.dev_quick_start +Mirroring MOAB on Chicoma +------------------------- + +The firewall on LANL IC's Chicoma blocks access to the MOAB package (at least +at the moment -- Xylar has made a request to allow access). To get around +this, someone testing or deploying spack builds on Chicoma will first need to +update the local spack mirror with the desired version of MOAB (5.5.1 in this +example). + +First, you need to know the versions of the ``mache`` and ``moab`` packages +that are needed (1.20.0 and 5.5.1, respectively, in this example). These are +specified in ``conda/configure_compass_env.py`` and ``conda/default.cfg``, +respectively. On a LANL laptop with either (1) the VPN turned off and the +proxies unset or (2) the VPN turned on and the proxies set, run: + +.. code-block:: bash + + MACHE_VER=1.20.0 + MOAB_VER=5.5.1 + mkdir spack_mirror + cd spack_mirror + git clone git@github.com:E3SM-Project/spack.git -b spack_for_mache_${MACHE_VER} spack_for_mache_${MACHE_VER} + source spack_for_mache_${MACHE_VER}/share/spack/setup-env.sh + + # remove any cache files that might cause trouble + rm -rf ~/.spack + + # this should create spack_mirror with subdirectories moab and _source-cache + spack mirror create -d spack_mirror moab@${MOAB_VER} + + tar cvfj spack_mirror.tar.bz2 spack_mirror + +Then, if you used option (1) above turn on the LANL VPN (and set the proxies). +You may find it convenient to login on to Chicoma +(e.g. ``ssh -tt wtrw 'ssh ch-fe'``) in a separate terminal if you have +configured your laptop to preserve connections. + +.. code-block:: bash + + rsync -rLpt -e 'ssh wtrw ssh' spack_mirror.tar.bz2 ch-fe:/usr/projects/e3sm/compass/chicoma-cpu/spack/ + + +Then, on Chicoma: + +.. code-block:: bash + + cd /usr/projects/e3sm/compass/chicoma-cpu/spack/ + tar xvf spack_mirror.tar.bz2 + chgrp -R climate spack_mirror/ + chmod -R ug+w spack_mirror/ + chmod -R ugo+rX spack_mirror/ + rm spack_mirror.tar.bz2 + Creating spack environments ---------------------------