Several "make check" tests time out and compiled gmx binary hangs

GROMACS version: 2020.4
GROMACS modification: No

I built Gromacs 2020.04 on a Ubuntu 20.04 machine using gcc-9.3.0 and cuda-11. Using the following command:

cmake … -DGMX_GPU=ON -DCUDA_TOOLKIT_ROOT_DIR=/usr/local/cuda -DGMX_SIMD=“AVX2_256” -DGMX_DOUBLE=off -DGMX_BUILD_OWN_FFTW=ON.

then I type “make” and everything appears to build fine (i.e. there are no errors)

However if I run “make check” then several of the tests fail due to timeout reasons (I can’t upload the output of “make check”, but i can email the entire output). Below are the list of the tests that failed:

The following tests FAILED:
30 - GmxAnaTest (Timeout)
38 - TrajectoryAnalysisUnitTests (Timeout)
39 - EnergyAnalysisUnitTests (Timeout)
44 - MdrunModulesTests (Timeout)
45 - MdrunIOTests (Timeout)
46 - MdrunTests (Timeout)
47 - MdrunNonIntegratorTests (Timeout)
48 - MdrunTpiTests (Timeout)

I decided to proceed with installation anyway (“make install”). The command “gmx” (with no options or inputs) produces the expected terminal output. However, instead of terminating and the Bash shell prompt reappearing; the program hangs. If I run “gmx pdb2gmx” the program produces the expected output and terminates normally (does NOT hang). if I run however “gmx pdb2gmx -f 1ubq.pdb -o 1ubq.gro -p 1ubq.top” select force field “8” and water model “1” when prompted, the program executes as normal, produces the relevant files (which appear at a cursory glance, correct) and then hangs. I was wondering if anyone has experienced this and what the fix would be?

My machine uses a AMD RYZEN 5 3600X six core processor and a NVDIA GeForce RTX 2070 graphics card

UPDATE:

I used sudo apt-get install gromacs on Ubuntu 20.04.1 to get the precompiled binaries of gromacs 2020.1 (different from version 2020.4 as I was using above). The gmx binary also has an identical hanging issue between these two different versions and build methods. I also did a fresh re-installation of the OS, with no improvement.

I also tried rebuilding version 2020.4 again with gcc-8.4.0 and CUDA-11.1, as well as just gcc-8.4.0 with graphics card support entirely turned off, so I am fairly confident it is nothing to do with the graphics libraries/card

Dear
I have Ubuntu 20.04 and today install 2020.4 ver of gromacs and my problem solved! please do not use synaptic method for its installation. Install it directly:

Cheers
Muhmmad

Thanks for you reply,

What version of GCC (or what compiler did you use) and what version of CUDA (if any) did you use?

I opened up a bug report GROMACS 2020.4 - gmx binary hangs (#3855) · Issues · GROMACS / GROMACS · GitLab. It turns out that this is a an issue with certain AMD RYZEN processors that have faulty microcode. The link above explains what you need to do. In essence GROMACS is using a call to the processor to generate random numbers, this call is failing as a result gmx will hang. I have been told that later versions (i.e. 2020.5) will generate random numbers via a different mechanism if the software determines that the processor is failing to generate them properly.

Below is a link that discusses the bug in a bit more detail.

While 2020.5 will make GROMACS work, everyone with this bug should fix the random number generation through a BIOS update on their motherboard. Any other software that tries to use this means of RNG could fail to work as expected and, as I understand, there are significant security implications if you don’t have proper RNG.