Ask Your Question

How to change check-in interval from puppet master?

asked 2014-06-25 04:21:50 -0600

Jason C gravatar image

I'd like to be able to change the check-in interval on my agents from 30 minutes to 6 hours. I see I can do this by editing the agent's puppet.conf and setting runinterval=21600, but I'd prefer not to have to do file-editing on clients every time I set up an agent.

Is there a way to pipe this setting from the puppet master?

My agents are exclusively Windows Server boxes.

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted

answered 2014-06-26 09:49:55 -0600

llowder gravatar image

updated 2014-06-27 08:45:02 -0600

There are a couple of different ways you can do this.

If you already manage the puppet.conf via Puppet you can just update your template.

If you do not, you can use something like the inifile resource to push out that change.

For example:

inifile::setting { 'agent_runinterval':
  ensure => present,
  path    => "/etc/puppetlabs/puppet/puppet.conf",
  section => "main",
  setting => "runinterval",
  value => "21600",

If you are not using Puppet Enterprise, the default path for puppet.conf is /etc/puppet/puppet.conf. If you are not running Puppet as root, the default path is ~/.puppet/puppet.conf .

edit flag offensive delete link more


Thanks, I used this method. I needed a few syntax corrections, giving: ini_setting { 'agent_runinterval': ensure => present, path => "/etc/puppetlabs/puppet/puppet.conf", section => "main", setting => "runinterval", value => "21600", }

Jason C gravatar imageJason C ( 2014-06-27 05:21:27 -0600 )edit

Glad that worked. I updated my answer to reflect the corrected section value.

llowder gravatar imagellowder ( 2014-06-27 08:45:39 -0600 )edit

answered 2014-06-25 15:39:16 -0600

Stefan gravatar image

There is no build in functionality but you can of course ship the puppet.conf configuration file with a file resource through puppet. That is actually quite common.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools


Asked: 2014-06-25 04:21:50 -0600

Seen: 1,626 times

Last updated: Jun 27 '14