Change the environment_timeout setting
The environment_timeout
setting controls if and how long the primary
server caches environment data. Environment caching can reduce your Puppet Server's CPU usage, but longer cache times extend the amount
of time it takes for environments to reflect changes to their Puppet code.
The environment_timeout
parameter accepts these
values:
- No caching:
0
- Retain environment data caches indefinitely:
unlimited
- Cache environments for a specified length of time after their last use: Any
length of time, such as
5m
By default, environment_timeout
is set to 0
. When
you Enable Code Manager, environment_timeout
is set to 5m
.
However, if you set code_manager_auto_configure
to true
in your Code Manager settings , then
environment_timeout
is automatically set to
unlimited
.
environment_timeout
to 0
taxes your primary server's performance but makes it
easy for new users to deploy updated Puppet code.
Once your code deployment process is mature (or after enabling Code Manager), we recommend changing this setting to
unlimited
.Refer to the Puppet documentation for more information About environments, including Environment limitations, such as leakage and resource conflicts.
The following steps explain how to change the environment_timeout
setting in pe.conf
. You can also change this setting in the PE console in the PE Master
node group. For instructions on changing settings in the console, refer to Configure settings in the PE console.
- On your primary server, open the
pe.conf
file in a text editor. - Add the
environment_timeout
parameter and the desired value. For example:puppet_enterprise::master::environment_timeout: 0
- Save the file and run:
puppet agent -t