Skip to content

Instantly share code, notes, and snippets.

@garethr
Created August 20, 2011 10:20
Puzzling puppet error
require 'puppet'
Puppet.parse_config
Puppet::Node.terminus_class = :yaml
Puppet[:clientyamldir] = "$yamldir"
nodes = Puppet::Node.search("*")
=> ...
nodes.count
=> 4
Puppet::Resource::Catalog.find(nodes[0].name)
Puppet::Error: Could not find default node or by name with 'garethr4.xen.prgmr.com, garethr4.xen.prgmr, garethr4.xen, garethr4' on node garethr4.xen.prgmr.com
from /usr/lib/ruby/1.8/puppet/parser/compiler.rb:21:in `compile'
from /usr/lib/ruby/1.8/puppet/indirector/catalog/compiler.rb:77:in `compile'
from /usr/lib/ruby/1.8/puppet/util.rb:188:in `benchmark'
from /usr/lib/ruby/1.8/puppet/indirector/catalog/compiler.rb:75:in `compile'
from /usr/lib/ruby/1.8/puppet/indirector/catalog/compiler.rb:34:in `find'
from /usr/lib/ruby/1.8/puppet/indirector/indirection.rb:193:in `find'
from /usr/lib/ruby/1.8/puppet/indirector.rb:50:in `find'
from (irb):11
from /usr/local/lib/site_ruby/1.8/rubygems/deprecate.rb:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment