[FLASH-USERS] Problem with MPI while running FLASH in Docker

Marissa Adams madams at pas.rochester.edu
Mon Jul 8 17:39:59 EDT 2019


You're welcome :) Doing my best to help.

TL;DR: you do not need to install anything in docker, but make sure you're using docker correctly first, and no there are no other images -- and yes this one is usable (used it yesterday, and so have other folks here!), and I would suggest maintaining your own libraries for ease so then you can use gdb, for instance (the image doesn't have that installed, and also docker has a weird case insensitivity issue -- that's a docker thing, not a FLASH thing)

On Mon, Jul 8, 2019 at 3:35 PM Полина Бевад <black_estrella at mail.ru<mailto:black_estrella at mail.ru>> wrote:
Marissa, thank you!

Yes, I wanted to fix these paths, and mount FLASH folder to docker, but the main problem, I assume, that docker image doesn't include MPI, HDF5

It does have the libraries already installed. Can you try running with just the paths denoted as /usr/local ? The rest of the Makefile will use those paths to get the information stored in the libraries below. *Everything is already installed on docker, so you do not need to maintain or commit changes there to the libraries.*

Just to make sure it isn't something else, I'll detail how I use docker to run FLASH.

When I have used docker, this is a short hand of what I normally do (I am on a Mac OS):
NOTE: Docker doesn't let you use emacs (although vi and less are usable), if you're an emacs user, you may want to open another tab of the equivalent directory to edit files, etc. Docker still processes those changes outside of it.

1. Make sure docker is running via application.
2. Use the command: docker run -v ~/:/Work -it icksa/flash4-deps
3. Usually, in my ~/, I have my FLASH4.X.Y directory. I don't start the docker image right in the FLASH4.X.Y directory; one layer out.
4. cd into "Work" where I've placed the container, then into my FLASH4.X.Y.
5. I "set up" in the docker environment, as well as make in there.
6. Using the Makefile.h mentioned prior with the small changes I suggested, you can do a simple set up like (even better if you create a Sedov.sh file with that contained and chmod a+x-ing it so then you can save all set up commands used IMO),
./setup -auto Sedov -site=Prototypes/Linux -objdir=Sedov
7. cd into new object directory Sedov/
8. make -j
9. ./flash4

Doing this you should be good to go with no errors or discrepancies in the libraries. Are there any deviations from what I detailed above that have taken place?

Also, it is not the end of the world to install your own libraries! If you're using a Mac, I would suggest using homebrew (https://brew.sh/, macports isn't being managed anymore to my knowledge?).

via homebrew, install open-mpi 4.0.1_1. Doing this will install all of the dependencies open MPI needs (GCC etc)
I would then suggest HIGHLY of self-installing hdf5 1.8.20 parallelized with fortran, and hypre 2.11.2. If you install HDF5 and HYPRE via homebrew, homebrew may update them to versions that are too new for FLASH to deal with (i.e. haven't been tested with FLASH yet).

For instance, for HYPRE:

Download one of their more stable versions (https://computation.llnl.gov/projects/hypre-scalable-linear-solvers-multigrid-methods/software) I downloaded 2.11 from 2017.

I put them in my Modules directory, where I normally build things like this. However, you can have it placed in /usr/local:
Look at the README and the INSTALL files to get an idea of what you're doing. Then I did the following list of commands:


tar -xvf hypre-2.11.2.tar.gz

cd hypre-2.11.2

cd src/

FC=mpif90 CC=mpicc ./configure --prefix=/usr/local/hypre_2.11.2-selfbuilt

sudo make install

enter your password and voila! you would follow a similar pattern for HDF5 install.

Then I made my own site directory and put my own Makefile.h in there. For instance, my paths are:

MPI_PATH   = /usr/local/Cellar/open-mpi/4.0.1_1

HDF4_PATH  =

HDF5_PATH  = /usr/local/hdf5_1.8.20-parallelfortran

HYPRE_PATH = /usr/local/hypre_2.11.2-selfbuilt


and other libraries and then the purpose of this image isn't clear - if I need to install MPI and hdf5 as usual and then commit changes in image, then it the same as the common installation.

Just make the changes I suggested below, does it run?

Maybe there are some other images, because this one from manual was updated 4 years ago (https://hub.docker.com/r/icksa/flash4-deps)?

Nope :X


Понедельник, 8 июля 2019, 22:14 +03:00 от Marissa Adams <madams at pas.rochester.edu>:

To use the docker image you want to make sure you're using the appropriate Makefile.h. Prototypes/Linux/Makefile.h is the most amenable to docker. However, it needs some small changes for the paths:


MPI_PATH   = /usr/local

HDF4_PATH  =

HDF5_PATH  = /usr/local

HYPRE_PATH = /usr/local

If FLASH is not using the appropriate Makefile.h, you can tell it to do so in the set-up script you want via the flag -site=Prototypes/Linux/

FYI you can find a list of all setup flags in section 5.2 in the User Manual: http://flash.uchicago.edu/site/flashcode/user_support/flash4_ug_4p5.pdf


On Mon, Jul 8, 2019 at 1:58 PM Полина Бевад <black_estrella at mail.ru> wrote:

Dear FLASH users,

Has anyone encountered the problem of running FLASH 4.6 from Docker image `icksa/flash4-deps`?

I received the error "/usr/local/mpich2 can't be found while run `make` command after `setup.py`, that means that MPI isn't installed (and yes, this folder is really absent in docker container). It is strange, because this image must be fully predefined and must contain all needed libraries.

I tried Docker image as a simplier way to try new version, because a primitive update of folder with FLASH from 4.4 to 4.6 version didn't work in my case: error of /usr/local/hdf5 -lz appeared and I would not want to reinstall libraries again...

Thanks in advance!
--
Polina Bevad


--
Полина Бевад
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://flash.rochester.edu/pipermail/flash-users/attachments/20190708/677b0195/attachment.htm>


More information about the flash-users mailing list