Chinaunix首页 | 论坛 | 博客
  • 博客访问: 7399274
  • 博文数量: 1756
  • 博客积分: 18684
  • 博客等级: 上将
  • 技术积分: 16232
  • 用 户 组: 普通用户
  • 注册时间: 2010-06-02 10:28
个人简介

啥也没写

文章分类

全部博文(1756)

文章存档

2024年(2)

2023年(44)

2022年(39)

2021年(46)

2020年(43)

2019年(27)

2018年(44)

2017年(50)

2016年(47)

2015年(15)

2014年(21)

2013年(43)

2012年(143)

2011年(228)

2010年(263)

2009年(384)

2008年(246)

2007年(30)

2006年(38)

2005年(2)

2004年(1)

分类: LINUX

2012-06-19 17:25:13

安装rabbitmq
wget -O /etc/yum.repos.d/epel-erlang.repo
yum install erlang git -y

wget
rpm -ivh rabbitmq-server-2.8.2-1.noarch.rpm

启用插件:
rabbitmq-plugins enable mochiweb rabbitmq_management rabbitmq_management_agent rabbitmq_mochiweb webmachine amqp_client rabbitmq_stomp

启动服务:
/etc/init.d/rabbitmq-server start

管理页面
guest:guest

添加MC用户:
rabbitmqctl add_user mcollective akin
rabbitmqctl set_permissions -p / mcollective "^amq.gen-" ".*" ".*"


安装MC2.0
gem install stomp

git clone git://github.com/puppetlabs/marionette-collective.git
cd marionette-collective
git checkout 2.1.0
rake rpm

cd /usr/src/redhat/RPMS/noarch
rpm -ivh mcollective-common-2.1.0-1.el5.noarch.rpm
rpm -ivh mcollective-2.1.0-1.el5.noarch.rpm
//大家可以直接可以下载RPM的包,是一样的,


puppet client安装mc server
配置如下:
vi /etc/mcollective/server.cfg
topicprefix = /topic/
main_collective = mcollective
collectives = mcollective
libdir = /usr/libexec/mcollective
logfile = /var/log/mcollective.log
loglevel = info
daemonize = 1

# Plugins
securityprovider = psk
plugin.psk = unset

connector = stomp
plugin.stomp.host = localhost
plugin.stomp.port = 61613
plugin.stomp.user = mcollective
plugin.stomp.password = akin

# Facts
factsource = yaml
plugin.yaml = /etc/mcollective/facts.yaml


puppet server端安装mc client:(当然可以两个都安装,配置同上)
cat /etc/mcollective/client.cfg 
topicprefix = /topic/
main_collective = mcollective
collectives = mcollective
libdir = /usr/libexec/mcollective
logger_type = console
loglevel = warn

# Plugins
securityprovider = psk
plugin.psk = unset

connector = stomp
plugin.stomp.host = 192.168.14.11
plugin.stomp.port = 6313
plugin.stomp.user = mcollective
plugin.stomp.password = akin

# Facts
factsource = yaml
plugin.yaml = /etc/mcollective/facts.yaml

启动:
/etc/init.d/mcollective start

测试:
[root@akin puppet]# mco ping
akin2.com                                time=69.73 ms
akin.com                                 time=72.82 ms


---- ping statistics ----
2 replies max: 72.82 min: 69.73 avg: 71.27 
You have new mail in /var/spool/mail/root
[root@akin puppet]# mco find
akin2.com
akin.com

阅读(1048) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~