Puppet - packages long runtime

38 views
Skip to first unread message

Royee Tager

unread,
Jan 5, 2015, 1:50:17 AM1/5/15
to puppet...@googlegroups.com
Hello all,

New CentOS 6.5 clients which run Puppet for the first time have many packages to install.
As you can see below the total runtime is 355.0697 sec.
The package part takes 262.6 sec.
Is it somehow possible to reduce that time?


config_retrieval6.464
cron0.0105
exec49.8922
file33.3775
file_line0.0192
mount0.1564
package261.6271
service3.2403
ssh_authorized_key0.0068
yumrepo0.2743
Total355.0697

Martin Alfke

unread,
Jan 5, 2015, 5:07:31 AM1/5/15
to puppet...@googlegroups.com
Hi,
On 05 Jan 2015, at 07:50, Royee Tager <roye...@gmail.com> wrote:

> Hello all,
>
> New CentOS 6.5 clients which run Puppet for the first time have many packages to install.
> As you can see below the total runtime is 355.0697 sec.
> The package part takes 262.6 sec.
> Is it somehow possible to reduce that time?

Did you measure the time for manual installation?
I assume that the timing is similar.
You can speed package installation by installing a local repo mirror and disable the fastest mirror option.

hth,

Martin



>
>
> config_retrieval 6.464
> cron 0.0105
> exec 49.8922
> file 33.3775
> file_line 0.0192
> mount 0.1564
> package 261.6271
> service 3.2403
> ssh_authorized_key 0.0068
> yumrepo 0.2743
> Total 355.0697
>
> --
> 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/15a5de74-2bc9-4627-ae37-82865dae9d1b%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

Christopher Wood

unread,
Jan 5, 2015, 7:04:34 AM1/5/15
to puppet...@googlegroups.com
On Mon, Jan 05, 2015 at 11:07:12AM +0100, Martin Alfke wrote:
> Hi,
> On 05 Jan 2015, at 07:50, Royee Tager <roye...@gmail.com> wrote:
>
> > Hello all,
> >
> > New CentOS 6.5 clients which run Puppet for the first time have many packages to install.
> > As you can see below the total runtime is 355.0697 sec.
> > The package part takes 262.6 sec.
> > Is it somehow possible to reduce that time?
>
> Did you measure the time for manual installation?
> I assume that the timing is similar.
> You can speed package installation by installing a local repo mirror and disable the fastest mirror option.

Explicitly selecting local mirrors will speed up the download.

https://docs.puppetlabs.com/references/latest/type.html#yumrepo

An idea I've toyed with, but haven't yet implemented (since we're so far fine with having initial agent runs take 5 minutes), is grepping package names for a particular set of profiles out of the classes in question and making a new rpm which depends on all those. Then have puppet install the new rpm first using some creative chaining. I suspect that yum might be quicker at dependency resolution than puppet is.

(I would still have all the other packages listed to provide a complete server spec in puppet.)

> hth,
>
> Martin
>
>
>
> >
> >
> > config_retrieval 6.464
> > cron 0.0105
> > exec 49.8922
> > file 33.3775
> > file_line 0.0192
> > mount 0.1564
> > package 261.6271
> > service 3.2403
> > ssh_authorized_key 0.0068
> > yumrepo 0.2743
> > Total 355.0697
> >
> > --
> > 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/15a5de74-2bc9-4627-ae37-82865dae9d1b%40googlegroups.com.
> > For more options, visit https://groups.google.com/d/optout.
>
> --
> 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/D298D66E-3E1D-4D98-B61F-660FB7126D11%40gmail.com.

kaustubh chaudhari

unread,
Jan 5, 2015, 9:20:52 AM1/5/15
to puppet...@googlegroups.com
Depends on which package you are installing ... also as mentioned in the mail trail you need to check the manual time or installation.

# time yum -y pkg

kaustubh chaudhari

unread,
Jan 5, 2015, 9:43:48 AM1/5/15
to puppet...@googlegroups.com
Also you might want to run puppet agent with the below parameters for details:

# puppet agent --evaltrace -td

-HTH
Kaustubh
Reply all
Reply to author
Forward
0 new messages