Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am using a ruby script to retrieve the class parameters and my YAML output is as below:

classes:
  tomcat_install:
    tmp_dir: /tmp
    tomcat_home: /tmp/tomcat6

puppet.conf is as below:

[master]
node_terminus = exec
external_nodes = /etc/puppet/readnodedefinitions.rb

When I give the test command from puppet agent the log is:

Notice: Ignoring --listen on onetime run
Info: Retrieving plugin
Info: Caching catalog for puppet-agent
Info: Applying configuration version '1367987990'
Notice: Finished catalog run in 0.06 seconds

But the classes specified in ruby script are getting ignored. Any idea why its ignored?

debug mode gave this


Debug: Finishing transaction 69977541744660
Debug: Loaded state in 0.00 seconds
Debug: node supports formats: b64_zlib_yaml pson raw yaml; using pson
Debug: Using cached certificate for ca
Debug: Using cached certificate for puppet-agent.cs1cloud.internal
Debug: Using cached certificate_revocation_list for ca
Info: Retrieving plugin
Debug: file_metadata supports formats: b64_zlib_yaml pson raw yaml; using pson
Debug: Finishing transaction 69977541525360
Debug: catalog supports formats: b64_zlib_yaml dot pson raw yaml; using pson
Info: Caching catalog for puppet-agent.cs1cloud.internal
Debug: Creating default schedules
Debug: Loaded state in 0.00 seconds
Info: Applying configuration version '1367987990'
Debug: /Schedule[daily]: Skipping device resources because running on a host
Debug: /Schedule[monthly]: Skipping device resources because running on a host
Debug: /Schedule[hourly]: Skipping device resources because running on a host
Debug: /Schedule[never]: Skipping device resources because running on a host
Debug: /Schedule[weekly]: Skipping device resources because running on a host
Debug: /Schedule[puppet]: Skipping device resources because running on a host
Debug: Finishing transaction 69977541711700
Debug: Storing state
Debug: Stored state in 0.03 seconds
Notice: Finished catalog run in 0.07 seconds
Debug: Value of 'preferred_serialization_format' (pson) is invalid for report, u                                                                                        sing default (b64_zlib_yaml)
Debug: report supports formats: b64_zlib_yaml raw yaml; using b64_zlib_yaml
share|improve this question
    
Run puppet with --debug and paste the output please. That may give more clues. –  Dennis Kaarsemaker May 8 '13 at 5:48
    
have added the debug message to the question.... –  user172857 May 8 '13 at 6:00
    
Why not use hiera instead? You can have custom facts if you need to using facter-dot-d or directly /etc/facter/facts.d if using a recent facter –  dawud May 8 '13 at 6:49
    
I am using ruby script to pick the class parameters from DB , as I am gonna build a custom UI on top of it. I am not sure if Hiera supports this feature. –  user172857 May 8 '13 at 6:57

1 Answer 1

It seems your YAML output lost some - and Puppet can't recognize it as a YAML file. Maybe it should like this?

---
classes:
  puppet-agent.cs1cloud.internal:
    tmp_dir: /tmp
    tomcat_home: /tmp/tomcat6
share|improve this answer
    
docs.puppetlabs.com/guides/external_nodes.html have refered this link and it clearly says array syntax cannot be used for parameterized classes. So I believe the yaml output that i construct is correct. –  user172857 May 9 '13 at 4:59
    
maybe you use the wrong node name. it should be puppet-agent.cs1cloud.internal instead of tomcat_install. i should just comment your question, but i don't have the privilege, sorry. –  txworking May 9 '13 at 7:07
    
yaml consists of the class name("tomcat_install") and params ("tmpd_dir","tomcat_home").Node name is automatically detected by the puppet once the test command is run. –  user172857 May 10 '13 at 4:13

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.