Puppetserver service error when using PuppetDB terminus

431 views
Skip to first unread message

mluc...@gmail.com

unread,
Sep 21, 2020, 3:31:17 PM9/21/20
to Puppet Users

I've started receiving the following error when the puppetserver service starts on my Puppet Master (open source version) but only when it is configured to use PuppetDB.

● puppetserver.service - puppetserver Service
   Loaded: loaded (/lib/systemd/system/puppetserver.service; disabled; vendor preset: enabled)
   Active: active (running) since Mon 2020-09-21 19:21:03 UTC; 3s ago
  Process: 7479 ExecStart=/opt/puppetlabs/server/apps/puppetserver/bin/puppetserver start (code=exited, status=0/SUCCESS)
 Main PID: 7525 (java)
    Tasks: 66 (limit: 4915)
   CGroup: /system.slice/puppetserver.service
           └─7525 /usr/bin/java -Xms2g -Xmx2g -Djruby.logger.class=com.puppetlabs.jruby_utils.jruby.Slf4jLogger -XX:OnOutOfMemoryError="kill -9 %p" -XX:ErrorFile=/var/log/puppetlabs/puppetserver/puppetserver_err_pid%p.log -cp /opt/puppet


If I remove the storeconfigs settings from my puppet.conf as well as remove the puppetdb.conf and routes.yaml files the service will start fine. So I know it is being caused by PuppetDB. Any help would be appreciated. Thanks!

mluc...@gmail.com

unread,
Sep 21, 2020, 4:09:28 PM9/21/20
to Puppet Users
Additional info from journalctl -xe

Sep 21 20:08:04 puppet puppetserver[16427]: ArgumentError: Could not find terminus puppetdb for indirection facts
Sep 21 20:08:04 puppet puppetserver[16427]:       validate_terminus_class at /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector/indirection.rb:181
Sep 21 20:08:04 puppet puppetserver[16427]:            set_global_setting at /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector/indirection.rb:121
Sep 21 20:08:04 puppet puppetserver[16427]:              configure_routes at /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector.rb:27
Sep 21 20:08:04 puppet puppetserver[16427]:                          each at org/jruby/RubyHash.java:1415
Sep 21 20:08:04 puppet puppetserver[16427]:              configure_routes at /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector.rb:17
Sep 21 20:08:04 puppet puppetserver[16427]:   configure_indirector_routes at /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application_support.rb:57
Sep 21 20:08:04 puppet puppetserver[16427]:             initialize_puppet at uri:classloader:/puppetserver-lib/puppet/server/puppet_config.rb:103
Sep 21 20:08:04 puppet puppetserver[16427]:                    initialize at uri:classloader:/puppetserver-lib/puppet/server/master.rb:38
Sep 21 20:08:04 puppet puppetserver[16427]: Execution error (ArgumentError) at RUBY/validate_terminus_class (/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector/indirection.rb:181).
Sep 21 20:08:04 puppet puppetserver[16427]: (ArgumentError) Could not find terminus puppetdb for indirection facts
Sep 21 20:08:04 puppet puppetserver[16427]: Full report at:
Sep 21 20:08:04 puppet puppetserver[16427]: /tmp/clojure-7723747667634594981.edn
Sep 21 20:08:05 puppet puppetserver[16427]: Background process 16472 exited before start had completed

mluc...@gmail.com

unread,
Sep 21, 2020, 4:46:27 PM9/21/20
to Puppet Users
I figured it out! Something weird happened with the SSL certs...in case this happens to anyone I had to do the following. NOTE that I use the puppetlabs-puppetdb module for managing PuppetDB, once I had the certs fixed, running puppet agent -t on both PuppetDB and Puppet Master fixed the rest.

Disable PuppetDB on your Puppet Master by removing storeconfigs from your puppet.conf and moving/renaming puppetdb.conf and routes.yaml
Follow Step 3 on the PuppetDB Server: https://puppet.com/docs/puppet/5.5/ssl_regenerate_certificates.html#puppetdb
Rename SSL dir on PuppetDB: mv /etc/puppetlabs/puppetdb/ssl/ /etc/puppetlabs/puppetdb/ssl-old
Rerun PuppetDB SSL setup:  puppetdb ssl-setup -f


After this is done, I ran puppet agent -t on my Puppet Master and it pulled in the new certificate and regenerated puppetdb.conf and routes.yaml. After putting back my storeconfigs settings and restarting the services, all is well now.
Reply all
Reply to author
Forward
0 new messages