Re: [Puppet Users] MCollective Puppet plugin - runall not working

2013-07-11 Thread Jon Ward
Ah that's working perfectly now, thanks so much for your time.

Yep, I will update my Puppet scripts to install the deb packages going 
forward.

Jon

On Thursday, July 11, 2013 11:01:33 AM UTC+1, R.I. Pienaar wrote:
>
>
>
> - Original Message - 
> > From: "Jon Ward" > 
> > To: puppet...@googlegroups.com  
> > Sent: Thursday, July 11, 2013 10:59:11 AM 
> > Subject: Re: [Puppet Users] MCollective Puppet plugin - runall not 
> working 
> > 
> > Ah, sorry the node I was testing was disabled, and the ones that were 
> > enabled were missing some of the $libdir/ directories (I had copied them 
> up 
> > manually and Puppet had wiped them out without my realising.) 
>
> best to install the agents using the debs yeah, takes care of all these 
> problems 
>
> > 
> > I'm getting an error now, but at least the nodes are being discovered: 
> > 
> > # mco puppet -v runall 2 
> > 2013-07-11 09:56:31: Running all nodes with a concurrency of 2 
> > 2013-07-11 09:56:31: Discovering enabled Puppet nodes to manage 
> > Discovering hosts using the mc method for 3 second(s)  2 
> > 2013-07-11 09:56:34: Found 2 enabled nodes 
> > Discovering hosts using the mc method for 3 second(s)  0 
> > 
> > The puppet application failed to run, use -v for full error details: Can 
> > only supply discovery data if direct_addressing is enabled 
>
> set direct_addressing=1 everywhere, you need to be using the ActiveMQ or 
> RabbitMQ connectors for this. 
>

-- 
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+unsubscr...@googlegroups.com.
To post to this group, send email to puppet-users@googlegroups.com.
Visit this group at http://groups.google.com/group/puppet-users.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [Puppet Users] MCollective Puppet plugin - runall not working

2013-07-11 Thread R.I.Pienaar


- Original Message -
> From: "Jon Ward" 
> To: puppet-users@googlegroups.com
> Sent: Thursday, July 11, 2013 10:59:11 AM
> Subject: Re: [Puppet Users] MCollective Puppet plugin - runall not working
> 
> Ah, sorry the node I was testing was disabled, and the ones that were
> enabled were missing some of the $libdir/ directories (I had copied them up
> manually and Puppet had wiped them out without my realising.)

best to install the agents using the debs yeah, takes care of all these problems

> 
> I'm getting an error now, but at least the nodes are being discovered:
> 
> # mco puppet -v runall 2
> 2013-07-11 09:56:31: Running all nodes with a concurrency of 2
> 2013-07-11 09:56:31: Discovering enabled Puppet nodes to manage
> Discovering hosts using the mc method for 3 second(s)  2
> 2013-07-11 09:56:34: Found 2 enabled nodes
> Discovering hosts using the mc method for 3 second(s)  0
> 
> The puppet application failed to run, use -v for full error details: Can
> only supply discovery data if direct_addressing is enabled

set direct_addressing=1 everywhere, you need to be using the ActiveMQ or
RabbitMQ connectors for this.

-- 
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+unsubscr...@googlegroups.com.
To post to this group, send email to puppet-users@googlegroups.com.
Visit this group at http://groups.google.com/group/puppet-users.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [Puppet Users] MCollective Puppet plugin - runall not working

2013-07-11 Thread Jon Ward
Ah, sorry the node I was testing was disabled, and the ones that were 
enabled were missing some of the $libdir/ directories (I had copied them up 
manually and Puppet had wiped them out without my realising.)

I'm getting an error now, but at least the nodes are being discovered:

# mco puppet -v runall 2
2013-07-11 09:56:31: Running all nodes with a concurrency of 2
2013-07-11 09:56:31: Discovering enabled Puppet nodes to manage
Discovering hosts using the mc method for 3 second(s)  2
2013-07-11 09:56:34: Found 2 enabled nodes
Discovering hosts using the mc method for 3 second(s)  0

The puppet application failed to run, use -v for full error details: Can 
only supply discovery data if direct_addressing is enabled

Can only supply discovery data if direct_addressing is enabled 
(RuntimeError)
from /usr/lib/ruby/1.8/mcollective/rpc/client.rb:467:in `discover'  
<
from 
/usr/share/mcollective/plugins/mcollective/util/puppetrunner.rb:82:in 
`runhost'
from 
/usr/share/mcollective/plugins/mcollective/util/puppetrunner.rb:75:in 
`runhosts'
from /usr/lib/ruby/1.8/timeout.rb:79:in `each_with_index'
from 
/usr/share/mcollective/plugins/mcollective/util/puppetrunner.rb:65:in `each'
from 
/usr/share/mcollective/plugins/mcollective/util/puppetrunner.rb:65:in 
`each_with_index'
from 
/usr/share/mcollective/plugins/mcollective/util/puppetrunner.rb:65:in 
`runhosts'
from 
/usr/share/mcollective/plugins/mcollective/util/puppetrunner.rb:59:in 
`runall_once'
from 
/usr/share/mcollective/plugins/mcollective/util/puppetrunner.rb:21:in 
`runall'
from 
/usr/share/mcollective/plugins/mcollective/application/puppet.rb:277:in 
`runall_command'
from 
/usr/share/mcollective/plugins/mcollective/application/puppet.rb:382:in 
`send'
from 
/usr/share/mcollective/plugins/mcollective/application/puppet.rb:382:in 
`main'
from /usr/lib/ruby/1.8/mcollective/application.rb:285:in `run'
from /usr/lib/ruby/1.8/mcollective/applications.rb:23:in `run'
from /usr/bin/mco:20




On Thursday, July 11, 2013 10:43:43 AM UTC+1, R.I. Pienaar wrote:
>
>
>
> - Original Message - 
> > From: "Jon Ward" > 
> > To: puppet...@googlegroups.com  
> > Sent: Thursday, July 11, 2013 10:37:00 AM 
> > Subject: Re: [Puppet Users] MCollective Puppet plugin - runall not 
> working 
> > 
> > Hi, 
> > 
> > I had just copied the files over manually and placed them in the 
> respective 
> > directories, I've now also installed the deb packages 
> > "mcollective-puppet-agent" on the agent nodes and 
> > "mcollective-puppet-common" on the client nodes from the Puppetlabs repo 
> > although this didn't make a difference. 
> > 
> > I have the following files in my $libdir/mcollective/data on both the 
> > client and agent nodes: 
> > 
> > agent_data.ddl 
> > agent_data.rb 
> > fstat_data.ddl 
> > fstat_data.rb 
> > puppet_data.ddl 
> > puppet_data.rb 
> > resource_data.ddl 
> > resource_data.rb 
> > 
> > I also have everything from the util, validator, aggregate and agent 
> dirs 
> > on both nodes, and the application dir on the client node. 
>
> that certainly all seems fine, no exception logged in the servers log? We 
> do now log them - but I suspect that's only in the development series. 
>
> If there's no exception, put this little script on your node and just run 
>
>ruby test.rb 
>
> and show us what it says http://p.devco.net/409 
>

-- 
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+unsubscr...@googlegroups.com.
To post to this group, send email to puppet-users@googlegroups.com.
Visit this group at http://groups.google.com/group/puppet-users.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [Puppet Users] MCollective Puppet plugin - runall not working

2013-07-11 Thread R.I.Pienaar


- Original Message -
> From: "Jon Ward" 
> To: puppet-users@googlegroups.com
> Sent: Thursday, July 11, 2013 10:37:00 AM
> Subject: Re: [Puppet Users] MCollective Puppet plugin - runall not working
> 
> Hi,
> 
> I had just copied the files over manually and placed them in the respective
> directories, I've now also installed the deb packages
> "mcollective-puppet-agent" on the agent nodes and
> "mcollective-puppet-common" on the client nodes from the Puppetlabs repo
> although this didn't make a difference.
> 
> I have the following files in my $libdir/mcollective/data on both the
> client and agent nodes:
> 
> agent_data.ddl
> agent_data.rb
> fstat_data.ddl
> fstat_data.rb
> puppet_data.ddl
> puppet_data.rb
> resource_data.ddl
> resource_data.rb
> 
> I also have everything from the util, validator, aggregate and agent dirs
> on both nodes, and the application dir on the client node.

that certainly all seems fine, no exception logged in the servers log? We
do now log them - but I suspect that's only in the development series.

If there's no exception, put this little script on your node and just run

   ruby test.rb

and show us what it says http://p.devco.net/409

-- 
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+unsubscr...@googlegroups.com.
To post to this group, send email to puppet-users@googlegroups.com.
Visit this group at http://groups.google.com/group/puppet-users.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [Puppet Users] MCollective Puppet plugin - runall not working

2013-07-11 Thread Jon Ward
Hi,

I had just copied the files over manually and placed them in the respective 
directories, I've now also installed the deb packages 
"mcollective-puppet-agent" on the agent nodes and 
"mcollective-puppet-common" on the client nodes from the Puppetlabs repo 
although this didn't make a difference.

I have the following files in my $libdir/mcollective/data on both the 
client and agent nodes:

agent_data.ddl
agent_data.rb
fstat_data.ddl
fstat_data.rb
puppet_data.ddl
puppet_data.rb
resource_data.ddl
resource_data.rb

I also have everything from the util, validator, aggregate and agent dirs 
on both nodes, and the application dir on the client node.

Thanks,

Jon

On Wednesday, July 10, 2013 10:40:23 PM UTC+1, R.I. Pienaar wrote:
>
>
>
> - Original Message - 
> > From: "Jon Ward" > 
> > To: puppet...@googlegroups.com  
> > Sent: Wednesday, July 10, 2013 5:15:59 PM 
> > Subject: [Puppet Users] MCollective Puppet plugin - runall not working 
> > 
> > Hi, 
> > 
> > I've got the Puppet plugin for MCollective installed and working, 
> however 
> > the 'runall' action always discovers 0 enabled nodes. 
> > 
> > # mco puppet runall 2 
> > > 2013-07-10 15:57:16: Running all nodes with a concurrency of 2 
> > > 2013-07-10 15:57:16: Discovering enabled Puppet nodes to manage 
> > > 2013-07-10 15:57:19: Found 0 enabled nodes 
> > 
> > 
> > Looking in the server log on a node I would have expected to run I can 
> see 
> > this: 
> > 
> > D, [2013-07-10T15:03:53.137854 #9657] DEBUG -- : base.rb:25:in `lookup' 
> > > Doing data query puppet_data for '' 
> > > D, [2013-07-10T15:03:53.139202 #9657] DEBUG -- : base.rb:109:in 
> > > `validate_filter?' Failing based on class and fact composition 
> > > D, [2013-07-10T15:03:53.139318 #9657] DEBUG -- : base.rb:117:in 
> > > `validate_filter?' Passing based on agent puppet 
> > > D, [2013-07-10T15:03:53.139404 #9657] DEBUG -- : base.rb:159:in 
> > > `validate_filter?' Message failed the filter checks 
> > 
> > 
> > As far as I can work out, the following line in util/puppetrunner.rb 
> might 
> > be failing: 
> > 
> > > def find_enabled_nodes 
> > > 
> > > ... 
> > > 
> > > @client.compound_filter("puppet().enabled=true") 
> > > 
> > > ... 
> > > 
> > > end 
> > > 
> > > 
> > If I do an 'mco puppet status' then the Summary of Applying and Summary 
> of 
> > Idling work, however the Summary of enabled and Summary of 
> daemon_present 
> > show: 
> > 
> > > *Could not compute summary - exception raised while processing startup 
> > > hook* 
> > > 
> > 
> >  So it seems that it thinks all the nodes are disabled. However other 
> > actions such as "enable" and "disable" work correctly, and "runonce" 
> > correctly determines which nodes are enabled. 
> > 
> > I've had a dig around the code but got completely lost so any pointers 
> > would be gratefully appreciated! 
> > 
> > I'm running Puppet 3.2.1, MCollective 2.2.4 with activemq on Debian 6. 
> > 
>
> how did you install the plugin? did you install the data plugins on the 
> node? 
>

-- 
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+unsubscr...@googlegroups.com.
To post to this group, send email to puppet-users@googlegroups.com.
Visit this group at http://groups.google.com/group/puppet-users.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [Puppet Users] MCollective Puppet plugin - runall not working

2013-07-10 Thread R.I.Pienaar


- Original Message -
> From: "Jon Ward" 
> To: puppet-users@googlegroups.com
> Sent: Wednesday, July 10, 2013 5:15:59 PM
> Subject: [Puppet Users] MCollective Puppet plugin - runall not working
> 
> Hi,
> 
> I've got the Puppet plugin for MCollective installed and working, however
> the 'runall' action always discovers 0 enabled nodes.
> 
> # mco puppet runall 2
> > 2013-07-10 15:57:16: Running all nodes with a concurrency of 2
> > 2013-07-10 15:57:16: Discovering enabled Puppet nodes to manage
> > 2013-07-10 15:57:19: Found 0 enabled nodes
> 
> 
> Looking in the server log on a node I would have expected to run I can see
> this:
> 
> D, [2013-07-10T15:03:53.137854 #9657] DEBUG -- : base.rb:25:in `lookup'
> > Doing data query puppet_data for ''
> > D, [2013-07-10T15:03:53.139202 #9657] DEBUG -- : base.rb:109:in
> > `validate_filter?' Failing based on class and fact composition
> > D, [2013-07-10T15:03:53.139318 #9657] DEBUG -- : base.rb:117:in
> > `validate_filter?' Passing based on agent puppet
> > D, [2013-07-10T15:03:53.139404 #9657] DEBUG -- : base.rb:159:in
> > `validate_filter?' Message failed the filter checks
> 
> 
> As far as I can work out, the following line in util/puppetrunner.rb might
> be failing:
> 
> > def find_enabled_nodes
> >
> > ...
> >
> > @client.compound_filter("puppet().enabled=true")
> >
> > ...
> >
> > end
> >
> >
> If I do an 'mco puppet status' then the Summary of Applying and Summary of
> Idling work, however the Summary of enabled and Summary of daemon_present
> show:
> 
> > *Could not compute summary - exception raised while processing startup
> > hook*
> >
> 
>  So it seems that it thinks all the nodes are disabled. However other
> actions such as "enable" and "disable" work correctly, and "runonce"
> correctly determines which nodes are enabled.
> 
> I've had a dig around the code but got completely lost so any pointers
> would be gratefully appreciated!
> 
> I'm running Puppet 3.2.1, MCollective 2.2.4 with activemq on Debian 6.
> 

how did you install the plugin? did you install the data plugins on the node?

-- 
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+unsubscr...@googlegroups.com.
To post to this group, send email to puppet-users@googlegroups.com.
Visit this group at http://groups.google.com/group/puppet-users.
For more options, visit https://groups.google.com/groups/opt_out.




[Puppet Users] MCollective Puppet plugin - runall not working

2013-07-10 Thread Jon Ward
Hi,

I've got the Puppet plugin for MCollective installed and working, however 
the 'runall' action always discovers 0 enabled nodes.

# mco puppet runall 2
> 2013-07-10 15:57:16: Running all nodes with a concurrency of 2
> 2013-07-10 15:57:16: Discovering enabled Puppet nodes to manage
> 2013-07-10 15:57:19: Found 0 enabled nodes


Looking in the server log on a node I would have expected to run I can see 
this:

D, [2013-07-10T15:03:53.137854 #9657] DEBUG -- : base.rb:25:in `lookup' 
> Doing data query puppet_data for ''
> D, [2013-07-10T15:03:53.139202 #9657] DEBUG -- : base.rb:109:in 
> `validate_filter?' Failing based on class and fact composition
> D, [2013-07-10T15:03:53.139318 #9657] DEBUG -- : base.rb:117:in 
> `validate_filter?' Passing based on agent puppet
> D, [2013-07-10T15:03:53.139404 #9657] DEBUG -- : base.rb:159:in 
> `validate_filter?' Message failed the filter checks


As far as I can work out, the following line in util/puppetrunner.rb might 
be failing:

> def find_enabled_nodes
>
> ...
>
> @client.compound_filter("puppet().enabled=true")
>
> ...
>
> end
>
>
If I do an 'mco puppet status' then the Summary of Applying and Summary of 
Idling work, however the Summary of enabled and Summary of daemon_present 
show:

> *Could not compute summary - exception raised while processing startup 
> hook*
>

 So it seems that it thinks all the nodes are disabled. However other 
actions such as "enable" and "disable" work correctly, and "runonce" 
correctly determines which nodes are enabled.

I've had a dig around the code but got completely lost so any pointers 
would be gratefully appreciated!

I'm running Puppet 3.2.1, MCollective 2.2.4 with activemq on Debian 6.

Cheers,

Jon

-- 
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+unsubscr...@googlegroups.com.
To post to this group, send email to puppet-users@googlegroups.com.
Visit this group at http://groups.google.com/group/puppet-users.
For more options, visit https://groups.google.com/groups/opt_out.