Problem with Foreman apache proxy and Puppet 3.5

Hi,

I have the following

HOSTNAME: t2gw03.t2.ucsd.edu
OS: redhat
RELEASE: CentOS release 6.5 (Final)
FOREMAN: 1.4.2
RUBY: ruby 1.8.7 (2011-06-30 patchlevel 352) [x86_64-linux]
PUPPET: 3.5.1

I uploaded the debug run results via the tool.

I recently installed foreman 1.4.2 and it came with an older version of
puppet. I then upgrade to the latest puppet 3.5.1 that I could get.

Foreman is running, and reading the puppet stuff in the web interface, but
the agent and the server keep complaining with the following error.

May 7 15:31:52 t2gw03 puppet-master[16443]: no 'environments' in
{:current_environment=>#<Puppet::Node::Environment:0x7f0fba8a1990
@name=:"root", @manifest="/etc/puppet/rack", @modulepath=[]>,
:root_environment=>#<Puppet::Node::Environment:0x7f0fba8a1990
@name=:"root", @manifest="/etc/puppet/rack", @modulepath=[]>} at top of []

Now, if I shut down apache and run puppetmaster directly I get a different
result on the client node…

Warning: Unable to fetch my node definition, but the agent run will
continue:
Warning: Error 400 on SERVER: Failed to find cabinet-4-4-0.t2.ucsd.edu via
exec: Execution of '/etc/puppet/node.rb cabinet-4-4-0.t2.ucsd.edu' returned
1:
Info: Retrieving pluginfacts
Info: Retrieving plugin
Info: Loading facts in /var/lib/puppet/lib/facter/facter_dot_d.rb
Info: Loading facts in /var/lib/puppet/lib/facter/concat_basedir.rb
Info: Loading facts in /var/lib/puppet/lib/facter/root_home.rb
Info: Loading facts in /var/lib/puppet/lib/facter/pe_version.rb
Info: Loading facts in /var/lib/puppet/lib/facter/puppet_vardir.rb
Error: Could not retrieve catalog from remote server: Error 400 on SERVER:
Failed when searching for node cabinet-4-4-0.t2.ucsd.edu: Failed to find
cabinet-4-4-0.t2.ucsd.edu via exec: Execution of '/etc/puppet/node.rb
cabinet-4-4-0.t2.ucsd.edu' returned 1:
Warning: Not using cache on failed catalog
Error: Could not retrieve catalog; skipping run

Different, not really working, but different.

I must have some configuration mess up somewhere, but I am just not sure
where.

Any suggestions?

Thanks,

Terrence

> Hi,
>
> I have the following
>
> HOSTNAME: t2gw03.t2.ucsd.edu
> OS: redhat
> RELEASE: CentOS release 6.5 (Final)
> FOREMAN: 1.4.2
> RUBY: ruby 1.8.7 (2011-06-30 patchlevel 352) [x86_64-linux]
> PUPPET: 3.5.1
>
> I uploaded the debug run results via the tool.
>
> I recently installed foreman 1.4.2 and it came with an older version of
> puppet. I then upgrade to the latest puppet 3.5.1 that I could get.

Depending on what you upgraded from (maybe 2.7 from EPEL?) then there
might be some config changes to make.

See
http://projects.theforeman.org/projects/foreman/wiki/FAQ#Upgrade-puppet-from-v2-to-v3-gotchas

(and of course, the release notes. Or re-run the foreman-installer.)

> Foreman is running, and reading the puppet stuff in the web interface,
> but the agent and the server keep complaining with the following error.
>
> May 7 15:31:52 t2gw03 puppet-master[16443]: no 'environments' in
> {:current_environment=>#<Puppet::Node::Environment:0x7f0fba8a1990
> @name=:"root", @manifest="/etc/puppet/rack", @modulepath=[]>,
> :root_environment=>#<Puppet::Node::Environment:0x7f0fba8a1990
> @name=:"root", @manifest="/etc/puppet/rack", @modulepath=[]>} at top of []
>
> Now, if I shut down apache and run puppetmaster directly I get a
> different result on the client node…
>
> Warning: Unable to fetch my node definition, but the agent run will
> continue:
> Warning: Error 400 on SERVER: Failed to find cabinet-4-4-0.t2.ucsd.edu
> via exec: Execution of '/etc/puppet/node.rb cabinet-4-4-0.t2.ucsd.edu'
> returned 1:
> Info: Retrieving pluginfacts
> Info: Retrieving plugin
> Info: Loading facts in /var/lib/puppet/lib/facter/facter_dot_d.rb
> Info: Loading facts in /var/lib/puppet/lib/facter/concat_basedir.rb
> Info: Loading facts in /var/lib/puppet/lib/facter/root_home.rb
> Info: Loading facts in /var/lib/puppet/lib/facter/pe_version.rb
> Info: Loading facts in /var/lib/puppet/lib/facter/puppet_vardir.rb
> Error: Could not retrieve catalog from remote server: Error 400 on
> SERVER: Failed when searching for node cabinet-4-4-0.t2.ucsd.edu: Failed
> to find cabinet-4-4-0.t2.ucsd.edu via exec: Execution of
> '/etc/puppet/node.rb cabinet-4-4-0.t2.ucsd.edu' returned 1:
> Warning: Not using cache on failed catalog
> Error: Could not retrieve catalog; skipping run
>
> Different, not really working, but different.
>
> I must have some configuration mess up somewhere, but I am just not sure
> where.
>
> Any suggestions?

Try running that command manually, copy/paste the output and also any
changes in /var/log/foreman/production.log while running it:

/etc/puppet/node.rb cabinet-4-4-0.t2.ucsd.edu

··· On 07/05/14 23:53, twm139@gmail.com wrote:


Dominic Cleal
Red Hat Engineering