Jay Christopherson
2013-Dec-08 04:22 UTC
[Puppet Users] using mco to manage puppet resources by class
Has anyone successfully use the class selectors for the puppet MCollective plugin? Something like: $ mco puppet runonce --tags mysql::master From the docs: *puppet_tags* *===========* *Validates that a comma seperated list of tags are valid Puppet class names* * Author: R.I.Pienaar <rip@devco.net <rip@devco.net>>* * Version: 1.0* * License: ASL 2.0* * Timeout: 1* * Home Page: http://devco.net/ <http://devco.net/>* * Puppet tags can be a comma seperated list of valid class names, for details* * about valid class names please see the puppet_variable validator documentation.* * An example of 2 tags would be:* * apache,mysql::master* When I run that command, even though that class is only applied to a single host, the list it compiles is all 43 of the hosts currently under mco control: $ mco puppet runonce --noop --tags mysql::master * [ ============================================================> ] 43 / 43 Finished processing 43 / 43 hosts in 3720.64 ms I''ve tried several variations and classes without success. It always processes the list of all servers. -- 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+unsubscribe@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CAFwM5Hwyg7_QM4TKWLHsVo-C1oSa4wH%3DF%3DGjcjwA2UKOwOU%2BoA%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.
Felix Frank
2013-Dec-10 20:34 UTC
Re: [Puppet Users] using mco to manage puppet resources by class
Hi, I haven''t played with mco, but doesn''t the document you quote say "puppet_tags" instead of just "tags"? I assume the parameter should be --puppet_tags=mysql::master. HTH, Felix On 12/08/2013 05:22 AM, Jay Christopherson wrote:> $ mco puppet runonce --tags mysql::master > > From the docs: > /puppet_tags/-- 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+unsubscribe@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/52A77AE1.8060205%40Alumni.TU-Berlin.de. For more options, visit https://groups.google.com/groups/opt_out.
Stefan Heijmans
2013-Dec-11 14:03 UTC
[Puppet Users] Re: using mco to manage puppet resources by class
Hi, mco puppet --help says the following for tags; --tags, --tag TAG Restrict the run to specific tags>>mco puppet runonce --noop --tags mysql::masterSo, it would be correct that this runs over all puppet nodes, except the Puppet run will only process mysql::master. --tags doesn''t act as a node filter for MCollective. If you want to filter you puppet run to nodes, only having the class mysql::master, use this filter; -C, --wc, --with-class CLASS Match hosts with a certain config management class mco puppet runonce --noop --wc mysql::master Stefan Op zondag 8 december 2013 05:22:53 UTC+1 schreef jc.listmail:> Has anyone successfully use the class selectors for the puppet MCollective > plugin? > > Something like: > > $ mco puppet runonce --tags mysql::master > > From the docs: > *puppet_tags* > *===========* > > *Validates that a comma seperated list of tags are valid Puppet class > names* > > * Author: R.I.Pienaar <r...@devco.net <javascript:>>* > * Version: 1.0* > * License: ASL 2.0* > * Timeout: 1* > * Home Page: http://devco.net/ <http://devco.net/>* > > * Puppet tags can be a comma seperated list of valid class names, for > details* > * about valid class names please see the puppet_variable validator > documentation.* > > * An example of 2 tags would be:* > > * apache,mysql::master* > > > When I run that command, even though that class is only applied to a > single host, the list it compiles is all 43 of the hosts currently under > mco control: > > $ mco puppet runonce --noop --tags mysql::master > > * [ ============================================================> ] 43 / > 43 > > > > > Finished processing 43 / 43 hosts in 3720.64 ms > > I''ve tried several variations and classes without success. It always > processes the list of all servers. >-- 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+unsubscribe@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/2544d7e8-e902-466e-bb51-27f91bc60bcf%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.