https://activemq.apache.org/ 官网下载对应版本:
apache-activemq-5.16.3-bin.tar.gz
tar -xvzf apache-activemq-5.16.3-bin.tar.gz
mv apache-activemq-5.16.3 /usr/local
cd conf/
vim activemq.xml
在broker标签上添加schedulerSupport="true"属性。如下:
<broker xmlns="http://activemq.apache.org/schema/core" brokerName="localhost" dataDirectory="${activemq.data}">
把上面这行修改成下面这行
<broker xmlns="http://activemq.apache.org/schema/core" brokerName="localhost" dataDirectory="${activemq.data}" schedulerSupport="true">
jetty绑定ip和端口的配置
vim jetty.xml
找到如下行,配置对应IP地址和端口
<bean id="jettyPort" class="org.apache.activemq.web.WebConsolePort" init-method="start">
<!-- the default port number for the web console -->
<property name="host" value="172.20.144.14"/>
<property name="port" value="8161"/>
</bean>
jetty的账号和密码已经对应角色配置
vim jetty-realm.properties
# username: password [,rolename ...]
admin: admin, admin
user: user, user
activemq的用户配置
vim users.properties
dmin=admin
启动程序:
直接进入activemq目录:
cd /usr/local/apache-activemq-5.16.3/bin
然后进入对应系统架构对应的启动程序目录:
cd linux-x86-64
执行启动程序:
./activemq start
运行结果:开启了8161端口和61616端口。
[root@iZbp1fe4xZ conf]# ps -ef |grep java
root 12633 12631 0 Aug26 ? 00:01:32 java -Dactivemq.home=../.. -Dactivemq.base=../.. -Djavax.net.ssl.keyStorePassword=password -Djavax.net.ssl.trustStorePassword=password -Djavax.net.ssl.keyStore=../../conf/broker.ks -Djavax.net.ssl.trustStore=../../conf/broker.ts -Dcom.sun.management.jmxremote -Dorg.apache.activemq.UseDedicatedTaskRunner=true -Djava.util.logging.config.file=logging.properties -Dactivemq.conf=../../conf -Dactivemq.data=../../data -Djava.security.auth.login.config=../../conf/login.config -Xmx1024m -Djava.library.path=../../bin/linux-x86-64/ -classpath ../../bin/wrapper.jar:../../bin/activemq.jar -Dwrapper.key=FPdLEHaV0sEQvymP -Dwrapper.port=32000 -Dwrapper.jvm.port.min=31000 -Dwrapper.jvm.port.max=31999 -Dwrapper.pid=12631 -Dwrapper.version=3.2.3 -Dwrapper.native_library=wrapper -Dwrapper.service=TRUE -Dwrapper.cpu.timeout=10 -Dwrapper.jvmid=1 org.tanukisoftware.wrapper.WrapperSimpleApp org.apache.activemq.console.Main start
root 22691 22639 0 01:11 pts/0 00:00:00 grep --color=auto java
[root@iZbp1fe4xZ conf]# lsof -i:8161
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
java 12633 root 165u IPv6 52541 0t0 TCP iZbp1fek774yyhkay98k4xZ:patrol-snmp (LISTEN)
[root@iZbp1fe4xZ conf]# lsof -i:61616
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
java 12633 root 151u IPv6 51876 0t0 TCP *:61616 (LISTEN)
标签:教程,..,activemq,Dwrapper,conf,apache,root,安装
From: https://blog.51cto.com/lenglingx/6390778