目录
linux 安装
1.下载二进制安装包到~目录下
2.解压
unzip rocketmq-all-4.4.0-bin-release.zip
3.RocketMQ默认分配的JVM内存比较大,而虚拟机没有那么大的配置,会导致broker启动失败, 所以需要依次修改下面两个文件
3.1 # /bin/runbroker.sh
JAVA_OPT="${JAVA_OPT} -server -Xms256m -Xmx256m -Xmn128m
3.2 # /bin/runserver.sh
JAVA_OPT="${JAVA_OPT} -server -Xms256m -Xmx256m -Xmn128m -XX:MetaspaceSize=128m -XX:MaxMetaspaceSize=320m"
4.启动
# 1.启动NameServer
nohup sh bin/mqnamesrv &
# 2.查看启动日志
tail -f ~/logs/rocketmqlogs/namesrv.log
# 3.启动Broker
nohup sh bin/mqbroker -n localhost:9876 &
# 4.查看启动日志
tail -f ~/logs/rocketmqlogs/broker.log
验证启动成功:
官网:
标签:bin,OPT,RockerMQ,启动,sh,Xmn128m,JAVA From: https://www.cnblogs.com/czzz/p/16630530.html