Ask Your Question

what determines which modules are examined for catalog compilation?

asked 2017-06-07 12:28:26 -0500

gene gravatar image

I have a node defined in site.pp like this:

node 'potassium',
        include profile::it::potassium

When I run 'puppet agent -t' on potassium I get this error:

[root@potassium ~]# puppet agent -t
Info: Using configured environment 'production'
Info: Retrieving pluginfacts
Info: Retrieving plugin
Info: Loading facts
Error: Could not retrieve catalog from remote server: Error 500 on SERVER: Server Error: Evaluation Error: No matching entry for selector parameter with value 'RedHat' at /etc/puppetlabs/code/environments/production/modules/profile/manifests/buildserver/wireshark.pp:3:27 on node potassium.
Warning: Not using cache on failed catalog
Error: Could not retrieve catalog; skipping run
[root@potassium ~]#

I understand what the error is referring to and it is true that there is no selector for 'RedHat' in the wireshark module. What I don't understandis why puppet is even looking at the module when compiling the catalog for node potassium. Based upon what I have in site.pp, I'm thinking it should look at the init.pp for module 'profile':

[root@orion manifests]# 
[root@orion manifests]# pwd
[root@orion manifests]# cat init.pp
class profile {

[root@orion manifests]#

As you can see, that contains nothing of relevance. And then I would assume it would look directly at the profile::it::potassium class, which is currently just an empty class:

[root@orion it]# pwd
[root@orion it]# ll
total 12
-rw-r--r-- 1 root root 1252 Jun  5 09:40 aptrepo.pp
-rw-r--r-- 1 root root 1252 May 25 09:41 neon.pp
-rw-r--r-- 1 root root   35 Jun  6 11:42 potassium.pp
[root@orion it]# cat potassium.pp 
class profile::it::potassium {

[root@orion it]#

In case it is relevant; i did just upgrade the puppet server from 4.2 to 4.10.1. The agent on potassium is 4.10.1

I appreciate any insight anyone can give me?


edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2017-06-08 16:31:28 -0500

gene gravatar image

Ok, this problem turned out to self induced (as most of mine have been). I thought I was really missing something in my understanding of what manfiests were being included to build the catalog for this system. I couldn't figure out why the wireshark manfiest was even in play for node potassium. Well, turns out I had some unintended consequences with misplaced syntax in my site.pp in an area not related to node potassium but it certainly did impact it. Below is what I had:

        include role::buildserver
        include profile::buildserver::nfs
        include profile::vbuildws
        include profile::common::sssd
        include profile::buildserver::wireshark

As you can see the includes were outside of the curly braces for this set of nodes, which apparenly puts them in play for all nodes... Once I put the includes actually inside the curly braces, all was as I expected it to be. I can't tell you how many times I looked over the site.pp file without noticing that.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2017-06-07 12:28:26 -0500

Seen: 11 times

Last updated: Jun 08