Home PC Games Linux Windows Database Network Programming Server Mobile  
           
  Home \ Server \ Analysis RabbitMQ cluster     - After restarting network services, DNS address failure (Linux)

- 10 useful tools for Linux users (Linux)

- Linux kernel source code analysis (Linux)

- iOS in the event delivery and the responder chain (Programming)

- Java how to achieve bubble sort the problem Arraylist (Programming)

- MySQL error: ERROR 1175: You are using safe update mode solution (Database)

- Rely on IP chain established Linux firewall (Linux)

- IntelliJ IDEA run in Mac10.9 and JDK7 environment (Linux)

- MySQL Error Code Complete (Database)

- Java generate two-dimensional code by Zxing (Programming)

- Java and Python use make way dictionary word search script (Programming)

- df show disk space usage (Linux)

- Visual Studio Code experience (Linux)

- CentOS6 installed Tomcat (Server)

- Windows Desktop use VNC remote connect Linux (Linux)

- blecat: Bluetooth Gadgets (Linux)

- Build their own recursive DNS server (Server)

- VNC connection VMware vSphere ESXi 5.5 (Linux)

- Linux system started to learn: Teaches you install Fedora 22 on VirtualBox (Linux)

- Configure the ASM process on Red Hat Linux 6.5 (Database)

 
         
  Analysis RabbitMQ cluster
     
  Add Date : 2018-11-21      
         
         
         
  1.1 base installation

Character

IP address

CPU name

MQ version

Master

192.168.103.83

rabbit-jxs-10383

3.5.2-1

slave

192.168.103.84

rabbit-jxs-10384

3.5.2-1

1) Configure yum source (Master / slave configured)

yum -y install epel-release

1) Install erlang (Master / slave configured)

Yum -y install erlang

http://www.rabbitmq.com/releases/rabbitmq-server/v3.5.2/rabbitmq-server-3.5.2-1.noarch.rpm

2) Install RabbitMQ (Master / slave configured)

rpm -vih rababitmq-server-3.5.2-1.noarch.rpm

3) modify the hostname

a) Hostname rabbit-jxs-10383 #slave

b) Vim / etc / sysconfig / network

• Hostname = rabbit-jxs-10383

c) Vim / etc / hosts (Master / slave configured)

• 192.168.103.83 rabbit-jxs-10383

• 192.168.103.84 rabbit-jxs-10384

1.2 MQ Master Configuration

d) MQ WEB configuration

• [rabbitmq_management, rabbitmq_management_agent].

e) MQ Service Configuration

[Root @ rabbit-jxs-10383 rabbitmq] # cat rabbitmq.conf

% This file managed by Puppet

% Template Path: rabbitmq / templates / rabbitmq.config

[

{Rabbit, [

{Default_user, << "autohome" >>},

{Default_pass, << "! S7 CUy3lZ5; _ [K" >>},

{Tcp_listeners, [5672]},

{Cluster_partition_handling, ignore}

]},

{Kernel, [

]}

].

% EOF

f) MQ environment variable configuration

[Root @ rabbit-jxs-10383 rabbitmq] # cat rabbitmq-env.conf

RABBITMQ_NODE_PORT = 5672

MNESIA_BASE = / data / rabbitmq / data

LOG_BASE = / data / rabbitmq / log

g) MQ to create the directory

• Mkdir / data / rabitmq / data -p

• Mkdir / data / rabbitmq / log -p

• Chown rabbitmq: rabbitmq / data / rabbitmq -R

h) MQ start service

• Service rabbitmq-serve restart

• Chkconfig rabbitmq-server on

i) MQ listener port

[Root @ rabbit-jxs-10383 rabbitmq] # netstat -tnpl | grep 567

tcp 0 0 0.0.0.0:5672 0.0.0.0:* LISTEN 10020 / beam.smp

tcp 0 0 0.0.0.0:25672 0.0.0.0:* LISTEN 10020 / beam.smp

tcp 0 0 0.0.0.0:15672 0.0.0.0:* LISTEN 10020 / beam.smp

[Root @ rabbit-jxs-10383 rabbitmq] #

4) MQ slave configuration service

a) Synchronous Master RabbitMQ file configuration

• Scp -p 30000 192.168.103.83:/etc/rabbitmq/* / etc / rabbitmq /

• Chown rabbitmq: rabbitmq -R / etc / rabbitmq /

b) MQ Create a working directory

• Mkdir / data / rabbitmq / data -p

• Mkdir / data / rabbitmq / log -p

• Chown rabbitmq: rabbitmq -R / data / rabbitmq

c) Synchronization Master Rabbitmq .erlang.cookie

• Scp -p 30000 192.168.103.83:/var/lib/rabbitmq/.erlang.cookie ./var/lib/rabbitmq/

• Chown rabbitmq: rabbitmq / var / lib / rabbitmq

d) start MQ slave service

1.Service rabbitmq-server restart

2.chkconfig rabbitmq on

1.3 MQ cluster configuration (Mater operation)

e) Stop Master MQ

• rabbitmqctl stop_app

f) Clear Master MQ information

• rabbitmqctl reset

g) was added to the 10384 MQ cluster

• rabbitmqctl join_cluster rabbit @ rabbit-jxs-10384

h) Start MQmaster service

• rabbitmqctl start_app

i) Check status

[Root @ rabbit-jxs-10383 ~] # rabbitmqctl cluster_status

Cluster status of node 'rabbit @ rabbit-jxs-10383' ...

[{Nodes, [{disc, [ 'rabbit @ rabbit-jxs-10383', 'rabbit @ rabbit-jxs-10384']}]},

{Running_nodes, [ 'rabbit @ rabbit-jxs-10384', 'rabbit @ rabbit-jxs-10383']},

{Cluster_name, << "rabbit @ rabbit-jxs-10383" >>},

{Partitions, []}]

1.4 MQ follow-up

1) Create an administrative user Rabbit

a) rabbitmqctl add_user admin admin

2) give the user permissions

a) rabbitmqctl set_user_tags admin administrator

3) MQ mirroring

a) rabbitmqctl set_policy ha-all "^" '{ "ha-mode": "all"}'

4) complete MQ configuration

a) http://192.168.103.84:15672
     
         
         
         
  More:      
 
- Linux RPM default installation path (Linux)
- MySQL5.7 implement virtual column expression index (Database)
- Ubuntu 14.04 How to install Cinnamon 2.4.5 (Linux)
- How to Install Android Studio on Ubuntu 15.04 / CentOS7 (Linux)
- Oracle Data Guard LOG_ARCHIVE_DEST_n optional attribute parameters (Database)
- How to use scientific data Docker quickly configure the development environment (Server)
- MySQL DATE_FORMAT () function (Database)
- To install Xen in Ubuntu 12.04 (Linux)
- FileZilla 3.10.1.1 install on Ubuntu 14.10 (Linux)
- Python extension module Ganglia 3.1.x (Linux)
- ORA-04091 and Compound Trigger (Oracle 11g) (Database)
- Install mono offline on CentOS (Server)
- httpd-2.4 feature (Server)
- PostgreSQL vacuum principle of a function and parameters (Database)
- Bash environment is automatically install and initialize oh-my-zsh & autojump zsh (Linux)
- C ++ thread creates transmission parameters are changed (Programming)
- Storm how to ensure that at least once semantics (Programming)
- Oracle table of nested loop connection (Database)
- Lua4.0 interpreter documents (Programming)
- Apache Tomcat integration and resin (Server)
     
           
     
  CopyRight 2002-2022 newfreesoft.com, All Rights Reserved.