📅  最后修改于: 2020-12-26 12:43:19             🧑  作者: Mango
Ansible和Puppet正在迅速成为管理大量服务器的必备组件。它们通常称为配置管理和远程执行工具。
这些超级有用的应用程序使管理员可以同时在多台服务器上执行操作,并单击一下即可部署多个应用程序。它使配置和维护数千台服务器变得更加容易。在继续前,先看一下Ansible和木偶。
Ansible是一个开源IT引擎,可自动执行应用程序部署,云供应,内部服务编排和其他IT工具。
Ansible易于部署,因为它在客户端不使用任何代理程序或自定义安全性基础结构,而无需通过将模块推送到客户端。这些模块在客户端本地执行,并将输出推回Ansible服务器。
它可以使用SSH密钥轻松连接到客户端,从而简化了整个过程。客户端详细信息(例如主机名或IP地址和SSH端口)存储在文件中,这些文件称为清单文件。如果您创建并填充了清单文件,则Ansible可以使用它。
Ansible使用剧本来描述自动化作业,使用剧本来使用简单的语言,即YAML 。 YAML是一种人类可读的数据序列化语言,通常用于配置文件,但可以在存储数据的许多应用程序中使用。
一个显着的优势是,即使是IT基础结构支持人员也可以阅读和理解该手册,并在需要时进行调试。
Ansible专为多层部署而设计。 Ansible不会一次管理一个系统,而是通过描述所有系统相互关联来对IT基础架构进行建模。 Ansible完全没有代理,这意味着Ansible通过SSH (默认情况下)连接节点来工作。如果需要其他连接方法(例如Kerberos), Ansible将为您提供选择。
Puppet是一种配置管理工具,用于配置,部署和管理服务器。它还执行以下功能,例如:
Puppet使用主从结构,其中主服务器和从服务器在SSL的帮助下通过安全的加密通道进行通信。
以下是Ansible和Puppet之间的一些主要区别:
Parameters | Ansible | Puppet | |
---|---|---|---|
Availability | Ansible runs with a single active node, called the Primary instance. If the primary goes down, there is a Secondary instance to take its place. | Puppet has multi-master architecture. If the active master goes down, then the other master takes the active master place. | |
Easy to setup | Ansible has only a master running on the server machine, but no agents running on the client machine. It uses an SSH connection to log in to client systems or the nodes you want to configure. Client machine VM requires no unique setup. That’s why it is faster to setup! | Puppet also has a master-agent architecture. Puppet server runs on the master machine, and Puppet clients run as an agent on the client machine. After that, there is a certificate signing between the agent and the master. That’s why it is not that easy to setup. | |
Management | Easy to manage the configurations as it uses YAML (Yet Another Markup Language). The server pushes configurations to all the nodes. Suitable for real-time application, and there is immediate remote execution. | Puppet is not easy to manage the configurations as it uses its language called Puppet DSL. The client pulls the configurations from the Server. It is entirely system-administrator oriented, and there is non-immediate remote execution. | |
Configuration language | Ansible uses YAML (Python). It is quite easy to learn, and it is administrator oriented. Python is inbuilt into most Unix and Linux deployments, so setting the tool up and running is quicker. | Puppet uses its puppet Domain Specific Language (Puppet DSL). It is not easy to learn, and it is system administrator oriented. | |
Interoperability | The Ansible server has to be on Linux/Unix machine. As well as Ansible supports windows machines. | Puppet Master works only on Linux/Unix, but Puppet Agent also works on windows. | |
Pricing | The pricing for Ansible Tower for standard IT operations up to 100 nodes is $10,000 per year. This includes 8*5 support, whereas premium offers 24*7 support for $14000 per year. | The pricing for puppet ranges from $112 node per year with a standard support plan to $199 node per year with the premium plan. | |
GUI | Ansible was the command-line tool only at the time of its inception. Now it has the UI in the enterprise version, but it is not perfect. Sometimes, GUI is not in perfect sync with the Command line and not able to perform the same things like the command-line interface. | Puppet’s Graphical User Interface is more interactive than Ansible. It is used to manage, view, and monitor more complex tasks. Otherwise, there is an option of using a command-line interface too when need which is written in Ruby. |