LAMMPS Docker Image not working

Hi,

I’ve recently managed to pull the available Docker Image of LAMMPS on a GPU cluster, which I call using:

docker run -v /home/DockerDir:/home/WorkDir/ --gpus all --rm -it lammps/lammps:latest

Then, I get:

LAMMPS (30 Jul 2021)
OMP_NUM_THREADS environment is not set. Defaulting to 1 thread. (src/comm.cpp:98)
  using 1 OpenMP thread(s) per MPI task

From there I can write on the terminal, my guess is that I can run whatever I need, but using:

mpirun -n 8 lmp_mpi example_dir/in.example

always gets me to

ERROR: Unknown command: mpirun -n 8 lmp_mpi example_dir/in.example (src/input.cpp:274)
Last command: mpirun -n 8 lmp_mpi example_dir/in.example

Am I missing something?
In the Docker list of Images there are also

which I do not know if are complementary or just other versions of the same Image.

Many thanks!

Roger B

You are not on the shell prompt but what you see is LAMMPS waiting for input.
Try typing “info config” and you will see some information about how LAMMPS was compiled.

I think the reason is the “run” option to docker which will launch the predefined executable.
You probably want to use something like “docker exec” and append the “mpirun” command line.
That is what you would do with singularity, which I am familiar with.

Thanks a lot!