# Unable to extend the simulation time in the mdp input file for production run

**URL:** <https://gromacs.bioexcel.eu/t/unable-to-extend-the-simulation-time-in-the-mdp-input-file-for-production-run/1511>\
**Category:** User discussions\
**Created:** [January 29, 2021, 4:38pm UTC](https://gromacs.bioexcel.eu/t/unable-to-extend-the-simulation-time-in-the-mdp-input-file-for-production-run/1511 "2021-01-29T16:38:13Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![dkd54](https://avatars.discourse-cdn.com/v4/letter/d/c4cdca/32.png) [@dkd54](https://gromacs.bioexcel.eu/u/dkd54)\
**Post date:** [January 29, 2021, 4:38pm UTC](https://gromacs.bioexcel.eu/t/unable-to-extend-the-simulation-time-in-the-mdp-input-file-for-production-run/1511/1 "2021-01-29T16:38:13Z")

</div>

GROMACS version: 2018.3  
GROMACS modification: Yes/No  
I have recently learned to perform coarse graining simulation on a protein using this martini tutorial: [Proteins](http://cgmartini.nl/index.php/tutorials-general-introduction-gmx5/proteins-gmx5). After successfully performing all the steps using the sample files, I’m now trying to extend the production run to 2 microseconds. Usually in all atom MD simulation, I achieve that by tweaking the ‘nstlim’ in the production-input file. I tried to do the same here, in the ‘dynamic.mdp’ file I changed the nsteps to 70000000 (and dt=0.03ps), which should give me a simulation time of 2.1 microsecond. However, when I execute the production run using the ‘gmx mdrun -deffnm dynamic -v’ command, it still runs only for the default 3000000 steps. What am I doing wrong here?  
Thanks for your help in advance.

---

<div class="post-metadata">

**Author:** ![jalemkul](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/jalemkul/32/18_2.png) [@jalemkul](https://gromacs.bioexcel.eu/u/jalemkul)\
**Post date:** [January 29, 2021, 5:34pm UTC](https://gromacs.bioexcel.eu/t/unable-to-extend-the-simulation-time-in-the-mdp-input-file-for-production-run/1511/2 "2021-01-29T17:34:35Z")

</div>

`nstlim` is not a valid keyword, but `nsteps` is. If you need to extend an existing simulation, please follow [Managing long simulations — GROMACS 2021 documentation](https://manual.gromacs.org/current/user-guide/managing-simulations.html#extending-a-tpr-file)

---

<div class="post-metadata">

**Author:** ![dkd54](https://avatars.discourse-cdn.com/v4/letter/d/c4cdca/32.png) [@dkd54](https://gromacs.bioexcel.eu/u/dkd54)\
**Post date:** [January 29, 2021, 5:35pm UTC](https://gromacs.bioexcel.eu/t/unable-to-extend-the-simulation-time-in-the-mdp-input-file-for-production-run/1511/3 "2021-01-29T17:35:36Z")

</div>

@jalemkul My apologies, I meant nsteps (nstlim is the keyword in all-atom MD).

---

<div class="post-metadata">

**Author:** ![dkd54](https://avatars.discourse-cdn.com/v4/letter/d/c4cdca/32.png) [@dkd54](https://gromacs.bioexcel.eu/u/dkd54)\
**Post date:** [January 29, 2021, 5:47pm UTC](https://gromacs.bioexcel.eu/t/unable-to-extend-the-simulation-time-in-the-mdp-input-file-for-production-run/1511/4 "2021-01-29T17:47:32Z")

</div>

Thank you @jalemkul sir. In the link that you shared, it says: **The time can also be extended using the `-until` and `-nsteps` options**. Can you kindly elaborate how to achieve that? As I mentioned above, I tried changing the value for -nsteps, but it didn’t work.

---

<div class="post-metadata">

**Author:** ![jalemkul](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/jalemkul/32/18_2.png) [@jalemkul](https://gromacs.bioexcel.eu/u/jalemkul)\
**Post date:** [January 29, 2021, 5:59pm UTC](https://gromacs.bioexcel.eu/t/unable-to-extend-the-simulation-time-in-the-mdp-input-file-for-production-run/1511/5 "2021-01-29T17:59:52Z")

</div>

Please provide the exact sequence of commands you used. You need to create the new `.tpr` file with one of the `convert-tpr` options, then use `mdrun -cpi -append` with the new `.tpr` and previous `.cpt` file.

---

<div class="post-metadata">

**Author:** ![dkd54](https://avatars.discourse-cdn.com/v4/letter/d/c4cdca/32.png) [@dkd54](https://gromacs.bioexcel.eu/u/dkd54)\
**Post date:** [January 29, 2021, 8:04pm UTC](https://gromacs.bioexcel.eu/t/unable-to-extend-the-simulation-time-in-the-mdp-input-file-for-production-run/1511/6 "2021-01-29T20:04:27Z")

</div>

Hi @jalemkul  
First I ran the command: `gmx convert-tpr -s dynamic.tpr -extend 67000000 -o dynamic_extended.tpr` which ran without any issues.  
Then,  
I ran this command: `gmx mdrun -s dynamic_extended.tpr -cpi dynamic_prev.cpt`

But, it gave me the following error:

Command line:  
gmx mdrun -s dynamic\_extended.tpr -cpi dynamic\_prev.cpt  
Output file appending has been requested, but some output files listed in the checkpoint file dynamic\_prev.cpt are not present or not named as the output files by the current program:  
Expect output files present:

Expected output files not present or named differently:  
dynamic.log  
dynamic.xtc  
dynamic.edr

* * *

Program: gmx mdrun, version 2018.2  
Source file: src/gromacs/mdrunutility/handlerestart.cpp (line 179)

Fatal error:  
File appending requested, but 3 of the 3 output files are not present or are  
named differently. For safety reasons, GROMACS-2016 and later only allows file  
appending to be used when all files have the same names as they had in the  
original run. Checkpointing is merely intended for plain continuation of runs.  
For safety reasons you must specify all file names (e.g. with -deffnm), and  
all these files must match the names used in the run prior to checkpointing  
since we will append to them by default. If you used -deffnm and the files  
listed above as not present are in fact present, try explicitly specifying  
them in respective mdrun options. If the files are not available, you can add  
the -noappend flag to mdrun and write separate new parts. For mere  
concatenation of files, you should use the gmx trjcat tool instead.

For more information and tips for troubleshooting, please check the GROMACS  
website at [Errors - Gromacs](http://www.gromacs.org/Documentation/Errors)

* * *
