Hey, all.

Somehow, I've stumbled and bumbled my way toward a working mCollective (I 
did not use Choria.io).  The Linux agents seem to be working well, for the 
most part.  But, as with a lot of shops, mine is a mixed Linux/Windows 
one.  I've used instructions from 
here: 
https://github.com/puppetlabs/marionette-collective/tree/master/ext/windows 
to get mCollective installed on my Windows servers.  Here's what the 
install looks like:

Windows Server 2008R2 and Windows Server 2012R2 boxes
Mcollective installed at C:\marionette-collective
Server.cfg:
topicprefix = /topic/
main_collective = mcollective
collectives = mcollective
#libdir = C:\marionette-collective\lib\mcollective
libdir = C:\marionette-collective\plugins
logfile = C:\marionette-collective\mcollective.log
loglevel = info
daemonize = 1

# Plugins
securityprovider = psk
plugin.psk = unset

connector = activemq
plugin.activemq.pool.size = 1
plugin.activemq.pool.1.host = activemq.mydomain.com
plugin.activemq.pool.1.port = 61613
plugin.activemq.pool.1.user = mcollective
plugin.activemq.pool.1.password = marionette

# Facts
factsource = yaml
plugin.yaml = C:\marionette-collective\etc\facts.yaml
direct_addressing = yes

#plugin.puppet.command = "C:/Program Files/Puppet 
Labs/Puppet/bin/puppet.bat" agent

#plugin.puppet.command = puppet agent

The servers respond to "mco ping", and to "mco rpc rpcutil agent_inventory 
-I server", the output of which is:

server02                              
   Agents: [{:agent=>"discovery",
             :license=>"Apache License, Version 2",
             :timeout=>5,
             :description=>"MCollective Discovery Agent",
             :name=>"Discovery Agent",
             :url=>"https://docs.puppetlabs.com/mcollective/";,
             :version=>"2.11.4",
             :author=>"R.I.Pienaar <r...@devco.net>"},
            {:agent=>"rpcutil",
             :license=>"Apache License, Version 2.0",
             :timeout=>10,
             :description=>
              "General helpful actions that expose stats and internals to 
SimpleRPC clients",
             :name=>"rpcutil",
             :url=>"https://docs.puppetlabs.com/mcollective/";,
             :version=>"1.0",
             :author=>"R.I.Pienaar <r...@devco.net>"},
            {:agent=>"service",
             :license=>"GPLv3",
             :timeout=>10,
             :description=>"Windows Services Controller",
             :name=>"Windows Service",
             :url=>"",
             :version=>"1.0",
             :author=>"Marco Mornati"}]

As you might be able to see, I've added some plugins from Marco Mornati.  
However, the only one that shows up in the above is agent=>"service".  
That's about it.

A look at mcollective.log shows plenty of warning and errors, none of which 
I can come up with a fix for, e.g.:

[2017-11-06T09:22:13.439518 #22040]  INFO -- : windows_daemon.rb:20:in 
`service_stop' Windows service stopping
I, [2017-11-06T09:22:13.440518 #22040]  INFO -- : activemq.rb:106:in 
`on_disconnect' Disconnected from 
stomp://mcollect...@automation01.netatlantic.com:61613
W, [2017-11-06T09:22:13.745536 #22040]  WARN -- : runner.rb:206:in `rescue 
in block in receiver_thread' Failed to handle message: undefined method 
`body' for nil:NilClass - NoMethodError

W, [2017-11-06T09:22:13.745536 #22040]  WARN -- : runner.rb:207:in `rescue 
in block in receiver_thread' 
C:/marionette-collective/plugins/mcollective/connector/activemq.rb:246:in 
`receive'
C:/marionette-collective/lib/mcollective/runner.rb:225:in `receive'
C:/marionette-collective/lib/mcollective/runner.rb:189:in `block in 
receiver_thread'
C:/marionette-collective/lib/mcollective/runner.rb:187:in `loop'
C:/marionette-collective/lib/mcollective/runner.rb:187:in `receiver_thread'
C:/marionette-collective/lib/mcollective/runner.rb:142:in `block in 
start_receiver_thread'
I, [2017-11-06T09:22:15.300625 #16988]  INFO -- : config.rb:167:in 
`loadconfig' The Marionette Collective version 2.8.1 started by 
C:/marionette-collective/bin/mcollectived using config file 
C:\marionette-collective\etc\server.cfg
I, [2017-11-06T09:22:15.300625 #16988]  INFO -- : mcollectived:64:in 
`<main>' The Marionette Collective 2.8.1 started logging at info level
W, [2017-11-06T09:22:21.315969 #16988]  WARN -- : runner.rb:64:in `run' The 
#run method has been deprecated. Use #main_loop instead.
I, [2017-11-06T09:22:21.316969 #16988]  INFO -- : activemq.rb:96:in 
`on_connecting' TCP Connection attempt 0 to 
stomp://mcollect...@automation01.netatlantic.com:61613
I, [2017-11-06T09:22:21.324969 #16988]  INFO -- : activemq.rb:101:in 
`on_connected' Conncted to 
stomp://mcollect...@automation01.netatlantic.com:61613
E, [2017-11-06T09:22:21.332970 #16988] ERROR -- : pluginmanager.rb:171:in 
`rescue in loadclass' Failed to load MCollective::Agent::Eventlog: cannot 
load such file -- win32/eventlog
E, [2017-11-06T09:22:21.333970 #16988] ERROR -- : agents.rb:71:in `rescue 
in loadagent' Loading agent eventlog failed: cannot load such file -- 
win32/eventlog
E, [2017-11-06T09:22:21.366972 #16988] ERROR -- : agents.rb:71:in `rescue 
in loadagent' Loading agent puppet failed: Could not create instance of 
plugin MCollective::Agent::Puppet: uninitialized constant Class::Puppet
E, [2017-11-06T09:22:21.384973 #16988] ERROR -- : pluginmanager.rb:171:in 
`rescue in loadclass' Failed to load MCollective::Agent::Eventlog: cannot 
load such file -- win32/eventlog
E, [2017-11-06T09:22:21.385973 #16988] ERROR -- : agents.rb:71:in `rescue 
in loadagent' Loading agent eventlog failed: cannot load such file -- 
win32/eventlog
E, [2017-11-06T09:22:21.386973 #16988] ERROR -- : agents.rb:71:in `rescue 
in loadagent' Loading agent puppet failed: Could not create instance of 
plugin MCollective::Agent::Puppet: uninitialized constant Class::Puppet

I would love to get Mcollective working on Windows, and any help (as 
detailed as possible) would be greatly appreciated.

Dimitri

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"mcollective-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to mcollective-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to