ActiveMQ安装
来源:互联网 发布:java前端面试题 编辑:程序博客网 时间:2024/06/05 18:35
一、下载并安装
1.从http://activemq.apache.org/download.html页面中下载最新的ActiveMQ,选择自己的系统版本下载,这里我们演示的是Linux系统(自己装的虚拟机)的版本。
2.下载后将tar.gz包直接上传至服务器目录,并解压。因为是java编译的,所以只要系统安装了jdk配置好了环境变量,那么ActiveMQ只要解压完成就表名安装完成了,十分简单。
[activemq@localhost ~]$ lsapache-activemq-5.15.2-bin.tar.gz[activemq@localhost ~]$ tar -xvf apache-activemq-5.15.2-bin.tar.gz ......[activemq@localhost ~]$ lsapache-activemq-5.15.2 apache-activemq-5.15.2-bin.tar.gz[activemq@localhost ~]$ cd apache-activemq-5.15.2[activemq@localhost apache-activemq-5.15.2]$ lsactivemq-all-5.15.2.jar bin conf data docs examples lib LICENSE NOTICE README.txt webapps webapps-demo[activemq@localhost apache-activemq-5.15.2]$
二、启动并运行
1.进入安装目录的bin下,使用命令./activemq start启动(需要确保jdk已安装,环境变量已配置,不再赘述)
[activemq@localhost apache-activemq-5.15.2]$ java -versionjava version "1.8.0_131"Java(TM) SE Runtime Environment (build 1.8.0_131-b11)Java HotSpot(TM) 64-Bit Server VM (build 25.131-b11, mixed mode)[activemq@localhost apache-activemq-5.15.2]$ ll总用量 17756-rwxr-xr-x. 1 activemq activemq 18098716 10月 17 07:25 activemq-all-5.15.2.jardrwxrwxr-x. 5 activemq activemq 4096 12月 5 23:12 bindrwxr-xr-x. 2 activemq activemq 4096 12月 5 23:12 confdrwxr-xr-x. 2 activemq activemq 4096 12月 5 23:12 datadrwxr-xr-x. 2 activemq activemq 4096 12月 5 23:12 docsdrwxr-xr-x. 7 activemq activemq 4096 10月 17 07:28 examplesdrwxr-xr-x. 6 activemq activemq 4096 12月 5 23:12 lib-rw-r--r--. 1 activemq activemq 40580 10月 17 07:28 LICENSE-rw-r--r--. 1 activemq activemq 3334 10月 17 07:28 NOTICE-rw-r--r--. 1 activemq activemq 2610 10月 17 07:28 README.txtdrwxr-xr-x. 6 activemq activemq 4096 12月 5 23:12 webappsdrwxrwxr-x. 3 activemq activemq 4096 12月 5 23:12 webapps-demo[activemq@localhost apache-activemq-5.15.2]$ cd bin[activemq@localhost bin]$ lsactivemq activemq-diag activemq.jar env linux-x86-32 linux-x86-64 macosx wrapper.jar[activemq@localhost bin]$ ./activemq startINFO: Loading '/home/activemq/apache-activemq-5.15.2//bin/env'INFO: Using java '/usr/java/jdk1.8.0_131/bin/java'INFO: Starting - inspect logfiles specified in logging.properties and log4j.properties to get detailsINFO: pidfile created : '/home/activemq/apache-activemq-5.15.2//data/activemq.pid' (pid '3314')[activemq@localhost bin]$
2.ActiveMQ默认采用61616端口提供JMS服务,使用8161端口提供管理台服务,所以可以通过查看端口检测服务是否正常启动。
[activemq@localhost bin]$ netstat -ano | grep 61616tcp 0 0 :::61616 :::* LISTEN off (0.00/0/0)[activemq@localhost bin]$ netstat -ano | grep 8161tcp 0 0 :::8161 :::* LISTEN off (0.00/0/0)[activemq@localhost bin]$ ps -ef | grep activemqroot 2809 2768 0 22:59 pts/1 00:00:00 su - activemqactivemq 2810 2809 0 22:59 pts/1 00:00:00 -bashroot 2902 2098 0 23:01 ? 00:00:00 sshd: activemq [priv]activemq 2906 2902 0 23:01 ? 00:00:00 sshd: activemq@nottyactivemq 2907 2906 0 23:01 ? 00:00:00 /usr/libexec/openssh/sftp-serveractivemq 2921 2906 0 23:02 ? 00:00:00 /usr/libexec/openssh/sftp-serveractivemq 3314 1 5 23:14 pts/1 00:00:07 /usr/java/jdk1.8.0_131/bin/java -Xms64M -Xmx1G -Djava.util.logging.config.file=logging.properties -Djava.security.auth.login.config=/home/activemq/apache-activemq-5.15.2//conf/login.config -Dcom.sun.management.jmxremote -Djava.awt.headless=true -Djava.io.tmpdir=/home/activemq/apache-activemq-5.15.2//tmp -Dactivemq.classpath=/home/activemq/apache-activemq-5.15.2//conf:/home/activemq/apache-activemq-5.15.2//../lib/: -Dactivemq.home=/home/activemq/apache-activemq-5.15.2/ -Dactivemq.base=/home/activemq/apache-activemq-5.15.2/ -Dactivemq.conf=/home/activemq/apache-activemq-5.15.2//conf -Dactivemq.data=/home/activemq/apache-activemq-5.15.2//data -jar /home/activemq/apache-activemq-5.15.2//bin/activemq.jar startactivemq 3370 2810 4 23:17 pts/1 00:00:00 ps -efactivemq 3371 2810 0 23:17 pts/1 00:00:00 grep activemq
3.直接通过浏览器登录管理台,地址是:http://ip:8161/admin/,用户名密码默认都是admin
这个管理端在以后可以提供可视化的管理
4.启动的时候可以指定日志:./activemq start > startup.log
三、关闭
1.可以使用命令./activemq stop
2.也可以使用ps -ef | grep activemq获取进程号,然后使用kill命令停止
阅读全文
0 0
- ActiveMq安装
- ActiveMQ安装
- ActiveMQ安装
- ActiveMQ 安装
- ActiveMQ安装
- ActiveMq安装
- ActiveMQ安装
- ActiveMQ安装
- ActiveMQ安装
- activemq安装
- ActiveMQ安装
- ActiveMQ安装
- ActiveMq安装
- 安装activemq
- 安装ActiveMQ
- 安装ActiveMQ
- ActiveMQ安装
- ActiveMQ安装
- sort()用法详解
- C++对拍程序写法(转)
- Unity敌人的AI
- LeetCode-007 Reverse Integer
- win xp 激活
- ActiveMQ安装
- 决策树实践学习
- 完全跨域的单点登录
- 前端HTML与CSS初步认识
- 部署Maven项目无法找到Maven管理的Jar包
- C语言实验——整数位
- 为学习网页布局打基础的CSS的单位和盒模型
- Linux下源码安装的配置(configure)步骤之--prefix
- solr 的安装配置