Details
-
Bug
-
Status: Closed
-
Normal
-
Resolution: Fixed
-
PUP 4.9.2
-
None
-
Puppet Developer Experience
-
1
-
PDE 2017-02-22, PDE 2017-03-08
-
Bug Fix
-
A regression in Puppet 4.9.0 / hiera 5 meant that the error "Error: Could not run: Hiera type mismatch: expected Hash and got String" could be raised when using eyaml and other hiera 3 backends using the oldest version of the backend API.
-
Automate
-
not fully covered by unit tests. eyaml backwards compat with hiera3 config, will cover in test against related ticket.
Description
I have a running puppetserver 2.7.2-1puppetlabs1 running with puppet-agent 1.3.3-trusty1. With these versions everything is working fine, but if I upgrade puppet-agent to 1.9.0-1trusty or 1.9.1-1trusty then puppetservers stop working.
When running a puppet agent client (updated or not to 1.9.1) in the server I get:
Feb 14 09:54:59 mus30 puppetserver: [puppetserver] Puppet Not using expired facts for mus30.um.es from cache; expired at 2017-02-13 11:40:22 +0100
|
Feb 14 09:55:00 mus30 puppetserver: [puppetserver] Puppet Caching facts for mus30.um.es
|
Feb 14 09:55:00 mus30 puppetserver: [puppetserver] Puppet Caching node for mus30.um.es
|
Feb 14 09:55:11 mus30 puppetserver: [puppetserver] Puppet 'replace_facts' command for mus30.um.es submitted to PuppetDB with UUID b80aa7a1-4f45-45a7-a2db-a98ae668e022
|
Feb 14 09:55:13 mus30 puppetserver: [puppetserver] Puppet Caching node for mus30.um.es
|
Feb 14 09:55:14 mus30 puppetserver: [puppetserver] Puppet The function 'hiera_include' is deprecated in favor of using 'lookup'. See https://docs.puppet.com/puppet/4.9.2/reference/deprecated_language.html#012 (file & line not available)
|
Feb 14 09:55:14 mus30 puppetserver: [puppetserver] Puppet /etc/puppetlabs/puppet/hiera.yaml: Use of 'hiera.yaml' version 3 is deprecated. It should be converted to version 5#012 (in /etc/puppetlabs/puppet/hiera.yaml)
|
Feb 14 09:55:14 mus30 puppetserver: [puppetserver] Puppet Undefined variable 'hostgroup_l1'; #012 (file & line not available)
|
Feb 14 09:55:14 mus30 puppetserver: [puppetserver] Puppet Undefined variable 'hostgroup'; #012 (file & line not available)
|
Feb 14 09:55:15 mus30 puppetserver: [puppetserver] Puppet Evaluation Error: Error while evaluating a Function Call, undefined method `[]' for nil:NilClass at /etc/puppetlabs/code/environments/production/manifests/site.pp:17:3 on node mus30.um.es#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_adapter.rb:147:in `lookup_lookup_options'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_adapter.rb:124:in `lookup_merge_options'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_adapter.rb:58:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/invocation.rb:54:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_adapter.rb:50:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/hiera_config.rb:231:in `alias_interpolate'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/interpolate.rb:70:in `do_interpolation'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/recursive_guard.rb:16:in `check'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/interpolate.rb:68:in `do_interpolation'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/interpolate.rb:47:in `interpolate'#012org/jruby/RubyString.java:3064:in `gsub'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/interpolate.rb:46:in `interpolate'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/backend.rb:146:in `parse_string'#012/opt/puppetlabs/server/data/puppetserver/jruby-gems/gems/hiera-eyaml-2.1.0/lib/hiera/backend/eyaml_backend.rb:132:in `parse_string'#012/opt/puppetlabs/server/data/puppetserver/jruby-gems/gems/hiera-eyaml-2.1.0/lib/hiera/backend/eyaml_backend.rb:101:in `parse_answer'#012/opt/puppetlabs/server/data/puppetserver/jruby-gems/gems/hiera-eyaml-2.1.0/lib/hiera/backend/eyaml_backend.rb:53:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/backend.rb:95:in `datasources'#012org/jruby/RubyArray.java:2414:in `map'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/backend.rb:90:in `datasources'#012/opt/puppetlabs/server/data/puppetserver/jruby-gems/gems/hiera-eyaml-2.1.0/lib/hiera/backend/eyaml_backend.rb:29:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/backend.rb:18:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_key_function_provider.rb:60:in `lookup_key'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_key_function_provider.rb:24:in `unchecked_key_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/invocation.rb:116:in `with'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_key_function_provider.rb:23:in `unchecked_key_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/merge_strategy.rb:129:in `lookup'#012org/jruby/RubyKernel.java:1242:in `catch'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/merge_strategy.rb:128:in `lookup'#012org/jruby/RubyArray.java:1613:in `each'#012org/jruby/RubyEnumerable.java:852:in `inject'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/merge_strategy.rb:126:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/invocation.rb:116:in `with'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/merge_strategy.rb:125:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_key_function_provider.rb:18:in `unchecked_key_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/invocation.rb:116:in `with'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_key_function_provider.rb:17:in `unchecked_key_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/configured_data_provider.rb:50:in `unchecked_key_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/merge_strategy.rb:123:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/configured_data_provider.rb:49:in `unchecked_key_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/invocation.rb:116:in `with'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/configured_data_provider.rb:42:in `unchecked_key_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/global_data_provider.rb:26:in `unchecked_key_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/data_provider.rb:45:in `key_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/invocation.rb:73:in `check'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/data_provider.rb:45:in `key_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_adapter.rb:72:in `lookup_global'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_adapter.rb:223:in `do_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_adapter.rb:61:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/invocation.rb:116:in `with'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_adapter.rb:61:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/invocation.rb:58:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_adapter.rb:50:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup.rb:76:in `search_and_merge'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup.rb:31:in `lookup'#012org/jruby/RubyKernel.java:1242:in `catch'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup.rb:31:in `lookup'#012org/jruby/RubyArray.java:1613:in `each'#012org/jruby/RubyEnumerable.java:852:in `inject'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup.rb:29:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/puppet_function.rb:70:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/puppet_function.rb:46:in `hiera_no_default'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/functions/dispatch.rb:47:in `invoke'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/functions/dispatcher.rb:36:in `dispatch'#012org/jruby/RubyKernel.java:1242:in `catch'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/functions/dispatcher.rb:35:in `dispatch'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/functions/function.rb:46:in `call'#012org/jruby/RubyKernel.java:1242:in `catch'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/functions/function.rb:45:in `call'#012/etc/puppetlabs/code/environments/production/manifests/site.pp:17:in `call_function'#012org/jruby/RubyKernel.java:1079:in `eval'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/evaluator/runtime3_support.rb:284:in `call_function'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/profiler/around_profiler.rb:58:in `profile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/profiler.rb:51:in `profile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/evaluator/runtime3_support.rb:282:in `call_function'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/evaluator/evaluator_impl.rb:941:in `call_function_with_block'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/evaluator/evaluator_impl.rb:910:in `eval_CallNamedFunctionExpression'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/visitor.rb:48:in `visit_this'#012org/jruby/RubyArray.java:1613:in `each'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/visitor.rb:42:in `visit_this'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/visitor.rb:71:in `visit_this_1'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/evaluator/evaluator_impl.rb:82:in `evaluate'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/evaluator/evaluator_impl.rb:638:in `eval_BlockExpression'#012org/jruby/RubyArray.java:1613:in `each'#012org/jruby/RubyEnumerable.java:852:in `inject'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/evaluator/evaluator_impl.rb:638:in `eval_BlockExpression'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/visitor.rb:69:in `visit_this_1'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/evaluator/evaluator_impl.rb:82:in `evaluate'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/parser/evaluating_parser.rb:63:in `evaluate'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/parser/ast/pops_bridge.rb:32:in `evaluate'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/parser/ast.rb:31:in `safeevaluate'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/resource/type.rb:184:in `evaluate_code'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/parser/resource.rb:81:in `evaluate'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/profiler/around_profiler.rb:58:in `profile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/profiler.rb:51:in `profile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/parser/resource.rb:73:in `evaluate'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/parser/compiler.rb:555:in `evaluate_ast_node'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/parser/compiler.rb:178:in `compile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/profiler/around_profiler.rb:58:in `profile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/profiler.rb:51:in `profile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/parser/compiler.rb:178:in `compile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/context.rb:65:in `override'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet.rb:293:in `override'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/parser/compiler.rb:162:in `compile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/parser/compiler.rb:33:in `compile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector/catalog/compiler.rb:266:in `compile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/profiler/around_profiler.rb:58:in `profile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/profiler.rb:51:in `profile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector/catalog/compiler.rb:264:in `compile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:223:in `benchmark'#012/opt/puppetlabs/server/apps/puppetserver/puppet-server-release.jar!/META-INF/jruby.home/lib/ruby/1.9/benchmark.rb:295:in `realtime'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:222:in `benchmark'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector/catalog/compiler.rb:262:in `compile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector/catalog/compiler.rb:53:in `find'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector/indirection.rb:194:in `find'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/network/http/api/indirected_routes.rb:121:in `do_find'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/network/http/api/indirected_routes.rb:48:in `call'
|
Feb 14 09:55:15 mus30 puppetserver: [puppetserver] Puppet Evaluation Error: Error while evaluating a Function Call, undefined method `[]' for nil:NilClass at /etc/puppetlabs/code/environments/production/manifests/site.pp:17:3 on node mus30.um.es
|
Feb 14 09:55:15 mus30 puppetserver: [puppetserver] Puppet Server Error: Evaluation Error: Error while evaluating a Function Call, undefined method `[]' for nil:NilClass at /etc/puppetlabs/code/environments/production/manifests/site.pp:17:3 on node mus30.um.es#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_adapter.rb:147:in `lookup_lookup_options'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_adapter.rb:124:in `lookup_merge_options'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_adapter.rb:58:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/invocation.rb:54:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_adapter.rb:50:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/hiera_config.rb:231:in `alias_interpolate'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/interpolate.rb:70:in `do_interpolation'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/recursive_guard.rb:16:in `check'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/interpolate.rb:68:in `do_interpolation'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/interpolate.rb:47:in `interpolate'#012org/jruby/RubyString.java:3064:in `gsub'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/interpolate.rb:46:in `interpolate'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/backend.rb:146:in `parse_string'#012/opt/puppetlabs/server/data/puppetserver/jruby-gems/gems/hiera-eyaml-2.1.0/lib/hiera/backend/eyaml_backend.rb:132:in `parse_string'#012/opt/puppetlabs/server/data/puppetserver/jruby-gems/gems/hiera-eyaml-2.1.0/lib/hiera/backend/eyaml_backend.rb:101:in `parse_answer'#012/opt/puppetlabs/server/data/puppetserver/jruby-gems/gems/hiera-eyaml-2.1.0/lib/hiera/backend/eyaml_backend.rb:53:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/backend.rb:95:in `datasources'#012org/jruby/RubyArray.java:2414:in `map'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/backend.rb:90:in `datasources'#012/opt/puppetlabs/server/data/puppetserver/jruby-gems/gems/hiera-eyaml-2.1.0/lib/hiera/backend/eyaml_backend.rb:29:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/backend.rb:18:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_key_function_provider.rb:60:in `lookup_key'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_key_function_provider.rb:24:in `unchecked_key_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/invocation.rb:116:in `with'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_key_function_provider.rb:23:in `unchecked_key_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/merge_strategy.rb:129:in `lookup'#012org/jruby/RubyKernel.java:1242:in `catch'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/merge_strategy.rb:128:in `lookup'#012org/jruby/RubyArray.java:1613:in `each'#012org/jruby/RubyEnumerable.java:852:in `inject'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/merge_strategy.rb:126:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/invocation.rb:116:in `with'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/merge_strategy.rb:125:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_key_function_provider.rb:18:in `unchecked_key_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/invocation.rb:116:in `with'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_key_function_provider.rb:17:in `unchecked_key_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/configured_data_provider.rb:50:in `unchecked_key_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/merge_strategy.rb:123:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/configured_data_provider.rb:49:in `unchecked_key_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/invocation.rb:116:in `with'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/configured_data_provider.rb:42:in `unchecked_key_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/global_data_provider.rb:26:in `unchecked_key_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/data_provider.rb:45:in `key_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/invocation.rb:73:in `check'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/data_provider.rb:45:in `key_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_adapter.rb:72:in `lookup_global'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_adapter.rb:223:in `do_lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_adapter.rb:61:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/invocation.rb:116:in `with'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_adapter.rb:61:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/invocation.rb:58:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup/lookup_adapter.rb:50:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup.rb:76:in `search_and_merge'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup.rb:31:in `lookup'#012org/jruby/RubyKernel.java:1242:in `catch'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup.rb:31:in `lookup'#012org/jruby/RubyArray.java:1613:in `each'#012org/jruby/RubyEnumerable.java:852:in `inject'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/lookup.rb:29:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/puppet_function.rb:70:in `lookup'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/hiera/puppet_function.rb:46:in `hiera_no_default'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/functions/dispatch.rb:47:in `invoke'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/functions/dispatcher.rb:36:in `dispatch'#012org/jruby/RubyKernel.java:1242:in `catch'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/functions/dispatcher.rb:35:in `dispatch'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/functions/function.rb:46:in `call'#012org/jruby/RubyKernel.java:1242:in `catch'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/functions/function.rb:45:in `call'#012/etc/puppetlabs/code/environments/production/manifests/site.pp:17:in `call_function'#012org/jruby/RubyKernel.java:1079:in `eval'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/evaluator/runtime3_support.rb:284:in `call_function'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/profiler/around_profiler.rb:58:in `profile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/profiler.rb:51:in `profile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/evaluator/runtime3_support.rb:282:in `call_function'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/evaluator/evaluator_impl.rb:941:in `call_function_with_block'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/evaluator/evaluator_impl.rb:910:in `eval_CallNamedFunctionExpression'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/visitor.rb:48:in `visit_this'#012org/jruby/RubyArray.java:1613:in `each'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/visitor.rb:42:in `visit_this'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/visitor.rb:71:in `visit_this_1'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/evaluator/evaluator_impl.rb:82:in `evaluate'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/evaluator/evaluator_impl.rb:638:in `eval_BlockExpression'#012org/jruby/RubyArray.java:1613:in `each'#012org/jruby/RubyEnumerable.java:852:in `inject'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/evaluator/evaluator_impl.rb:638:in `eval_BlockExpression'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/visitor.rb:69:in `visit_this_1'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/evaluator/evaluator_impl.rb:82:in `evaluate'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/pops/parser/evaluating_parser.rb:63:in `evaluate'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/parser/ast/pops_bridge.rb:32:in `evaluate'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/parser/ast.rb:31:in `safeevaluate'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/resource/type.rb:184:in `evaluate_code'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/parser/resource.rb:81:in `evaluate'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/profiler/around_profiler.rb:58:in `profile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/profiler.rb:51:in `profile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/parser/resource.rb:73:in `evaluate'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/parser/compiler.rb:555:in `evaluate_ast_node'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/parser/compiler.rb:178:in `compile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/profiler/around_profiler.rb:58:in `profile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/profiler.rb:51:in `profile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/parser/compiler.rb:178:in `compile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/context.rb:65:in `override'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet.rb:293:in `override'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/parser/compiler.rb:162:in `compile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/parser/compiler.rb:33:in `compile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector/catalog/compiler.rb:266:in `compile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/profiler/around_profiler.rb:58:in `profile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/profiler.rb:51:in `profile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector/catalog/compiler.rb:264:in `compile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:223:in `benchmark'#012/opt/puppetlabs/server/apps/puppetserver/puppet-server-release.jar!/META-INF/jruby.home/lib/ruby/1.9/benchmark.rb:295:in `realtime'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:222:in `benchmark'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector/catalog/compiler.rb:262:in `compile'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector/catalog/compiler.rb:53:in `find'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector/indirection.rb:194:in `find'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/network/http/api/indirected_routes.rb:121:in `do_find'#012/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/network/http/api/indirected_routes.rb:48:in `call'
|
and in the client
amateo_adm@mus30:~$ sudo puppet agent -t --server mus30.um.es --noop
|
Info: Using configured environment 'production'
|
Info: Retrieving pluginfacts
|
Info: Retrieving plugin
|
Info: Loading facts
|
Error: Could not retrieve catalog from remote server: Error 500 on SERVER: Server Error: Evaluation Error: Error while evaluating a Function Call, undefined method `[]' for nil:NilClass at /etc/puppetlabs/code/environments/production/manifests/site.pp:17:3 on node mus30.um.es
|
Warning: Not using cache on failed catalog
|
Error: Could not retrieve catalog; skipping run
|
The reported error points to a hiera_include call in my manifest. So I have tried to lookup for the variable used in this call (role) but I get the error (complete log is in attachment):
Error: Could not run: Hiera type mismatch: expected Hash and got String
|
These same configuration is working with puppet-agent 1.8.3 in the puppetserver.
I have also tried to change eyaml backend to yaml (copying .eyaml files to .yaml) and with yaml works fine, so I guess is not a problem with my data files.