Quantcast
Channel: Ask Puppet: Puppet DevOps Q&A Community - RSS feed
Viewing all articles
Browse latest Browse all 6104

Puppet lookup --node $var.in.common.yaml and # puppet agent -t --noop differ

$
0
0
While rewriting a module to move config from hard-coded files to hieradata (and use the data in a template) I managed to get me behaviour I can't explain. Env: - Puppet 4.10.9 server and clients - Introduction of completely new variable for hash - Variable needed defined in common.yaml - For some systems hash gets additional config - lookup merge-type deep - 1000+ nodes in config - all but 2 get var as specified in common.yaml (or extended) - 2 don't get the var at all Situation 1: - module with Hash $var and no default. - puppet lookup --node $node $var on server results in error - on node puppet agent -t --noop gives error as well. I get the same result on both occasions, but only for the 2 problem nodes, all others work. Situation 2: - module gets empty hash as default - puppet lookup --node $node $var on server results in expected output (content of $var as specified in common.yaml ) - on node puppet agent -t --noop gives empty file that should be filled in data from $var. What puzzles me is: - Why do I get different results on 2 nodes compared to all others - Why don't I get a variable that it in common.yaml in a puppet run while a puppet lookup for the 2 specific nodes shows the variable when I set a default. - Why does a puppet lookup fail on 2 nodes when no default is set, but works for all other nodes? What can cause this behaviour? Expected behaviour: - Consistent results over all nodes and compared between puppet lookup for the node and a puppet run on the node.

Viewing all articles
Browse latest Browse all 6104

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>