This is a how-to guide on using: https://github.com/camptocamp/puppet-ghostbuster First get this working so that you can access this gui dashboard: https://puppet.com/docs/puppetdb/5.1/maintain_and_tune.html#monitor-the-performance-dashboard Install rvm: $ gpg –keyserver hkp://keys.gnupg.net –recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB $ \curl -sSL https://get.rvm.io | bash -s stable –ruby Check rvm install is successful: schowdhury@Shers-MacBook-Pro:~$ rvm –version rvm 1.29.3 (latest) […]
Read More
External facts is a great way to attach (arbitrary) metadata to a machine during the the launch of a new machine. E.g. when building a Centos 7 aws ec2 instance, you can generate the external facts via userdata. Puppet can use these external facts in the way as any other […]
Read More
You can query the PuppetDB API to identify puppet environments, modules, and classes that are no longer being used. This is handy for housekeeping purposes.
Read More
The latest version of PE 2016.4 has the capability to monitor the heap memory as a feature of puppet server 2.6. https://docs.puppet.com/puppetserver/2.6/status-api/v1/services.html#example-request-and-response-for-a-debug-level-get-request this guide: https://puppet.com/blog/puppet-server-advanced-memory-debugging https://docs.puppet.com/pe/latest/install_multimaster.html https://support.puppet.com/hc/en-us/articles/225049688 https://docs.puppet.com/puppetserver/latest/tuning_guide.html#number-of-jrubies Thundering herd test: After you’ve added hundreds of nodes to your deployment you may notice that your agents are running slow or […]
Read More
This is a script I wrote that queries the ec2 tags of an aws console, in order to figure out what environment a node belongs to, and what class to assign to it. #!/bin/bash # https://docs.puppetlabs.com/guides/external_nodes.html # http://docs.aws.amazon.com/cli/latest/userguide/cli-chap-getting-started.html export AWS_ACCESS_KEY_ID=xxxxxxxxxxxxxxxxxxxxxx export AWS_SECRET_ACCESS_KEY=xxxxxxxxxxxxxxxxxxxxxx export AWS_DEFAULT_REGION=xxxxxxx instanceid=`echo $1 | awk -F”_” ‘{print […]
Read More
Exported Resources https://docs.puppet.com/puppet/latest/reference/lang_collectors.html https://docs.puppet.com/pe/latest/node_deactivation.html querying puppetdb with postgres command line, psql psql -h localhost -U puppetdb puppetdb However to connect to puppet enterprise’s puppetdb, then follow: https://gist.github.com/tnolet/7133083 \q \h \l \d select * FROM catalog_resources \X \x SELECT * FROM catalog_resourcesSELECT * FROM factsselect * from factsssselect * from reports […]
Read More
http://docs.puppetlabs.com/puppetdb/latest/ https://github.com/spotify/puppetexplorer
Read More
The fastest way to learn Puppet is to get a full picture of the puppet infrastrucutre. The best way to do to this is if you have a story (aka narrative) to follow along that starts from the puppet basics to the advanced stuff. When you learn something new about […]
Read More
https://programmaticponderings.wordpress.com/tag/virtualbox/
Read More
the rake’s spec command does is comprised of the following: spec = spec_prep + spec_standalone + spec_clean So we need to avoid running spec_clean. To do this simply run: $ bundle exec rake spec_prep After that, always run $ bundle exec rake spec_standalone Instead of the “spec” command
Read More