puppet-rabbitmq
puppet-rabbitmq copied to clipboard
Autoload error that sometimes occurs on Puppet Enterprise 2017.2.2
Could not retrieve catalog from remote server: Error 500 on SERVER: Server Error: Evaluation Error: Error while evaluating a Resource Statement, Evaluation Error: Error while evaluating a Virtual Query, Could not autoload puppet/type/rabbitmq_plugin: Attempt to redefine entity 'http://puppet.com/2016.1/runtime/type/rabbitmq_plugin'. Set at unknown location at /etc/puppetlabs/code/environments/tst/modules/rabbitmq/manifests/init.pp:310:35 on node stackstorm-rabbitmq-02t.
Everything used to run fine on Puppet Enterprise 2016.4.0.
Just wondering, which version of the module are you running? And if an older version, does current master fix anything?
We're hoping to release 6.0.0 soon, first release under Voxpupuli.
Also, which version of RabbitMQ are you running, and on what platform?
I'm using module: mod 'puppetlabs/rabbitmq', '5.6.0'
The YUM rabbitmq-server package is version 3.6.2 on RHEL 7.4 (selinux enabled).
If it's at all possible, could you test against current master, and see if it exhibits the same behavior (in a test environment, if doing that would be disruptive)?
A quick web search also suggests that pluginsync needs to be enabled, though I'm assuming it is? Maybe ask on IRC or Slack and see if the error message rings a bell for anyone?
Is the current master compatible with major version 5? Or is it code what will soon be released as 6? What I mean to say, are there breaking changes? :-)
@pietervogelaar yes, there are some breaking changes coming. Big change is the switch to datatypes, and changing the 'UNSET'
pattern to true undef
. There are also some changes to the way repos and installation work, though they likely wouldn't affect you if the package is already installed.
I have this issue too. RHEL 7.4, PM it 2017.2.0,
@bostrowski13 I am guessing you're seeing this with current git master (6.0.0-rc0) too?
For anyone on RHEL / CentOS, does /usr/lib/rabbitmq/bin/rabbitmq-plugins
exist? I don't think it's the same issue as #566 but just curious.
#570 is a proposed "fix" for this if anyone wants to try.
i have rabbitmq-plugins in that location, even on the installation that fails in https://github.com/voxpupuli/puppet-rabbitmq/issues/611#issuecomment-327565166
@wyardley yes, I've seen this too.
@hunner pointed me in the direction of https://tickets.puppetlabs.com/browse/PUP-7466, FWIW
@wyardley I am also having this issue on our puppet enterprise instance randomly
I wonder if it could have to do with the fact that some of the plugins have
provider => 'rabbitmqplugins'
explicitly spelled out (that does seem to be the right provider name, though I don't think it's necessary).
Can folks post what code lines up with the line number given in the error in the version they're seeing this error with?
Here's the error I see...
Error: Could not retrieve catalog from remote server: Error 500 on SERVER: Server Error: Evaluation Error: Error while evaluating a Resource Statement, Evaluation Error: Error while evaluating a Virtual Query, Could not autoload puppet/type/rabbitmq_plugin: Attempt to redefine entity 'http://puppet.com/2016.1/runtime/type/rabbitmq_plugin'. Set at unknown location at /etc/puppetlabs/code/environments/production/modules/rabbitmq/manifests/init.pp:394:33 on node server1.domain.com
and the associated line number....
# Make sure the various providers have their requirements in place.
Class['rabbitmq::install'] -> Rabbitmq_plugin<| |>
i'm also using this version of the module puppet-rabbitmq (v6.0.1-rc0)
Tried out solving this with v7.0.0 of the module and still seeing the same error randomly on my test server (4 times today). It happens on 7 of our CentOS 7 RabbitMQ servers. Happening at the exact same line as bostrowski13 mentioned. We are using using PE 2016.4.2.
I faintly remember this starting when I had to run puppet generate types
to solve another module's upgrade issue. Running that command puts files into .resource_types
in whatever environment the command is ran for.
My next test will be to against our production version of the RabbitMQ module and remove those as at the time they weren't needed for the RabbitMQ module. Usually get at least 1 hit of the error in 24 hours.
So after 5 days, removing my_environment/.resource_types/rabbitmq_plugin.pp
ensured the error didn't happen. I added it back today and got 2 of the errors about 2 hours after. That supports my theory that it started after running puppet generate types
in my case.
With the file back, I also tried to manage some of the RabbitMQ plugins with the module to see if something was "empty" and it having a value would get passed the error. My first noop try with that showed the error, so I don't believe it is that is a work around.
Will take me some time to dig into what rabbitmq_plugin.pp
is doing.