ActiveMq工作笔记001---Centos7.3安装ActiveMq

版权声明:本文为博主原创文章,未经博主credreamer 允许不得转载 违者追究法律责任。 https://blog.csdn.net/lidew521/article/details/88893694

技术交流QQ群【JAVA,.NET,BigData,AI】:170933152

很简单,先安装jdk,然后下载,解压,启动,访问ok

下载:

[root@localhost usr]# wget http://archive.apache.org/dist/activemq/5.14.5/apache-activemq-5.14.5-bin.tar.gz
--2019-03-29 21:45:50--  http://archive.apache.org/dist/activemq/5.14.5/apache-activemq-5.14.5-bin.tar.gz
Resolving archive.apache.org (archive.apache.org)... 163.172.17.199
Connecting to archive.apache.org (archive.apache.org)|163.172.17.199|:80... connected.
HTTP request sent, awaiting response... 302 Found
Location: http://59.80.44.98/archive.apache.org/dist/activemq/5.14.5/apache-activemq-5.14.5-bin.tar.gz [following]
--2019-03-29 21:45:50--  http://59.80.44.98/archive.apache.org/dist/activemq/5.14.5/apache-activemq-5.14.5-bin.tar.gz
Connecting to 59.80.44.98:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 54294367 (52M) [application/x-gzip]
Saving to: ‘apache-activemq-5.14.5-bin.tar.gz’

100%[=========================================================================================================================================>] 54,294,367  2.56MB/s   in 25s    

[root@localhost usr]# mv apache-activemq-5.14.5-bin.tar.gz /opt
[root@localhost opt]# cp apache-activemq-5.14.5-bin.tar.gz /usr/activemq

解压

[root@localhost activemq]# tar zxvf apache-activemq-5.14.5-bin.tar.gz 

重新命名,看着舒服: 

[root@localhost activemq]# mv apache-activemq-5.14.5 activemq

进入bin目录启动:

[root@localhost activemq]# cd activemq/
[root@localhost activemq]# ll
total 15888
-rwxr-xr-x 1 root root 16211254 Apr 11  2017 activemq-all-5.14.5.jar
drwxr-xr-x 5 root root      147 Mar 29 21:49 bin
drwxr-xr-x 2 root root     4096 Mar 29 21:49 conf
drwxr-xr-x 2 root root       26 Mar 29 21:49 data
drwxr-xr-x 2 root root       76 Mar 29 21:49 docs
drwxr-xr-x 7 root root       71 Apr 11  2017 examples
drwxr-xr-x 6 root root     4096 Mar 29 21:49 lib
-rw-r--r-- 1 root root    40580 Apr 11  2017 LICENSE
-rw-r--r-- 1 root root     3334 Apr 11  2017 NOTICE
-rw-r--r-- 1 root root     2610 Apr 11  2017 README.txt
drwxr-xr-x 6 root root       95 Mar 29 21:49 webapps
drwxr-xr-x 3 root root       18 Mar 29 21:49 webapps-demo

 启动吧:

[root@localhost bin]# ./activemq start
INFO: Loading '/usr/activemq/activemq//bin/env'
INFO: Using java '/lib/jvm/bin/java'
INFO: Starting - inspect logfiles specified in logging.properties and log4j.properties to get details
INFO: pidfile created : '/usr/activemq/activemq//data/activemq.pid' (pid '1447')
[root@localhost bin]# ps -ef|grep activemq
root       1447      1 86 23:02 pts/0    00:00:12 /lib/jvm/bin/java -Xms64M -Xmx1G -Djava.util.logging.config.file=logging.properties -Djava.security.auth.login.config=/usr/activemq/activemq//conf/login.config -Dcom.sun.management.jmxremote -Djava.awt.headless=true -Djava.io.tmpdir=/usr/activemq/activemq//tmp -Dactivemq.classpath=/usr/activemq/activemq//conf:/usr/activemq/activemq//../lib/: -Dactivemq.home=/usr/activemq/activemq/ -Dactivemq.base=/usr/activemq/activemq/ -Dactivemq.conf=/usr/activemq/activemq//conf -Dactivemq.data=/usr/activemq/activemq//data -jar /usr/activemq/activemq//bin/activemq.jar start
root       1490   1312  0 23:02 pts/0    00:00:00 grep --color=auto activemq
[root@localhost bin]# http://192.168.0.110:8161/admin/

浏览器测试:

http://192.168.136.110:8161/admin/

然后,admin admin 用户名密码

就进去了。

如果有防火墙的话,关闭一下防火墙,或者设置防火墙规则:

防火墙的设置添加8161和61616端口号:

firewall-cmd --zone=public --add-port=8161/tcp --permanent (--permanent永久生效,没有此参数重启后失效)

重新载入 firewall-cmd --reload

查看端口是否设置成功:firewall-cmd --zone=public --list-ports

9、最后验证结果输入http://ip地址:8161/admin   用户名:admin 密码:admin

猜你喜欢

转载自blog.csdn.net/lidew521/article/details/88893694
今日推荐