Posted over 6 years ago. Visible to the public.

vague puppet error messages with broken yaml files

If you get one of this errors:

Copy
Error: Could not retrieve catalog from remote server: Error 400 on SERVER: (<unknown>): found character that cannot start any token while scanning for the next token at line 1297 column 3 Warning: Not using cache on failed catalog Error: Could not retrieve catalog; skipping run Error: Could not retrieve catalog from remote server: Error 400 on SERVER: undefined method `empty?' for nil:NilClass at /etc/puppet/environments/production/manifests/nodes.pp:1 on node example.makandra.de Warning: Not using cache on failed catalog Error: Could not retrieve catalog; skipping run

it's probably an error in your hiera yaml files.

In my case it was a facter variable I've used without quotes after a puppetmaster update (it was working for months before that).

Bad:

Copy
foo: %{::fqdn}

Good:

Copy
foo: "%{::fqdn}"

I've debugged the error like this:

  • deleted all yaml files one by one until the error didn't happend
  • comment out all lines in this yaml and removed the comments step by step until I've found the bad line
Growing Rails Applications in Practice
Check out our new e-book:
Learn to structure large Ruby on Rails codebases with the tools you already know and love.

Owner of this card:

Avatar
Kim Jahn
Last edit:
over 6 years ago
by Thomas Eisenbarth
About this deck:
We are makandra and do test-driven, agile Ruby on Rails software development.
License for source code
Posted by Kim Jahn to makandra dev
This website uses short-lived cookies to improve usability.
Accept or learn more