一、设置主机名
1
2
3
|
[root@puppet ~]# vi /etc/sysconfig/network
HOSTNAME=puppet.ewin.com
[root@puppet ~]#echo “10.99.1.30 puppet.ewp.com” >> /etc/hosts
|
二、安装Puppet
1、安装
1
2
3
|
[root@puppet ~]# rpm -ivh http://yum.puppetlabs.com/puppetlabs-release-el-6.noarch.rpm
[root@puppet ~]# yum install -y http://mirrors.163.com/centos/6/os/x86_64/Packages/rubygems-1.3.7-5.el6.noarch.rpm
[root@puppet ~]# yum install -y puppet-server-3.7.3
|
2、启动服务
1
2
3
|
[root@puppet ~]# service puppetmaster start
[root@puppet ~]# ps -ef | grep puppet
[root@puppet ~]# netstat -lnpt|grep 8140
|
3、防火墙
1
2
|
[root@puppet ~]# iptables -I INPUT -p tcp –dport 8140 -j ACCEPT
[root@puppet ~]# service iptables save
|
4、测试
1
2
3
4
5
6
7
8
|
[root@puppet ~]# puppet agent –server puppet.ewp.com –test
Info: Retrieving pluginfacts
Info: Retrieving plugin
Info: Caching catalog for puppet.ewp.com
Info: Applying configuration version ‘1438758233’
Notice: Finished catalog run in 0.12 seconds
[root@puppet ~]# puppet cert –list –all
+ “puppet.ewp.com” (SHA256) AC:DB:B2:8B:09:76:5F:AA:22:7A:1D:D2:F2:1B:25:71:D0:44:32:F0:64:C3:28:2D:6B:BC:CC:A7:F8:B9:EC:10 (alt names: “DNS:puppet”, “DNS:puppet.ewp.com”)
|
原创文章,作者:ItWorker,如若转载,请注明出处:https://blog.ytso.com/56265.html