Bug #1655
closedFailed to list puppet environments: Attempting to initialize global default settings more than once!
Description
Happens with smart-proxy git when trying to import classes and environments twice from foreman without restarting smart-proxy:
E, [2012-05-28T09:57:14.479552 #3577] ERROR -- : Failed to list puppet environments: Attempting to initialize global default settings more than once! /usr/lib/ruby/1.8/puppet/settings.rb:136:in `initialize_global_settings'
/usr/lib/ruby/1.8/puppet.rb:140:in `do_initialize_settings_for_run_mode'
/usr/lib/ruby/1.8/puppet.rb:128:in `initialize_settings'
/usr/lib/ruby/1.8/puppet.rb:118:in `parse_config'
/home/orphis/smart-proxy/bin/../lib/proxy/puppet/environment.rb:24:in `puppet_environments'
/home/orphis/smart-proxy/bin/../lib/proxy/puppet/environment.rb:11:in `all'
/home/orphis/smart-proxy/bin/../lib/puppet_api.rb:15:in `GET /puppet/environments'
/usr/lib/ruby/1.8/sinatra/base.rb:863:in `call'
/usr/lib/ruby/1.8/sinatra/base.rb:863:in `route'
/usr/lib/ruby/1.8/sinatra/base.rb:521:in `instance_eval'
/usr/lib/ruby/1.8/sinatra/base.rb:521:in `route_eval'
/usr/lib/ruby/1.8/sinatra/base.rb:500:in `route!'
/usr/lib/ruby/1.8/sinatra/base.rb:497:in `catch'
/usr/lib/ruby/1.8/sinatra/base.rb:497:in `route!'
/usr/lib/ruby/1.8/sinatra/base.rb:476:in `each'
/usr/lib/ruby/1.8/sinatra/base.rb:476:in `route!'
/usr/lib/ruby/1.8/sinatra/base.rb:601:in `dispatch!'
/usr/lib/ruby/1.8/sinatra/base.rb:411:in `call!'
/usr/lib/ruby/1.8/sinatra/base.rb:566:in `instance_eval'
/usr/lib/ruby/1.8/sinatra/base.rb:566:in `invoke'
/usr/lib/ruby/1.8/sinatra/base.rb:566:in `catch'
/usr/lib/ruby/1.8/sinatra/base.rb:566:in `invoke'
/usr/lib/ruby/1.8/sinatra/base.rb:411:in `call!'
/usr/lib/ruby/1.8/sinatra/base.rb:399:in `call'
/usr/lib/ruby/1.8/rack/showexceptions.rb:24:in `call'
/usr/lib/ruby/1.8/rack/commonlogger.rb:18:in `call'
/usr/lib/ruby/1.8/sinatra/base.rb:979:in `call'
/usr/lib/ruby/1.8/sinatra/base.rb:1005:in `synchronize'
/usr/lib/ruby/1.8/sinatra/base.rb:979:in `call'
/usr/lib/ruby/1.8/rack/content_length.rb:13:in `call'
/usr/lib/ruby/1.8/rack/handler/webrick.rb:48:in `service'
/usr/lib/ruby/1.8/webrick/httpserver.rb:104:in `service'
/usr/lib/ruby/1.8/webrick/httpserver.rb:65:in `run'
/usr/lib/ruby/1.8/webrick/server.rb:173:in `start_thread'
/usr/lib/ruby/1.8/webrick/server.rb:162:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:162:in `start_thread'
/usr/lib/ruby/1.8/webrick/server.rb:95:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:92:in `each'
/usr/lib/ruby/1.8/webrick/server.rb:92:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:23:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:82:in `start'
/usr/lib/ruby/1.8/rack/handler/webrick.rb:14:in `run'
/home/orphis/smart-proxy/bin/../lib/sinatra-patch.rb:36:in `run!'
/home/orphis/smart-proxy/bin/smart-proxy:102
Updated by Myles Steinhauser almost 12 years ago
This is still an issue for me as of foreman-proxy from git. Running Puppet 3.0 so it is definitely related.
Updated by Drew Blessing over 11 years ago
This issue seems to be resolved by http://theforeman.org/issues/1915. I applied the changes from the commit at https://github.com/theforeman/smart-proxy/pull/42 and no longer saw this error.
Updated by Dominic Cleal over 11 years ago
- Status changed from New to Resolved
Thanks for confirming Drew!