This top-level .itp file has been removed. Edit your topology to include it from your force field di

GROMACS version: 2021.6
GROMACS modification: No
Here post your question:
I was following Prof. Groot’s tutorial on non-equilibrium free energy calculation at https://www3.mpibpc.mpg.de/groups/de_groot/compbio2/p10/index_original.html
and tried to run with GROMACS 2021.6. I kept having the ‘Fatal error: Topology include file “ffgmx.itp” not found’ until
found an older version of gromacs and downloaded some of the old files required, including ffgmx.itp, ff_dump.itp, ffgmxbon.itp, ffgmxnb.itp, GROMACS/share/top at master · aar2163/GROMACS · GitHub
I then copied these files to the /usr/local/gromacs/share/gromacs/top folder, and the error messages concerning these .itp files disappeared.

However, I am now having new error messages:
Fatal error:

Syntax error - File spc.itp, line 1

Last line read:

'#error This top-level .itp file has been removed. Edit your topology to

include it from your force field directory instead, e.g. “oplsaa.ff/spc.itp”’

For more information and tips for troubleshooting, please check the GROMACS

website at Common Errors — GROMACS webpage https://www.gromacs.org documentation

so what does this mean??
where is the force field directory?

Here is the topology file(topol.top)'s content:

; Include forcefield parameters
#include “ffgmx.itp”

[ moleculetype ]
; NAme nrexcl
NA 1

[ atoms ]
; nr type resnr residue atom cgnr charge mass typeB chargeB massB
1 NA 1 NA NA 1 0 22.98980 NA 1 22.98980

; Include water topology
#include “spc.itp”

[ system ]
; NAme
NA+ in water

[ molecules ]
; Compound #mols
SOL 431
NA 1
topol.top (END)

Here is the initial log:
GROMACS: gmx grompp, version 2021.6

Executable: /usr/local/gromacs/bin/gmx

Data prefix: /usr/local/gromacs

Working dir: /Users/jiangxu/Documents/gromacs_tutorial/MD_tutorial_Groot/non_equilibrium_free_energy_calculation/practicum_crooks/fast_FWD

Command line:

gmx grompp -f forward.mdp -c fwd_snapshot.pdb -o fwb_run.tpr -p topol.top

Ignoring obsolete mdp entry ‘cpp’

Ignoring obsolete mdp entry ‘domain-decomposition’

Ignoring obsolete mdp entry ‘andersen_seed’

Ignoring obsolete mdp entry ‘dihre’

Ignoring obsolete mdp entry ‘dihre-fc’

Ignoring obsolete mdp entry ‘dihre-tau’

Ignoring obsolete mdp entry ‘nstdihreout’

Ignoring obsolete mdp entry ‘nstcheckpoint’

Ignoring obsolete mdp entry ‘optimize_fft’

Ignoring obsolete mdp entry ‘gb_algorithm’

Ignoring obsolete mdp entry ‘nstgbradii’

Ignoring obsolete mdp entry ‘rgbradii’

Ignoring obsolete mdp entry ‘gb_saltconc’

Ignoring obsolete mdp entry ‘ns-type’

Replacing old mdp entry ‘unconstrained-start’ by ‘continuation’

Replacing old mdp entry ‘nstxtcout’ by ‘nstxout-compressed’

Replacing old mdp entry ‘xtc-precision’ by ‘compressed-x-precision’

NOTE 1 [file forward.mdp]:

Setting nstcalcenergy (100) equal to nstdhdl (50)

NOTE 2 [file forward.mdp]:

nstcomm < nstcalcenergy defeats the purpose of nstcalcenergy, setting

nstcomm to nstcalcenergy

NOTE 3 [file forward.mdp]:

The Berendsen thermostat does not generate the correct kinetic energy

distribution. You might want to consider using the V-rescale thermostat.


Program: gmx grompp, version 2021.6

Source file: src/gromacs/gmxpreprocess/gmxcpp.cpp (line 298)

Fatal error:

Topology include file “ffgmx.itp” not found

For more information and tips for troubleshooting, please check the GROMACS

Here is the new error message:

GROMACS: gmx grompp, version 2021.6

Executable: /usr/local/gromacs/bin/gmx

Data prefix: /usr/local/gromacs

Working dir: /Users/jiangxu/Documents/gromacs_tutorial/MD_tutorial_Groot/non_equilibrium_free_energy_calculation/practicum_crooks/fast_FWD

Command line:

gmx grompp -f forward.mdp -c fwd_snapshot.pdb -o fwd_run.tpr -p topol.top

Ignoring obsolete mdp entry ‘cpp’

Ignoring obsolete mdp entry ‘domain-decomposition’

Ignoring obsolete mdp entry ‘andersen_seed’

Ignoring obsolete mdp entry ‘dihre’

Ignoring obsolete mdp entry ‘dihre-fc’

Ignoring obsolete mdp entry ‘dihre-tau’

Ignoring obsolete mdp entry ‘nstdihreout’

Ignoring obsolete mdp entry ‘nstcheckpoint’

Ignoring obsolete mdp entry ‘optimize_fft’

Ignoring obsolete mdp entry ‘gb_algorithm’

Ignoring obsolete mdp entry ‘nstgbradii’

Ignoring obsolete mdp entry ‘rgbradii’

Ignoring obsolete mdp entry ‘gb_saltconc’

Ignoring obsolete mdp entry ‘ns-type’

Replacing old mdp entry ‘unconstrained-start’ by ‘continuation’

Replacing old mdp entry ‘nstxtcout’ by ‘nstxout-compressed’

Replacing old mdp entry ‘xtc-precision’ by ‘compressed-x-precision’

NOTE 1 [file forward.mdp]:

Setting nstcalcenergy (100) equal to nstdhdl (50)

NOTE 2 [file forward.mdp]:

nstcomm < nstcalcenergy defeats the purpose of nstcalcenergy, setting

nstcomm to nstcalcenergy

NOTE 3 [file forward.mdp]:

The Berendsen thermostat does not generate the correct kinetic energy

distribution. You might want to consider using the V-rescale thermostat.

Generated 1284 of the 1485 non-bonded parameter combinations


Program: gmx grompp, version 2021.6

Source file: src/gromacs/gmxpreprocess/topio.cpp (line 466)

Fatal error:

Syntax error - File spc.itp, line 1

Last line read:

'#error This top-level .itp file has been removed. Edit your topology to

include it from your force field directory instead, e.g. “oplsaa.ff/spc.itp”’

For more information and tips for troubleshooting, please check the GROMACS

website at Common Errors — GROMACS webpage https://www.gromacs.org documentation


There are (at least) two problems. Both are related to the .itp files included in your topol.top file. Firstly, your ffgmx.itp file is not found. This is not a standard force field file. The pattern to include “ff*.itp” to load your force field has been disabled since before 2016, but I don’t know exactly when. The ffgmx.itp force field is also obsolete. You should use a more modern force field, either one of the ones included in the GROMACS distribution or an even more updated version.

Regarding the “spc.itp” error. Nowadays, you should include the water models specifically from the force field that you are using. An example would be:

; Include forcefield parameters
#include “amber99sb-ildn.ff/forcefield.itp”

...

; Include water topology
#include “amber99sb-ildn.ff/spc.itp”

You should of course modify the above example to use the force field you want to use.

Thanks a lot.
I tried to download the files and put it in the folder at /usr/local/gromacs/share/gromacs/top
This solved the files not found problem.
I then modified the top.topol file as you suggested.
Problem solved.
Thank you!!!

I’m glad to hear it worked. Just as a piece of advice, I would avoid adding new force fields (or modifying existing force fields) in the installed GROMACS location (/usr/local/gromacs/ in your case). That can cause confusion for other users (if there are others) or for yourself in the future, e.g. after updating GROMACS. I would recommend either placing the force field directory in the same directory as your topol.top file - then you do not have to modify anything in the file either, or to put your custom force fields in a separate directory, e.g. /home/<user_name>/Documents/force_fields/ and then you’d have to modify your `topol.top file to, e.g.:

; Include forcefield parameters
#include “/home/<user_name>/Documents/force_fields/amber99sb-ildn.ff/forcefield.itp”

...

; Include water topology
#include “/home/<user_name>/Documents/force_fields/amber99sb-ildn.ff/spc.itp”

But that is all up to you. Good luck with your simulations.

Thanks a lot. Really appreciate the advice!!
I was wondering what did the “share” folder mean. Now it makes sense.