Hello, I''ve mcollective 1.2.1 with puppet 2.6.12 on rhel5.6, facter 1.6.2 setup from http://projects.puppetlabs.com/projects/mcollective-plugins/wiki/FactsFacterYAML. Now I''ve create a custom fact in /usr/lib/ruby/site_ruby/1.8/facter/ customer_status.rb. On the client; Running facter customer_status works. Running ''puppet agent --test'' works, customer_status is set in /etc/ mcollective/facts.yaml On the server; But running ''mc-puppetd --wi <client> runonce'' doesn''t set the customer_status in /etc/mcollective/facts.yaml. Anyone an idea why? Thanks, Stefan -- 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.
----- Original Message -----> Hello, > > I''ve mcollective 1.2.1 with puppet 2.6.12 on rhel5.6, facter 1.6.2 > setup from > http://projects.puppetlabs.com/projects/mcollective-plugins/wiki/FactsFacterYAML. > > Now I''ve create a custom fact in /usr/lib/ruby/site_ruby/1.8/facter/ > customer_status.rb.you should be using pluginsync to copy out custom facts: http://docs.puppetlabs.com/guides/plugins_in_modules.html> On the client; > Running facter customer_status works. > Running ''puppet agent --test'' works, customer_status is set in /etc/ > mcollective/facts.yaml > > On the server; > But running ''mc-puppetd --wi <client> runonce'' doesn''t set the > customer_status in /etc/mcollective/facts.yaml.this could only really be down to some environment change, maybe its not picking up those fact or your custom fact only works based on some set of stuff in the environment etc? all runonce does is do: puppetd --onetime which will spawn off a copy of puppet into the background and let it do a normal run, with pluginsync enabled in puppet.conf etc it should all work fine. -- 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.
Stefan Heijmans
2011-Nov-01 22:00 UTC
[Puppet Users] Re: Custom fact not set with mc-puppetd
On Nov 1, 10:00 pm, "R.I.Pienaar" <r...@devco.net> wrote:> ----- Original Message ----- > > you should be using pluginsync to copy out custom facts: > > http://docs.puppetlabs.com/guides/plugins_in_modules.html >Ok, enabled pluginsync, customer_status.rb is now copied to the client in /var/lib/puppet/lib/facts.> this could only really be down to some environment change, maybe its > not picking up those fact or your custom fact only works based on > some set of stuff in the environment etc? >Correct, customer_status.rb was picking up an environment variable set from a file in /etc/profile.d/ I''ve changed customer_status.rb to get the value directly from this file. ''mc-puppetd --wi <client> runonce'' doens''t work with customer_status.rb in /var/lib/puppet/lib/facts but it does work with customer_status.rb in /usr/lib/ruby/site_ruby/ 1.8/facter. -- 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.