You could try to debug it from the server side. I usually run: hiera -c /etc/puppet/hiera.yaml -d classes environment=your_env ::fqdn=hostname
soemtimes this is useful. Best, Arnau 2016-09-24 0:51 GMT+02:00 Jagga Soorma <[email protected]>: > Hi Guys, > > I am trying to setup a new puppet environment using hiera and have > everything setup. However, when I do a puppet agent run I get the > following error: > > -- > Error: Could not retrieve catalog from remote server: Error 400 on > SERVER: Could not find data item classes in any Hiera data file and no > default supplied at > /etc/puppet/environments/production/manifests/site.pp:26 on node > resmesostst01.gene.com > Warning: Not using cache on failed catalog > Error: Could not retrieve catalog; skipping run > -- > > I am running puppet version 3.8.7. Here is my site.pp: > > -- > # cat /etc/puppet/environments/production/manifests/site.pp | grep -v > '#' | sed '/^$/d' > filebucket { 'main': > server => 'resforetst01.gene.com', > path => false, > } > File { backup => 'true' } > Package { allow_virtual => true } > node default { > hiera_include('classes') > } > notify { 'debug_location': name => "THE NODE LOCATION IS: ${location}" } > notify { 'debug_environment': name => "THE NODE ENVIRONMENT IS: > ${environment}" } > notify { 'debug_ype': name => "THE NODE TYPE IS: ${pr_type}" } > notify { 'debug_hostgroup': name => "THE NODE HOST GROUP IS: ${hostgroup}" > } > -- > > Here is my hiera.yaml: > > -- > [root@resforetst01 production]# cat /etc/puppet/hiera.yaml | grep -v '#' > --- > :backends: > - yaml > :hierarchy: > - "node/%{::fqdn}" > - "role/%{::hostgroup}" > - "type/%{::pr_type}" > - "site/%{::domain}" > - common > :yaml: > :datadir: "/etc/puppet/environments/%{::environment}/hieradata" > :logger: console > -- > > Any clues on what I seem to be missing? > > Thanks! > > -- > You received this message because you are subscribed to the Google Groups > "Puppet Users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit https://groups.google.com/d/ > msgid/puppet-users/CAKyjK51g9opXvj0UpVEs8owG7V3kn > 5v%3DjJb7s4j%2B%2Ba9iwGvwdg%40mail.gmail.com. > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CAM69jx9OYeP9OfL-%3DA0%3D%3DCQo9-xMXn%3DnNzDQSmpcg0XPZt2bQw%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
