Ubuntu 安装emqttd

一、安装环境

系统:Ubuntu14.04 64位

参考:http://emqtt.io/docs/v2/install.html

安装包:链接: http://pan.baidu.com/s/1qYH6tsS 密码: v9e5

工具:MQTT Lens 链接: http://pan.baidu.com/s/1skBOxKL 密码: 9e4z

二、安装

1.下载Ubuntu的emqttd二进制包(与上面的安装包相同)

执行:wget http://emqtt.io/downloads/latest/ubuntu

结果:在当前目录下下载名为Ubuntu的压缩包

2.解压缩

执行:unzip ubuntu

结果:名为emqtt的目录被解压缩出来

3.以console模式启动emqttd

执行:cd emqttd && ./bin/emqttd console

结果:

starting emqttd on node 'emqttd@127.0.0.1'
emqttd ctl is starting...[ok]
emqttd hook is starting...[ok]
emqttd router is starting...[ok]
emqttd pubsub is starting...[ok]
emqttd stats is starting...[ok]
emqttd metrics is starting...[ok]
emqttd retainer is starting...[ok]
emqttd pooler is starting...[ok]
emqttd trace is starting...[ok]
emqttd client manager is starting...[ok]
emqttd session manager is starting...[ok]
emqttd session supervisor is starting...[ok]
emqttd wsclient supervisor is starting...[ok]
emqttd broker is starting...[ok]
emqttd alarm is starting...[ok]
emqttd mod supervisor is starting...[ok]
emqttd bridge supervisor is starting...[ok]
emqttd access control is starting...[ok]
emqttd system monitor is starting...[ok]
dashboard listen on 0.0.0.0:18083 with 4 acceptors.
mqtt listen on 0.0.0.0:1883 with 16 acceptors.
mqtts listen on 0.0.0.0:8883 with 4 acceptors.
http listen on 0.0.0.0:8083 with 4 acceptors.
Erlang MQTT Broker 2.0 is running now
Eshell V7.3  (abort with ^G)

4. 退出console模式,后台启动

执行:Ctrol+C,a 退出console

执行:./bin/emqttd start 后台启动emqttd

执行:./bin/emqttd_ctl status 检查启动状态

结果:

Node 'emqttd@127.0.0.1' is started
emqttd 2.0 is running

三、测试

使用MQTTLens进行发布订阅

1. 新建连接

162301_bFI1_2319290.png

2. 添加订阅

162605_zejz_2319290.png

3. 发布消息

162744_TbHf_2319290.png

转载于:https://my.oschina.net/u/2319290/blog/741088

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值