emqttd配置_emqttd学习教程(一):emqttd安装与部署-Go语言中文社区
emqttd学习笔记目录:
一、简介
emqttd(Erlang MQTT Broker)是采用Erlang语言开发的开源MQTT消息服务器。Erlang/OTP是出色的软实时(Soft-Realtime)、低延时(Low-Latency)、分布式(Distributed)的语言平台。MQTT是轻量的(Lightweight)、发布订阅模式(PubSub)的物联网消息协议。
emqttd设计目标是承载移动终端或物联网终端大量的MQTT连接,并实现在大量终端间快速低延时(Low-Latency)消息路由:
稳定承载大规模的MQTT客户端连接,单服务器节点支持50万到100万连接。
分布式节点集群,快速低延时的消息路由,单集群支持1000万规模的路由。
消息服务器内扩展,支持定制多种认证方式、高效存储消息到后端数据库。消息服务器内扩展,支持定制多种认证方式、高效存储消息到后端数据库。
完整支持MQTT V3.1.1协议,扩展支持WebSocket、CoAP或私有TCP等多协议。完整支持MQTT V3.1.1协议,扩展支持WebSocket、CoAP或私有TCP等多协议。
二、安装
1、从官网http://emqtt.com/downloads下载稳定版本的emqttd;
2、将下载的压缩包解压;
[root@localhost test]# unzip emqttd-centos7-v2.3.11.zip
3、cd进入到emqttd/etc/目录,修改emq.conf的参数,如下几项去掉注释,修改如下:
listener.tcp.internal.rate_limit = 100000,10000 //内部连接带宽迸发数 和平均数 (KB)
listener.tcp.external.rate_limit = 100000,10000 //外部连接带宽迸发数 和平均数 (KB)
log.syslog.level = debug //系统日志级别
log.console = file //console 日志指向文件
log.console.size = 10485760 //console 日志文件大小
log.console.count = 10 //console 日志回滚大小
mqtt.allow_anonymous = false //不开启匿名
4、cd进入到emqttd/bin目录下,控制台调试模式启动,检查emqttd是否可正常启动;
[root@localhost test]# cd emqttd/bin/
[root@localhost bin]# ./emqttd console
启动成功后会有如下打印:
starting emqttd on node 'emq@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 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]
emqttd 2.3.11 is running now
Eshell V9.0 (abort with ^G)
(emq@127.0.0.1)1> Load emq_mod_presence module successfully.
dashboard:http listen on 0.0.0.0:18083 with 4 acceptors.
mqtt:tcp listen on 127.0.0.1:11883 with 4 acceptors.
mqtt:tcp listen on 0.0.0.0:1883 with 16 acceptors.
mqtt:ws listen on 0.0.0.0:8083 with 4 acceptors.
mqtt:ssl listen on 0.0.0.0:8883 with 16 acceptors.
mqtt:wss listen on 0.0.0.0:8084 with 4 acceptors.
mqtt:api listen on 0.0.0.0:8080 with 4 acceptors.
5、CTRL+c关闭控制台,使用守护进程模式启动:
[root@localhost bin]# ./emqttd start
emqttd 2.3.11 is started successfully!
[root@localhost bin]#
6、查看运行状态:
[root@localhost bin]# ./emqttd_ctl status
Node 'emq@127.0.0.1' is started
emqttd 2.3.11 is running
7、停止服务器:
[root@localhost bin]# ./emqttd stop
ok
三、管理
emqttd消息服务器启动后,会默认加载Dashboard插件,启动Web管理控制台。用户可通过Web控制台, 查看服务器运行状态、统计数据、客户端(Client)、会话(Session)、主题(Topic)、订阅(Subscription)。
控制台地址: http://127.0.0.1:18083,默认用户: admin,密码:public (127.0.0.1需要修改为自己本机部署的服务器地址)
参考文章:http://emqtt.com/docs/v1/install.html
emqttd配置_emqttd学习教程(一):emqttd安装与部署-Go语言中文社区相关推荐
- emqttd配置_emqttd学习教程(二):emqttd配置说明
一.配置文件说明 emqttd消息服务器通过 etc/ 目录下配置文件进行设置,主要配置文件包括: 配置文件说明 etc/emq.conf消息服务器配置文件 etc/acl.conf默认ACL规则配置 ...
- centos6 yum快速安装mysql_centos6.10 yum安装mysql 5.6-Go语言中文社区
一.检查系统是否安装其他版本的MYSQL数据 #yum list installed | grep mysql #yum -y remove 文件名 二.安装及配置 # wget http://rep ...
- linux mcrypt扩展,Linux下php安装mcrypt扩展-Go语言中文社区
说明: 操作系统:CentOS 5.x 64位 已安装php版本:php-5.4.4 已安装php路径:/usr/local/php 实现目的: 在不影响网站访问的情况下,重新编译php,增加对mcr ...
- linux自动化安装linux系统,Linux下—自动化boot引导安装linux系统安装-Go语言中文社区...
系统光盘中isolinux目录列表 1.solinux.bin:光盘引导程序,在mkisofs的选项中需要明确给出文件路径,这个文件属于SYSLINUX项目 2.isolinux.cfg: isoli ...
- centos下安装mysql选什么版本_CentOS 7 安装MySQL 5.7 或安装指定版本MySQL-Go语言中文社区...
1 摘要 目前(2019)年,MySQL 的最新版本为 MySQL 8.0 ,然而很多项目中依然使用的是 MySQL 5.7,个人开发环境中为了和线上项目数据库保持一致,也需要安装相同版本的 MySQ ...
- motan yar php,motan学习笔记 六 opentracing Brave+zipkin实现-Go语言中文社区
前面我们学习了,opentracing的接口定义 本文来学习motan用filter 来拦截请求,并用brace来实现,上报数据到zipkin zipkin是什么 本文主要讲brace 如何实现ope ...
- linux内核字符驱动设备,Linux学习笔记——linux内核字符设备驱动-Go语言中文社区...
尝试在树莓派安装的raspbian系统上进行linux字符设备驱动 1.更新安装kernel header源码 sudo apt-get update sudo apt-get install ras ...
- 电脑可以同时装python2和3吗_在同一台电脑上同时安装Python2和Python3-Go语言中文社区...
在同一台电脑上同时安装Python2和Python3 目前Python的两个版本Python2和Python3同时存在,且这两个版本同时在更新与维护. 到底是选择Python2还是选择Python3, ...
- 如何高效率学习R?[转自微信:R语言中文社区]
学R主要在于5点三阶段: 第一阶段有一点: 基础的文件操作(read.*, write.*).数据结构知识,认识什么是数据框(data.frame).列表(list).矩阵(matrix).向量(ve ...
最新文章
- LeetCode--055--跳跃游戏(java)
- IEnumeratorTItem和IEnumerator Java 抽象类和普通类、接口的区别——看完你就顿悟了...
- 最全三大框架整合(使用映射)——数据库资源文件jdbc.properties
- 折线图表android,Android 折线图表MPAndroidChart的实现
- JavaScript 专题之函数柯里化
- 我恋爱了,对象是纸片人
- P3146 [USACO16OPEN]248 G(python3实现)
- 密钥生成并配置_如何在 CentOS 8 上设置 SSH 密钥
- Kotlin入门(3)基本变量类型的用法
- Hive远程模式安装指导
- java中的T extends Comparable ? super T
- 永久删除掉qq安全防护进程q盾
- 信号检测与估计理论pdf
- RubyOnRails环境搭建
- acs cisco 查看log_Cisco ASA 5510 防火墙 配置笔记
- freemyapps 推荐链接
- 计算机主机内部数据线,机箱内的各种线缆安装步骤(图文)
- RPA之家视频讲解RPA-3
- 矩阵论笔记(七)——矩阵的微分和积分
- 户外耳机品牌哪个好、最新的户外耳机品牌排行