ROCKETMQ stand-alone construction

Source: Internet
Author: User
Tags nameserver

ROCKETMQ is the Alibaba open source message queue.

This article is using the open source version v3.18

System: centos6.x Minimized installation

Required Packages:

Jdk-7u67-linux-x64.tar.gz

Alibaba-rocketmq-3.1.8.tar.gz

Start installation

#tar xvf jdk-7u67-linux-x64.tar.gz -C /opt/#tar xvf alibaba-rocketmq-3.1.8.tar.gz -C /opt/#ln -s /opt/jdk1.7.0_67 /opt/jdk

Configuring Environment variables

Last added in/etc/profile

export JAVA_HOME=/opt/jdkexport ROCKETMQ_HOME=/opt/alibaba-rocketmqexport PATH=$JAVA_HOME/bin:$ROCKETMQ_HOME/bin:$PATH

Make variables effective

source /etc/profile

Validating Java

# java -versionjava version "1.7.0_67"Java(TM) SE Runtime Environment (build 1.7.0_67-b01)Java HotSpot(TM) 64-Bit Server VM (build 24.65-b04, mixed mode)

Execute permissions for the following commands

#cd /opt/alibaba-rocketmq/bin/;chmod +x mqadmin mqbroker mqfiltersrv mqshutdown  mqnamesrv

Start nameserver

#nohup  mqnamesrv >/var/log/ns.log &

Verify that NameServer is started

# tail -f /var/log/ns.logThe Name Server boot success.

Start broker

You need to specify a nameserver address before starting Borker

#export NAMESRV_ADDR=Your_name_IP:9876#nohup mqbroker >/var/log/mq.log &

Verify that Mqbroker is started

# tail -f /var/log/mq.logThe broker[Your_hostname, Your_IP:10911] boot success. and name server is Your_IP:9876

Finally configure the firewall

NameServer Port is 9876

Broker Port is 10911

lokkit -p 9876:tcp -p 10911:tcp

Close NameServer Broker

#mqshutdown namesrv#mqshutdown broker

This ROCKERMQ installation is complete.

ROCKETMQ stand-alone construction

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.