Ask Your Question

Error 400 on Server: uninitialized constant Puppet::Pops when using puppetlabs/stdlib pw_hash [closed]

asked 2017-08-29 10:37:02 -0600

M.Laroche gravatar image

updated 2017-08-29 10:38:35 -0600


Before i open an issue, i want ask here if someone has a similar problem, cause i don't believe this is an issue from puppetlabs/stdlib. First i think, it is an error on my puppet server.

I've updated the puppetlabs/stdlib from v4.16 zu v4.19. Since then i get the error message

Error: Could not retrieve catalog from remote server: Error 400 on SERVER: uninitialized constant Puppet::Pops at <module> on node <host>.

when the function pw_hash from the puppetlabs/stdlib is used.

user { $name:
  ensure         => present,
  uid            => $user[uid],
  gid            => $user[gid],
  comment        => $user[comment],
  shell          => $user[shell],
  home           => $user[home],
  managehome     => true,
  purge_ssh_keys => true,
  password       => pw_hash($user[password], 'SHA-512', '<SALT>'), 

So i downgrade the puppetforge/stdlib to v4.16. But now i still get the error! Wihtout the function pw_hash all works fine. Because of this behavior i don't believe that this is an issue from the stdlib, but i've no idea what now get wrong.

The puppetserver.log show this:

2017-08-29 15:46:36,348 ERROR [puppet-server] Puppet uninitialized constant Puppet::Pops at /etc/puppet/environments/dev/code/users/manifests/os_user.pp:32 on node
org/jruby/ `const_missing'
/etc/puppet/environments/dev/puppetforge/stdlib/lib/puppet/parser/functions/pw_hash.rb:31:in `real_function_pw_hash'
org/jruby/ `map!'
/etc/puppet/environments/dev/puppetforge/stdlib/lib/puppet/parser/functions/pw_hash.rb:30:in `real_function_pw_hash'
/usr/lib/ruby/site_ruby/1.8/puppet/parser/functions.rb:164:in `function_pw_hash'

Used versions:

hiera --version
puppet --version
puppetserver --version
puppetserver version: 1.2.0
ruby --version
ruby 1.8.7 (2013-06-27 patchlevel 374) [x86_64-linux]

Red Hat Enterprise Linux Server release 6.9 (Santiago)

MfG Matthias

edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by M.Laroche
close date 2017-08-31 01:52:04.504917

1 Answer

Sort by » oldest newest most voted

answered 2017-08-31 01:51:09 -0600

M.Laroche gravatar image


I've found the issue and a handling error from me with Puppetserver 1.2. It is an issue from pupperlabs/stdlib v4.19.0.

It seems, that the Puppetserver v1.2 cache (ruby) provider and not load new ruby-code, when it change in the environment. I didn't restart the Puppetserver, when i downgarded puppetlabs/stdlib to < v4.19.0, so the provider pwhash.rb was still used in version v4.19.0. First when the Puppetserver is restarted, the new old provider pwhash.rb from v4.18.0 (or less) will be used, and the error don't appear any more.

A similar issue is even documented in the Puppetserver Docs

Config Reload

SERVER-15: In the current builds of Puppet Server, there is no signal handling mechanism that allows you to request a config reload/service refresh. In order to clear out the Ruby environments and reload all config, you must restart the service. This is expensive, and in the future we’d like to support some mechanisms for reloading rather than restarting.

So i close this question.

MfG Matthias Laroche

edit flag offensive delete link more

Question Tools

1 follower


Asked: 2017-08-29 10:37:02 -0600

Seen: 132 times

Last updated: Aug 31 '17