Basic Learning for Puppet
1. view official download sources
Https://docs.puppet.com/guides/puppetlabs_package_repositories.html
2. Select the download source for the corresponding system
Because the local machine is CentOS 7.1, select the YUM Source
Https://yum.puppetlabs.com/
3. Install Puppet
# Wget https://yum.puppetlabs.com/puppetlabs-release-el-7.noarch.rpm
# Rpm-ivh puppetlabs-release-el-7.noarch.rpm
client
Puppet agent -- server cahoa.linux.net -- Test -- verbose -- debug -- no-daemonize
# Apply for authentication from the server, obtain files, enable verbose, debug, and re-output information # redirect to Console mode (no-daemonize)
8. You can see that the above command is run, and the final output is:
Exiting; no certificate found and waitforcert is disabled
The
Tags: des style http io ar OS sp for strongLearning Puppet-Resource OrderingLearn about dependencies and refresh events, manage the relationships between resources, and discover the fundamental Puppet design pattern.DisorderLet's look back on one of our manifests from the last page:[[Email protected] manifests] # vim site. pp[[Email protected] manifests] # cat site. ppImport 'order. PP'[[Email p
First, installation environmentRequires two computers or virtual machines; one is server and one is client; the configuration is as follows:Cat/etc/hosts127.0.0.1 localhost.localdomain localhost192.168.*.200 server.example.com Server192.168.*.180 client.example.com ClientNote: The host name must be a combination of letters and numbers, no special symbols such as _;Note: All hosts require clock synchronizationYum Install NTPChkconfig NTP onNtpdate pool.ntp.orgNote: Configure the Epel sourceRPM-IV
1.Puupet Introduction
Puppet is an open source automation configuration and Deployment tool, Puppet is based on the C/S architecture, the server is called Puppet Master, the client software is called Puppet Agent,puppet The maste
/autosign.conf*.hnr.com2. Modify fileserver.confgrant to this file /etc/puppet/files permissions for the directory# vi/etc/puppet/fileserver.conf[Files]Path/etc/puppet/filesAllow *.hnr.comFour, Puppet Agent Client Configuration1. increase the listening and specifying the ser
10 seconds, detects the service side, and updates.Then the puppet service is re-moved/etc/init.d/puppet restartFour SSL-generated certificatesManual:On the clientPuppet Agent--test--server=master.liuwenzhi.comView and sign-off certificate on the service sidePuppet cert list--all(There is no sign of the + sign in front of you)Sign OrderPuppet cert--sign Slave.liu
In the production environment, the puppet update needs the node to update automatically, there is need to push the update through the puppetmaster, and the node update time is discrete. Here are three ways to update
2.7 Puppet update mode
2.7.1 Node Timing update
[Root@agent1 ~]# vim/etc/puppet/puppet.conf
[Main]
Server=puppetserver.rsyslog.org #指向puppetserv
=present, #要求setup这个包处于安装状态5 }6file{'/ETC/MOTD':#定义file资源7ensure =present, #要求文件存在8Owner ='Root',#要求file属主为root9Group ='Root',#要求file属组为rootTenmode ='0644', OneSource ="PUPPET:///MODULES/MOTD/ETC/MOTD",#文件在服务器上的位置 Arequire = package['Setup'], #要求文件在被配置之前执行package资源 - } -}The following is a brief description:Require is a meta-parameter that ensures that the package resource executes before the file is configured,Under the instructions source, tell
env.ppAfter installing java , you also need to configure environment variables such as JAVA_HOMD for Tomcat to run, so you need to create a configuration file to set the environment variablesVim/etc/puppet/modules/java7/manifests/env.ppclassjava7::env {File {"/usr/java/env":Owner = "Root",Group = "Root",Source = "Puppet:///modules/java7/env"}exec {"Set env": #set java_homeCommand = "Cat/usr/java/env>>/etc/
; proxy_temp_file_write_size 10 m; proxy_read_timeout 120;} In Nginx. add the following code to the conf configuration file. Upstream puppetmaster {server 127.0.0.1: 18140; server 127.0.0.1: 18141; server 127.0.0.1: 18142; server 127.0.0.1: 18143; server 127.0.0.1: 18144;} include vhosts. conf; 6. Verify the configuration and restart the puppetmaster and nginx services: [root @ 192-9-117-162 ~] #/Etc/init. d/puppetmaster restart;/usr/local/nginx/sbin/nginx stop puppetmaster: Port: 18140 [failed]
How the puppet client cancels the active updateRunintervalHow often puppet agent applies the client configuration, in seconds. Note that a runinterval of 0 means "run continuously" rather than "never run." If you want puppet agent to Never run, you should start it with the--
Dashboard is the puppet console for displaying information about puppet Master and puppet agents. This article provides Web services with the default Webrick. DashBoard installed in master.test.com. And in the client configuration file do the following configuration#vim/etc/puppet/puppet.conf[
PuppetFeatures and introduction: Batch management and deployment for multiple serversRequired Package: facter-1.6.18.tar.gz puppet-2.7.22.tar.gz (Facter package is Puppet's dependent package)Steps:server-ip:192.168.13.54 Domain name www.wyx1.comclient-ip:192.168.13.55 Domain name www.wyx2.comServerIptables-fSetenforce 0Hostname www.wyx1.comVim/etc/hosts192.168.13.54 www.wyx1.com192.168.13.55 www.wyx2.com1. Time synchronization, and write crontab, serv
Tag: Puppet Apache modules class node regular expression => creating the httpd Base module #mkdir/etc/puppet/modules/httpd/{files,manifests,templates}-pv# tree/etc/puppet/modules/httpd//etc/puppet/modules/httpd/├──files//the configuration file called by the base module, The agent
First, IntroductionBy installing and deploying the Puppet/C/S model, puppet server manages the entire lifecycle of all the controllers: from initialization to software upgrades, from profile creation to test deployment, from system maintenance to server migrations, and more. Puppet is able to continuously interact with the controlled machine to enable timely dete
Tags: puppet push pullSSH by default using the Tcp22 port, in order to protect the Linux 22-side xxx break, we sometimes need to change the port of SSH, however, in the enterprise environment, the number of servers is huge, one can imagine the workload modification. The use of puppet can be a good solution to such problems, for operations and maintenance personnel to alleviate the burden of work.The case to
---restore content starts---1. Introduction1.1. Official website: https://docs.puppet.com/1.2. Puppet is an IT Infrastructure automation management tool whose entire life cycle includes: provisioning,configuration,orchestration,reporting1.3. Puppet is a master/agent model, but the agent can perform the operation indepe
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.