The checkpointing feature of Ansys Fluent allows you to save case and data files while your simulation is running. While similar to the autosave feature of Ansys Fluent (Automatic Saving of Case and Data Files), which allows you to save files throughout a simulation, checkpointing allows you slightly more control in that you can save an Ansys Fluent job even after you have started the job and did not set the autosave option. Checkpointing also allows you to save case and data files and then exit out of Ansys Fluent. This feature is especially useful when you need to stop an Ansys Fluent job abruptly and save its data.
There are two different ways to checkpoint an Ansys Fluent simulation, depending upon how the simulation has been started.
Ansys Fluent running under LSF or SGE
Ansys Fluent is integrated with load management tools like LSF and SGE. These two tools allow you to checkpoint any job running under them. You can use the standard method provided by these tools to checkpoint the Ansys Fluent job.
For more information on using Ansys Fluent and SGE or LSF, see Part III: Running Fluent Under SGE or Part I: Running Fluent Under LSF, respectively.
Independently running Ansys Fluent
When not using tools such as LSF or SGE, a different checkpointing mechanism can be used when running an Ansys Fluent simulation. You can checkpoint an Ansys Fluent simulation while iterating / time stepping, so that Ansys Fluent saves the case and data files and then continues the calculation, or so that Ansys Fluent saves the case and data files and then exits.
Saving case and data files and continuing the calculation:
On Linux, create a file named
check-fluent
in the working directory; on Windows, create a file namedcheck-fluent.txt
in the working directory. After the case and data files are saved, thecheck-fluent
/check-fluent.txt
file will be automatically deleted. Note that if multiple Fluent sessions are running with the same working directory, case and data files will be saved for all of them.Saving case and data files and exiting Ansys Fluent:
On Linux, create a file named
exit-fluent
in the working directory; on Windows, create a file namedexit-fluent.txt
in the working directory. After the case and data files are saved and Fluent exits, theexit-fluent
/exit-fluent.txt
file will be automatically deleted.Note that if you are running multiple Fluent sessions with the same working directory, case and data files will be saved for all of them, but only a single session will exit. To ensure that your intended session exits, you must type the process ID of the Cortex process for that session as the first line of text in the
exit-fluent
/exit-fluent.txt
file. You can find this process ID by generating a transcript file, as the process ID is included as the last string of digits in the name of the transcript file (for details, see Creating Transcript Files). Alternatively, the process ID can be found by using operating system tools from a command prompt; for example, you could use theps
command in Linux and look for thePID
of theCMD
namedcortex.24.2.0
, or you could use thetasklist
command in Windows and look for thePID
of theImage Name
namedcx2420.exe
.
The saved case and data files will have the current iteration number appended to their file names.
Ansys Fluent offers an alternate way to checkpoint an unsteady simulation. While the default behavior is to checkpoint the simulation at the end of the current iteration, for unsteady simulations you have the option of completing all of the iterations in the current time step before checkpointing. This can be set by entering the following Scheme command prior to running the unsteady simulation:
(ckpt/time-step? #t)
Now when you save the checkpoint file (as described previously), the case and data file will be saved at the end of the current time step and named accordingly. To switch back to the default checkpointing mechanism at the end of the current iteration, use the following Scheme command:
(ckpt/time-step? #f)
Important: Note that the
(ckpt/time-step? #t)
command will have the effect only in the case of an unsteady simulation.
Note: It is recommended that you do not use checkpointing when using
Ansys Fluent in Workbench. However, if checkpointing is necessary, the
exit-fluent
/ exit-fluent.txt
file can be used
and the file will be checked in its default location (the FFF/FLU
system directory containing the *.set
file). If Ansys Fluent is
calculating, then the existence of the file is equivalent to an interrupt command. Similarly, the check-fluent
/
check-fluent.txt
file can be used to save the project on demand when
Ansys Fluent is calculating.