Depending on the characteristics of a particular computer system, it is sometimes necessary for performance reasons to override some of the defaults built into the program. This can be done by creating a customization file. On UNIX-based systems, this file is named Default.Route, residing in $g16root/g16. Under Windows, the Gaussian defaults file is Default.Rou, and it is located in the Gaussian 16W scratch subdirectory (e.g., C:\G16W\scratch). The format of the file is the same on all computer systems.
The following subsections describe the types of information which can be supplied in the defaults file.
There may be more than one -#- line in the file.
and the route section contains the MP2 keyword, then the conventional MP2 algorithm will be used. However, if the route section contains the MP2=Direct keyword, then the direct algorithm will be used.
The directive -R- is a synonym for -#-.
Maximum Disk Usage
You will usually want to specify the amount of scratch disk space available via the MaxDisk keyword in the Default.Route file. For example, the following line sets MaxDisk to 2 GB:
The amount of available disk space is given in 8-byte words by default. This value may also be followed by KB, MB, GB, TB, KW, MW, GW, or TW (without intervening spaces) to specify units of kilo-, mega-, giga-, or tera-bytes/words.
The scratch disk space is set unlimited by default: i.e., MaxDisk=-1. In other words, it is assumed that enough disk space is available to perform a given calculation with no redundant work. Thus, specifying the amount of available memory and disk is by far the most important way of optimizing performance for your calculations. Doing so allows the program to decide between the various available algorithms, selecting the optimal one for your particular system configuration. Keep in mind that the more disk space available, the faster the evaluation, especially for MP2.
Gaussian jobs which unwisely use excessive memory can cause severe difficulties on the system. The memory directive -M- enforces a default dynamic memory limit. For example, the following line sets default memory use to 3GB:
The amount of available memory is given in 8-byte words (default); this value may also be followed by KB, MB, GB, TB, KW, MW, GW, or TW (without intervening spaces) to specify units of kilo-, mega-, giga-, or tera-bytes or words. The default memory size is 800 MB (100 MW). Note that this limit can be overridden with the %Mem Link 0 command.
The memory directive -U- sets default memory to use in utilities such as formchk and freqchk.
User Defaults Files
Gaussian users may set their own defaults by creating their own Default.Route file. Gaussian checks the current working directory for a file of this name when a job is initiated. Settings in the local file take precedence over those in the site-wide file, and options specified in the route section of the job take precedence over both of them.
Command Line Options & Environment Variable Equivalents
All of these directives can also be set via environment variables or UNIX/Linux command line arguments. The environment variable GAUSS_XDEF provides a command line equivalent to -X- in the Default.Route file. Similarly, the command line argument to g16 –x="value" specifies the same setting. For example, all of the following have the equivalent effect:
-M- 4GB in Default.Route export GAUSS_MDEF=4GB g16 -m="4GB" …
Order of Priority
The order of priority is:
- command line argument
- environment variable
- Default.Route setting
- internal program default
Not all route section keywords are honored in the Default.Route file. In general, the rule is that options which are specific to a specific job type are ignored. Thus, Integral=SuperFine, which changes the default integration grid, will be honored, while Freq=Raman, which specifies a setting for a specific job type, will be ignored.
Parallel Job Directives
Parallel Execution on Shared Memory Multiprocessors
Gaussian defaults to execution on only a single processor. If your computer system has multiple processors/cores, and parallel processing is supported in your version of Gaussian, you may the specific CPUs on which to run with the -C- directive. For example, the following directive specifies that the program should run on the first 5 cores of a hexacore system (reserving one core for other use):
The node list can also be specified as a range (e.g., 0-5). Ranges can also be followed by a suffix of the form /n, which says to use every nth processor in the range (e.g., /2 specifies every second processor/core).
The older -P- directive can be used to specify the total number of processors on which to execute (leaving the selection of processors to the operating system). Clearly, the number of processors requested should not exceed the number of processors available, or a substantial decrease in performance will result.
Network/Cluster Parallel Execution
You can specify the list of Linda workers in Default.Route via the -W- directive:
This example will use the specified five nodes for parallel execution, placing 2 worker processes on lavoisier, 3 workers on agassiz, and one worker on each of the other systems. If the master node—the node where the job is started—is not one of these systems, a worker will also run on that system (making a total of six nodes).
This directive corresponds to—and can be overridden by—the Link 0 command %LindaWorkers.
The -S- directive specifies which program to use to start worker processes. It takes either rsh (the default) or ssh as its parameter.
Combining SMP and Network Parallelism
When -W- is combined with -C- or -P-, then an SMP parallel worker process is started on each node in the node list (or more than one such process when multiple workers are specified for that node). In other words, these individual worker processes run in parallel according to the SMP-related settings. If the settings are inappropriate for a listed computer, then the work will fail on that node. For example, the following directives will start workers as multiprocessors jobs on the specified systems:
-W- alpha,beta,gamma -C- 0,1,2,3
However, if system beta is a dual-core workstation, that worker process will fail as there is no processor 2 or 3 present on that computer. This mechanism is designed primarily for cluster environments with uniform nodes.
Note that it is the Default.Route file on the master which is relevant; Default.Route files that may be present on worker systems are not used.
Parallel Execution on GPUs
The -G- directive sets the default list of GPUs to use. When using GPUs it is essential to have each GPU controlled by a specific CPU and much preferable if the CPU is physically close to the GPU it is controlling. The list uses the syntax gpu#(s)=core#(s) to indicate which GPUs to use and the core to which each is pinned. For example, the following directive tells Gaussian to execute on GPU0 through GPU3:
GPU0 and GPU1 are pinned to cores 0 and 1, while GPU2 and GPU3 are pinned to cores 16 and 17 (respectively).
Ranges of GPUs and/or cores can be used in this directive. For example, the following is equivalent to the preceding:
The -F- directive sets the default options for the formchk utility. By default formchk produces a formatted checkpoint file that is backwardly compatible with all previous versions of Gaussian.
The parameter to -F- can be -3 or -2 to create a formatted checkpoint file of the corresponding version (version 3 is the default). The parameter can also contain -c, which causes the molecular mechanics atom types to appear in the formatted checkpoint file as strings rather than integers.
The memory directive -U- sets default memory to use in utilities such as formchk and freqchk.
For a dual-core workstation with 8 GB memory and 1 TB of disk, the default algorithms and memory allocation are fine. However, MaxDisk and the default CPUs for execution need to be specified:
-C- 0,1 -#- MaxDisk=200GB
On a server with 4 octa-core processors and 256 GB of memory designed to be used for large jobs, 8 cores should be used by default: the first 8 odd numbered cores starting with core 0. Also, more memory should be given to each job (2 GB/core):
-M- 16GB -C- 0-16/2 -#- MaxDisk=500GB
On some older Intel processors (Nehalem and before), there is not enough memory bandwidth to keep all the CPUs on a chip busy, and it is often preferable to use half the CPUs, each with twice as much memory as if all were used. For example, on such a machine with 4 12-core chips and 128 GBytes of memory, with CPUs 0-11 on the first chip, 12-23 on the second, etc., it is better to run using 24 processors (6 on each chip) and give them 72/24=3GByte memory each, rather than use all 48 with only 1.5GBytes of memory each. The appropriate directive would be
-M- 72GB -C- 0-47/2
/2 says to use every other core: i.e., cores 0, 2, 4, 6, 8 and 10 on chip 0, cores 12, 14, 16, 18, 20 and 22 on chip 1, and so on.
|Default.Route||Link 0||Option||Env. Var.||Description|
|-#-||-r||GAUSS_RDEF||Route section keyword list.|
|-C-||%CPU||-c||GAUSS_CDEF||Processor/core list for multiprocessor parallel jobs.|
|-F-||GAUSS_FDEF||Options for the formchk utility.|
|-G-||%GPUCPU||-g||GAUSS_GDEF||GPUs=Cores list for GPU parallel jobs.|
|-M-||%Mem||-m||GAUSS_MDEF||Memory amount for Gaussian jobs.|
|-O-||GAUSS_ODEF||Organization (site) name.|
|-P-||%NProcShared||-p||GAUSS_PDEF||Number of processors/cores for multiprocessor parallel jobs.
Superseded in most cases by -C-.
|-R-||-r||GAUSS_RDEF||Route section keyword list.|
|-S-||%UseSSH||-s||GAUSS_SDEF||Program to start workers for network parallel jobs: rsh or ssh.|
|-U-||GAUSS_UDEF||Memory amount for utilities.|
|-W-||%LindaWorkers||-w||GAUSS_WDEF||List of hostnames for network parallel jobs.|
Last updated on: 05 January 2017. [G16 Rev. A.03]