CentOS用yum安装puppet
CentOS用yum安装puppet
公认的CentOS安装软件最快的是yum ,今天2011年3月31日我就用这个最快的安装RPM的工具安装下puppet,安装过程如下:
复制代码首先设置yum repositories
创建 puppet.repo
- cd /etc/yum.repos.d/
- vi puppet.repo
复制代码复制代码
在puppet.repo写入内容如下:
- [puppetlabs]
- name=Puppet Labs Packages
- baseurl=http://yum.puppetlabs.com/base/
- enabled=0
- gpgcheck=0
复制代码创建 epel.repo
- cd /etc/yum.repos.d/
- vi epel.repo
复制代码复制代码在epel.repo 写入内容如下:
- [epel]
- name=Extra Packages for Enterprise Linux 5 - $basearch
- #baseurl=http://download.fedoraproject.org/pub/epel/5/$basearch
- mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=epel-5&arch=$basearch
- failovermethod=priority
- enabled=0
- gpgcheck=0
复制代码
- [epel-puppet]
- name=epel puppet
- baseurl=http://tmz.fedorapeople.org/repo/puppet/epel/5/$basearch/
- enabled=0
- gpgcheck=0
复制代码创建ruby.repo
- cd /etc/yum.repos.d/
- vi ruby.repo
复制代码复制代码
在ruby.repo 写入内容如下:
- [ruby]
- name=ruby
- baseurl=http://repo.premiumhelp.eu/ruby/
- gpgcheck=0
- enabled=0
复制代码因为puppet的是用ruby语言写的,所以要第一个安装(系统里没有安装ruby的系统)域升级ruby:
- yum --enablerepo="ruby" install ruby
复制代码[上面为安装ruby命令]
下面是安装过程
[此处省略安装回显条目...]
- Dependencies Resolved
- ================================================================================
- Package Arch Version Repository Size
- ================================================================================
- Installing:
- ruby i686 1.8.6.111-1 ruby 525 k
- Installing for dependencies:
- ruby-libs i686 1.8.6.111-1 ruby 2.6 M
- Transaction Summary
- ================================================================================
- Install 2 Package(s)
- Upgrade 0 Package(s)
- Total download size: 3.1 M
- Is this ok [y/N]: y
- Downloading Packages:
- (1/2): ruby-1.8.6.111-1.i686.rpm | 525 kB 00:14
- (2/2): ruby-libs-1.8.6.111-1.i686.rpm | 2.6 MB 01:13
- --------------------------------------------------------------------------------
- Total 33 kB/s | 3.1 MB 01:35
- Running rpm_check_debug
- Running Transaction Test
- Finished Transaction Test
- Transaction Test Succeeded
- Running Transaction
- Installing : ruby-libs 1/2
- Installing : ruby 2/2
- Installed:
- ruby.i686 0:1.8.6.111-1
- Dependency Installed:
- ruby-libs.i686 0:1.8.6.111-1
- Complete!
复制代码复制代码查询ruby安装是否成功:
ruby --version
ruby 1.8.6 (2007-09-24 patchlevel 111) [i686-linux]
安装 Puppet Server:
yum --enablerepo=epel,epel-puppet install puppet-server
复制代码安装过程如下:
- [...]
- Setting up Install Process
- Resolving Dependencies
- --> Running transaction check
- ---> Package puppet-server.noarch 0:2.6.7-1.el5 set to be updated
- --> Finished Dependency Resolution
- Dependencies Resolved
- ================================================================================
- Package Arch Version Repository Size
- ================================================================================
- Installing:
- puppet-server noarch 2.6.7-1.el5 epel-puppet 20 k
- Transaction Summary
- ================================================================================
- Install 1 Package(s)
- Upgrade 0 Package(s)
- Total download size: 20 k
- Is this ok [y/N]: y
- Downloading Packages:
- puppet-server-2.6.7-1.el5.noarch.rpm | 20 kB 00:02
- Running rpm_check_debug
- Running Transaction Test
- Finished Transaction Test
- Transaction Test Succeeded
- Running Transaction
- Installing : puppet-server 1/1
- Installed:
- puppet-server.noarch 0:2.6.7-1.el5
- Complete!
复制代码显示puppet版本:
- # puppet --version
- 2.6.7
复制代码安装putpet 客户端:
- #yum --enablerepo="epel,epel-puppet" install puppet
复制代码复制代码
安装全部完成; puppet在CentOS5.5上测试成功,也适用于redhat RHEL
祝大家使用puppet愉快!
文章是我原创@-@!
参考http://www.craigdunn.org/2010/08 ... centos-with-yumrpm/
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论