Pavel Shevaev
2009-Jul-01 12:36 UTC
[Puppet Users] Forcing puppetd ask puppemasterd for new changes
Guys, I seriously could not find this topic in the documentation. What do you do when you need to force puppetd hosts get the new settings from puppetmasterd? What I found was only sending USR1 signal to the client process in order to make it refresh its configuration from the master. But I find it a bit inconvenient for a large amount of hosts. There is also puppetrun which, if I understand correctly, can make specific puppet hosts check for new changes. However it seems it tries to connect to port 8139 and for some reason my puppetd hosts are not listening on this port, while puppetd is running for sure. I believe it can be configured somehow, I just thought it was the default option... And finally, how often does puppetd running in the daemon mode ask puppetmasterd for new chages? Does it do it more than once? puppetd --help says(I''m using 0.24.4 on Gentoo): =====================================================Synopsis -------- .... Currently must be run out periodically, using cron or something similar. ====================================================== Is it true? Thanks in advance. -- Best regards, Pavel --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---
Roberto Moral
2009-Jul-01 13:12 UTC
[Puppet Users] Re: Forcing puppetd ask puppemasterd for new changes
In order to use puppetrun you need to run puppetd with the --listen option, you will also need a namespaceauth.conf client side (http://reductivelabs.com/trac/puppet/wiki/NameSpaceAuth ) from http://reductivelabs.com/trac/puppet/wiki/PuppetExecutables#id7 puppetd Puppet''s agent. It does not know how to find or compile manifests and is only useful for contacting a central server. Note that there are multiple clients that can be loaded within this agent, and the agent can listen for incoming connections. If you start it with --listen, by default it will accept triggers from puppetrun, but puppetd will refuse to start if listen is enabled and it has no namespaceauth.conf file. It can load other handlers; check its documentation for more detail. On Wednesday,Jul 1, 2009, at Wednesday,Jul 1, 20098:36 AM, Pavel Shevaev wrote:> > Guys, I seriously could not find this topic in the documentation. > > What do you do when you need to force puppetd hosts get the new > settings from puppetmasterd? > > What I found was only sending USR1 signal to the client process in > order to make it refresh its configuration from the master. > But I find it a bit inconvenient for a large amount of hosts. > > There is also puppetrun which, if I understand correctly, can make > specific puppet hosts check for new changes. > However it seems it tries to connect to port 8139 and for some reason > my puppetd hosts are not listening on this port, while puppetd is > running for sure. > I believe it can be configured somehow, I just thought it was the > default option... > > And finally, how often does puppetd running in the daemon mode ask > puppetmasterd for new chages? Does it do it more than once? > > puppetd --help says(I''m using 0.24.4 on Gentoo): > > =====================================================> Synopsis > -------- > .... > Currently must be run out periodically, using cron or something > similar. > > ======================================================> > Is it true? > > Thanks in advance. > > -- > Best regards, Pavel > > >--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---
Pavel Shevaev
2009-Jul-01 16:12 UTC
[Puppet Users] Re: Forcing puppetd ask puppemasterd for new changes
On Wed, Jul 1, 2009 at 5:12 PM, Roberto Moral<telmox@gmail.com> wrote:> > In order to use puppetrun you need to run puppetd with the --listen > option, you will also need a namespaceauth.conf client side (http://reductivelabs.com/trac/puppet/wiki/NameSpaceAuth > ) > > from http://reductivelabs.com/trac/puppet/wiki/PuppetExecutables#id7Thank you for the quick answer. So, I guess I have 2 options then: a) running puppetd via cron, e.g: puppetd --no-daemonize --onetime --server master.host b) running puppetd as a daemon with --listen option and force updates using puppetrun What''s the most preferred way? Or maybe there is even a better option? -- Best regards, Pavel --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---
Macno
2009-Jul-01 20:53 UTC
[Puppet Users] Re: Forcing puppetd ask puppemasterd for new changes
Well, since by default the puppet daemon checks the puppetmaster every 30 mins (can be reduced, but I don''t think it''s a great idea on large installations) if you want to trigger a puppetrun whenever you want, puppetrun is the way. This can leave you the option to force the puppet daemon checks (or cronjob runs) less frequently, which is a not a bad thing in most cases. my 2c On Jul 1, 6:12 pm, Pavel Shevaev <pacha.shev...@gmail.com> wrote:> On Wed, Jul 1, 2009 at 5:12 PM, Roberto Moral<tel...@gmail.com> wrote: > > > In order to use puppetrun you need to run puppetd with the --listen > > option, you will also need a namespaceauth.conf client side (http://reductivelabs.com/trac/puppet/wiki/NameSpaceAuth > > ) > > > fromhttp://reductivelabs.com/trac/puppet/wiki/PuppetExecutables#id7 > > Thank you for the quick answer. So, I guess I have 2 options then: > a) running puppetd via cron, e.g: puppetd --no-daemonize --onetime > --server master.host > b) running puppetd as a daemon with --listen option and force updates > using puppetrun > > What''s the most preferred way? Or maybe there is even a better option? > > -- > Best regards, Pavel--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---
Pavel Shevaev
2009-Jul-02 03:57 UTC
[Puppet Users] Re: Forcing puppetd ask puppemasterd for new changes
On Thu, Jul 2, 2009 at 12:53 AM, Macno<lab42.it@gmail.com> wrote:> > Well, since by default the puppet daemon checks the puppetmaster every > 30 mins (can be reduced, but I don''t think it''s a great idea on large > installations)Could you please tell me which config option is responsible for that? if you want to trigger a puppetrun whenever you want,> puppetrun is the way. > This can leave you the option to force the puppet daemon checks (or > cronjob runs) less frequently, which is a not a bad thing in most > cases.The most flexible way for me would be to decrease the sync interval for each puppetd to about 3 minutes and running each puppetd with --listen option. -- Best regards, Pavel --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---
James Turnbull
2009-Jul-02 05:58 UTC
[Puppet Users] Re: Forcing puppetd ask puppemasterd for new changes
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Pavel Shevaev wrote:> On Thu, Jul 2, 2009 at 12:53 AM, Macno<lab42.it@gmail.com> wrote: >> Well, since by default the puppet daemon checks the puppetmaster every >> 30 mins (can be reduced, but I don''t think it''s a great idea on large >> installations) > > Could you please tell me which config option is responsible for that?- --runinterval See http://reductivelabs.com/trac/puppet/wiki/ConfigurationReference. Regards James Turnbull - -- Author of: * Pro Linux Systems Administration (http://tinyurl.com/linuxadmin) * Pulling Strings with Puppet (http://tinyurl.com/pupbook) * Pro Nagios 2.0 (http://tinyurl.com/pronagios) * Hardening Linux (http://tinyurl.com/hardeninglinux) -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iEYEARECAAYFAkpMTIgACgkQ9hTGvAxC30BKMACfRsR59b1o6BWM8TPN2jHuTK9L tY4Anjj4aqxHj8HUY4ANM3el8WLo5WRH =Hj6D -----END PGP SIGNATURE----- --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---
Pavel Shevaev
2009-Jul-02 07:26 UTC
[Puppet Users] Re: Forcing puppetd ask puppemasterd for new changes
> - --runinterval > > See http://reductivelabs.com/trac/puppet/wiki/ConfigurationReference.Thanks a lot! -- Best regards, Pavel --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---
Pavel Shevaev
2009-Jul-02 08:47 UTC
[Puppet Users] Re: Forcing puppetd ask puppemasterd for new changes
Sorry folks, I''m replying to myself but here is what I found out. For some reason running with shorter --runinterval gives me a warning on the second and further update sessions with puppetmasterd: "Other end went away; restarting connection and retrying." But puppetmasterd is running for sure.... Here is a sample verbose session: =========================================================================pachanga@stage ~ $ sudo puppetd --no-daemonize --server master --verbose --runinterval 30 Password: notice: Starting Puppet client version 0.24.4 info: Retrieving plugins info: Caching catalog at /var/lib/puppet/localconfig.yaml notice: Starting catalog run ... * Some changes are applied here* ... notice: Finished catalog run in 2.15 seconds * Next interval * info: Retrieving plugins info: Configuration is up to date notice: Starting catalog run notice: Finished catalog run in 5.88 seconds info: Retrieving plugins warning: Other end went away; restarting connection and retrying info: Configuration is up to date notice: Starting catalog run notice: Finished catalog run in 1.08 seconds ========================================================================= If I cancel this command witch Ctrl-C and start it again puppetd retrieves the new changes from the master. I definitely don''t understand something very obvious related to the proper invocation of the puppetd daemon, please guide into the right direction. -- Best regards, Pavel --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---
Macno
2009-Jul-02 09:07 UTC
[Puppet Users] Re: Forcing puppetd ask puppemasterd for new changes
--runinterval is an option to be used in daemon mode (place it in puppet.conf) If you trigger puppet via cron, you can decide the interval at cron level. I personally would never place a runinterval value lesser than 30 minutes (3 mins is really extreme, if you need to apply changes immediately use puppetrun, and leave the interval check at 30). ciao On 2 Lug, 10:47, Pavel Shevaev <pacha.shev...@gmail.com> wrote:> Sorry folks, I''m replying to myself but here is what I found out. For > some reason running with shorter --runinterval gives me a warning on > the second and further update sessions with puppetmasterd: > > "Other end went away; restarting connection and retrying." > > But puppetmasterd is running for sure.... > > Here is a sample verbose session: > =========================================================================> pachanga@stage ~ $ sudo puppetd --no-daemonize --server master > --verbose --runinterval 30 > Password: > notice: Starting Puppet client version 0.24.4 > info: Retrieving plugins > info: Caching catalog at /var/lib/puppet/localconfig.yaml > notice: Starting catalog run > ... > * Some changes are applied here* > ... > notice: Finished catalog run in 2.15 seconds > > * Next interval * > > info: Retrieving plugins > info: Configuration is up to date > notice: Starting catalog run > notice: Finished catalog run in 5.88 seconds > info: Retrieving plugins > warning: Other end went away; restarting connection and retrying > info: Configuration is up to date > notice: Starting catalog run > notice: Finished catalog run in 1.08 seconds > =========================================================================> > If I cancel this command witch Ctrl-C and start it again puppetd > retrieves the new changes from the master. > > I definitely don''t understand something very obvious related to the > proper invocation of the puppetd daemon, please guide into the right > direction. > > -- > Best regards, Pavel--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---
Sam Rowe
2009-Jul-03 14:23 UTC
[Puppet Users] Re: Forcing puppetd ask puppemasterd for new changes
FYI puppetd --test or puppetd -t is shorter than all of that --one-time --no-daemonize etc stuff and is basically the same. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---
Pete Emerson
2009-Jul-03 16:18 UTC
[Puppet Users] Re: Forcing puppetd ask puppemasterd for new changes
I also turn on reporting back to puppetmaster via --report and have found that very useful for debugging and figuring out state centrally. On 7/3/09, Sam Rowe <sam@samrowe.com> wrote:> > FYI puppetd --test or puppetd -t is shorter than all of that > --one-time --no-daemonize etc stuff and is basically the same. > > > >-- Sent from my mobile device --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---