This post is the second in a series on Live Management, new in Puppet Enterprise 2.0, a capability that lets you visually discover, clone, and manage resources across your entire deployment, all through the graphical interface (GUI). In the first post in this series we covered how to make quick changes across your infrastructure by browsing and cloning resources.
Once you have used the browsing and cloning capabilities to establish a desired configuration, the next step is to Puppetize your infrastructure by building a set of manifests. This process is covered in our Learning Puppet documentation.
After you are working with a fully Puppetized infrastructure, there are several other awesome capabilities available in Live Management that you will be able to take advantage of. These advanced tools are available under the links next to ‘Manage Resources’ at the top of the page: Control Puppet and Advanced Tasks.
Under Control Puppet, you can control the behavior of Puppet on clusters of nodes in your infrastructure. Under Advanced Tasks there are tools available to allow you to directly interact with MCollective, which we’ve incorporated into Puppet Enterprise to support Live Management.
Some background on MCollective before we dive in:
MCollective, also known as Marionette Collective, is a framework on which to build server orchestration or parallel job execution systems. Puppet Labs acquired this open source project in the Fall of 2010 from R.I. Pienaar (@ripienaar) who is now a part of our development team. With this release of PE 2.0 we’ve made it easy to use the greatest capabilities of MCollective through our GUI. It’s easy to extend the capabilities of MCollective yourself, either by installing agents written by members of the Puppet community, or by writing your own. These new agents will automatically have a GUI generated for them within Live Management. This process of extending MCollective and Live Management will be covered in the next post in this series.
Now, back to Live Management.
Clicking the ‘Control Puppet’ link takes you to a page where you can control various aspects of Puppet on your nodes.
Similar to the resource browsing and cloning functionality explored in Part 1 of
the series, you can select various subsets of your nodes in the left pane, using hostname searching or by querying the values of various facts. The commands you can perform on these nodes from the Control Puppet tab include:
- disable: This disables the daemonized Puppet agent on the selected nodes, so that no Puppet runs will occur until it has been re-enabled. This can be useful for periods where you want to test at-will changes (possibly made through the resource browsing and cloning functionality of Live Management) so that they will not be overwritten by Puppet.
- enable: The opposite of disable, this will re-enable the Puppet agent daemon on the selected nodes.
- last_run_summary: This command provides you with a summary of the most recent run of the Puppet agent on the selected nodes.
- runonce: Kicks off a puppet agent run on the selected nodes, regardless of whether one is scheduled (or whether the daemonized Puppet agent is even enabled). This can be useful to test recent changes to your Puppet manifests in a single run, without actually enabling the daemonized agent.
- status: Fetches the status of the Puppet daemon from the selected nodes—whether or not it’s enabled, if it’s currently in the middle of a run, and when Puppet was last run.
The Control Puppet tab operates by executing various commands over the MCollective messaging framework. The ‘Advanced Tasks’ link gives you direct control over MCollective agents, simple programs that contain actions to be executed on your nodes when they receive certain messages from MCollective. Clicking ‘Advanced Tasks’ will show you a list of all of the MCollective agents you currently have installed on your nodes.
In this example, we show the default agents that are accessible from Puppet Enterprise 2.0. Clicking the name of any given agent will show you its actions, which you can then execute on the currently selected set of nodes. Actions can be run by clicking their name, then clicking the ‘Run’ button that appears. If any input is required for the action, an input field will appear. Some of the agents that ship with Puppet Enterprise and can be controlled through the ‘Advanced Tasks’ tab include:
package: An agent for managing packages. This has various actions to check for updates, update packages, and more.
puppetral: Allows you to search for information about resources from Puppet’s resource abstraction layer. This is the agent that resource browsing and cloning uses under the hood.
rpcutil: A utility agent used by MCollective to collect various information about nodes. This includes information about the agents they have, their facts, and more.
service: An agent for controlling various services on your system (such as httpd, or Puppet and MCollective themselves). You can also use this agent to check the status of various services.
Any of these actions can be run on any cluster in your infrastructure quickly and easily through the Advanced Tasks pane, making this an exceptionally useful and powerful tool in your systems management. In the next post in this series, I’ll be covering how to add more MCollective agents to your infrastructure and get them to show up in Live Management.