Fatal error: reading tpx file (md.tpr) version 120 with version 119 program

Hi gmx users,

With the gromacs input files received, my run fails with md.tpr / md.tpx file incompatibility issues:

Command line:
gmx_mpi mdrun -v -deffnm md

Reading file md.tpr, VERSION 2020.2-dev-UNCHECKED (single precision)


Program: gmx mdrun, version 2020.6
Source file: src/gromacs/fileio/tpxio.cpp (line 2709)
MPI rank: 0 (out of 32)

Fatal error:
reading tpx file (md.tpr) version 120 with version 119 program

I did try multiple versions of gromacs: 2020, 2020.2 & 2020.6. But it fails with the same error each time.

If 2021.4 version is used then it fails with:

Command line:
gmx_mpi mdrun -v -deffnm md

Reading file md.tpr, VERSION 2020.2-dev-UNCHECKED (single precision)


Program: gmx mdrun, version 2021.4
MPI rank: 0 (out of 8)

Standard library logic error (bug):
(exception type: St12length_error)
vector::_M_default_append

Can someone confirm, is dev version: 2020.2-dev-UNCHECKED causing this error? I mean if md.tpr was generated with a stable version, then this error might have not appeared? Or any other reason?

HI,
which version was used to generate tpr file?
In general, if you do not special reason to use a dev version. Better use the last release versions for data production.

Alessandra

Hi,

I’ve not generated the .tpr file myself. As per the output pasted in the query, it is generated using a devel version(beta Or nightly build) i.e. 2020.2 dev unchecked.
Gromacs developers should confirm here if.tpr file generated from a dev-unchecked version can’t be used by a stable release version.

The problem is that you’re using a newer version of the software to produce the .tpr file than to read it. That is something that has never been supported in GROMACS. Use the same version to create and use .tpr files, and generally do not use beta or unstable versions for anything you intend to publish.

The problem is that you’re using a newer version of the software to produce the .tprfile than to read it.
No. I haven’t used lower version to read the md.tpr file.
md.tpr file is created using 2020.2-dev-UNCHECKED.
For reading the md.tpr file, I have tried using 2020.2 & 2020.6. But each time it failed with same error as mentioned in the previous mail.

The .tpr file is still “newer” in the sense that some feature has been added to it that required a change in the file format. This is generally not done within patch releases (that is, a .tpr file generated by 2020.x version should be readable by any other 2020.x version). Since this is not the case, it appears someone has changed the file format in a way that has broken compatibility. Where did the source code come from? In what way is it modified? The fact that it completely fails in the 2021.x series suggests the code is simply not robust.

The solution is to use only real, released versions of GROMACS, and to remain consistent in using the same version to produce and subsequently read files. At this point, it’s not likely to be productive to even try using this developmental .tpr file for anything.