Puppet agent (Puppet 4) taking too long to apply the catalog

1,451 views
Skip to first unread message

Lauro Silveira

unread,
Dec 1, 2015, 11:14:07 AM12/1/15
to puppet...@googlegroups.com
Hi, 


Until yesterday, an agent on a node was applying the catalog very fast (about 5 seconds).
Yesterday, i've made  a definition that manages the fstab, using the module "herculesteam-augeasproviders_mounttab". The code appears to be very simple :

define linuxbasico::fstab(
  $mntpointsource,
  $mntpointdir,
  $mntpointtype,
  $mntpointoptions
) {
  file { "${mntpointdir}":
    ensure => directory,
  }

  ->

  mounttab { "${mntpointdir}":
    ensure   => present,
    device   => "${mntpointsource}",
    fstype   => "${mntpointtype}",
    options  => $mntpointoptions,
    dump     => "0",
    pass     => "0",
    provider => augeas,
  }
}

So, i've some tests to manage a mount point through this definition and everything worked fine. But, after a few more tests, the agent was taking too long to apply the catalog (more than 100 seconds). So, i removed the reference to my new definition and also removed the mounttab module, but the slowness persisted.
What i've noticed through debug messages is the following group of messages lots of times:


Debug: Failed to load library 'msgpack' for feature 'msgpack'
Debug: Puppet::Network::Format[msgpack]: feature msgpack is missing
Debug: file_metadata supports formats: pson yaml binary
Debug: Using cached connection for https://tucano1.redeteste.camara.gov.br:8140
Debug: Caching connection for https://tucano1.redeteste.camara.gov.br:8140

Another detail, after the message:

Notice: Applied catalog in 104.19 seconds

the agent is still hanging for about 30 seconds.



I've added the following config on the puppetserver, but nothing changed

always_cache_features = true

Any tips?

Thanks in advance.

Ps: Debug log file is attached

Lauro

puppetagent.txt

DEGREMONT Aurelien

unread,
Dec 1, 2015, 12:01:31 PM12/1/15
to puppet...@googlegroups.com
Hello

To debug this slowness, try the following command:

time puppet agent -t --noop --evaltrace --summarize

And look for which part is slow in the summary and possibly which resource evaluation take too much time.


Aurélien
--
You received this message because you are subscribed to the Google Groups "Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CA%2B-B7vurYCOScip42_0Fx_XMWvMfb9PNN_oVM9JnpP-iSirJ8g%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Lauro Silveira

unread,
Dec 3, 2015, 10:33:07 AM12/3/15
to Puppet Users
Thank you, Aurelien!

These options(--noop --evaltrace --summarize) helped me a lot. The problem was a directory that had "recurse => true" by mistake and a subfolder tmp was growing too fast.

Lauro
Reply all
Reply to author
Forward
0 new messages