[Puppet Users] Re: Alternating results with mount Puppet resource
On Tuesday, January 7, 2014 3:10:31 PM UTC+1, zerozer...@gmail.com wrote: The problem is with automated puppet runs every 30 minutes, as per default: 50% of the runs end with no errors in the report, even though the class is not correctly applied. Just for completeness, here is an excerpt from puppet's log showing the alternating pattern (host and class names have been masked): Jan 8 06:25:38 hostname puppet-agent[1330]: (/Stage[main]/Test::Testrepo/Mount[repomount]/ensure) defined 'ensure' as 'mounted' Jan 8 06:25:38 hostname puppet-agent[1330]: (/Stage[main]/Test::Testrepo/Mount[repomount]) Could not evaluate: Field 'device' is required Jan 8 06:25:38 hostname puppet-agent[1330]: (/Stage[main]/Test::Testrepo/Yumrepo[test-lab]) Dependency Mount[repomount] has failures: true Jan 8 06:25:38 hostname puppet-agent[1330]: (/Stage[main]/Test::Testrepo/Yumrepo[test-lab]) Skipping because of failed dependencies Jan 8 06:25:38 hostname puppet-agent[1330]: Finished catalog run in 0.28 seconds Jan 8 06:55:41 hostname puppet-agent[1330]: Finished catalog run in 0.27 seconds Jan 8 07:25:43 hostname puppet-agent[1330]: (/Stage[main]/Test::Testrepo/Mount[repomount]/ensure) defined 'ensure' as 'mounted' Jan 8 07:25:43 hostname puppet-agent[1330]: (/Stage[main]/Test::Testrepo/Mount[repomount]) Could not evaluate: Field 'device' is required Jan 8 07:25:43 hostname puppet-agent[1330]: (/Stage[main]/Test::Testrepo/Yumrepo[test-lab]) Dependency Mount[repomount] has failures: true Jan 8 07:25:43 hostname puppet-agent[1330]: (/Stage[main]/Test::Testrepo/Yumrepo[test-lab]) Skipping because of failed dependencies Jan 8 07:25:43 hostname puppet-agent[1330]: Finished catalog run in 0.28 seconds Jan 8 07:55:46 hostname puppet-agent[1330]: Finished catalog run in 0.28 seconds Thanks for any help. Marco -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/5ded5431-7bf7-4f32-a049-57db2e9669b4%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: [Puppet Users] Re: Alternating results with mount Puppet resource
Hi, can you reproduce this using puppet agent --one-time? If not, you may have to activate debug logging in your background agent. Otherwise, it will be difficult to determine what's happening when and why. Thanks, Felix On 01/08/2014 10:12 AM, zerozerouno...@gmail.com wrote: Just for completeness, here is an excerpt from puppet's log showing the alternating pattern (host and class names have been masked): -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/52CD253C.40509%40alumni.tu-berlin.de. For more options, visit https://groups.google.com/groups/opt_out.
[Puppet Users] Puppet report als JMS Message
Hi everybody We are actually using Puppet and MCollective with ActiveMQ. The Puppet Reports are now forwarded from the Puppet Master to our application using the HTTP report mechanism: reports = store, http reporturl = http://machine:port/qapp/reports I would like to know if there is (or is it planned to have) a JMS report mechanism? The idea would be to reuse the ActiveMQ broker to transport the Puppet reports via JMS. Thank you in advance for feedback! Best regards Stéphane -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/ab6768cb-3f0a-43b4-8b48-07ddf1d645b6%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
[Puppet Users] What is a good way to manage individual XML settings on Windows?
Hi, I'm looking for a good way to manage individual XML values on Windows. Apparently, Augeas does not work on Windows and we cannot manage the entire file as a template because of some values that are generated during installation of the package. How would I manage individual values in XML files on Windows machines? Thanks in advance, Ger -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/00dbf19e-660c-41f2-a0cb-84ffb91f817e%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
[Puppet Users] Re: Upgrading from 2x to 3x while simultaneously learning Puppet
On Tuesday, January 7, 2014 5:19:42 PM UTC-6, Salient Digital wrote: I'm new here, and to Puppet also. I've inherited some Puppet 2x code in an SVN repo at my work, and have the daunting task of sorting out whether we can/should use what we have, or if we should upgrade/rewrite everything from scratch on Puppet 3x. Obviously there are pros and cons of each approach. We have to manage about 40 servers with the setup. *Are there any dead giveaways to tell what version of Puppet this code was written for?* In analyzing the puppet code that I have access to, it appears it was built for Puppet 2.6 or 2.7 but I can't tell for sure. (Of course code comments would be great if there were any.) Does it matter? The easiest thing to do would be to look at what version of Puppet the code is already being used with, but I suppose you wouldn't be asking if that were possible. You can get an upper bound on the target version by looking at files' SVN timestamps. Puppet has gone from version 0.24.x to 3.4.x in under five years (with 0.25 being the predecessor of 2.6), so the timestamps can give a relatively fine-grained indication. If your code uses parameterized classes then it is targeted at 2.6.x or later. Overall, though, DSL code is fairly portable from one version of Puppet to another, so there are no real distinguishing characteristics to tie code to one specific Puppet version. *Anyone have any good puppet 2x to 3x upgrade guides/notes/links?* What would be killer is a complete list of changes and example code like if you did it this way in Puppet 2x then this is how you do that in Puppet 3x. Wishful thinking maybe. Best strategy: get your code running under 2.7.latest, resolve all warnings, then move up to 3.latest and fix what breaks (if anything). One of the key objectives of 2.7 was to help people prepare for 3.x. *Do any meta-data upgrade tools exist?* I have a lot of /extdata/ folders containing CSVs. I assume that this should be re-done with Heira for Puppet 3.4. I've read the Puppet 3x upgrade docs and lots of blog posts about upgrading puppet, but it doesn't mention much about upgrading your own Puppet code and data sources. The extlookup() function still exists in Puppet 3.4, so it is not essential to convert your manifests or data right away. With that said, hiera is all-around better than extlookup, and Puppet 3's automated data binding feature relies on it, so you are likely to want to switch. It should be possible to write a CSV backend for hiera (in the unlikely event that none is yet available), and that would ease your transition by allowing you to convert your manifests completely to hiera up front, while transitioning your data over time. *Should I start from scratch?* I see here that the puppet code I'm looking at was built by hand for SLES Zypper with a custom RPM (I don't have access to) and we're using a different OS now. (CentOS mainly), so I'm not sure there's really any value to what we have beyond study as example code of how things used to be done. That's a fair question, but only you can truly answer it. Given the amount of uncertainty surrounding your legacy Puppet code, however, I am inclined to suspect that you would indeed be better off starting from scratch. By all means do keep the old code and data around, though -- beyond their value as an example, they may contain valuable information somewhere within. *How do I tell what files, services, packages are managed by Puppet?* I've found a few tools that scan puppet code to find resources (files) managed by puppet, but I'd also like to know which packages, services, users and ssh keys are managed by puppet. This is on a VM we have running Puppet 2.6. Suggestions here would be very helpful. Packages, services, etc. managed by Puppet are also resources in Puppet terminology, so do the tools you have found (which?) actually identify only File resources, or do they perhaps already do what you are asking? Given that you say you have a VM running Puppet (as in a single machine), it must either serve as its own Puppet master, or else it must use puppet apply instead of puppet agent. Either agent/master or apply is ok, but you should be sure you know which, and you should have an informed plan for which approach to move forward with. In any case, you should be able to process the compiled YAML catalog, recorded in a file on the target machine, to identify all managed resources. I don't have a specific tool to recommend to you; for a one-off, it is possible to do it by hand. Of course, that tells you only about that particular node. You can manually compile catalogs for other specific nodes, too, and examine the results, but to reliably find all resources that might possibly be managed on *any* node, based on a given manifest set and data, there is no good alternative to manually analyzing the manifests and
Re: [Puppet Users] Hiera and puppet apply/puppet agent
On Tuesday, January 7, 2014 11:39:14 AM UTC-6, kai wrote: What version of Puppet are you running? *3.4.1 for both master and agent* As what user is the master running? (Typically an unprivileged user named 'puppet'.) *The master is running as user puppet* As what user are you running the agent in your tests? *I am running the agent and the apply commands on the master as the root user* As what user are you running puppet apply in your tests? *root* What are the ownership and permissions of /etc/puppet/data/ loc.example.com/production/Debian/wheezy.yaml and all the directories in the path to it? Do any of those have extended ACLs set on them? *The permissions of the directory and the yaml file are root:root. No ALC's. I chown-ed then to puppet:puppet with the same result.* Are you running SELinux in enforcing mode? If so, then do you see relevant AVC messages in the system log? *This is a Debian Wheezy, so no selinux or apparmor on it.* The point here was that the master need to be able to access and read those hiera data files that exist, and indeed to determine which do exist. That does not necessarily require user 'puppet' to own the file and directories, but it does require 'puppet' to have read permission on the file itself and both read and traverse permission on ALL directories in the path to the file. The bellow works fine with this: $ puppet apply --debug --environment=production -e '$test = hiera('ssh_service_config') notify { $::test: }' Debug: hiera(): Hiera YAML backend starting Debug: hiera(): Looking up ssh_service_config in YAML backend Debug: hiera(): Looking for data source defaults Debug: hiera(): Looking for data source puppetmaster.iad3.example.com Debug: hiera(): Cannot find datafile /etc/puppet/data/puppetmaster.iad3.example.com.yaml, skipping Debug: hiera(): Looking for data source production/Debian/wheezy *Debug: hiera(): Found ssh_service_config in production/Debian/wheezy* but not with $ pupept agent -tv *Error: Could not retrieve catalog from remote server: Error 400 on SERVER: Could not find data item ssh_package_name in any Hiera data file and no default supplied at /srv/puppet/environments/production/modules/ssh/manifests/install.pp:2 on node puppetmaster.iad3.example.com http://puppetmaster.iad3.example.com* So far I don't think you have presented the master's logs for the failure case. Those might be illuminating. Do first restart the master with debug logging enabled to gather the most information. You could also put Notify resources or notice() calls in your manifests on the master to verify that the fact values the agent presents to the master are the same as the ones used by puppet apply. Overall, I see only two reasonable possibilities: 1. the master is looking for a different data file than puppet apply reads, or no file at all, or 2. the master is prevented from reading the specified file, and perhaps from even testing for its existence. The former would suggest a configuration issue, whereas the latter would be some kind of access control issue. I am so far disinclined to think that there is a Puppet bug in play here. John -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/b737c422-335f-4d88-832d-0c6c1a826dde%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: [Puppet Users] What is a good way to manage individual XML settings on Windows?
Depending on your comfort level you could use PowerShell to do it, see http://powershell.com/cs/blogs/tobias/archive/2009/02/02/xml-part-2-write-add-and-change-xml-data.aspx You could combine that XML read/manipulate/write technique with the Powershell exec provider from https://forge.puppetlabs.com/joshcooper/powershell to create a Windows XML-manipulation resource if you found yourself doing that a lot. Hopefully someone has an easier answer, I know that's a bit of coding to have to do, Jeff On 01/08/2014 06:51 AM, Ger Apeldoorn wrote: Hi, I'm looking for a good way to manage individual XML values on Windows. Apparently, Augeas does not work on Windows and we cannot manage the entire file as a template because of some values that are generated during installation of the package. How would I manage individual values in XML files on Windows machines? Thanks in advance, Ger -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/00dbf19e-660c-41f2-a0cb-84ffb91f817e%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out. -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/52CD72AE.7080300%40bericotechnologies.com. For more options, visit https://groups.google.com/groups/opt_out.
[Puppet Users] When does puppet agent load newly installed facter facts?
I think I have run into some sort of facter caching issue in the puppet agent that I am hoping someone can explain. When I launch a new server I run the following command to get things started. puppet agent --test --onetime --no-daemonize --waitforcert 5 The puppetmaster then downloads to the server as one would expect. Included in this download are some new custom facts (one is called cassandra_home_dir) that I have written. It correctly puts them in /var/lib/puppet/lib/facter. After the puppet agent has downloaded the custom facts it continues processing. In one of my .pp files there is a resource declaration as follows: file {cassandraEnv: owner = 'cassandra', group = 'cassandra', mode = '744', ensure = present, path = *${cassandra_home_dir}*/conf/cassandra-env.sh, content = template('db/cassandra-env.sh.template.erb'), require = Exec['installCassandra'], } But it is failing on this resource because ${cassandra_home_dir} is empty and therefore it is trying to put the file in the /conf directory which doesn't exist. The Exec['installCassandra'] executed correctly immediately prior to the attempt to create the file['cassandraEnv'] resource. So I know the appropriate information is available from the file system. If I run the puppet agent command again everything works fine because the ${cassandra_home_dir} variable is no longer empty. So I have done nothing different other than rerun the puppet agent. *Does puppet agent cache facter facts at startup that is preventing it from loading my newly downloaded fact?* -- John Pyeatt Singlewire Software, LLC www.singlewire.com -- 608.661.1184 john.pye...@singlewire.com -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CAEisTL%3D-%3DLyqHUOwNrumVr2b9jr7BrCBpapgfvT2te5PgTVu2w%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: [Puppet Users] Hiera and puppet apply/puppet agent
John, thank you for pointing me in the right direction. The problem was that each time I made changes to hiera.yaml file I'll restart the master with service puppetmaster restart. Well apparently the master was not really restarting even though it was saying it was. So it was going into this strange state where sometimes puppet agent -tv would find the file and sometimes it would not. So after each change I had to go and kill the process because using service puppetmaster restart/stop did not really kill the process. I tried this on Centos instead of Debian Wheezy and did not have this problem. On Wednesday, January 8, 2014 9:38:12 AM UTC-6, jcbollinger wrote: On Tuesday, January 7, 2014 11:39:14 AM UTC-6, kai wrote: What version of Puppet are you running? *3.4.1 for both master and agent* As what user is the master running? (Typically an unprivileged user named 'puppet'.) *The master is running as user puppet* As what user are you running the agent in your tests? *I am running the agent and the apply commands on the master as the root user* As what user are you running puppet apply in your tests? *root* What are the ownership and permissions of /etc/puppet/data/ loc.example.com/production/Debian/wheezy.yaml and all the directories in the path to it? Do any of those have extended ACLs set on them? *The permissions of the directory and the yaml file are root:root. No ALC's. I chown-ed then to puppet:puppet with the same result.* Are you running SELinux in enforcing mode? If so, then do you see relevant AVC messages in the system log? *This is a Debian Wheezy, so no selinux or apparmor on it.* The point here was that the master need to be able to access and read those hiera data files that exist, and indeed to determine which do exist. That does not necessarily require user 'puppet' to own the file and directories, but it does require 'puppet' to have read permission on the file itself and both read and traverse permission on ALL directories in the path to the file. The bellow works fine with this: $ puppet apply --debug --environment=production -e '$test = hiera('ssh_service_config') notify { $::test: }' Debug: hiera(): Hiera YAML backend starting Debug: hiera(): Looking up ssh_service_config in YAML backend Debug: hiera(): Looking for data source defaults Debug: hiera(): Looking for data source puppetmaster.iad3.example.com Debug: hiera(): Cannot find datafile /etc/puppet/data/puppetmaster.iad3.example.com.yaml, skipping Debug: hiera(): Looking for data source production/Debian/wheezy *Debug: hiera(): Found ssh_service_config in production/Debian/wheezy* but not with $ pupept agent -tv *Error: Could not retrieve catalog from remote server: Error 400 on SERVER: Could not find data item ssh_package_name in any Hiera data file and no default supplied at /srv/puppet/environments/production/modules/ssh/manifests/install.pp:2 on node puppetmaster.iad3.example.com http://puppetmaster.iad3.example.com* So far I don't think you have presented the master's logs for the failure case. Those might be illuminating. Do first restart the master with debug logging enabled to gather the most information. You could also put Notify resources or notice() calls in your manifests on the master to verify that the fact values the agent presents to the master are the same as the ones used by puppet apply. Overall, I see only two reasonable possibilities: 1. the master is looking for a different data file than puppet apply reads, or no file at all, or 2. the master is prevented from reading the specified file, and perhaps from even testing for its existence. The former would suggest a configuration issue, whereas the latter would be some kind of access control issue. I am so far disinclined to think that there is a Puppet bug in play here. John -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/eb3183cc-b71b-4151-89eb-28ff1fcf2ba6%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
[Puppet Users] When does puppet agent load newly installed facter facts?
Puppet loads facts first of all, so custom facts deployed are not there until next run. Regards -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/f298496f-7b16-4d89-ad88-ddfdcc3645f7%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: [Puppet Users] The Future - ENCs vs Hiera?
Jose Luis Ledesma joseluis.lede...@gmail.com writes: Enforcing environment from the master is a must for us, and I don't really see the point of configuring hiera against LDAP when puppet supports it natively. Do you know some benefit I'm missing? Last time I checked the native LDAP terminus did not support parametrized classes. This alone justified writing my own ENC, which was initially just an improved version of the LDAP terminus (this was before Hiera even existed, let alone was supported out of the box). -- Arnaud -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/m3txdefckx.fsf%40carrosse.glou.org. For more options, visit https://groups.google.com/groups/opt_out.
Re: [Puppet Users] The Future - ENCs vs Hiera?
On 01/08/2014 09:22 PM, Arnaud Gomes-do-Vale wrote: Jose Luis Ledesma joseluis.lede...@gmail.com writes: Enforcing environment from the master is a must for us, and I don't really see the point of configuring hiera against LDAP when puppet supports it natively. Do you know some benefit I'm missing? Last time I checked the native LDAP terminus did not support parametrized classes. This alone justified writing my own ENC, which was initially just an improved version of the LDAP terminus (this was before Hiera even existed, let alone was supported out of the box). Hi Arnoud, I'm very interested in your improvement. Is it available for the public somewhere ? Grts Jo -- Johan De Wit Open Source Consultant Red Hat Certified Engineer (805008667232363) Puppet Certified Professional 2013 (PCP006) _ Open-Future Phone +32 (0)2/255 70 70 Zavelstraat 72 Fax +32 (0)2/255 70 71 3071 KORTENBERG Mobile+32 (0)474/42 40 73 BELGIUM http://www.open-future.be _ Next Events: Puppet Advanced Training | http://www.open-future.be/puppet-advanced-training-7-till-9th-january Puppet Fundamentals Training | http://www.open-future.be/puppet-fundamentals-training-4-till-6th-february Subscribe to our newsletter | http://eepurl.com/BUG8H -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/52CDB43B.1080905%40open-future.be. For more options, visit https://groups.google.com/groups/opt_out.
[Puppet Users] installing PE 3.1 on OpenSuse 13.1 x64
Hi All, Does anyone know how to install PE (3.1 latest) on OpenSuse (13.1 x64) Linux. I'm getting: !! ERROR: Unknown platform trying to run # /puppet-enterprise-3.1.1-all/puppet-enterprise-installer # cat /etc/issue Welcome to openSUSE 13.1 Bottle - Kernel \r (\l). uname -a Linux puppetmaster 3.11.6-4-default #1 SMP Wed Oct 30 18:04:56 UTC 2013 (e6d4a27) x86_64 x86_64 x86_64 GNU/Linux Please advice. Thank you. Regards, Kirils. -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/c1cdc9fb-b9fc-46a8-ae1d-2d30936de2b0%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: [Puppet Users] The Future - ENCs vs Hiera?
True, but with a profiles/roles design + hiera you shouldn't need to parametrize classes in the LDAP. Regards, -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/4421f494-cacb-4cca-90f5-0599bf9bf94e%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
[Puppet Users] Where do custom facter facts go on the Learning VM ? Is that the cause of these behaviors?
Platform: I've downloaded and installed the learning VM. This system runs CentOS with Facter v1.7.3 and Puppet v3.3.1 (Puppet Enterprise 3.1.0). I've created a fact called hello.rb with the following content: Facter.add(:hello) do setcode do Hello world! end end I've placed the file in /etc/puppetlabs/facter/facts.d (I made this directory since the tutorial said to create it if it did not exist). I added a line to /etc/puppetlabs/puppet/manifests/site.pp for the default node: notify { $::hello: } .If I run puppet agent --test, it behaves as if my custom fact does not exist: Notice: undef Notice: /Stage[main]//Node[default]/Notify[undef]/message: defined 'message' as 'undef' So then the instructions said we could debug the fact by running facter --debug. If I do this, I see an error: Fact file /etc/puppetlabs/facter/facts.d/hello.rb was parsed but returned an empty data set I thought this meaningful but the same error will occur for any Facter custom fact I put in there. Even verbatim copy/paste jobs from known working examples off the tutorial. Does anyone know what is going on?I can't tell if the fact is in the wrong directory for Puppet when it uses Facter, but for some reason Facter sees it when run in standalone?If the latter is the case, why do I get these parse errors despite having valid source? Thanks for any help. -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/90578665-1151-4df5-8a46-27e03ab877d6%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
[Puppet Users] Decommission puppetdb
I'm trying to decommission puppetdb, but it's being very persistent. I've removed the puppetdb-terminus rpm, and commented out the storeconfigs entries in puppet.conf, but the managed systems can't apply without puppetdb running on the server. The error messages are: Warning: Unable to fetch my node definition, but the agent run will continue: Warning: Error 400 on SERVER: Could not retrieve facts for medusa.keck.waisman.wisc.edu: Failed to find facts from PuppetDB at puppetdb:8081: Connection refused - connect(2) ...and... Error: Could not retrieve catalog from remote server: Error 400 on SERVER: Failed to submit 'replace facts' command for medusa.keck.waisman.wisc.edu to PuppetDB at puppetdb:8081: Connection refused - connect(2) Warning: Not using cache on failed catalog Error: Could not retrieve catalog; skipping run Anyone know the rest of the magic sauce to make a managed system *not* talk to puppetdb? -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/5a7abd23-45ab-41b7-9022-7f5c3cf1360b%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: [Puppet Users] Decommission puppetdb
On Wed, Jan 8, 2014 at 3:17 PM, David Thompson dthomp...@waisman.wisc.eduwrote: I'm trying to decommission puppetdb, but it's being very persistent. I've removed the puppetdb-terminus rpm, and commented out the storeconfigs entries in puppet.conf, but the managed systems can't apply without puppetdb running on the server. Do you still have a routes.yml file that references puppetdb? The error messages are: Warning: Unable to fetch my node definition, but the agent run will continue: Warning: Error 400 on SERVER: Could not retrieve facts for medusa.keck.waisman.wisc.edu: Failed to find facts from PuppetDB at puppetdb:8081: Connection refused - connect(2) ...and... Error: Could not retrieve catalog from remote server: Error 400 on SERVER: Failed to submit 'replace facts' command for medusa.keck.waisman.wisc.eduto PuppetDB at puppetdb:8081: Connection refused - connect(2) Warning: Not using cache on failed catalog Error: Could not retrieve catalog; skipping run Anyone know the rest of the magic sauce to make a managed system *not* talk to puppetdb? I'm not 100% sure what you mean by managed system, but unless you're using it with puppet apply the only systems that talk to PuppetDB are your puppetmasters. Agents never talk to it directly. deepak -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/5a7abd23-45ab-41b7-9022-7f5c3cf1360b%40googlegroups.com . For more options, visit https://groups.google.com/groups/opt_out. -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CAOjOXY29TxsPL5WfsRwgVirwPDcBRJovEMx0zwJw%3DWZynwbtag%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: [Puppet Users] Decommission puppetdb
Remove also /etc/puppet/puppetdb.conf -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/75458c12-527b-4b80-b800-148cce25cb94%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: [Puppet Users] installing PE 3.1 on OpenSuse 13.1 x64
On Wed, Jan 8, 2014 at 12:21 PM, expouser churi...@gmail.com wrote: Hi All, Does anyone know how to install PE (3.1 latest) on OpenSuse (13.1 x64) Linux. Unfortunately, you can't as it's not a supported platform (SLES is though!) I'm getting: !! ERROR: Unknown platform trying to run # /puppet-enterprise-3.1.1-all/puppet-enterprise-installer # cat /etc/issue Welcome to openSUSE 13.1 Bottle - Kernel \r (\l). uname -a Linux puppetmaster 3.11.6-4-default #1 SMP Wed Oct 30 18:04:56 UTC 2013 (e6d4a27) x86_64 x86_64 x86_64 GNU/Linux Please advice. Thank you. Regards, Kirils. -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/c1cdc9fb-b9fc-46a8-ae1d-2d30936de2b0%40googlegroups.com . For more options, visit https://groups.google.com/groups/opt_out. -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CA%2B%3DBEqWA-0GdAhJ0UW4jVcbizR37bRQKfx12r3sjBv5x8j3Bqg%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.
[Puppet Users] postgres issue with puppetdb unexpected EOF on client connection
Hi, Hoping someone can help with this error. Check your puppetdb logs and you might see the same error. This doesn’t seem to cause any harm but I have seen occasional crashes with puppetdb. This error is littering my postgres log files. The puppetdb must be closing the connection incorrectly and causing this error. Anybody else running into this? Is this a known error? Running: Centos 6.4 postgres (PostgreSQL) 8.4.13 puppetdb 1.5.0 puppet 3.2.4 LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/4A9D8184-9086-4572-A026-BEA92CF47305%40logicminds.biz. For more options, visit https://groups.google.com/groups/opt_out.
Re: [Puppet Users] postgres issue with puppetdb unexpected EOF on client connection
On Wed, Jan 8, 2014 at 4:39 PM, Corey Osman co...@logicminds.biz wrote: Hi, Hoping someone can help with this error. Check your puppetdb logs and you might see the same error. This doesn’t seem to cause any harm but I have seen occasional crashes with puppetdb. This error is littering my postgres log files. The puppetdb must be closing the connection incorrectly and causing this error. Anybody else running into this? Is this a known error? Are you connecting to postgres through a load balancer, or firewall, or some other intermediary that may be cutting off long-lived connections? I've not seen any other causes of this in the field that I'm aware of. Are there any error messages logged on the puppetdb side of things? There are some options you can use to tune the connection pool inside of puppetdb to be more aggressive about terminating connections: http://docs.puppetlabs.com/puppetdb/1.6/configure.html#conn-max-age deepak Running: Centos 6.4 postgres (PostgreSQL) 8.4.13 puppetdb 1.5.0 puppet 3.2.4 LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection LOG: unexpected EOF on client connection -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/4A9D8184-9086-4572-A026-BEA92CF47305%40logicminds.biz . For more options, visit https://groups.google.com/groups/opt_out. -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CAOjOXY0e%2Bx8EAYQ9NkPHqmpv1jrAJkdqeJFUne-QVOSLc6cUsg%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: [Puppet Users] The Future - ENCs vs Hiera?
Keep in mind that Hiera can support multiple backends and not all of them mean manipulating JSON or YAML. For instance, I'm a proponent of something like this: On Sat, Jan 4, 2014 at 10:15 AM, Jose Luis Ledesma joseluis.lede...@gmail.com wrote: I'm in the process of setting up puppet in my company and I don't like at all the idea of having some thousand of files for describe the nodes. And, despite the well known limitations, I like a lot the idea of having an enc like ldap. Regards, -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/cbae58f9-3e14-472e-906d-ce7a3be355af%40googlegroups.com . For more options, visit https://groups.google.com/groups/opt_out. -- --- Nathan Valentine, Puppet Labs Professional Services Have you seen : http://ask.puppetlabs.com , http://puppetlabs.com/learn ? -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CA%2BsYer2ur0DoMdOa9K5VMG4SYn_goz3LjLocvTK_GsjyukY5dA%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: [Puppet Users] The Future - ENCs vs Hiera?
Sorry, bitten by the Gmail interface on that last one... I'm a proponent of something like this: http://www.craigdunn.org/2012/11/puppet-data-from-couchdb-using-hiera-http/ with classification data that doesn't change much ( 'require ::site::profile::base' ) perhaps living in YAML and specific one-off tweaks to a node's config like perhaps an override of the default NTP server coming from CouchDB. Much easier for the less Puppet-y people on a team to login and twiddle things via CouchDB web interface. On Wed, Jan 8, 2014 at 3:52 PM, Nathan Valentine nat...@puppetlabs.comwrote: Keep in mind that Hiera can support multiple backends and not all of them mean manipulating JSON or YAML. For instance, I'm a proponent of something like this: On Sat, Jan 4, 2014 at 10:15 AM, Jose Luis Ledesma joseluis.lede...@gmail.com wrote: I'm in the process of setting up puppet in my company and I don't like at all the idea of having some thousand of files for describe the nodes. And, despite the well known limitations, I like a lot the idea of having an enc like ldap. Regards, -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/cbae58f9-3e14-472e-906d-ce7a3be355af%40googlegroups.com . For more options, visit https://groups.google.com/groups/opt_out. -- --- Nathan Valentine, Puppet Labs Professional Services Have you seen : http://ask.puppetlabs.com , http://puppetlabs.com/learn ? -- --- Nathan Valentine, Puppet Labs Professional Services Have you seen : http://ask.puppetlabs.com , http://puppetlabs.com/learn ? -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CA%2BsYer3urU3CM6RRWMQ6CCdhdbSFapX6H07ZsUtOO%2BHLdyTvFA%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: [Puppet Users] Where do custom facter facts go on the Learning VM ? Is that the cause of these behaviors?
You are making external facts too complicated. More like this: hello.rb --- #!/usr/bin/env ruby puts hello=Hello, World! hello.yaml --- --- hello='Hello, World!' https://docs.puppetlabs.com/guides/custom_facts.html#external-facts -- --- Nathan Valentine, Puppet Labs Professional Services Have you seen : http://ask.puppetlabs.com , http://puppetlabs.com/learn ? -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CA%2BsYer3KWFMnc1W6BfLhoO23B-uapxCEKf5Gv98r5HbDq%2Bz%2BSQ%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: [Puppet Users] Where do custom facter facts go on the Learning VM ? Is that the cause of these behaviors?
sorry, s/=/:/g in hello.yaml On Wed, Jan 8, 2014 at 4:40 PM, Nathan Valentine nat...@puppetlabs.com wrote: You are making external facts too complicated. More like this: hello.rb --- #!/usr/bin/env ruby puts hello=Hello, World! hello.yaml --- --- hello='Hello, World!' https://docs.puppetlabs.com/guides/custom_facts.html#external-facts -- --- Nathan Valentine, Puppet Labs Professional Services Have you seen : http://ask.puppetlabs.com , http://puppetlabs.com/learn ? -- --- Nathan Valentine, Puppet Labs Professional Services Have you seen : http://ask.puppetlabs.com , http://puppetlabs.com/learn ? -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CA%2BsYer0yOMFcMWt0Fvr2swnphUp4VdvvXzYX3mGZ8CXQJKH6bw%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: [Puppet Users] Where do custom facter facts go on the Learning VM ? Is that the cause of these behaviors?
The simpler ruby script you gave still exhibits the same behavior. I'm sure the code in the facts I am using is correct, so I don't think it is a matter of their content. As I mentioned I have literally copied examples from the tutorial and elsewhere. If I run facter --debug all of the facts give the same error message I give above that they were parsed but returned an empty dataset. If I run puppet agent --test then it is as if my fact did not exist. Any ideas? On Wednesday, January 8, 2014 4:40:10 PM UTC-8, Nathan Valentine wrote: You are making external facts too complicated. More like this: hello.rb --- #!/usr/bin/env ruby puts hello=Hello, World! hello.yaml --- --- hello='Hello, World!' https://docs.puppetlabs.com/guides/custom_facts.html#external-facts -- --- Nathan Valentine, Puppet Labs Professional Services Have you seen : http://ask.puppetlabs.com , http://puppetlabs.com/learn ? -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/faf70d9b-d15f-4f23-a058-f2ef79189636%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
[Puppet Users] error testing puppet 3.x upgrade: You need rubygems to use Hiera
All- I've been struggling with this all afternoon, so it's time to ask for some help. The TL;DR version: On a 2.7.14 puppet client promoted to be a test 3.4.2 master, whenever a client connects I get: Warning: Puppet.features.rubygems? is deprecated. Require rubygems in your application's entry point if you need it. (at /usr/lib/ruby/site_ruby/1.8/puppet/util/feature.rb:17:in `add') Error: You need rubygems to use Hiera at /etc/puppet/manifests/users.pp:243 on node rh6client.example.com Error: You need rubygems to use Hiera at /etc/puppet/manifests/users.pp:243 on node rh6client.example.com Error: You need rubygems to use Hiera at /etc/puppet/manifests/users.pp:243 on node rh6client.example.com I have the RHEL-provided rubygems package installed (it gets installed automatically as a dependency of puppet 3.4.2 from Puppet Labs), so why the error? The full version: We're currently using puppet 2.7.14 with facter 1.5.9, both on master and on our clients. All of our clients are currently RHEL 5.x or RHEL 6.x, though we'll likely be adding other OSes once we're on Puppet 3.x. I'm beginning our testing of 3.4.x by following the documentation here: http://docs.puppetlabs.com/guides/upgrading.html I'm following the Option 1 route, promoting a client to be the master. The client I'm promoting is a fresh install of RHEL 6.5 with our puppet 2.7.14, and I have done a puppet apply on it to get all local config in place for a basic puppet client in our environment. I then copied all of /etc/puppet and /var/lib/puppet from our current master over to the client I wish to promote. To promote the client to be the test master, I uninstall our locally-built RPMs for facter puppet, then install the PuppetLabs EL6 rpms for facter-1.7.4-1.el6 hiera-1.3.0-1.el6 puppet-3.4.2-1.el6 puppet-server-3.4.2-1.el6 rubygem-json-1.5.5-1.el6 ruby-rgen-0.6.5-1.el6 That also auto-installed, for dependencies, Red Hat's packages for ruby-rdoc-1.8.7.352-13.el6.x86_64 ruby-irb-1.8.7.352-13.el6.x86_64 rubygems-1.3.7-5.el6.noarch I have updated the auth.conf to have allow_ip stanzas for the one custom file serving location we use. I start up the temporary puppet master: # puppet master --no-daemonize --verbose Notice: Starting Puppet master version 3.4.2 I then pick an existing client, rh6client.example.com, uninstall facter puppet, install the Puppet Labs facter puppet, which also pull in Puppet Labs' hiera rubygem-json, as well as the Red Hat ruby-rdoc, ruby-irb, and rubygems. I point the client at the temporary master and receive (on the client) the error: # puppet agent --server pm-tmp.example.com --test --noop Info: Retrieving plugin Info: Loading facts in /var/lib/puppet/lib/facter/printers.rb Info: Loading facts in /var/lib/puppet/lib/facter/root_home.rb Info: Loading facts in /var/lib/puppet/lib/facter/net_location.rb Info: Loading facts in /var/lib/puppet/lib/facter/biosversion.rb Info: Loading facts in /var/lib/puppet/lib/facter/net_info.rb Info: Loading facts in /var/lib/puppet/lib/facter/ipmi_product.rb Info: Loading facts in /var/lib/puppet/lib/facter/facter_dot_d.rb Info: Loading facts in /var/lib/puppet/lib/facter/pacemaker.rb Error: Could not retrieve catalog from remote server: Error 400 on SERVER: You need rubygems to use Hiera at /etc/puppet/manifests/users.pp:243 on node rh6client.example.com Warning: Not using cache on failed catalog Error: Could not retrieve catalog; skipping run On the temporary server, it has output a bunch of Info statements about processing for auth.conf, but follows that with: Info: Caching node for rh6client.example.com Info: Caching node for rh6client.example.com Warning: Puppet.features.rubygems? is deprecated. Require rubygems in your application's entry point if you need it. (at /usr/lib/ruby/site_ruby/1.8/puppet/util/feature.rb:17:in `add') Error: You need rubygems to use Hiera at /etc/puppet/manifests/users.pp:243 on node rh6client.example.com Error: You need rubygems to use Hiera at /etc/puppet/manifests/users.pp:243 on node rh6client.example.com Error: You need rubygems to use Hiera at /etc/puppet/manifests/users.pp:243 on node rh6client.example.com That part of the manifest looks like this: # used on the netflow server @user { 'ncsprime': home = '/var/netflow/ncsprime', gid= 'ncsprime', comment= 'Cisco NCS Prime backup file owner', membership = inclusive, uid= '709844', password = hiera('ncsprime_password', '!!'), } Our /etc/puppet/hiera.yaml that I copied from our existing 2.7.14 master to the promoted 3.4.2 temporary master is --- :backends: - yaml :hierarchy: - secure/fqdn/%{clientcert} - fqdn/%{clientcert} - secure/location/%{location} - location/%{location} - secure/common - common :yaml: :datadir: /etc/puppet/hiera-data I don't understand what I'm
Re: [Puppet Users] error testing puppet 3.x upgrade: You need rubygems to use Hiera
Any chance you have a symlink to /usr/lib/ruby/site_ruby/1.8/hiera/backend/ (or something similar) floating around in your /var/lib/puppet? This was a common way to get Hiera to work in Puppet 2.7 before the necessary glue was built into 3.x. If you do, remove it and restart. Ramin On 1/8/2014 5:16 PM, Tim Mooney wrote: All- I've been struggling with this all afternoon, so it's time to ask for some help. The TL;DR version: On a 2.7.14 puppet client promoted to be a test 3.4.2 master, whenever a client connects I get: Warning: Puppet.features.rubygems? is deprecated. Require rubygems in your application's entry point if you need it. (at /usr/lib/ruby/site_ruby/1.8/puppet/util/feature.rb:17:in `add') Error: You need rubygems to use Hiera at /etc/puppet/manifests/users.pp:243 on node rh6client.example.com Error: You need rubygems to use Hiera at /etc/puppet/manifests/users.pp:243 on node rh6client.example.com Error: You need rubygems to use Hiera at /etc/puppet/manifests/users.pp:243 on node rh6client.example.com I have the RHEL-provided rubygems package installed (it gets installed automatically as a dependency of puppet 3.4.2 from Puppet Labs), so why the error? The full version: We're currently using puppet 2.7.14 with facter 1.5.9, both on master and on our clients. All of our clients are currently RHEL 5.x or RHEL 6.x, though we'll likely be adding other OSes once we're on Puppet 3.x. I'm beginning our testing of 3.4.x by following the documentation here: http://docs.puppetlabs.com/guides/upgrading.html I'm following the Option 1 route, promoting a client to be the master. The client I'm promoting is a fresh install of RHEL 6.5 with our puppet 2.7.14, and I have done a puppet apply on it to get all local config in place for a basic puppet client in our environment. I then copied all of /etc/puppet and /var/lib/puppet from our current master over to the client I wish to promote. To promote the client to be the test master, I uninstall our locally-built RPMs for facter puppet, then install the PuppetLabs EL6 rpms for facter-1.7.4-1.el6 hiera-1.3.0-1.el6 puppet-3.4.2-1.el6 puppet-server-3.4.2-1.el6 rubygem-json-1.5.5-1.el6 ruby-rgen-0.6.5-1.el6 That also auto-installed, for dependencies, Red Hat's packages for ruby-rdoc-1.8.7.352-13.el6.x86_64 ruby-irb-1.8.7.352-13.el6.x86_64 rubygems-1.3.7-5.el6.noarch I have updated the auth.conf to have allow_ip stanzas for the one custom file serving location we use. I start up the temporary puppet master: # puppet master --no-daemonize --verbose Notice: Starting Puppet master version 3.4.2 I then pick an existing client, rh6client.example.com, uninstall facter puppet, install the Puppet Labs facter puppet, which also pull in Puppet Labs' hiera rubygem-json, as well as the Red Hat ruby-rdoc, ruby-irb, and rubygems. I point the client at the temporary master and receive (on the client) the error: # puppet agent --server pm-tmp.example.com --test --noop Info: Retrieving plugin Info: Loading facts in /var/lib/puppet/lib/facter/printers.rb Info: Loading facts in /var/lib/puppet/lib/facter/root_home.rb Info: Loading facts in /var/lib/puppet/lib/facter/net_location.rb Info: Loading facts in /var/lib/puppet/lib/facter/biosversion.rb Info: Loading facts in /var/lib/puppet/lib/facter/net_info.rb Info: Loading facts in /var/lib/puppet/lib/facter/ipmi_product.rb Info: Loading facts in /var/lib/puppet/lib/facter/facter_dot_d.rb Info: Loading facts in /var/lib/puppet/lib/facter/pacemaker.rb Error: Could not retrieve catalog from remote server: Error 400 on SERVER: You need rubygems to use Hiera at /etc/puppet/manifests/users.pp:243 on node rh6client.example.com Warning: Not using cache on failed catalog Error: Could not retrieve catalog; skipping run On the temporary server, it has output a bunch of Info statements about processing for auth.conf, but follows that with: Info: Caching node for rh6client.example.com Info: Caching node for rh6client.example.com Warning: Puppet.features.rubygems? is deprecated. Require rubygems in your application's entry point if you need it. (at /usr/lib/ruby/site_ruby/1.8/puppet/util/feature.rb:17:in `add') Error: You need rubygems to use Hiera at /etc/puppet/manifests/users.pp:243 on node rh6client.example.com Error: You need rubygems to use Hiera at /etc/puppet/manifests/users.pp:243 on node rh6client.example.com Error: You need rubygems to use Hiera at /etc/puppet/manifests/users.pp:243 on node rh6client.example.com That part of the manifest looks like this: # used on the netflow server @user { 'ncsprime': home = '/var/netflow/ncsprime', gid= 'ncsprime', comment= 'Cisco NCS Prime backup file owner', membership = inclusive, uid= '709844', password = hiera('ncsprime_password', '!!'), } Our /etc/puppet/hiera.yaml that I copied from our existing 2.7.14 master to the promoted 3.4.2 temporary master is ---
Re: [Puppet Users] Where do custom facter facts go on the Learning VM ? Is that the cause of these behaviors?
The Facter.add scaffolding isn't required for external facts. That's actually a key part of the design. Here's an example vagrant environment with external facts similar to your demo code: https://github.com/nrvale0/vagrant-extfacts-demo On Wed, Jan 8, 2014 at 5:03 PM, Shark Laser sharklaser1...@gmail.com wrote: The simpler ruby script you gave still exhibits the same behavior. I'm sure the code in the facts I am using is correct, so I don't think it is a matter of their content. As I mentioned I have literally copied examples from the tutorial and elsewhere. If I run facter --debug all of the facts give the same error message I give above that they were parsed but returned an empty dataset. If I run puppet agent --test then it is as if my fact did not exist. Any ideas? On Wednesday, January 8, 2014 4:40:10 PM UTC-8, Nathan Valentine wrote: You are making external facts too complicated. More like this: hello.rb --- #!/usr/bin/env ruby puts hello=Hello, World! hello.yaml --- --- hello='Hello, World!' https://docs.puppetlabs.com/guides/custom_facts.html#external-facts -- --- Nathan Valentine, Puppet Labs Professional Services Have you seen : http://ask.puppetlabs.com , http://puppetlabs.com/learn ? -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/faf70d9b-d15f-4f23-a058-f2ef79189636%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out. -- --- Nathan Valentine, Puppet Labs Professional Services Have you seen : http://ask.puppetlabs.com , http://puppetlabs.com/learn ? -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CA%2BsYer24MG%2BBZu03R8rRutStLXit1gP%3Dwt611CJSJ%2BgOGV%2BOXA%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: [Puppet Users] dashed by dashboard
Thanks Sam. On Jan 7, 2014, at 1:58 AM, Sam Kottler s...@kottlerdevelopment.com wrote: On Mon, Jan 6, 2014 at 8:51 PM, Stuart Cracraft smcracr...@gmail.com wrote: Okay, took care of that. Thanks. Now, when doing per page 170 in chapter 7 (chapter puppet consoles) in Pro Puppet by Krum et al, I have: ruby /usr/share/foreman-installer/generate_answers.rb We changed the installation process as part of a pretty large overhaul in the Foreman installer that was released in 1.3. You can see the up-to-date installation guide here: http://theforeman.org/manuals/1.3/quickstart_guide.html but it does not have a file generate_answers.rb anywhere in the /usr/share/foreman-installer tree. Has anyone else encountered the above? On Monday, January 6, 2014 10:46:57 AM UTC-8, Jose Luis Ledesma wrote: You hace to enable both epel and optional repositories. Regards, -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/d41f912e-2ed0-4efd-9354-a3f1d78c084c%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out. -- You received this message because you are subscribed to a topic in the Google Groups Puppet Users group. To unsubscribe from this topic, visit https://groups.google.com/d/topic/puppet-users/XYf9pNGRVmY/unsubscribe. To unsubscribe from this group and all its topics, send an email to puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CAPO4y0SGQBMxdGe5YwPnSy2ePcnhnqNsZx%2BvJWg3AUzutFCX2g%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out. -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/F3A65763-68A9-4F60-9DE5-1EC18CC6A68F%40me.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: [Puppet Users] Where do custom facter facts go on the Learning VM ? Is that the cause of these behaviors?
i think everything is fine with your code. Problem might be with location. Dont know about PE, but for facter if you do export FACTERLIB= you dir, then you can run facter to see your custom fact On 8 Jan 2014 21:52, Shark Laser sharklaser1...@gmail.com wrote: Platform: I've downloaded and installed the learning VM. This system runs CentOS with Facter v1.7.3 and Puppet v3.3.1 (Puppet Enterprise 3.1.0). I've created a fact called hello.rb with the following content: Facter.add(:hello) do setcode do Hello world! end end I've placed the file in /etc/puppetlabs/facter/facts.d (I made this directory since the tutorial said to create it if it did not exist). I added a line to /etc/puppetlabs/puppet/manifests/site.pp for the default node: notify { $::hello: } .If I run puppet agent --test, it behaves as if my custom fact does not exist: Notice: undef Notice: /Stage[main]//Node[default]/Notify[undef]/message: defined 'message' as 'undef' So then the instructions said we could debug the fact by running facter --debug. If I do this, I see an error: Fact file /etc/puppetlabs/facter/facts.d/hello.rb was parsed but returned an empty data set I thought this meaningful but the same error will occur for any Facter custom fact I put in there. Even verbatim copy/paste jobs from known working examples off the tutorial. Does anyone know what is going on?I can't tell if the fact is in the wrong directory for Puppet when it uses Facter, but for some reason Facter sees it when run in standalone?If the latter is the case, why do I get these parse errors despite having valid source? Thanks for any help. -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/90578665-1151-4df5-8a46-27e03ab877d6%40googlegroups.com . For more options, visit https://groups.google.com/groups/opt_out. -- 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 puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CACzr%3DFeponBw8Q3DEM3HXy9FCCDPcszp57ejNyWzSEYSq_r6KQ%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.