[puppet for automated operation and maintenance]

Puppet is a centralized configuration management system for Linux, Unix, and Windows platforms. It uses its own puppet description language to manage configuration files, users, cron tasks, software packages, and system services. puppet refers to these system entities as resources. The design goal of puppet is to simplify the management of these resources and properly handle the dependencies between resources.



 

Puppet adopts a C/S star structure, and all clients interact with one or several servers. Each client periodically (half an hour by default) sends a request to the server to obtain its latest configuration information and ensure synchronization with the configuration information. Each puppet client connects to the server every half an hour (can be set), downloads the latest configuration file, and configures the client strictly according to the configuration file. After the configuration is completed, the puppet client can feedback a message to the server. If there is an error , will also send a message back to the server.

 

 

One of the biggest differences between puppet and other manual operation tools is that puppet's configuration is stable, so you can execute puppet multiple times. Once you update your configuration file, puppet will change your machine configuration according to the configuration file, usually Check every 30 minutes. puppet will keep your system state consistent with the state required by the configuration file. For example, your configuration file requires that the ssh service must be enabled. If the ssh service is accidentally disabled, the next time you execute puppet , puppet will find this exception, and then start the ssh service. In order to make the system state and configuration file consistent. Puppet is like a magician, which will make your messy system converge to the desired state of the puppet configuration file.



 

 

 

You can use puppet to manage the entire life cycle of servers, from initialization to decommissioning. Unlike traditional methods such as sun's Jumpstart or redhat's Kickstart, puppet can keep servers up-to-date for many years. Just configure them correctly at the beginning, and then Leave them alone. Usually puppet users just need to install puppet on their machines and let them run, and puppet does the rest.

 

 

principle:



 

1) The client collects client information through facter and sends it to the server

2) Connect to the server and request the catalog log

3) Request node (node) information

4) Receive an instance of a node from the server

5) Compile the code (including syntax checking, etc.)

6) Query whether there are exported virtual resources

7) Receive virtual resource from database, if any

8) Receive complete catalog log

9) Store the catalog log to the database

10) The client receives the complete catalog log

 

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326688013&siteId=291194637