zoukankan      html  css  js  c++  java
  • openstack controller ha测试环境搭建记录(五)——配置rabbitmq集群

    配置rabbitmq集群的步骤非常简单,因为其本身含集群功能,参考openstack官网文档:
    http://docs.openstack.org/ha-guide/controller-ha-rabbitmq.html


    在所有节点安装rabbitmq:
    # yum install -y rabbitmq-server


    在所有节点设置rabbitmq开机启动:
    # systemctl enable rabbitmq-server.service
    # systemctl start rabbitmq-server.service


    关闭所有节点的rabbitmq服务:
    # systemctl stop rabbitmq-server.service


    在节点1,拷贝cookie至其它节点:
    # scp /var/lib/rabbitmq/.erlang.cookie root@controller2:/var/lib/rabbitmq/.erlang.cookie
    # scp /var/lib/rabbitmq/.erlang.cookie root@controller3:/var/lib/rabbitmq/.erlang.cookie


    在所有节点启动rabbitmq服务:
    # systemctl start rabbitmq-server.service


    在节点2、节点3,加入节点1的集群:
    # rabbitmqctl stop_app
    Stopping node rabbit@controller2...
    ...done.
    # rabbitmqctl join_cluster rabbit@controller1
    # rabbitmqctl start_app
    Starting node rabbit@controller2 ...
    ...done.


    在任意节点验证集群状态:
    # rabbitmqctl cluster_status
    Cluster status of node rabbit@controller1 ...
    [{nodes,[{disc,[rabbit@controller1,rabbit@controller2,rabbit@controller3]}]},
    {running_nodes,[rabbit@controller3,rabbit@controller2,rabbit@controller1]},
    {cluster_name,<<"rabbit@controller1">>},
    {partitions,[]}]
    ...done.


    在任意节点执行HA策略设置:
    # rabbitmqctl set_policy ha-all '^(?!amq.).*' '{"ha-mode": "all"}'


    在任意节点设置密码:
    # rabbitmqctl change_password guest 123456

    -----------------------------------------------------------------------------------

    以下组件或服务以高可用队列(HA queues)的方式工作:
    OpenStack Compute
    OpenStack Block Storage
    OpenStack Networking
    Telemetry

  • 相关阅读:
    Android自定义之ScrollView下拉刷新
    android Viewpager取消预加载及Fragment方法的学习
    Android上下左右滑动,显示底层布局
    android权限大全
    android学习之VelocityTracker
    Android之自定义(上方标题随ViewPager手势慢慢滑动)
    Red Hat Enterprise Linux 7.5安装极点五笔
    Red Hat Enterprise Linux 7.5安装盘内容做本地YUM源
    RHEL7+Oracle11g笔记
    CentOS安装VNC方法
  • 原文地址:https://www.cnblogs.com/endoresu/p/5043363.html
Copyright © 2011-2022 走看看